Closed cjjaeckson closed 9 months ago
displayShutdopwn() does not do what you think it does. Try just clearing the display.
These kinds of problems are usually caused by wiring problems. Have you got the pull up/down resistor (can't remember which) on the comms control signals (just google this and there are lots of references). Other issues are voltage fluctuations for the display supply (eg, electromechanical devices being powered by the same power supply).
Subject of the issue
Problems with pixel errors after an undefined period of time.
Your Environment
Library Version:3.7.1 Arduino IDE version:1.8.19 Host OS and Version:? CPU Hardware model/type: MEGA 2560
Steps to Reproduce
Display works without problems at first. After a longer time, there are pixel artifacts. Mostly in the lower rows. I have attached a picture.
Expected Behaviour
The present code reads a lidar sensor and shows the result on the display. The values of the sensor are intended for level determination of a ton. If the signal of the lidar is too low, "Signal!" is displayed; if the signal is good, the fill level of the ton is displayed as a percentage value. If the ton is overfilled, "Error!" and every second LED flashes alternately.
Actual Behaviour
After a undefined period of time random leds are shining. Mostly last row. I've tried several things to avoid that behaviour. When the microcontroller is reset, the pixel errors are gone. Therefore I tried to find a way to reset the display in a certain time interval in the code. The function for this is attached.
Code Demonstrating the Issue
I hope someone can help! Thanks a lot! :)