Note

This is the documentation for the latest development branch and may refer to features that are not available in released versions. If you are looking for the documentation for a specific release, use the drop-down menu on the left and select the desired version.

I2C SSD1306 Example

I2C SSD1306 Example#

Overview#

This sample drives an SSD1306 OLED panel over I2C.

Source file:

src/rtsmart/examples/peripheral/i2c_ssd1306/test_i2c_ssd1306.c

Sample Behavior#

  • initialize the display

  • draw a checkerboard test pattern

  • refresh the screen

Key APIs#

  • drv_fpioa_set_pin_func()

  • drv_i2c_inst_create() / drv_i2c_inst_destroy()

  • drv_i2c_transfer()

Build and Run#

cd src/rtsmart/examples/peripheral/i2c_ssd1306
make
./test_i2c_ssd1306

Notes#

If your board uses different pins, bus numbering, or the 0x3D address, update the source first.

Comments list
Comments
Log in