You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+36-27Lines changed: 36 additions & 27 deletions
Original file line number
Diff line number
Diff line change
@@ -3,16 +3,17 @@
3
3
4
4
This library allows you to update sketches on your board over WiFi or Ethernet.
5
5
6
-
The library is a modification of the Arduino WiFi101OTA library. For more information about how to use this library please visit
7
-
https://www.arduino.cc/en/Reference/WiFi101OTA
6
+
The library is a modification of the Arduino WiFi101OTA library.
8
7
9
-
## Supported microcontrollers
8
+

9
+
10
+
## Supported micro-controllers
10
11
11
12
* ATmega AVR with at least 64 kB of flash (Arduino Mega, [MegaCore](https://github.com/MCUdude/MegaCore) MCUs, MightyCore 1284p and 644)
12
13
* Arduino SAMD boards like Zero, M0 or MKR
13
14
* nRF5 board supported by [nRF5 core](https://github.com/sandeepmistry/arduino-nRF5).
14
15
15
-
## Supported libraries
16
+
## Supported networking libraries
16
17
17
18
* Ethernet library - shields and modules with Wiznet 5100, 5200 and 5500 chips
18
19
* WiFi101 - WiFi101 shield and MKR 1000
@@ -26,31 +27,29 @@ UIPEthernet, WiFiSpi and WiFi library don't support UDP multicast for MDNS, so A
26
27
27
28
WiFiEsp library for esp8266 with AT firmware failed tests and there is no easy fix.
28
29
29
-
## ATmega support
30
+
## Installation
30
31
31
-
The size of networking library and SD library limit the use of ArduinoOTA library to ATmega MCUs with at least 64 kB flash memory. There are other network upload options for here excluded ATmega328p ([Ariadne bootloader](https://github.com/loathingKernel/ariadne-bootloader) for Wiznet chips, [WiFiLink firmware](https://github.com/jandrassy/arduino-firmware-wifilink) for the esp8266).
32
+
The library is in Library Manager of the Arduino IDE.
32
33
33
-
For upload over InternalStorage Optiboot bootloader with [`copy_flash_pages` function](https://github.com/Optiboot/optiboot/pull/269) is required. Arduino AVR package doesn't use Optiboot for Arduino Mega. For Arduino Mega you can download [my boards definitions](https://github.com/jandrassy/my_boards) and use it [to burn](https://arduino.stackexchange.com/questions/473/how-do-i-burn-the-bootloader) the modified Optiboot and to upload sketches to your Mega over USB and over network.
34
+
Arduino SAMD boards (Zero, M0, MKR) are supported 'out of the box'.
34
35
35
-
For SDStorage a 'SD bootloader' is required to load the uploaded file from the SD card. There is no good SD bootloader. 2boots works only with not available old types of SD cards and zevero/avr_boot doesn't yet support USB upload of sketch. The SDStorage was tested with zevero/avr_boot. The ATmega_SD example shows how to use this ArduinoOTA library with SD bootloader.
36
+
For nRF5 boards two lines need to be added to platform.txt file of the nRF5 Arduino package (until the PR that adds them is accepted and included in a release). Only nRF51 was tested until now. For details scroll down.
36
37
37
-
To use remote upload from IDE with SDStorage or InternalStorage, you must add some lines to platform.txt file of the boards package. Packages are located in ~/.arduino15/packages/ on Linux and %userprofile%\AppData\Local\Arduino15\packages\ on Windows (AppData is a hidden folder).
38
+
ATmega boards require to flash a modified Optiboot bootloader for flash write operations. Details are below.
38
39
39
-
The upload over ArduinoOTA library requires upload of .bin file. To set Arduino IDE to create a .bin file add following lines after existing similar lines:
The size of networking library and SD library limit the use of ArduinoOTA library to ATmega MCUs with at least 64 kB flash memory.
45
43
46
-
To configure the network upload tool in IDE add following lines to platform.txt file at the end of section "AVR Uploader/Programmers tools".
44
+
*There are other network upload options for here excluded ATmega328p ([Ariadne bootloader](https://github.com/loathingKernel/ariadne-bootloader) for Wiznet chips, [WiFiLink firmware](https://github.com/jandrassy/arduino-firmware-wifilink) for the esp8266).*
For upload over InternalStorage, Optiboot bootloader with [`copy_flash_pages` function](https://github.com/Optiboot/optiboot/pull/269) is required. Arduino AVR package doesn't use Optiboot for Arduino Mega. For Arduino Mega you can download [my boards definitions](https://github.com/jandrassy/my_boards) and use it [to burn](https://arduino.stackexchange.com/questions/473/how-do-i-burn-the-bootloader) the modified Optiboot and to upload sketches to your Mega over USB and over network.
52
47
53
-
The Arduino AVR core has this lines but the tools.avrdude.upload.network_pattern is different (for Yun). Change it to this version. The upload tool is installed with Arduino AVR core package. At least version 1.2 of the arduinoOTA tool is required.
48
+
For SDStorage a 'SD bootloader' is required to load the uploaded file from the SD card. There is no good SD bootloader. 2boots works only with not available old types of SD cards and zevero/avr_boot doesn't yet support USB upload of sketch. The SDStorage was tested with zevero/avr_boot. The ATmega_SD example shows how to use this ArduinoOTA library with SD bootloader.
49
+
50
+
To use remote upload from IDE with SDStorage or InternalStorage, copy platform.local.txt from extras/avr folder, next to platform.txt in the boards package used (Arduino-avr or MCUdude packages). Packages are located in ~/.arduino15/packages/ on Linux and %userprofile%\AppData\Local\Arduino15\packages\ on Windows (AppData is a hidden folder). The platform.local.txt contains a line to create a .bin file and a line to override tools.avrdude.upload.network_pattern, because in platform.txt it is defined for Yun.
51
+
52
+
The IDE upload tool is installed with Arduino AVR core package. At least version 1.2 of the arduinoOTA tool is required. For upload from command line without IDE see the command template in extras/avr/platform.local.txt.
54
53
55
54
## nRF5 support
56
55
@@ -60,18 +59,28 @@ If SoftDevice is not used, the sketch is written from address 0. For write to ad
60
59
61
60
For SD card update use [SDUnRF5 library](https://github.com/jandrassy/SDUnRF5).
62
61
63
-
To use remote upload from IDE, add following lines to sandeepmistry/hardware/nRF5/0.6.0/platform.txt at the end of section "OpenOCD sketch upload":
To use remote upload from IDE, add lines from [this PR](https://github.com/sandeepmistry/arduino-nRF5/pull/327/commits/4b70ae7207124bd92afa14e562e4f0c4d931220d) to sandeepmistry/hardware/nRF5/0.6.0/platform.txt at the end of section "OpenOCD sketch upload":
69
63
70
-
If you use SoftDevice, stop BLE before applying update. Use `OTEthernet.beforeApply` to register a callback function. For example in setup `ArduinoOTA.beforeApply(shutdown);` and add the function to to sketch:
64
+
If you use SoftDevice, stop BLE before applying update. Use `ArduinoOTA.beforeApply` to register a callback function. For example in setup `ArduinoOTA.beforeApply(shutdown);` and add the function to to sketch:
71
65
72
66
```
73
67
void shutdown() {
74
68
blePeripheral.end();
75
69
}
76
70
```
71
+
## Boards tested
72
+
73
+
* SAMD
74
+
- Arduino MKR Zero
75
+
- Crowduino M0 SD
76
+
* nRF5
77
+
- Seeed Arch Link
78
+
* ATmega
79
+
- Arduino Mega
80
+
- Badio 1284p
81
+
82
+
## Contribution
83
+
84
+
Please report tested boards.
77
85
86
+
Other ARM based MCUs could be added with code similar to SAMD and nRF5.
0 commit comments