Adds support for LCDs based on the HD44780 controller chip - or compatibles.
This chip requires 3 control lines and either 4 or 8 data lines. All of these pins are general IO pins.
The 4 pin method requires a few less pins than the 8 pin method but is slightly slower in operation.
This device also supports a number of different sized displays. The number of lines/rows is normally 1,2 or 4 but the number of columns can typically be 8, 16, or 20.
These settings can be specified in Project Designer.
- clear - Clear the display and set the cursor to the home position.
- getNumColumns - Returns the total number of columns available.
- getNumLines - Returns the total number of lines available.
- home - Move the cursor to the home position ie top left corner.
- horizGraph - Draws a horizontal bar graph on the display.
- print - Prints the value of a number, or a string, to the stream.
- print_P - Prints a string from program memory to the stream.
- println - Sends a carriage return line feed sequence to the stream to indicate the end of a line of text.
- read - Reads the next byte from the device. This will return EOF, the end of file marker, if there are no characters available - otherwise it will return the next byte.
- setAutoScroll - Turn auto-scrolling on or off.
- setBacklight - Turn the display back light on or off (assuming that it has one and that it can be controlled in software).
- setBrightness - Set the brightness of the display.
- setContrast - Set the contrast of the display to a number between 0 (least) and 100 (most).
- setLineWrap - Turn automatic line wrapping on or off.
- setXY - Move the cursor to a given location.
- vertGraph - Draws a vertical bar graph on the display.
- write - Writes a single byte to the output stream. The returned value is normally the same value as the byte just written but on some devices it can return EOF to indicate a write error. For eaxmple: writing a byte out to a file stored on a µSD card may return EOF if there is no available space.
- write - Writes out a sequence of bytes from a given position in RAM. The returned value is the number of bytes actually written. This would only be less than the reqested number of bytes if there is an error writing to the stream.
- write_P - Writes out a sequence of bytes from a given position in program memory. The returned value is the number of bytes actually written. This would only be less than the reqested number of bytes if there is an error writing to the stream.