Show Posts
Pages: [1]
1  Using Arduino / Displays / Re: How to read HD44780 LCD programmatically on: March 09, 2013, 12:14:02 pm
A full implementation of the HD44780 is not necessary for 99.9% of the users.  Reading the LCD would only be necessary for those who want to copy the display to another device (PC, for example) or who need to test the LCD programatically in a production environment. 
2  Using Arduino / Displays / Re: How to read HD44780 LCD programmatically on: March 07, 2013, 03:00:32 pm
That sounds easy enough.  Thank you!  I'll look at the LiquidCrystal library, and make the recommended changes.  Thank you very much for your help!
3  Using Arduino / Displays / Re: How to read HD44780 LCD programmatically on: March 07, 2013, 01:43:59 pm
In PicBasic, the support for the LCD is built into the language, and I don't have access to it's source code.
The methods to read has two parameters, the first is the address to read from the LCD, usually $80 or $C0 for the first and second lines respectively.  The second parameter is an array of characters, where the LCD characters were placed. 

Examples for reading from the LCD:
  LCDIN $80, [ InArray[20], InArray[21], InArray[22], InArray[23],_
               InArray[24], InArray[25], InArray[26], InArray[27],_
               InArray[28], InArray[29], InArray[30], InArray[31],_
               InArray[32], InArray[33], InArray[34], InArray[35] ]
             
  LCDIN $c0, [InArray[36], InArray[37], InArray[38], InArray[39],_
              InArray[40], InArray[41], InArray[42], InArray[43],_
              InArray[44], InArray[45], InArray[46], InArray[47],_
              InArray[48], InArray[49], InArray[50], InArray[51] ]

I'll read the Fujitsu documentation and figure it out for the Arduino.  Wish I had other source code to access as a guide.  Maybe from the mfg.  Thank you.
4  Using Arduino / Displays / Re: How to read HD44780 LCD programmatically on: March 07, 2013, 12:47:53 pm
The HD44780 LCD  has functions to read the display in libraries for other microcontrollers (PicBasic, for example).   So I was just searching for the same functions for the Arduino.  I really, really like the Arduino, and don't like it when there is support for other microcontrollers which is lacking for the Arduino.

For the immediate need, I will create an in-memory ("shadow") view of the LCD, send that view to the LCD, and also then be able to read fro that view.  It will be a simple 2x16 array of char.  Fortunately there is a lot of extra programming space in the Mega 2560.  Having this view in RAM serves the capability of cloning the LCD display to the PC, but doesn't help any in auto-testing the LCD, hence the need to read the LCD.

In the future I will work on providing an update to the Arduino library to make it more complete. 

Thank you for all the comments and suggestions!  I consider the question to be answered.
Phil Dorcas
5  Using Arduino / Displays / How to read HD44780 LCD programmatically on: February 20, 2013, 10:12:19 pm
How can I read the LCD?  It is a common HD44780 compatible LCD, connected in parallel 4-bit mode.
Arduino Mega 2560 Rev 3.

#include <LiquidCrystal.h>
. . .
LiquidCrystal lcd(12, 11, 5, 4, 3, 2); 

There are lots of methods now for lcd, but they have to with writing to the display.
Are there other methods for the HD44780 in LiquidCrystal.h that are not exposed in the header that I can use for reading the display?
Is there another library with some methods for reading?
6  Using Arduino / Displays / How to read HD44780 LCD programmatically on: February 20, 2013, 09:51:07 pm
How can I read the LCD?  It is a common HD44780 compatible LCD, connected in parallel 4-bit mode.
Arduino Mega 2560 Rev 3.

#include <LiquidCrystal.h>
. . .
LiquidCrystal lcd(12, 11, 5, 4, 3, 2); 

There are lots of methods now for lcd, but they have to with writing to the display.
Are there other methods for the HD44780 in LiquidCrystal.h that are not exposed in the header that I can use for reading the display?
Is there another library with some methods for reading?

Pages: [1]