olikraus / ucglib

Arduino True Color Library for TFTs and OLEDs
https://github.com/olikraus/ucglib/wiki
Other
261 stars 76 forks source link

HWSPI with ESP32 compared to Arduino MEGA #104

Closed sirpete83 closed 5 years ago

sirpete83 commented 5 years ago

Hallo, I'm using the ESP32(Lolin32) Board. I have tested one OLED with SSD1351_18x128x128_FT_HWSPI, and there are 3 or 4 pixels that are not drawn with the right value. I think, that are the first pixels and the last pixels of the full frame. I used the same ino file with Arduino MEGA Board, same wiring and the pixels are all with the expected value/color. Later I tested TFT LCD ST7735_18x128x160_HWSPI, again first with the EPS32, here I got 3 or 4 pixels at the beginning of a frame with wrong color. at the ond of the frame it was fine. I didn't tested it yet with the MEGA board, but alternatively I took the Adafruit library for ST7735, and haven't seen any pixel errors. Maybe the SPI speed is to high? or the timing between CS and/or D/C and the fist data is critical? Did somebody got the same problems? Maybe SPI speed could be to high?

Would be nice to get some input on this.

sirpete83 commented 5 years ago

Hallo, I don't know why, but in the pixel_and_lines() function there are following lines: ucg.drawPixel(ucg.getWidth()-1, ucg.getHeight()-1); ucg.drawPixel(ucg.getWidth()-1-1, ucg.getHeight()-1); removed this line, an the flase pixels are not longer drawn.