I am trying to implement text scroll for long text lines on OLED display.
To do that, I need to determine the width of the given text.
I am using the following library and fonts
Code: Select all
import upip
upip.install("micropython-oled")
from oled import Write, SSD1306_I2C
from oled.fonts import ubuntu_mono_15, ubuntu_mono_20
...
display = SSD1306_I2C(WIDTH, HEIGHT, i2c)
d20 = Write(display, ubuntu_mono_20)
d20.text("Herzlich Glückwunsch",0,0)