Skip to main content

OLED Node

This node supports the Adafruit SSD1306 multi-line display device attached to the robot. This device is supported by the Adafruit-SSD1306 package:

olednode.py
loading...

The hardware itself is an I2C device. The Adafruit package manages the I2C interface and provides high level methods that enable images to be sent to the device for display.

The main operation supported by the node is the system-status event. When this event is received, the status data is used to build a string and passed to the method display_text to display the string on the device:

Handle System Status
loading...

In the display method, the text is written to an ImageDraw surface and this image is then sent to the OLED device:

Display Text
loading...