jojokatada
Full Member level 5

'display message on the 4 X 20 character LCD using pic16f84a and DS1820
DEFINE LCD_DREG PORTA 'LCD data port
DEFINE LCD_DBIT 0 'LCD data starting bit 0 or 4
DEFINE LCD_RSREG PORTA 'LCD register select port
DEFINE LCD_RSBIT 4 'LCD register select bit
DEFINE LCD_EREG PORTB 'LCD enable port
DEFINE LCD_EBIT 3 'LCD enable bit
DEFINE LCD_BITS 4 'LCD bus size 4 or 8
DEFINE LCD_LINES 4 'Number lines on LCD
DEFINE LCD_COMMANDUS 2000 'Command delay time in us
DEFINE LCD_DATAUS 50 'Data delay time
symbol DQ = PORTB.4
temp var word
cou var byte
cou1 var byte
pause 100
main:
owout DQ, 1,[$CC, $44]
owin DQ, 4,[cou]
if cou = 0 then
owout DQ, 1, [$cc, $BE]
owin DQ, 0,[temp.lowbyte, temp.highbyte, skip 4, cou,cou1]
endif
temp = (((temp >> 1) * 100) - 25 ) + (((cou -cou1) * 100) / cou)
lcdout $fe, 1, dec (temp / 100), " . " , dec2 temp, " C"
pause 1000
goto main
end
end
i got the error message please see the attachment
can anybody help me what wrong with my compiler?
DEFINE LCD_DREG PORTA 'LCD data port
DEFINE LCD_DBIT 0 'LCD data starting bit 0 or 4
DEFINE LCD_RSREG PORTA 'LCD register select port
DEFINE LCD_RSBIT 4 'LCD register select bit
DEFINE LCD_EREG PORTB 'LCD enable port
DEFINE LCD_EBIT 3 'LCD enable bit
DEFINE LCD_BITS 4 'LCD bus size 4 or 8
DEFINE LCD_LINES 4 'Number lines on LCD
DEFINE LCD_COMMANDUS 2000 'Command delay time in us
DEFINE LCD_DATAUS 50 'Data delay time
symbol DQ = PORTB.4
temp var word
cou var byte
cou1 var byte
pause 100
main:
owout DQ, 1,[$CC, $44]
owin DQ, 4,[cou]
if cou = 0 then
owout DQ, 1, [$cc, $BE]
owin DQ, 0,[temp.lowbyte, temp.highbyte, skip 4, cou,cou1]
endif
temp = (((temp >> 1) * 100) - 25 ) + (((cou -cou1) * 100) / cou)
lcdout $fe, 1, dec (temp / 100), " . " , dec2 temp, " C"
pause 1000
goto main
end
end
i got the error message please see the attachment
can anybody help me what wrong with my compiler?