You are on page 1of 1

/* LCD.

h (Author: Group STARSMOTIOUS)


* a header file to use PIC to command the LCD Display
* Only for 4-bit data transmission
* PIN(PIC) PIN(LCD)
* RB0 D4
* RB1 D5
* RB2 D6
* RB3 D7
* RB4 RS
* RB5 EN
* List of commands
* LCD_INIT() -> setup all the configuration bit for LCD Command
* LCD_CLEAR() -> clear LCD window
* LCD_SET_CURSOR(x,y) -> set the location or position where you want to write t
he character/word;
x - either 1 or 2, 1 is the upper row of LCD while 2 i
s the lower row
y - it's the column where you want to write the charac
ter/word. Because our LCD has 15 column, the range is 1-15
* LCD_WRITE_STRING("string",x,y) -> write string character in the LCD
string - the character/word you want to wri
te in the LCD
the x and y is like in the LCD_SET_CURSOR(x
,y)
set x and y to 0 if you use LCD_SET_CURSOR
command
* LCD_WRITE_STRING(z,x,y) -> write string character in the LCD
z - a variable with a value, must be char or string v
ariable, does not accept int, float, etc. as input,
- when the variable value is int/float/double etc.
type, you must convert the value to char or string
- use sprintf command to convert int etc. type to c
har/string
the x and y is like in the LCD_SET_CURSOR(x,y)
set x and y to 0 if you use LCD_SET_CURSOR command
* LCD_SRIGHT() -> shift the character to the RIGHT
* LCD_SLEFT() -> shift the character to the LEFT
* LCD_CLEAR_CELL(x,y,z) -> clear specific cell
x - either 1 or 2, 1 is the upper row of LCD while 2
is the lower row
y - it's the column where you want to clear the char
acter/word. Because our LCD has 15 column, the range is 1-15
z - clear the neighbor cell (right), how many cell d
o you want to clear to the right on your position cell
*/
/* ADC.h (Author: Group STARSMOTIOUS)
* Activating the Analog to Digital Converter of the PIC
* All PORTA and PORTE are all input and use as ADC
* List of Command
* ADC_INIT() -> Initializing the configuration bit of PIC to on the Analog to
Digital Converter
* ADC_GetValue(x) -> Getting the decimal digital bit value of the converter vo
ltage
Return as int variable
Range: 0 - 1023 (0V - 5V)
x - port use (AN0, AN1, AN2, AN3, AN4, AN5, AN6, AN7)
*/

You might also like