The OLD brick contains a 0.96 inch SSD1306 OLED display. The OLD brick has two I2C ports (left and right) for communication with the other I2Bricks
| | |
#Example Python code to test OLD brick. OLD is connected to ARD.
from I2Brick import *
port = I2Brick('COM4') #Windows: Initialize serial communication with I2Bricks
#port = I2Brick('/dev/ttyUSB0') #Linux: Initialize serial communication with I2Bricks
print(ard(port)) #test communication between ARD and PC
old(port,0,'') #clear screen
old(port,1,'test line 1') # write to the first line'test line 1'
old(port,2,' test line 2') # write to the second line' test line 2'
old(port,3,' test line 3') # write to the third line' test line 3'
old(port,4,' test line 4') # write to the fourth line' test line 4'
port.close()
|