Skip to content

v0.1.4

Choose a tag to compare

@nuraci nuraci released this 06 Nov 08:11

ESP32-4848S040 only: adjustable brightness, and a weather station. The other boards are unchanged: use v0.1.0.

  • Brightness: display_driver.backlight(percent) is now PWM on GPIO 38, no longer on/off. The display starts at 70%. Below about 30% the panel can no longer be read.
  • weather.py: current weather, wind and 5 days of forecast from Open-Meteo (no key, free for non-commercial use), with icons drawn by LVGL. Setup on the touchscreen: WiFi, place, style, brightness, and dimming at night between two times you choose. Copy it to the board, or save it as main.py to start at power-on.
  • SD card: machine.SDCard works after import display_driver. weather.py saves its settings there, or in the internal flash without a card.
import machine, os, display_driver
os.mount(machine.SDCard(slot=2, sck=48, miso=41, mosi=47, cs=42, freq=10_000_000), "/sd")

Good to know: weather.py keeps the WiFi password in clear in its settings file, and uses plain HTTP. The fonts have no accented letters, so "Forlì" shows as "Forli".

Tested on hardware: brightness by eye and after soft resets, t05_perf.py, t07_audio.py, weather.py by hand with an SD card.

Flash, on a board that had other firmware (this erases everything on it, your files too):

esptool.py --chip esp32s3 -p <port> erase_flash
esptool.py --chip esp32s3 -p <port> -b 460800 write_flash 0x0 ESP32_4848S040-v0.1.4.bin

Without erase_flash the board can stop at boot with "The filesystem appears to be corrupted". To update a board already on v0.1.0 or later and keep its files, skip erase_flash.