How to flash MicroPython onto the ESP32
11-23-2017
INSTALLING MICROPYTHON
------------------------
You can compile your own firmware by going to:
https://github.com/micropython/micropython-esp32
Find the port for ESP32 at something like
/ports/esp32/README.md
and read the guide. MicroPython can be a pain in the ass setting up
dependencies and compiling.
LETS JUST:
Get the latest MicroPython ESP32 firmare:
http://micropython.org/download
$ sudo apt install python-pip
$ sudo pip install --upgrade pip
$ sudo pip install esptool --upgrade
Plug in your ESP32 and search for the port it is on:
$ ls /dev/tty*
It should give you something like /dev/ttyUSB0
If you are flashing the board for the first time, erase it:
$ esptool.py --port /dev/ttyUSB0 erase_flash
Then flash the firmware you downloaded:
$ esptool.py --chip esp32 --port /dev/ttyUSB0 write_flash -z 0x1000 esp32-20171114-v1.9.2-443-g236297f4.bin
You just used the esptool.py program to put the firmware at the starting address of 0x1000
Establish a connection with your board using the following command:
$ minicom --baudrate 115200 --device /dev/ttyUSB0
or maybe
$ cu -l /dev/ttyUSB0 -s 115200
You may have to press the reset button on your microcontroller.
Now you have a Python Interpreter.
Language or Platform: None
Code:
Back