-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathLCD.h
More file actions
35 lines (27 loc) · 788 Bytes
/
Copy pathLCD.h
File metadata and controls
35 lines (27 loc) · 788 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
/*
* LCD.h
*
* Author : Hossam Elbahrawy
*/
#ifndef LCD_H_
#define LCD_H_
#include "pin_config.h"
#define LCD_CMD_CLEAR_DISPLAY 0x01
#define LCD_CMD_CURSOR_HOME 0x02
// Display control
#define LCD_CMD_DISPLAY_OFF 0x08
#define LCD_CMD_DISPLAY_NO_CURSOR 0x0c
#define LCD_CMD_DISPLAY_CURSOR_NO_BLINK 0x0E
#define LCD_CMD_DISPLAY_CURSOR_BLINK 0x0F
// Function set
#define LCD_CMD_4BIT_2ROW_5X7 0x28
#define LCD_CMD_8BIT_2ROW_5X7 0x38
//functions prototype
void lcd_init(void);
void lcd_send_command (uint8_t );
void lcd_write_character(uint8_t );
void lcd_write_word(uint8_t []);
void lcd_clear(void);
void lcd_set_courser(uint8_t,uint8_t);
void lcd_goto_xy (uint8_t , uint8_t );
#endif /* LCD_H_ */