Lcd Help, Pin allocation
Posted: Sat Aug 21, 2010 5:08 pm
Im using the custom component for ks108 lcd
Problem is im lost as i dont know which pin goes where, on the alphanumeric display you can select which port and pin each line goes to. with the custom component i cant do that.
When code is generated in C i just get this
//Common defines
#define MX_DATA_PORT portd //my value
#define MX_DATA_TRIS trisd //
#define MX_CONTROL_PORT portb //
#define MX_CONTROL_TRIS trisb //
#define MX_CS1 0 //
#define MX_CS2 1 //
#define MX_DAT_INST 2 //
#define MX_ENABLE 3 //
#define MX_READ_WRITE 4 //
This doesnt look right to me...
Is there something im missing, i want to be able to find the following
D0-D7 which pin is allocated the which, looking at the above code they appear to be on port D, but im not sure which pin on portD goes to Which pin on LCD
would it be like LCD- d0 --------Pic d0 and so on??
and i need to find the same for the control lines, i.e cs1, cs2, reset etc
I have looked at the readme file but the pinouts on there are different to my screen so there not 100% correct
Hope this makes sense, im only just learning so i might have confused you
Problem is im lost as i dont know which pin goes where, on the alphanumeric display you can select which port and pin each line goes to. with the custom component i cant do that.
When code is generated in C i just get this
//Common defines
#define MX_DATA_PORT portd //my value
#define MX_DATA_TRIS trisd //
#define MX_CONTROL_PORT portb //
#define MX_CONTROL_TRIS trisb //
#define MX_CS1 0 //
#define MX_CS2 1 //
#define MX_DAT_INST 2 //
#define MX_ENABLE 3 //
#define MX_READ_WRITE 4 //
This doesnt look right to me...
Is there something im missing, i want to be able to find the following
D0-D7 which pin is allocated the which, looking at the above code they appear to be on port D, but im not sure which pin on portD goes to Which pin on LCD
would it be like LCD- d0 --------Pic d0 and so on??
and i need to find the same for the control lines, i.e cs1, cs2, reset etc
I have looked at the readme file but the pinouts on there are different to my screen so there not 100% correct
Hope this makes sense, im only just learning so i might have confused you