This driver is a basic implementation to interface SSD1306 OLED Display with CH592F MCU over I2C protocol.
A Cube is rendered on the screen after the test is complete. This cube is then bounced indefinitely over the edges of the display with varying velocities.
OLED Test followed by Cube Render:
ssd1306_ch592f.mp4
-
Clone the Repo
git clone https://github.com/ravssh/CH592F-SSD1306
-
Open
/src/ssd1306/renderer.h
& change display resolution & power configuration. -
Build It -
make clean
make
-
Connect the Display to MCU according to the table below
Pin Number OLED Pin 5V VCC GND GND B15 SCK B14 SDA -
Hold the boot button on CH592F and connect it to your PC.
-
Run wchisp info to check if it's detected. We can flash it now.
make flash
This is only a basic implementation. The code is not polished and may cause some unexpected behaviour. There's no support to display fonts or images. Check out fbiego's implementation for LVGL support here.