de.wagner_ibw.iow.lcd
Interface LCD

All Known Implementing Classes:
GLCD128x128, LCD16x16, LCD16x21, LCDImpl

public interface LCD

This is the interface for the LCD special mode function. It supports only single controler LCD display.

Author:
Thomas Wagner

Method Summary
 void check()
          Prüft die korrekte Anzeige.
 long clearLCD()
          OK Clears entire dislplay and sets DDRAM address 0 in address counter.
 int getCols()
           
 int getRows()
           
 void moveSprite(int row, java.lang.String[] sprites, int wait)
           
 long setCGRAMAddr(int address)
          ?????
 long setCursor(int row, int col)
          OK Moves cursor to new Position.
 long setCursorDispOn()
          OK Convenient method: Turn LCD display on.
 long setCursorHome()
          OK Sets DDRAM address 0 in address counter.
 long setCursorleft()
          Move LCD cursor to the left
 long setCursorOff()
          OK Convenient method: Turn LCD cursor off.
 long setCursorOn()
          OK Convenient method: Turn LCD cursor on.
 long setCursorRight()
          Move LCD cursor to the right
 long setDDRAMAddr(int address)
          ?????
 long setDisplayControl(boolean dispOn, boolean cursorOn, boolean charBlinking)
          OK Sets ON/OFF of all display (dispOn), cursor ON/OFF (cursorOn), and blink of cursor position character (cursorBlink).
 long setDispOff()
          OK Convenient method: Turn LCD display off.
 long setEntryMode(boolean moveForward, boolean shiftDisp)
          OK Sets cursor move direction and specifies display shift.
 long setShiftControl(boolean shiftDisp, boolean shiftDir)
          OK Moves cursor and shifts display whitout changing DDRAM contents.
 void setSpecialChar(int code, int[] pattern)
           
 void writeLine(int row, boolean clear, java.lang.String str)
          Write the given String in row specified by parm row.
 void writeLine(int row, int col, boolean clear, java.lang.String str)
          Write the given String in the specified row and column.
 void writeString(java.lang.String str)
          OK Write the given string to LCD.
 

Method Detail

getRows

public int getRows()

getCols

public int getCols()

clearLCD

public long clearLCD()
OK Clears entire dislplay and sets DDRAM address 0 in address counter.

Returns:
Number of written bytes (8 expected for a successful operation).

setCursorHome

public long setCursorHome()
OK Sets DDRAM address 0 in address counter. Also returns display from being shiftet to original position. DDRAM contents remain unchanged.

Returns:
Number of written bytes (8 expected for a successful operation).

setEntryMode

public long setEntryMode(boolean moveForward,
                         boolean shiftDisp)
OK Sets cursor move direction and specifies display shift. These operations are performed during data write and read.

Parameters:
moveForward - true: increment, false: decrement
shiftDisp - true: display is shifted, false: display is not shifted
Returns:
Number of written bytes (8 expected for a successful operation).

setDisplayControl

public long setDisplayControl(boolean dispOn,
                              boolean cursorOn,
                              boolean charBlinking)
OK Sets ON/OFF of all display (dispOn), cursor ON/OFF (cursorOn), and blink of cursor position character (cursorBlink).

Parameters:
dispOn - true: the display is on, false: display is off
cursorOn - true: cursor is displayed, false: cursor is not displayed
charBlinking - true: the character indicated by the cursor blinks, false: blinks not
Returns:
Number of written bytes (8 expected for a successful operation).

setShiftControl

public long setShiftControl(boolean shiftDisp,
                            boolean shiftDir)
OK Moves cursor and shifts display whitout changing DDRAM contents.

Parameters:
shiftDisp - true: display shift, false: cursor move;
shiftDir - true: shift to the right, false: shift to the left
Returns:
Number of written bytes (8 expected for a successful operation).

writeLine

public void writeLine(int row,
                      boolean clear,
                      java.lang.String str)
               throws java.lang.IllegalArgumentException
Write the given String in row specified by parm row. If parm clear is true the row will be cleared before output. All characters exceeding the cols will be truncated.

Parameters:
row -
clear -
str -
java.lang.IllegalArgumentException

writeLine

public void writeLine(int row,
                      int col,
                      boolean clear,
                      java.lang.String str)
               throws java.lang.IllegalArgumentException
Write the given String in the specified row and column. If parm clear is true the row will be cleared before output. All characters exceeding the cols will be truncated.

Parameters:
row -
clear -
str -
java.lang.IllegalArgumentException

writeString

public void writeString(java.lang.String str)
OK Write the given string to LCD.

Parameters:
str - String to write

setDDRAMAddr

public long setDDRAMAddr(int address)
????? Set DDRAM address Parameters: Address - DDRAM address


setCGRAMAddr

public long setCGRAMAddr(int address)
????? Set DDRAM address Parameters: Address - DDRAM address


setCursor

public long setCursor(int row,
                      int col)
               throws java.lang.IllegalArgumentException
OK Moves cursor to new Position.

Parameters:
row - display line (1...4)
col - column in row (1...40)
java.lang.IllegalArgumentException

setCursorDispOn

public long setCursorDispOn()
OK Convenient method: Turn LCD display on.

Returns:
Number of written bytes (8 expected for a successful operation).

setDispOff

public long setDispOff()
OK Convenient method: Turn LCD display off.

Returns:
Number of written bytes (8 expected for a successful operation).

setCursorOn

public long setCursorOn()
OK Convenient method: Turn LCD cursor on.

Returns:
Number of written bytes (8 expected for a successful operation).

setCursorOff

public long setCursorOff()
OK Convenient method: Turn LCD cursor off.

Returns:
Number of written bytes (8 expected for a successful operation).

setCursorleft

public long setCursorleft()
Move LCD cursor to the left

Returns:
Number of written bytes (8 expected for a successful operation).

setCursorRight

public long setCursorRight()
Move LCD cursor to the right

Returns:
Number of written bytes (8 expected for a successful operation).

check

public void check()
Prüft die korrekte Anzeige.


setSpecialChar

public void setSpecialChar(int code,
                           int[] pattern)
                    throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException

moveSprite

public void moveSprite(int row,
                       java.lang.String[] sprites,
                       int wait)
                throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException