FIREMANJIM
New Member
I am trying to understand how to use the TIME variable on the Picaxe 14M2 and 20M2 chips. As I understand it it works as a true second counter that I can reset at will. So will something like this work??
Code:
EnableTime
if PirInput = 1 then
pause 29
if PIRInput = 0 then
goto WalkTest
Endif
high LED
nap 6 ' pause low power for 1.1 seconds
low LED
nap 8 ' pause low power for 4 seconds
Time = 0
endif
if Time >= 30 then ' approx 30 seconds
for Counter = 1 to 10
high LED
pause 200
low LED
pause 200
next Counter
pause 1000
Disable Time
goto MainProgramLoop ' start main program loop
endif
Nap 3
goto WalkTest
Last edited by a moderator: