-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathi2c0_lcd.h
36 lines (26 loc) · 1.19 KB
/
i2c0_lcd.h
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
36
// I2C0 LCD Library
// Jason Losh
//-----------------------------------------------------------------------------
// Hardware Target
//-----------------------------------------------------------------------------
// Target Platform: EK-TM4C123GXL with LCD/Keyboard Interface
// Target uC: TM4C123GH6PM
// System Clock: 40 MHz
// Hardware configuration:
// HD44780-based 16x2, 20x2, 16x4 20x4 LCD display
// Display driven by PCF8574 I2C 8-bit I/O expander at address 0x27
// I2C devices on I2C bus 0 with 2kohm pullups on SDA and SCL
// Display RS, R/W, E, backlight enable, and D4-7 connected to PCF8574 P0-7
//-----------------------------------------------------------------------------
// Device includes, defines, and assembler directives
//-----------------------------------------------------------------------------
#ifndef I2C0_LCD_H_
#define I2C0_LCD_H_
#include <stdint.h>
#include <stdbool.h>
//-----------------------------------------------------------------------------
// Subroutines
//-----------------------------------------------------------------------------
void initLcd();
void putsLcd(uint8_t row, uint8_t col, const char str[]);
#endif