In theory it has to work, you may have one of those LCD timing problem OR LVP mode set to on. try
for 16F877a
Code:
@ __CONFIG _XT_OSC & _LVP_OFF
define OSC 4
' Define LCD registers and bits
DEFINE LCD_DREG PORTB
DEFINE LCD_DBIT 4
DEFINE LCD_RSREG PORTB
DEFINE LCD_RSBIT 2
DEFINE LCD_EREG PORTB
DEFINE LCD_EBIT 3
DEFINE LCD_COMMANDUS 2000 'Command delay time in us
DEFINE LCD_DATAUS 50 'Data delay time in us
Play with the contrast pot, make sure the R/W pin is tied to low. Not better, you may need to play with COMMANDUS and DATAUS values.
For the 16F88 you may need to disable some Analog feature.
HTH
Last edited by mister_e; - 23rd April 2008 at 14:58.
Steve
It's not a bug, it's a random feature.
There's no problem, only learning opportunities.
Bookmarks