lcd_hd44780_common

common library for HD44780 based LCD

Author Richard Zengerink, Copyright (c) 2008..2009, all rights reserved.
Adapted-by Joep Suijs,
Compiler >=2.4j

Description

Common API for HD44780 based LCD
.
 Procedures which can be used by application program:
.
* lcd_write_char( byte in value ):
  writes 'value' to lcd
  example: lcd_write_char( "E" )  or lcd_write_char( 69 )
.
* lcd = value:
  writes 'value' to lcd
  example: lcd = "E"  or lcd = 69
.
* lcd_cursor_position(byte in line, byte in pos):
  places the cursor on position (pos) in line (line) (zero based!)
  example: lcd_new_line_cursor_position (1, 8)
.
* lcd_shift_left(byte in value):
  shifts the display [value] times to the left without changing DDRAM data.
  example: lcd_shift_left(4)
  or       lcd_shift_left(variable)
.
* lcd_shift_right(byte in value):
  shifts the display [value] times to the right without changing DDRAM data.
  example: lcd_shift_right(12)
  or       lcd_shift_right(variable)
.
* lcd_cursor_shift_left(byte in value):
  shifts the cursor [value] times to the left without changing display
  contents and DDRAM data.
  example: lcd_cursor_shift_left(8)
  or       lcd_cursor_shift_left(variable)
.
* lcd_cursor_shift_right(byte in value):
  shifts the cursor [value] times to the right without changing display
  contents and DDRAM data.
  example: lcd_cursor_shift_right(3)
  or       lcd_cursor_shift_right(variable)
.
* lcd_clear:
  Write "20H" to DDRAM and set DDRAM address to "00H" from AC
  This will clear the display.
.
* lcd_home:
  Set DDRAM address to "00H" from AC and return cursor to its original
  position if shifted. The contents of DDRAM are not changed.
.
* lcd_cursor_blink_display(bit in cursor,bit in blink,bit in display):
  sets the underline cursor on/off, let the block-cursor blinking/off
  and puts the display on/off
  example: lcd_cursor_blink_display(on,off,on)
.
* lcd_clear_line ( byte in line  )
  clears the line [line] of the lcd including DDRAM data of that line
  example: lcd_clear_line(1)
.
* lcd_progress(byte in line, byte in amount)
  create a progress bar on line [line] with a lenght of [amout]
  example: lcd_progress(2,12)


Dependencies

No dependency found



Summary

Global variables/contants

Procedures

Private

Functions

Private

API details

Global variables/contants

Procedures

Private
  • _lcd_restore_cursor()

    _lcd_restore_cursor - sets the cursor to the position in the shadow register
    (this routine is only used inside this file)
    
    

  • _hd44780_init()

    _hd44780_init - Initialise display (not realy internal, but not for users)
    
    This procedure is called from lcd_init of the interface used. lcd_init brings
    up the interface and powers up the display.
    This procedure sets the display in the pre-defined startposition (clear
    screen, no cursor etc).
    
    


Functions

Private

Related samples

No sample found