ski, i removed both of those flashing routines and the problem was still there. then i removed the SOUND statements aswel. seemed to have sorted out the lag issue. the problem is that now i have only a high led and low led when the setpoints are reached but thats not even working
Code:
checkdone:
if adcon0.2=1 then checkdone
adval.highbyte=adresh
adval.lowbyte=adresl
tempc=50*adval
tempc=tempc/100
If tempc>=highpt then
gosub high_flash
SOUND buzzer, [60, 100, 23, 200]
relayhigh = 1
else
relaylow = 0
lowled = 0
buzzer = 0
endif
If tempc<=lowpt then
gosub low_flash
SOUND buzzer, [20, 100, 23, 200]
relaylow = 1
else
relayhigh = 0
highled = 0
buzzer = 0
endif
return
Bookmarks