View previous topic :: View next topic |
Author |
Message |
jmaudley
Joined: 01 Feb 2011 Posts: 32 Location: 53
|
LCD example driver |
Posted: Tue Jan 15, 2013 11:24 am |
|
|
Hi,
I'm trying to get LCD.C example driver up and running.
The hardware is working. I know this because I can program it using another development language/compiler and it works.
The LCD interface is all portB so I want to use the port access.
The only issue I see is that the order of the pins is not the same as the example so I need to reconfigure pin access.
My port B is configured with the data lines on B0,1,2,3.
B4 is unused.
B5 is enable
B6 is rw
B7 is rs
So I have edited the LCD_PIN_MAP:
Code: |
unsigned int data:4 ;
int1 unused;
int1 enable;
int1 rw;
int1 rs; |
Wasn't sure if I needed to but I also reversed LCD_INPUT_MAP
16f873a
fuses HS,NOLVP,NOWDT,PUT
Result = not working.
Is there something wrong with my editing of the pin map?
Any help would be appreciated. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
|
jmaudley
Joined: 01 Feb 2011 Posts: 32 Location: 53
|
Got it working |
Posted: Wed Jan 16, 2013 5:57 am |
|
|
Thanks that was one of the problems.
I am also sharing the portB signals with the programmer interface.
It's taken me 4 hours of head scratching to realise that the programmer , which was connected, is affecting the state of the R/W signal.
When I unplugged the programmer it burst into life. |
|
|
|