Datasheet

LCD LIBRARY
The mikroC PRO for AVR provides a library for communication with Lcds (with
HD44780 compliant controllers) through the 4-bit interface. An example of Lcd con-
nections is given on the schematic at the bottom of this page.
For creating a set of custom Lcd characters use Lcd Custom Character Tool.
External dependencies of Lcd Library
305
MIKROELEKTRONIKA - SOFTWARE AND HARDWARE SOLUTIONS FOR EMBEDDED WORLD
Libraries
mikroC PRO for AVR
CHAPTER 6
The following variables
must be defined in all proj-
ects using Lcd Library :
Description : Example :
extern sfr sbit LCD_RS:
Register Select line.
sbit LCD_RS at
PORTD.B2;
extern sfr sbit LCD_EN:
Enable line.
sbit LCD_EN at
PORTD.B3;
extern sfr sbit LCD_D7;
Data 7 line.
sbit LCD_D7 at
PORTD.B4;
extern sfr sbit LCD_D6;
Data 6 line.
sbit LCD_D6 at
PORTD.B5;
extern sfr sbit LCD_D5;
Data 5 line.
sbit LCD_D5 at
PORTD.B6;
extern sfr sbit LCD_D4;
Data 4 line.
sbit LCD_D4 at
PORTD.B7;
extern sfr sbit
LCD_RS_Direction;
Register Select direc-
tion pin.
sbit
LCD_RS_Direction at
DDRD.B2;
extern sfr sbit
LCD_EN_Direction;
Enable direction pin.
sbit
LCD_EN_Direction at
DDRD.B3;
extern sfr sbit
LCD_D7_Direction;
Data 7 direction pin.
sbit
LCD_D7_Direction at
DDRD.B4;
extern sfr sbit
LCD_D6_Direction;
Data 6 direction pin.
sbit
LCD_D6_Direction at
DDRD.B5;
extern sfr sbit
LCD_D5_Direction;
Data 5 direction pin.
sbit
LCD_D5_Direction at
DDRD.B6;
extern sfr sbit
LCD_D4_Direction;
Data 4 direction pin.
sbit
LCD_D4_Direction at
DDRD.B7;