From 442b88a5b418a7cb7bec780800f9635e0c731cba Mon Sep 17 00:00:00 2001 From: William Harrington Date: Wed, 21 Aug 2019 03:07:37 -0500 Subject: Okay then --- build/default/production/lcd.i | 49 ++++++++++++++++++++++++++---------------- 1 file changed, 30 insertions(+), 19 deletions(-) (limited to 'build/default/production/lcd.i') diff --git a/build/default/production/lcd.i b/build/default/production/lcd.i index 370b6b7..6ca4575 100755 --- a/build/default/production/lcd.i +++ b/build/default/production/lcd.i @@ -8,20 +8,6 @@ # 2 "" 2 # 1 "lcd.c" 2 # 1 "./lcd.h" 1 -void Lcd_Port(char); -void Lcd_Cmd(char); -void Lcd_Clear(); -void Lcd_Set_Cursor(char, char); -void Lcd_Init(); -void Lcd_Write_Char(char); -void Lcd_Write_String(char *); -void Lcd_Shift_Right(); -void Lcd_Shift_Left(); - - -void Vfd_Set_Brightness(int); -# 1 "lcd.c" 2 - # 1 "./conf.h" 1 # 1 "C:\\Program Files (x86)\\Microchip\\xc8\\v2.05\\pic\\include\\xc.h" 1 3 # 18 "C:\\Program Files (x86)\\Microchip\\xc8\\v2.05\\pic\\include\\xc.h" 3 @@ -1748,7 +1734,23 @@ extern __bank0 __bit __timeout; #pragma config CPD = OFF #pragma config WRT = OFF #pragma config CP = OFF -# 2 "lcd.c" 2 +# 1 "./lcd.h" 2 + + +void Lcd_Port(char); +void Lcd_Cmd(char); +void Lcd_Clear(void); +void Lcd_Set_Cursor(char, char); +void Lcd_Init(void); +void Lcd_Write_Char(char); +void Lcd_Write_String(char *); +void Lcd_Shift_Right(void); +void Lcd_Shift_Left(void); + + + +void Vfd_Set_Brightness(int); +# 1 "lcd.c" 2 @@ -1783,7 +1785,7 @@ void Lcd_Cmd(char a) { RD3 = 0; } -void Lcd_Clear() { +void Lcd_Clear(void) { Lcd_Cmd(0); Lcd_Cmd(1); } @@ -1805,7 +1807,7 @@ void Lcd_Set_Cursor(char a, char b) { } } -void Lcd_Init() { +void Lcd_Init(void) { Lcd_Port(0x00); _delay((unsigned long)((20)*(20000000/4000.0))); Lcd_Cmd(0x03); @@ -1815,6 +1817,9 @@ void Lcd_Init() { Lcd_Cmd(0x03); Lcd_Cmd(0x02); + + Vfd_Set_Brightness(0); + Lcd_Cmd(0x02); Lcd_Cmd(0x08); Lcd_Cmd(0x00); @@ -1844,17 +1849,23 @@ void Lcd_Write_String(char *a) { Lcd_Write_Char(a[i]); } -void Lcd_Shift_Right() { +void Lcd_Shift_Right(void) { Lcd_Cmd(0x01); Lcd_Cmd(0x0C); } -void Lcd_Shift_Left() { +void Lcd_Shift_Left(void) { Lcd_Cmd(0x01); Lcd_Cmd(0x08); } + void Vfd_Set_Brightness(int level) { + Lcd_Cmd(0x03); + _delay((unsigned long)((11)*(20000000/4000.0))); + Lcd_Cmd(0x03); + Lcd_Cmd(0x02); + Lcd_Write_Char(level); } -- cgit v1.2.3-54-g00ecf