ESP32 configuration and scripts.
Hardware - Freenove ESP32-WROVER dev board. Check espressif documentation if you
have a different board and modify MICROPYTHON_BINARY environment variable(.env file will be created as part of the make init target) accordingly.
Ubuntu 20.04 as host OS, check documentation for CH340 installation instructions for your system.
CLI tools: direnv, git, poetry and pre-commit.
You can use this playbook for automated tools installation.
git clone [email protected]:cachuperia/freenove-esp32.git
cd freenove-esp32
make init
direnv allow- Connect dev board to the USB port, find port name with the help of
make find-portcommand and replaceESP32_PORTvalue in the.envfile. - Open
src/freenove_esp32/chip/cfg.pyfile and configure variables. - Write
MicroPythonbinary and code(src/freenove_esp32/chipfolder) to the chip with the help ofmake esp32-initcommand. Logs can be downloaded with the help ofmake get-logscommand.
Execute make help for list of all available commands.
poetry shell # activate venv
mpremote # connect to the serial terminal
# When you see the blank screen, hit Enter and you should be able to get the REPL prompt.
# Press `Ctrl-D` to initiate a soft reboot or `Ctrl-]` for disconnectpoetry shell # activate venv
mpremote exec "import network; wlan = network.WLAN(network.STA_IF); wlan.active(True); print(wlan.scan())"For more options, check mpremote documentation. Shortcut for upload all files from the src/freenove_esp32/chip folder to the MicroPython root folder - make write-code
You can start local WebREPL client this way:
git clone https://github.com/micropython/webrepl.git
cd webrepl
firefox webrepl.htmlUse Conventional Commits message style.
Release can be triggered by commit with feat or fix prefix. Check GitHub workflow for details.