ESP32 NodeMCU-ESP-32S board vs SSD1305 OLED display - 'class TwoWire' has no member named 'end'

Hello!

I want use my SSD1305 OLED display (2.23 inch OLED) with ESP32 ( NodeMCU-ESP-32S), but i get error if i try compile the simple display print example code.

I know there is a alternate display library called u8g2 (tested and working), but this library is too slow to use to my project.

#include <Wire.h>
#include <SPI.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1305.h>

#define OLED_CLK 13
#define OLED_MOSI 11
#define OLED_CS 10
#define OLED_DC 8
#define OLED_RST 9

#define WIDTH     128
#define HEIGHT     32

Adafruit_SSD1305 display(WIDTH, HEIGHT, &SPI, OLED_DC, OLED_RST, OLED_CS, 4000000UL);

void setup() {
display.begin(0x3C);
display.clearDisplay();
}

void loop() {
display.print("TEST");
}

I get this error:

C:\Users\X\Documents\Arduino\libraries\Adafruit_BusIO\Adafruit_I2CDevice.cpp: In member function 'void Adafruit_I2CDevice::end()':

C:\Users\X\Documents\Arduino\libraries\Adafruit_BusIO\Adafruit_I2CDevice.cpp:44:10: error: 'class TwoWire' has no member named 'end'

_wire->end();

      ^

exit status 1

Anybody have idea what is the problem, why i have trouble with compile? and/or how can i compile the code with the ssd1305 library?

thanks for any help

I will take a SWAG and say It appears you are getting the wrong library. In my code with speciality libraries I put them in the folder with the sketch, just the .h and .cpp files unless more are required. I then change the to "name". Nice part next year when I want to change something I do not have to worry about a library change.

1 Like

Yes, i have checked the library manager and filtered for aviable for update librarys and after few lib update compile was successfully. Tahnk you for the help.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.