lcd.c File Reference

#include "lcd.h"
#include <string.h>
#include <stdlib.h>

Include dependency graph for lcd.c:

Go to the source code of this file.

Functions

void lcd_cursor_home ()
void lcd_init ()
 Initialise LCD ready for display.
void lcd_set_cgram_pos (uns8 x)
void lcd_set_ddram_pos (uns8 x)
void lcd_setup ()
 Setup port and pins to talk to LCD.
void lcd_toggle_e ()
 LCD communicaiton routines.
void lcd_wait_busy ()
 Wait while LCD is busy.
void lcd_write_byte (uns8 data)
void lcd_write_command (uns8 data)
 Sends a command to the LCD.
void lcd_write_data (uns8 data)
 Send one byte of data to the LCD.
void lcd_write_data_int (uns16 i)
 Print a 16 bit integer the the LCD.
void lcd_write_data_str (char *str)
 Print a string to the LCD.
void lcd_write_nibble (uns8 data)


Function Documentation

void lcd_cursor_home (  ) 

Definition at line 184 of file lcd.c.

References LCD_CLEAR_DISP, and lcd_write_command().

Here is the call graph for this function:

void lcd_init (  ) 

Configures LCD for 4 bit operation and gets ready for displaying text

Definition at line 64 of file lcd.c.

References LCD_CLEAR_DISP, LCD_RETURN_HOME, lcd_toggle_e(), lcd_write_command(), and lcd_write_nibble().

Here is the call graph for this function:

void lcd_set_cgram_pos ( uns8  x  ) 

Definition at line 178 of file lcd.c.

References lcd_write_command().

Here is the call graph for this function:

void lcd_set_ddram_pos ( uns8  x  ) 

Definition at line 173 of file lcd.c.

References lcd_write_command().

Here is the call graph for this function:

void lcd_setup (  ) 

Call this routine first, to set up tris bits correctly to talk to the LCD

Definition at line 47 of file lcd.c.

References clear_pin, and make_output.

void lcd_toggle_e (  ) 

Ian Harris 2008 imharris [at] gmail.com Released under the "do whatever you like with this but if you use it send me an email" license. Oh, and if it breaks, you get to keep both pieces.

Definition at line 20 of file lcd.c.

References clear_pin, and set_pin.

Referenced by lcd_init(), and lcd_write_byte().

Here is the caller graph for this function:

void lcd_wait_busy (  ) 

Internal routine to wait while the LCD is busy and unable to accept more data

Definition at line 134 of file lcd.c.

References clear_pin, PORTA, set_pin, and test_pin.

Referenced by lcd_write_command(), lcd_write_data(), and lcd_write_data_str().

Here is the caller graph for this function:

void lcd_write_byte ( uns8  data  ) 

Definition at line 38 of file lcd.c.

References lcd_toggle_e(), and lcd_write_nibble().

Referenced by lcd_write_command(), lcd_write_data(), and lcd_write_data_str().

Here is the call graph for this function:

Here is the caller graph for this function:

void lcd_write_command ( uns8  data  ) 

Use this to send commands to the LCD, eg, changing cursor position

Definition at line 93 of file lcd.c.

References clear_pin, lcd_wait_busy(), and lcd_write_byte().

Referenced by lcd_cursor_home(), lcd_init(), lcd_set_cgram_pos(), and lcd_set_ddram_pos().

Here is the call graph for this function:

Here is the caller graph for this function:

void lcd_write_data ( uns8  data  ) 

Definition at line 103 of file lcd.c.

References clear_pin, lcd_wait_busy(), lcd_write_byte(), and set_pin.

Here is the call graph for this function:

void lcd_write_data_int ( uns16  i  ) 

Displays an unsigned 16 bit integer on the LCD

Definition at line 125 of file lcd.c.

References lcd_write_data_str().

Here is the call graph for this function:

void lcd_write_data_str ( char *  str  ) 

Display the string on the LCD from the current cursor position

Definition at line 112 of file lcd.c.

References clear_pin, lcd_wait_busy(), lcd_write_byte(), and set_pin.

Referenced by lcd_write_data_int().

Here is the call graph for this function:

Here is the caller graph for this function:

void lcd_write_nibble ( uns8  data  ) 

Definition at line 27 of file lcd.c.

References change_pin.

Referenced by lcd_init(), and lcd_write_byte().

Here is the caller graph for this function:


Generated on Fri May 16 12:18:57 2008 for Pic Pack by  doxygen 1.5.5