OLED display preventing RAK11310 RP2040 board from starting up

I have an RP2040 based RAK11310 core module that simply won’t start up (meaning never connects over USB) if an OLED display is connected to it. I’ve tried multiple base boards (RAK19003 & RAK19007), multiple OLED displays (multiple versions of OLED displays too), multiple ways of connecting the OLEDs (via pins on base board and via two different QWIIC modules), always the same result. Without the OLED, the board functions perfectly, it connects over USB just fine and the radio works. If I swap the RP2040 core for an nRF52840 core (RAK4631), everything works, the OLED displays info and the radio connects just fine. Other I2C devices, like sensors, work just fine with the RP2040, so I don’t think it’s an I2C issue. I’ve re-flashed the module a couple times to make sure it’s on the latest firmware.

Is this a known or expected behavior? Is there something I need to change in the configuration to get the RP2040 to work with an OLED display? Or should this be working and maybe I have a busted/bugged core module?

Seems related to: [Bug]: SSH1106 (128x64) screen not initialised correctly on RAK11310 · Issue #2985 · meshtastic/firmware · GitHub

Indeed that appears to be the same issue. I can confirm that the issue is also present with the SSD1306 OLED display, in addition to the SSD1106 mentioned in that post.

I can confirm this issue as well.

This issue will probably be fixed in the next release. Or you could try this artifact already: Upload pr3112-firmware-2.2.19.acfb1d8.zip (acfb1) · meshtastic/artifacts@366ce3b · GitHub

1 Like

My RP2040 node isn’t accessible right now, but I will try this out as soon as I can get to it.

I was able to try out that artifact firmware (firmware-rak11310-2.2.19.a91970a.uf2), but it didn’t change the behavior at all. The device still refuses to connect over USB and the OLED display still doesn’t light up. I will wait until the next full release and see if anything changes.

The fix is in the already released version 2.2.19. It seems there is another issue with the RAK11310 (it was tested with a normal Pico). Can you post the serial logs when the device boots with this artifact? Preferably on GitHub.

Not 100% sure exactly how you’re supposed to get the serial log, so please let me know if this is not what you’re looking for. I simply opened up the serial port in putty, hit the reset button, and copied the first few seconds of the output.
This is the output without the OLED display connected:

Ã@INFO  | ??:??:?? 0

//\ E S H T /\ S T / C


DEBUG | ??:??:?? 0 Filesystem files:
DEBUG | ??:??:?? 0  channels.proto (95 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  config.proto (94 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  db.proto (322 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  module.proto (109 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0 Using analog input 26 for battery level
INFO  | ??:??:?? 0 Scanning for i2c devices...
DEBUG | ??:??:?? 0 Scanning for i2c devices on port 1
INFO  | ??:??:?? 0 No I2C devices found
DEBUG | ??:??:?? 0 acc_info = 0
INFO  | ??:??:?? 0 Meshtastic hwvendor=26, swver=2.2.19.a91970a
INFO  | ??:??:?? 0 Initializing NodeDB
INFO  | ??:??:?? 0 Loading /prefs/db.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 0 Loaded saved devicestate version 22
INFO  | ??:??:?? 0 Loading /prefs/config.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 0 Loaded saved config version 22
INFO  | ??:??:?? 0 Loading /prefs/module.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 0 Loaded saved moduleConfig version 22
INFO  | ??:??:?? 0 Loading /prefs/channels.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 0 Loaded saved channelFile version 22
LittleFSDirImpl::openFile: rc=-2 fd=0x20013524 path=`/oem/oem.proto` openMode=0 accessMode=1 err=-2
                   INFO  | ??:??:?? 0 No /oem/oem.proto preferences found
DEBUG | ??:??:?? 0 cleanupMeshDB purged 2 entries
WARN  | ??:??:?? 0 Using nodenum 0x5370b622
INFO  | ??:??:?? 0 Wanted region 1, using US
DEBUG | ??:??:?? 0 region=1, NODENUM=0x5370b622, dbsize=3
DEBUG | ??:??:?? 0 Read RTC time as 2444
DEBUG | ??:??:?? 0 Running without GPS.
DEBUG | ??:??:?? 0 NeighborInfoModule is disabled
LittleFSDirImpl::openFile: rc=-2 fd=0x2001538c path=`/prefs/ringtone.proto` openMode=0 accessMode=1 err=-2
                          INFO  | ??:??:?? 0 No /prefs/ringtone.proto preferences found
INFO  | ??:??:?? 0 Initializing External Notification Module
INFO  | ??:??:?? 0 Using Pin 24 in digital mode
WARN  | ??:??:?? 0 SX126xInterface(cs=13, irq=29, rst=14, busy=15)
DEBUG | ??:??:?? 0 SX126X_DIO3_TCXO_VOLTAGE defined, using DIO3 as TCXO reference voltage at 1.800000 V
INFO  | ??:??:?? 0 Starting meshradio init...
DEBUG | ??:??:?? 0 (bw=250, sf=11, cr=4/5) packet symLen=8 ms, payloadSize=0, time 231 ms
DEBUG | ??:??:?? 0 (bw=250, sf=11, cr=4/5) packet symLen=8 ms, payloadSize=253, time 2115 ms
INFO  | ??:??:?? 0 Radio freq=927.125, config.lora.frequency_offset=0.000
INFO  | ??:??:?? 0 Set radio: region=US, name=mychannel, config=0, ch=100, power=30
INFO  | ??:??:?? 0 Radio myRegion->freqStart -> myRegion->freqEnd: 902.000000 -> 928.000000 (26.000000 mhz)
INFO  | ??:??:?? 0 Radio myRegion->numChannels: 104 x 250.000kHz
INFO  | ??:??:?? 0 Radio channel_num: 101
INFO  | ??:??:?? 0 Radio frequency: 927.125000
INFO  | ??:??:?? 0 Slot time: 42 msec
INFO  | ??:??:?? 0 Set radio: final power level=22
INFO  | ??:??:?? 0 SX126x init result 0
INFO  | ??:??:?? 0 Frequency set to 927.125000
INFO  | ??:??:?? 0 Bandwidth set to 250.000000
INFO  | ??:??:?? 0 Power output set to 22
DEBUG | ??:??:?? 0 Current limit set to 140.000000
DEBUG | ??:??:?? 0 Current limit set result 0
DEBUG | ??:??:?? 0 Setting DIO2 as RF switch
DEBUG | ??:??:?? 0 SX126X_RXEN not defined, defaulting to RADIOLIB_NC
DEBUG | ??:??:?? 0 SX126X_TXEN not defined, defaulting to RADIOLIB_NC
DEBUG | ??:??:?? 0 Using MCU pin -1 as RXEN and pin -1 as TXEN to control RF switching
INFO  | ??:??:?? 0 Set RX gain to boosted mode; result: 0
INFO  | ??:??:?? 0 SX1262 Radio init succeeded, using SX1262 radio
DEBUG | ??:??:?? 0 (bw=250, sf=11, cr=4/5) packet symLen=8 ms, payloadSize=237, time 2000 ms
DEBUG | ??:??:?? 0 LoRA bitrate = 118.500000 bytes / sec
INFO  | ??:??:?? 0 PowerFSM init, USB power=1
DEBUG | ??:??:?? 0 Enter state: BOOT
DEBUG | ??:??:?? 0 [Power] Battery: usbPower=0, isCharging=0, batMv=0, batPct=0

After this, there are tons of lines coming through every few seconds with the prefix "DEBUG : " as I would expect.

This is the output with the OLED display connected:

Ã@INFO  | ??:??:?? 0

//\ E S H T /\ S T / C


DEBUG | ??:??:?? 0 Filesystem files:
DEBUG | ??:??:?? 0  channels.proto (95 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  config.proto (94 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  db.proto (322 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0  module.proto (109 Bytes)
lfs_file_close: fd=0x20013784
                             DEBUG | ??:??:?? 0 Using analog input 26 for battery level
INFO  | ??:??:?? 0 Scanning for i2c devices...
DEBUG | ??:??:?? 0 Scanning for i2c devices on port 1
DEBUG | ??:??:?? 0 I2C device found at address 0x3c
INFO  | ??:??:?? 2 sh1106 display found
DEBUG | ??:??:?? 2 0x0 subtype probed in 1 tries
INFO  | ??:??:?? 2 1 I2C devices found
DEBUG | ??:??:?? 2 acc_info = 0
INFO  | ??:??:?? 2 Meshtastic hwvendor=26, swver=2.2.19.a91970a
INFO  | ??:??:?? 2 Initializing NodeDB
INFO  | ??:??:?? 2 Loading /prefs/db.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 2 Loaded saved devicestate version 22
INFO  | ??:??:?? 2 Loading /prefs/config.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 2 Loaded saved config version 22
INFO  | ??:??:?? 2 Loading /prefs/module.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 2 Loaded saved moduleConfig version 22
INFO  | ??:??:?? 2 Loading /prefs/channels.proto
lfs_file_close: fd=0x20013524
                             INFO  | ??:??:?? 2 Loaded saved channelFile version 22
LittleFSDirImpl::openFile: rc=-2 fd=0x20013524 path=`/oem/oem.proto` openMode=0 accessMode=1 err=-2
                   INFO  | ??:??:?? 2 No /oem/oem.proto preferences found
DEBUG | ??:??:?? 2 cleanupMeshDB purged 2 entries
WARN  | ??:??:?? 2 Using nodenum 0x5370b622
INFO  | ??:??:?? 2 Wanted region 1, using US
DEBUG | ??:??:?? 2 region=1, NODENUM=0x5370b622, dbsize=3
DEBUG | ??:??:?? 2 Read RTC time as 2444
DEBUG | ??:??:?? 2 Running without GPS.
DEBUG | ??:??:?? 2 NeighborInfoModule is disabled
LittleFSDirImpl::openFile: rc=-2 fd=0x2001538c path=`/prefs/ringtone.proto` openMode=0 accessMode=1 err=-2
                          INFO  | ??:??:?? 2 No /prefs/ringtone.proto preferences found
INFO  | ??:??:?? 2 Initializing External Notification Module
INFO  | ??:??:?? 2 Using Pin 24 in digital mode

After this there is nothing else printed to the serial console, even waiting several minutes. It’s clearly seeing the screen, the address of 0x3c is the address of the display. It appears to freeze a few lines befor the “Starting meshradio init…” line.

Yes, that’s what I meant.
Seems still the same issue appears. I don’t have this hardware, so I can’t really help. You could try adding some more debug statements or connect a debugger to find out what is going on.

pi 2040 waveshare the oled on pin 4 and five prevents lora start critical error 3 (waveshare show default pins-presume connected to lora module)
I believe the fix for both will be to allow the scani2c to scan another gpio I2C bus

I’ve tried setting mine to wire pins 6&7 without success, I believe the issue is that I2C SCAN only scans pin 4 & 5.
moving oled to a new gpio allows lora module to load, abet without screen