mirror of https://github.com/arendst/Tasmota.git
Created PlatformIO CLI (markdown)
parent
1dd385fd82
commit
6e88eaf481
|
@ -0,0 +1,44 @@
|
||||||
|
How to flash the Tasmota firmware onto a device using the `platformio` command line interface on Linux. This manual was tested on Ubuntu 17.10.
|
||||||
|
|
||||||
|
# Prerequisites
|
||||||
|
## Install Python and PIP
|
||||||
|
```
|
||||||
|
sudo apt-get install python-pip
|
||||||
|
```
|
||||||
|
|
||||||
|
## Install PlatformIO CLI
|
||||||
|
```
|
||||||
|
sudo pip install -U platformio
|
||||||
|
```
|
||||||
|
|
||||||
|
## Download the Sonoff-Tasmota source code
|
||||||
|
|
||||||
|
Either download the latest Tasmota release Source code from https://github.com/arendst/Sonoff-Tasmota/releases and extract it or clone the Git repository:
|
||||||
|
```
|
||||||
|
git clone https://github.com/arendst/Sonoff-Tasmota.git
|
||||||
|
```
|
||||||
|
|
||||||
|
## Select the environment
|
||||||
|
Edit the file `platformio.ini` and uncomment one of the `env_default` lines by removing the `;`, eg.:
|
||||||
|
```
|
||||||
|
; *** Uncomment one of the lines below to build/upload only one environment
|
||||||
|
env_default = sonoff
|
||||||
|
;env_default = sonoff-CN
|
||||||
|
;env_default = sonoff-DE
|
||||||
|
;env_default = sonoff-ES
|
||||||
|
;env_default = sonoff-FR
|
||||||
|
;env_default = sonoff-IT
|
||||||
|
;env_default = sonoff-NL
|
||||||
|
;env_default = sonoff-PL
|
||||||
|
;env_default = sonoff-minimal
|
||||||
|
;env_default = sonoff-ds18x20
|
||||||
|
```
|
||||||
|
|
||||||
|
# Compile and upload
|
||||||
|
Once all the prerequisites are in place compiling and uploading is one simple command. Execute this from within the `Sonoff-Tasmota` source code directory:
|
||||||
|
```
|
||||||
|
platformio run --target upload --upload-port /dev/ttyXYZ
|
||||||
|
```
|
||||||
|
Just make sure to replace `/dev/ttyXYZ` with [the actual serial port](https://unix.stackexchange.com/questions/144029/command-to-determine-ports-of-a-device-like-dev-ttyusb0) your device is connected to.
|
||||||
|
|
||||||
|
Depending on your configuration your user account [may need to be in the `dialout` group](https://askubuntu.com/questions/112568/how-do-i-allow-a-non-default-user-to-use-serial-device-ttyusb0).
|
Loading…
Reference in New Issue