I know. I know. Dev-board with OLED display is made to use this display, instead of disconnecting it :-).
You wrote about OLED in WiFi LoRa 32 (V2): “can be used to display debugging information, battery power, and other information”. But I need to connect to this Dev-board a much larger display. The original, 0, 96" can work but does not have to. Now I have both displays connected and working, but the larger display is connected via software I2C. So it is very slow.
I do not know if I read the Dev-board pinout diagram well, I do not see the possibility of connecting a second display through the hardware I2C port. But I can be wrong.
Can I “turn off” this 0.96 ‘’ OLED display and use the SPI pins that are now used by it?
But, if the attached code would show me the correct address, which Dev-board pins are marked SDA and SCL? I know that SDA_OLED is GPIO4 and SCL_OLED is GPIO15.
Because you didn’t connect any device on the I2C bus, so can’t get any address feedback. The attached code just show you how to config use another I2C bus.
ESP32 have IO_MUX function, any GPIO can be config to I2C bus.
I even tried on a few free ports. each time in Wire1.begin enter the GPIO to which the second display was connected. When I connect this display to the same GPIO with software I2C , it works.
Thanks for the answer. Exactly. I guess it’s a matter of using the olikraus u8g2 library, not the problems with the Heltec Dev-Board.
As Olikraus writes, his u8g2 library is based on the Arduino Wire library. If I understand correctly when using Wire1, there is no simple way to specify the port numbers to which the display is connected. Unfortunately, my knowledge is too small to change something in .h or .cpp files. I asked olikraus for help, I hope that thanks to his help I will be able to use the second display connected through the hardware I2C.
I have a question about your I2C scanner. Both for Wire and for Wire1, your scanner shows exactly the same address - 0x3C. (I enclose the pictures, so as not to confuse the entries, I added “on Wire” and “on Wire1” to the information displayed by the scanner.)
It seems that connecting two displays to this Dev-board is not easy at all. Here is what olikraus wrote to me:
One precondition for the second I2C interface is a proper definition of WIRE_INTERFACES_COUNT by the ESP32. The value for WIRE_INTERFACES_COUNT must be 2 or higher, denoting, that there is an additional Wire object called “wire1”.
Maybe if I used a different library to operate the second display, connecting it to WiFi LoRa 32 would be easier. However, the u8g2 library has many advantages. I can not find any similar.
I am thinking of changing the LoRa module to one without a display. In order not to change an almost ready, large program, I would need dev-board with ESP32, the option of connecting and charging the battery and - of course - without a display.
In your offer according to the table: