简体   繁体   中英

LCD screen corrupting

I am using an MSP430F5418 with the ST7565R LCD controller with easyGUI. I am using SPI to communicate with the LCD.

Suppose I have a screen like this:

实际画面

But sometimes (rarely) when I press a key (anything which make the testing board to move, usually it comes when pressing the key) the screen goes like this:

混乱

I didn't do anything on the code for this change... Why did it happen?

这听起来像是您的代码中的错误-我不熟悉easyGUI或特定控制器的细节,所以这只是一个疯狂的猜测,但是如果您在代码中的某个地方执行了printfwrite ,然后将stdout转到与您的显示器相同的设备上,并且当这些字符之一是换行符时,或者当该行环绕显示时,该字符将汇总一个字符吗?

I tried by adding the 'Display start line to zero' command before each LCD command so that the screen will never be corrupted. And That works for me :-). So it avoid the loose connections while moving the device.

It looks like you are using custom LCD glass. If that's the case check your connections between the display controller and the LCD glass. If the connections are not good it's possible that the display controller is turning on the wrong segments.

Check the pinout of the LCD glass along with the segments that are programmed to be on vs. the segments that are actually on to see if they are on adjacent pins. If they are then your connector is likely the problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM