Home        Store        Docs        Blog

BAR30 sensor with SSD1306 oled controller via i2c

Hi!

I would like to use this config with a Wemos D1 ESP-Wroom-02 board.
I’ve soldered the SDA/SCL connectors to the esp direcly from bar30. Separately the oled and the bar30 sensor works fine. I mean same breadboard wiring and different example codes.
When I would like to init the oled and the sensor from one code I cannot. If I initialize the oled first ( display.init(); // Initialise the display ) I’ve got the sensor error messages ( Are SDA/SCL connected correctly? )
When I initialize the sensor first the sensor works but there is no oled display.

I use the SSD1306Brzo.h library for the oled display.

Any suggession?

Thank you!

Hi,

This’ll only happen if both display and bar30 shares the same I²C ID (0x76), what is the ID of your display ?

hi!

I initialize the oled with this line:
SSD1306Brzo display(0x3c, 5, 4); // Initialize OLED display

I think the address of the oled is: 0x3c