Skip to content

Commit 558e3d0

Browse files
committed
Merge branch 'patch-2' of https://github.com/ivankravets/Arduino into ivankravets-patch-2
2 parents 9a4dc26 + 94fd033 commit 558e3d0

File tree

1 file changed

+32
-2
lines changed

1 file changed

+32
-2
lines changed

doc/platformio.md

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ platformio boards espressif
2828
# Initialise base project
2929
#
3030
platformio init --board %TYPE%(see above)
31+
# for example, initialise project for ESP8266 ESP-12E board (NodeMCU)
32+
platformio init --board esp12e
3133

3234
# The next files/directories will be created in myproject
3335
# platformio.ini - Project Configuration File. |-> PLEASE EDIT ME <-|
@@ -39,16 +41,44 @@ platformio init --board %TYPE%(see above)
3941
- Place your source code to `src` directory
4042
- Build/Upload project
4143

42-
```
44+
```bash
4345
# process/build project
4446
platformio run
4547

4648
# build+upload firmware
4749
platformio run --target upload
50+
```
51+
52+
## OTA firmware uploading
4853

49-
# build+upload firmware via OTA
54+
There are 2 options:
55+
56+
- Directly specify `--upoad-port` in command line
57+
```bash
5058
platformio run --target upload --upload-port IP_ADDRESS_HERE
5159
```
60+
- Specify [upload_port](http://docs.platformio.org/en/latest/projectconf.html#upload-port) option in `platformio.ini`
61+
```ini
62+
[env:***]
63+
...
64+
upload_port = IP_ADDRESS_HERE
65+
```
66+
67+
### Authentication and upload options
68+
69+
You can pass additional options/flags to OTA uploader using [upload_flags](http://docs.platformio.org/en/latest/projectconf.html#upload-flags) option in `platformio.ini`
70+
```ini
71+
[env:***]
72+
upload_flags = --port=8266
73+
```
74+
75+
Availalbe flags
76+
- `--port=ESP_PORT` ESP8266 ota Port. Default 8266
77+
- `--auth=AUTH` Set authentication password
78+
- `--spiffs` Use this option to transmit a SPIFFS image and do not flash the module
79+
80+
For the full list with availalbe options please run this command `~/.platformio/packages/framework-arduinoespressif/tools/espota.py -h`.
81+
5282

5383
## IDE Integration
5484
In addition, PlatformIO [can be integrated into the popular IDEs](http://docs.platformio.org/en/latest/ide.html). For example, initialise project for Espressif ESP8266 ESP-01 board and Eclipse IDE

0 commit comments

Comments
 (0)