EPAIII
Member
I have been experimenting with using a PICAXE for scrolling text on some HD44780 based LED displays of various sizes. The commands I talk about below are those for that device, not any PICAXE code.
I first clear the display and home the cursor sending a 01 command to the display. Then I change to One Line mode with a 48 command. A long text message is then sent to the display using the data mode in a loop to send all the characters. This message is 72 bytes long and should be going into LCD RAM locations 128 through 199.
At this point I have tried a number of commands to reliably reset the active window to the start of my message, but none of them seem to work for all the different displays I have tried this on. On some of the displays nothing works.
Then the text is scrolled using the Pan Right command: 24 in a loop that repeats it 136 times to display the complete message two times. The scrolling does work, but some times it starts at the beginning of the message and other times it starts at the 41st character. This action seems to be random.
As I stated above, I have tried inserting several different commands just before the scrolling routing but none of them have worked. These commands include repositioning the cursor to position 128, the start of the first line, homing the cursor (2), and adding a cursor right and a cursor left command after that. None of these measures seems to have any effect.
Does anybody know of a reliable way to have this scrolling message always start at it's beginning? If possible, I need a solution that works on all HD44780 based displays. I know that is a tall task.
I first clear the display and home the cursor sending a 01 command to the display. Then I change to One Line mode with a 48 command. A long text message is then sent to the display using the data mode in a loop to send all the characters. This message is 72 bytes long and should be going into LCD RAM locations 128 through 199.
At this point I have tried a number of commands to reliably reset the active window to the start of my message, but none of them seem to work for all the different displays I have tried this on. On some of the displays nothing works.
Then the text is scrolled using the Pan Right command: 24 in a loop that repeats it 136 times to display the complete message two times. The scrolling does work, but some times it starts at the beginning of the message and other times it starts at the 41st character. This action seems to be random.
As I stated above, I have tried inserting several different commands just before the scrolling routing but none of them have worked. These commands include repositioning the cursor to position 128, the start of the first line, homing the cursor (2), and adding a cursor right and a cursor left command after that. None of these measures seems to have any effect.
Does anybody know of a reliable way to have this scrolling message always start at it's beginning? If possible, I need a solution that works on all HD44780 based displays. I know that is a tall task.