5/30/2023 0 Comments Pic18f4550 mikroc 7seg display![]() ![]() In the lcd.h file are the IO ports listed which are used for the communication with the LCD. Included in the zip file are the new LCD.c file and the modified lcd.h file. The project I send to you is a setup for a CANBUS driver but only the LCD routine is included, so you can remove all CAN related features from the project tree, like can2510.h and spi.h. When the LCD is processing the data the PIC main program is free of any delays. Instead the timer1 is used to generate a waittime to let the LCD process the sended data. The advantage of this routine is that no delays are used for the LCD. Here I modified the c file completly into a state machine switch. I coud not find the modified XLCD.c file, instead I've mailed you the converted file. The lcd data is connected on bit 4.7 of port D #define TRIS_E TRISCbits.TRISC7 /* TRIS for E */ #define E_PIN LATCbits.LATC7 /* PORT for E */ #define TRIS_RS TRISCbits.TRISC6 /* TRIS for RS */ #define RS_PIN LATCbits.LATC6 /* PORT for RS */ #define TRIS_RW TRISCbits.TRISC5 /* TRIS for RW */ #define RW_PIN LATCbits.LATC5 /* PORT for RW */ ![]() * These are just samples, change to match your application. * CTRL_PORT defines the port where the control lines are connected. * DATA_PORT defines the port to which the LCD data lines are connected */ Nice to meet you (I continue in english, wish this discussion help other people).Īnd this is the version xlcd.h that I modified according to my board ( I have checked the elettric lines and I'm quite sure that it's correct)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
June 2023
Categories |