I have already successfully used the SAM D21 chip to control an SSD1309 OLED over SPI, and it works fine.
Now I'm trying to do it with the ESP8266 microcontroller, but when I try to write 'monkey' across the OLED, I can very barely make out the word 'monkey' but it's all garbled and surrounded by corrupt pixels. Sometimes monkey flashes up and down, and sometimes the OLED is just blank. It's not consistent.
In terms of troubleshooting this, could someone please suggest something that I could try Perhaps something that's different between the SAM D21 and the ESP8266, perhaps something to do with the SPI settings (e.g. endianness and so forth).
I'm sure that the SPI is working fine on my ESP8266 because it works fine to read from an SDcard reader. So now I've got both the SDcard reader and the SSD1309 connected to the same SPI pins (and I use a chip select pin to switch between them).
Could I be drawing too much current from the ESP8266? Anyone got any wild idea?
I wonder if the SD card reader is supposed to be alone on the SPI line? I think some devices, if you put them on an SPI line, effectively hog the line and don't allow anything else to operate . . . Could that be happening here?
This would be easy to test . . . I could just disconnect the SD card reader, but it's soldered on place and I can't get it off the board (I'm not great with a soldering iron).