#include <stdio.h>
#include <aversive/pgmspace.h>
#include <aversive.h>
#include <aversive/wait.h>
#include <lcd.h>
#include <lcd_protocol.h>
Go to the source code of this file.
Defines | |
#define | e_delay() _delay_loop_1(1) |
Functions | |
void | initial_8_bit_write (uint8_t value) |
void | lcd_command (uint8_t cmd) |
void | lcd_gotoxy (uint8_t x, uint8_t y) |
void | lcd_clrscr (void) |
void | lcd_home (void) |
void | lcd_putc (char c) |
int | lcd_dev_putc (char c, FILE *f) |
void | lcd_init (uint8_t dispAttr) |
Interface for the LCD module.
in this new version you can use lcd_putc(''); to clear the screen. This maintains an easy compatibility when you want to use an uart instad (form feed).
Definition in file lcd.c.
void initial_8_bit_write | ( | uint8_t | value | ) |
Definition at line 164 of file lcd.c.
References cbi, IRQ_LOCK, IRQ_UNLOCK, and LCD_DATA_MASK.
Referenced by lcd_init().
void lcd_clrscr | ( | void | ) |
clear all the screen avoid using this function, escpecially if you use printf
Definition at line 288 of file lcd.c.
References LCD_CLR, and lcd_command().
Referenced by lcd_init(), and lcd_putc().
void lcd_command | ( | uint8_t | cmd | ) |
Definition at line 207 of file lcd.c.
Referenced by lcd_clrscr(), lcd_gotoxy(), lcd_home(), and lcd_init().
int lcd_dev_putc | ( | char | c, | |
FILE * | f | |||
) |
same than lcd_putc but with a prototype that is compliant with avrlibc > 1.4.0 fdevopen prototype
Definition at line 328 of file lcd.c.
References lcd_putc().
void lcd_gotoxy | ( | uint8_t | x, | |
uint8_t | y | |||
) |
move the cursor in the screen, x= line, y = char
Definition at line 260 of file lcd.c.
References lcd_command(), and LCD_DDRAM.
Referenced by lcd_putc().
void lcd_home | ( | void | ) |
void lcd_init | ( | uint8_t | dispAttr | ) |
Init the LCD module
Definition at line 334 of file lcd.c.
References DDR, initial_8_bit_write(), lcd_clrscr(), lcd_command(), LCD_DISP_OFF, LCD_FUNCTION_4BIT_1LINE, LCD_FUNCTION_8BIT_1LINE, LCD_FUNCTION_DEFAULT, LCD_MODE_DEFAULT, and sbi.
void lcd_putc | ( | char | c | ) |
Put a char on screen if c =
cursor is positioned on the next line if c = the screen will be cleared
Definition at line 304 of file lcd.c.
References lcd_clrscr(), and lcd_gotoxy().
Referenced by lcd_dev_putc().