Skip to content

Commit 8cc111e

Browse files
committed
Add OTA support for ARDUINO_NICLA_VISION
1 parent 6cfab47 commit 8cc111e

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

src/AIoTC_Config.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@
102102
#define OTA_STORAGE_SSU (0)
103103
#endif
104104

105-
#if defined(ARDUINO_PORTENTA_H7_M7)
105+
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_NICLA_VISION)
106106
#define OTA_STORAGE_PORTENTA_QSPI (1)
107107
#else
108108
#define OTA_STORAGE_PORTENTA_QSPI (0)

src/ArduinoIoTCloudTCP.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ int ArduinoIoTCloudTCP::begin(bool const enable_watchdog, String brokerAddress,
151151
#endif /* AVR */
152152

153153
#if OTA_ENABLED && !defined(__AVR__)
154-
#if defined(ARDUINO_PORTENTA_H7_M7)
154+
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_NICLA_VISION)
155155
/* The length of the application can be retrieved the same way it was
156156
* communicated to the bootloader, that is by writing to the non-volatile
157157
* storage registers of the RTC.
@@ -288,7 +288,7 @@ int ArduinoIoTCloudTCP::begin(bool const enable_watchdog, String brokerAddress,
288288
}
289289
#endif /* OTA_STORAGE_SNU */
290290

291-
#if defined(ARDUINO_NANO_RP2040_CONNECT)
291+
#if defined(ARDUINO_NANO_RP2040_CONNECT) || defined(ARDUINO_NICLA_VISION)
292292
_ota_cap = true;
293293
#endif
294294

@@ -826,7 +826,7 @@ void ArduinoIoTCloudTCP::onOTARequest()
826826
_ota_error = rp2040_connect_onOTARequest(_ota_url.c_str());
827827
#endif
828828

829-
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4)
829+
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4) || defined(ARDUINO_NICLA_VISION)
830830
_ota_error = portenta_h7_onOTARequest(_ota_url.c_str());
831831
#endif
832832
}

src/utility/ota/OTA-portenta-h7.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
a commercial license, send an email to [email protected].
1616
*/
1717

18-
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4)
18+
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4) || defined(ARDUINO_NICLA_VISION)
1919

2020
/******************************************************************************
2121
* INCLUDE
@@ -87,4 +87,4 @@ int portenta_h7_onOTARequest(char const * ota_url)
8787
NVIC_SystemReset();
8888
}
8989

90-
#endif /* defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4) */
90+
#endif /* defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4) || defined(ARDUINO_NICLA_VISION) */

src/utility/ota/OTA.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ int samd_onOTARequest(char const * ota_url);
6262
int rp2040_connect_onOTARequest(char const * ota_url);
6363
#endif
6464

65-
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4)
65+
#if defined(ARDUINO_PORTENTA_H7_M7) || defined(ARDUINO_PORTENTA_H7_M4) || defined(ARDUINO_NICLA_VISION)
6666
int portenta_h7_onOTARequest(char const * ota_url);
6767
#endif
6868

0 commit comments

Comments
 (0)