espressif8266
¶Espressif Systems is a privately held fabless semiconductor company. They provide wireless communications and Wi-Fi chips which are widely used in mobile devices and the Internet of Things applications.
For more detailed information please visit vendor site.
Name |
Description |
---|---|
Arduino Wiring-based Framework (ESP8266 Core) |
|
Simba Framework |
|
ESP8266 SDK |
|
ESP8266 OTA utility |
|
esptool-ck |
|
Tool to build and unpack SPIFFS images |
|
xtensa-gcc |
Warning
Linux Users:
Ubuntu/Debian users may need to add own “username” to the “dialout”
group if they are not “root”, doing this issuing a
sudo usermod -a -G dialout yourusername
.
Install “udev” rules file 99-platformio-udev.rules (an instruction is located in the file).
Raspberry Pi users, please read this article Enable serial port on Raspberry Pi.
Windows Users: Please check that you have correctly installed USB driver from board manufacturer
Name |
Description |
---|---|
Arduino Wiring-based Framework allows writing cross-platform software to control devices attached to a wide range of Arduino boards to create all kinds of creative coding, interactive objects, spaces or physical experiences. |
|
Simba is an RTOS and build framework. It aims to make embedded programming easy and portable. |
Note
You can list pre-configured boards by platformio boards command or PlatformIO Boards Explorer
For more detailed board
information please scroll tables below by
horizontal.
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
512 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
1024 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
448 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
1024 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
1024 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
448 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
2048 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
512 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
512 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
ID |
Name |
Microcontroller |
Frequency |
Flash |
RAM |
---|---|---|---|---|---|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
|
|
ESP8266 |
80 MHz |
4096 Kb |
80 Kb |
See board_f_cpu option from Project Configuration File platformio.ini
[env:myenv]
; set frequency to 160MHz
board_f_cpu = 160000000L
See board_f_flash option from Project Configuration File platformio.ini. Possible values:
20000000L
26000000L
40000000L
80000000L
[env:myenv]
; set frequency to 80MHz
board_f_flash = 80000000L
Flash chip interface mode. This parameter is stored in the binary image header, along with the flash size and flash frequency. The ROM bootloader in the ESP chip uses the value of these parameters in order to know how to talk to the flash chip.
See board_flash_mode option from Project Configuration File platformio.ini. Possible values:
qio
qout
dio
dout
[env:myenv]
board_flash_mode = qio
You can set custom reset method using upload_resetmethod option from Project Configuration File platformio.ini.
The possible values are:
ck
- RTS controls RESET or CH_PD, DTR controls GPIO0
wifio
- TXD controls GPIO0 via PNP transistor and DTR controls RESET via a capacitor
nodemcu
- GPIO0 and RESET controlled using two NPN transistors as in NodeMCU devkit.
See default reset methods per board.
[env:myenv]
upload_resetmethod = ck
Warning
Please make sure to read ESP8266 Flash layout information first.
The list with preconfigured LD scripts is located in public repository platformio-pkg-ldscripts.
esp8266.flash.512k0.ld
512K (no SPIFFS)
esp8266.flash.512k64.ld
512K (64K SPIFFS)
esp8266.flash.1m64.ld
1M (64K SPIFFS)
esp8266.flash.1m128.ld
1M (128K SPIFFS)
esp8266.flash.1m256.ld
1M (256K SPIFFS)
esp8266.flash.1m512.ld
1M (512K SPIFFS)
esp8266.flash.2m.ld
2M (1M SPIFFS)
esp8266.flash.4m1m.ld
4M (1M SPIFFS)
esp8266.flash.4m.ld
4M (3M SPIFFS)
To override default LD script please use build_flags from Project Configuration File platformio.ini.
[env:myenv]
build_flags = -Wl,-Tesp8266.flash.4m.ld
You can set custom upload speed using upload_speed option from Project Configuration File platformio.ini
[env:myenv]
upload_speed = 9600
Warning
Please make sure to read ESP8266 Flash layout information first.
Initialize project platformio init (if you have not initialized yet)
Create data
folder (it should be on the same level as src
folder)
and put files here. Also, you can specify own location for data_dir
Run buildfs
or uploadfs
target using platformio run --target
command.
To upload SPIFFS image using OTA update please specify upload_port
/
--upload-port
as IP address or mDNS host name (ending with the *.local
).
For the details please follow to Over-the-Air (OTA) update.
By default, will be used default LD Script for the board where is specified SPIFFS offsets (start, end, page, block). You can override it using Custom Flash Size.
Active discussion is located in issue #382.
Firstly, please read What is OTA? How to use it?
There are 2 options:
Directly specify platformio run --upload-port
in command line
platformio run --target upload --upload-port IP_ADDRESS_HERE or mDNS_NAME.local
Specify upload_port
option in Project Configuration File platformio.ini
[env:myenv]
upload_port = IP_ADDRESS_HERE or mDNS_NAME.local
For example,
platformio run -t upload --upload-port 192.168.0.255
platformio run -t upload --upload-port myesp8266.local
You can pass additional options/flags to OTA uploader using
upload_flags
option in Project Configuration File platformio.ini
[env:myenv]
upload_flags = --port=8266
Available flags
--port=ESP_PORT
ESP8266 OTA Port. Default 8266
--auth=AUTH
Set authentication password
--spiffs
Use this option to transmit a SPIFFS image and do not flash
the module
For the full list with available options please run
~/.platformio/packages/framework-arduinoespressif8266/tools/espota.py -h
Usage: espota.py [options]
Transmit image over the air to the esp8266 module with OTA support.
Options:
-h, --help show this help message and exit
Destination:
-i ESP_IP, --ip=ESP_IP
ESP8266 IP Address.
-p ESP_PORT, --port=ESP_PORT
ESP8266 ota Port. Default 8266
Authentication:
-a AUTH, --auth=AUTH
Set authentication password.
Image:
-f FILE, --file=FILE
Image file.
-s, --spiffs Use this option to transmit a SPIFFS image and do not
flash the module.
Output:
-d, --debug Show debug output. And override loglevel with debug.
-r, --progress Show progress output. Does not work for ArduinoIDE
PlatformIO will install the latest Arduino Core for ESP8266 from https://github.com/esp8266/Arduino. The Git should be installed in a system. To update Arduino Core to the latest revision, please use platformio platform update command.
Install Espressif 8266 (Stage) development platform
platformio platform install https://github.com/platformio/platform-espressif8266.git#feature/stage
Set platform to espressif8266_stage
in
Project Configuration File platformio.ini. For example,
[env:nodemcuv2]
platform = espressif8266_stage
board = nodemcuv2
framework = arduino
Try to build project
If you see build errors, then try to build this project using the same
stage
with Arduino IDE
If it works with Arduino IDE but doesn’t work with PlatformIO, please file new issue with attached information:
test project/files
detailed log of build process from Arduino IDE (please copy it from console to http://pastebin.com)
detailed log of build process from PlatformIO Build System ( please copy it from console to http://pastebin.com)
Jan 12, 2017 - Tiest van Gool - OTA: PlatformIO and ESP8266
Sep 12, 2016 - Pedro Minatel - OTA – Como programar o ESP8266 pelo WiFi no platformIO (OTA programming for ESP8266 via Wi-Fi using PlatformIO, Portuguese)
Sep 2, 2016 - Tinkerman Optimizing files for SPIFFS with Gulp
Jul 15, 2016 - Jaime - ESP8266 Mobile Rick Roll Captive Portal
Jun 13, 2016 - Daniel Eichhorn - New Weather Station Demo on Github
Jun 3, 2016 - Daniel Eichhorn - ESP8266: Continuous Delivery Pipeline – Push To Production
May 29, 2016 - Chris Synan - Reverse Engineer RF Remote Controller for IoT!
May 22, 2016 - Pedro Minatel - Estação meteorológica com ESP8266 (Weather station with ESP8266, Portuguese)
May 16, 2016 - Pedro Minatel - Controle remoto WiFi com ESP8266 (WiFi remote control using ESP8266, Portuguese)
May 08, 2016 - Radoslaw Bob - Touch controlled buzzer (Nodemcu ESP8266)
Mar 07, 2016 - Joran Jessurun - Nieuwe wereld met PlatformIO (New world with PlatformIO, Dutch)
Feb 25, 2016 - NutDIY - PlatformIO Blink On Nodemcu Dev Kit V1.0 (ESP 12-E)
Feb 23, 2016 - Ptarmigan Labs - ESP8266 Over The Air updating – what are the options?
Jan 16, 2016 - Dani Eichhorn - ESP8266 Arduino IDE Alternative: PlatformIO
Dec 22, 2015 - Jan Penninkhof - Over-the-Air ESP8266 programming using PlatformIO
Dec 01, 2015 - Tateno Yuichi - ESP8266 を CUI で開発する (Develop a ESP8266 in CUI, Japanese)
See more Articles about us.
All project examples are located in PlatformIO repository Examples for Espressif 8266 platform.