EDIT: I solved the problem, the EBIT was on set to the wrong pin. Anyway, I will leave the post active if anyone wants to know how to interface a 16F819 with the LCDOUT command in PB. Setting on EPIC Programmer is XT.
I have tested my circuit on the 16F84A and the LCDOUT program works perfect.
I am now trying to get this working with 16F819 so I can use the ADC and I just cannot get anything to display on the LCD....any suggestions?
Also, I am not sure my config for the external osc is correct. I am using a 4Mhz crystal with two 18p caps and selecting XT in the EPIC oscillator Config setting....which worked fine for the 16F84A.
Code:DEFINE OSC 4 DEFINE LCD_DREG PORTA ' uses Port A on Ports A 0,1,2,3 DEFINE LCD_DBIT 0 DEFINE LCD_RSREG PORTA DEFINE LCD_RSBIT 4 DEFINE LCD_EREG PORTB DEFINE LCD_EBIT 3 DEFINE LCD_BITS 4 DEFINE LCD_LINES 2 TRISA = %00000000 'make Port A outputs TRISB = %00000000 'make Port B outptuts ADCON1 = 7 ' turns off adc Pause 1500 ' Wait for LCD to startup BlinkyLED VAR PORTB.1 ' This LED will BLINK Pause 1500 ' Wait for LCD to startup loop: High BlinkyLED LCDOut $fe, 1 ' Clear LCD screen Pause 500 LCDOut "Hello" ' Display Hello Pause 1000 ' Wait 1 second 'LCDOut $fe, 1 ' Clear LCD screen LCDOut $fe, $c0 ' Move to next line on LCD LCDOut "How are you?" Low BlinkyLED Pause 1000 ' Wait 1 second GoTo loop ' Do it forever





Bookmarks