khalido.org

every blog needs subheader text

Lilygo ttgo t5

posted tagged: iot

Notes on a lilygo eink board, which didn’t get very far, but interesting nonetheless.

Some takeways: a small eink board isn’t that useful, no wonder supermarkets are using them for pricing tags. For home use, its better to go big, something like the pimoroni eink display which have built in micropython drivers.

the board

TTGO T5 V2.3 Wireless WiFi Basic Wireless Module ESP-32 esp32 2.13 Inch ePaper Display Development board.

  • SKU: H239, github
  • Model DEPG0213BN
  • ESP32-D0WDQ6 (revision 1)
  • WiFi, BT, Dual Core, 240MHz, Crystal is 40MHz

esptool.py --port /dev/ttyUSB1 chip_id tells us:

Chip is ESP32-D0WDQ6 (revision 1)
Features: WiFi, BT, Dual Core, 240MHz

I downloaded the latest stable generic micropython ESP-IDF v4.x firmware. Flash it by: (assuming board is on ttyUSB1)

esptool.py --chip esp32 --port /dev/ttyUSB1 erase_flash
esptool.py --chip esp32 --port /dev/ttyUSB1 --baud 460800 write_flash -z 0x1000 esp32-idf4-20200902-v1.13.bin

So now micropython is running on the board.

An easier way to do the above is to use Mu, which has a flasher built it.

Copy files

Mu-editor has a built in file manager but it wasn’t working on my board, so I went with ampy.

Install that by: pip install adafruit-ampy then find the port the board is using.

On a mac this lists all the serial ports in use: ls -l /dev/tty.*

On my machine I got /dev/tty.usbserial-1420, so ampy basics is:

  • list files: ampy --port /dev/cu.usbserial-1420 ls
  • put a file on the board: ampy --port /dev/cu.usbserial-1420 put config.py
  • get a file: ampy --port /dev/cu.usbserial-1420 get config.py
  • delete: ampy --port /dev/cu.usbserial-1420 rm config.py

the display

This board comes with a 2.13 inch eink display.

todo: make it work!

resources

Micropython executes boot.py on startup, then runs main.py if found. So my code should go inside a main.py file. Mu should be able to see and write to the board, but its grayed out.

todo: find a easy solution to write files to the board.