Due to high demand expect some shipping delays at this time, orders may not ship for 1-2 business days.
0

SH110X OLED example help with nrf52840 Feather Express
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

SH110X OLED example help with nrf52840 Feather Express

by drumz on Tue Apr 13, 2021 11:38 pm

I'm using the nRF52840 Feather Express with the 128x64 SH110X OLED display Featherwing, and the display is completely dark when trying to run the example sketch https://learn.adafruit.com/adafruit-128x64-oled-featherwing/arduino-code.

I've added the while (!Serial) delay that can be found in the other nrf52840 examples, and I am also checking the return from display.begin( ) that indicates success from starting up the display. The only hint I have that I don't just have a dead display is that the behavior of the Button Test loop is not working as intended. I added a print to the serial monitor, and I get the following behavior.

If the Serial and display commands are in this sequence, then the buttons behave the way that they are supposed to (other than not appearing on the OLED):
Code: Select all | TOGGLE FULL SIZE
  if(!digitalRead(BUTTON_A)) Serial.println("A"); display.print("A");
  if(!digitalRead(BUTTON_B)) Serial.println("B"); display.print("B");
  if(!digitalRead(BUTTON_C)) Serial.println("C"); display.print("C");



In this sequence, it behaves as if all three buttons are pressed and it streams ABCABCABC.... to the serial monitor. Checking the voltage on those 3 pins confirms they are being pulled low to about 0.1V by something. This behavior is also present if the Serial.println calls are removed.
Code: Select all | TOGGLE FULL SIZE
  if(!digitalRead(BUTTON_A))  display.print("A"); Serial.println("A");
  if(!digitalRead(BUTTON_B))  display.print("B"); Serial.println("B");
  if(!digitalRead(BUTTON_C))  display.print("C"); Serial.println("C");



I'm not sure what to try next to get the display to be anything but blank, and haven't been able to devise a good test to isolate that the I2C is working correctly. Somehow it seems that the display.print( ) call is conflicting with the IO pins, but it's not clear how/why. Thanks for any suggestions.

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Wed Apr 14, 2021 12:55 pm

Please post a photo of your setup showing how everything is connected.

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Wed Apr 14, 2021 1:34 pm

Photo attached. There are stacking headers on the nrf52840, and regular pin headers on the SH110X display. Thanks!
Attachments
PXL_20210414_172403645.jpg
PXL_20210414_172403645.jpg (372.46 KiB) Viewed 163 times

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Wed Apr 14, 2021 1:42 pm

Are the stacking headers soldered on as well?

To sanity check the buttons via the Serial Monitor, try changing that code section to this:
Code: Select all | TOGGLE FULL SIZE
  if(!digitalRead(BUTTON_A)) {
    display.print("A");
    Serial.println("A");
  }
  if(!digitalRead(BUTTON_B)) {
    display.print("B");
    Serial.println("B");
  }
  if(!digitalRead(BUTTON_C)) {
    display.print("C");
    Serial.println("C");
}

You need the {}'s, otherwise only the first statement is part of the conditional.

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Wed Apr 14, 2021 4:29 pm

That change does make the buttons behave correctly, even with the Serial.println calls removed. Without the Serial.println I checked with a multimeter that all three pins are at 3.3V and go low only when the correct button is pressed. The stacking headers are soldered on the bottom side of the Feather board.

Thank you for the C instruction, I had not seen that shorthand for the single-statement conditional before.

Button mystery solved, but the OLED is still stubbornly black. I also tried unstacking the boards and connecting the critical pins, but without success. Display.begin() returns true, and also returns false if the display board is disconnected, but beyond that I'm not sure how to isolate things better.
Last edited by drumz on Wed Apr 14, 2021 5:01 pm, edited 1 time in total.

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Wed Apr 14, 2021 4:34 pm

OK, that's the expected behavior. The button pins are pulled high and get grounded through the buttons. HIGH/3V = not pressed. LOW/GND = pressed.

So the buttons are working fine. But still nothing on the OLED?

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Wed Apr 14, 2021 8:14 pm

I edited the previous post, probably while you were replying. No, nothing on the OLED display.

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Thu Apr 15, 2021 11:01 am

For the OLED, it might be a connection issue. Your soldering looks generally OK, but maybe a bit on the thin side on a few pins. And the soldering on the stacking headers matters as well.

See here for a good example of common issues:
https://learn.adafruit.com/adafruit-gui ... n-problems
and go over all your pins and see if any might need a little touch up. If so, you can just go back in with your soldering iron and reflow them.

You can also try running this I2C scanner sketch as a simple "is it there" check:
https://playground.arduino.cc/Main/I2cScanner/
It should find the OLED's address, which I think is 0x3C by default.

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Thu Apr 15, 2021 5:21 pm

Thanks. I touched up all the solder joints, photo included.

Running the I2C_scanner, it does find an I2C device at 0x3C as expected, but still nothing out of the display from the OLED_featherwing sketch. Thanks for the help!
Attachments
PXL_20210415_202054822.jpg
PXL_20210415_202054822.jpg (1006.85 KiB) Viewed 137 times

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Thu Apr 15, 2021 5:54 pm

Thanks. That soldering is excellent!

I'm wondering if the OLED is physically damaged. Is that a tear in the ribbon cable (arrow) and a crack in the display (circle)?
oled.jpg
oled.jpg (132.64 KiB) Viewed 136 times

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Thu Apr 15, 2021 7:03 pm

Dug out the crummy USB microscope to take a look, and I'm afraid you're right. The flex circuit looks OK, but the little cantilevered section of glass has a couple of serious cracks, outlined in the image on the right. That section definitely bends if poked gingerly. Mystery solved. :facepalm:
Attachments
2021-04-15 16_37_52.jpg
2021-04-15 16_37_52.jpg (62.89 KiB) Viewed 135 times

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Thu Apr 15, 2021 7:11 pm

Oof. Yep. I think that's it. Is this a new board that arrived like that? If so, we can totally replace it.

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by drumz on Thu Apr 15, 2021 7:43 pm

It came new in a padded envelope last Friday, and I've been careful with it when installing/removing from the Feather board. I certainly spent the week believing the source of error was sitting behind the keyboard. That little section of cantilevered glass could quite possibly have gotten crushed in shipping. If you're able to replace the board that would be amazing! Thank you for the help/patience!

drumz
 
Posts: 9
Joined: Sun Apr 11, 2021 4:50 pm

Re: SH110X OLED example help with nrf52840 Feather Express

by adafruit_support_carter on Thu Apr 15, 2021 8:27 pm

No problem. Thanks for all the great photos and working through all the trouble shooting steps. I'm bet your original soldering job was totally OK.

Send an email to support@adafruit.com with a link to this thread and your order number and they can send you a replacement FeatherWing OLED (PID 4650).

adafruit_support_carter
 
Posts: 20078
Joined: Tue Nov 29, 2016 2:45 pm

Please be positive and constructive with your questions and comments.