Close

Terminal Example and other Improvements

A project log for EPDiy: 9.7"/6" E-Paper controller

I always wanted a large, affordable E-Ink screen to play around with. This board talks to cheap E-Reader replacement screens with an ESP32.

valentinValentin 06/02/2020 at 18:195 Comments

During the last weeks, various improvements to the software and hardware where made, in part thanks to contributions from the Hackaday community. The highlights include:

The Terminal Example:

What you see here is a (almost) complete terminal (actually a port of the simple terminal from suckless.org), running on the ESP32! Currently, I'm using it to mirror a terminal emulator through `script -f /dev/ttyUSB0`, but I'm working on hooking up a laptop keyboard to make it fully stand-alone!

Discussions

Giovanni wrote 02/01/2021 at 22:47 point

Sorry, I should have mentioned it was x86. I am really just interested in an RTOS capable of window, icon, menu, pointer: https://en.wikipedia.org/wiki/WIMP_(computing)

Some OSes like Contiki have made it work: https://en.wikipedia.org/wiki/Contiki#/media/File:Contiki-avr.png

  Are you sure? yes | no

Valentin wrote 02/02/2021 at 14:45 point

I think there are some graphics frameworks out there for the ESP or Arduino. However, I'm not sure if this controller is suited for running graphical applications. The terminal is only that fast because I can do tiny partial updates. With graphical applications , you'll have to deal with a veery low frame rate.
Currently, update performance is limited by the ESPs external memory bandwith and has limited computational power.
So for a full graphical linux, why not use a hackably e-Book reader?

  Are you sure? yes | no

Giovanni wrote 02/02/2021 at 17:20 point

The goal is to develop a laptop like a solar powered calculator. There are some graphic libraries that have been ported to ESP32, like LVGL: https://blog.lvgl.io/2019-01-31/esp32 

LVGL can work with e-paper like here: https://twitter.com/moddabletech/status/1351753607553507328


One goal is to port applications that do not require a fast refresh rate before apps that require less than 1fps. Something like calculator and word processor, before something like mtPaint:
http://mtpaint.sourceforge.net/

Even for graphical applications like a GPS navigation, some interesting optimizations have been done with 1bit JBIG2:
https://twitter.com/JanDupal/status/1336800693886316545 (even if it requires remote compression)

The Inkplate has a 0.264s refresh rate https://www.crowdsupply.com/e-radionica/inkplate-6
Also a limited early BSD:
https://www.cnx-software.com/2021/01/27/mini-replica-of-dec-pdp-11-computer-runs-2-11-bsd-unix-on-esp32-soc/ 

I've also found some monohrome and ANSI GUI libraries like https://github.com/olikraus/u8g2
https://github.com/Immediate-Mode-UI/Nuklear
a linux-like RTOS running on 4KB of RAM.
https://www.youtube.com/watch?v=EzKcQYxe1M0&feature=emb_title
https://medium.com/@deryugin.denis/how-to-run-opencv-on-stm32-mcu-b581f42b0766
This goes more into saving data on a microcontroller: https://habr.com/ru/company/embox/blog/518258/
"Another option is to reduce the color bit depth to 16 (i.e. 2 bytes), and thus reduce the memory consumption to 256 KB, which can already fit into the main RAM."

A lot of these projects may be geared towards specific use, rather than general purpose, except for maybe Embox, which tries to run complex applications on an RTOS.

While some of these libraries can't be combined, I'm in the process of cataloging various softwares (I sometimes feel like I need to include many of these hyperlinks in this response to help better explain my point), drivers, and e-inks for developing a cross-compatible platform . The goal isn't to make it impossible, but to develop something I might see in my lifetime, even if it adds several layers of arduous complexity. While I do not think the ESP32 can be easily solar powered, the goal is to have a software development platform for low-bit depth displays 1bpp-4bpp that is cross-platform. So I explore which technologies may seek to be adopted towards an compatible platform. Having something like a mobile ITX motherboard would allow various e-ink displays to work with various MCUs on a chip that have support for the display drivers and the RTOS with a lightweight toolkit, like FLTK or DWM. A couple low power boards, https://ambiq.com/apollo4/ and https://www.dialog-semiconductor.com/products/da14695-development-kit-pro seem like they would be low power enough to run on amoprhous solar and allow for a linux OS with e-ink. Over time, the system on a chips (e.g. 5nm) will be lower power and allow for more RAM, so porting the display drivers will at a more developed stage by then. Though by then, it might be possible to have an application processor like the to run on a few uW, less than the amount generated by Panasonic Amorton solar cells. 

  Are you sure? yes | no

Giovanni wrote 02/01/2021 at 00:09 point

Very cool- wondering if it would be possible to run Tiny SliTaz w/FLTK on the ESP32-S2 WROVER (4.5MB RAM):

https://github.com/SliTaz-official/tiny-slitaz (x86 based, needs 4MB RAM minimum)

 https://www.crowdsupply.com/e-radionica/inkplate-10/updates/read-e-books-with-inkplate-10 

  Are you sure? yes | no

Paul wrote 02/01/2021 at 18:57 point

"ESP32" is mentioned nowhere on the website and it's x86 based ... not that it's not possible, but sounds like it would be a whole lot of work ...

  Are you sure? yes | no