Due to a health issue I haven't been dabbling for a while, could someone please point me in the right direction as to why this will switch on and off at the desired interval.
main:
if pin1 = 0 then main
if pin1 = 1 then lev1
lev1:
wait 5
high 2
wait 5
low 2
goto main:
But if I use PWM as in:
main:
if pin1 = 0 then main
if pin1 = 1 then lev1
lev1:
wait 5
pwmout 2, 199, 400
wait 5
low 2
goto main:
the switching does not work.
Many thanks.
Lez.
main:
if pin1 = 0 then main
if pin1 = 1 then lev1
lev1:
wait 5
high 2
wait 5
low 2
goto main:
But if I use PWM as in:
main:
if pin1 = 0 then main
if pin1 = 1 then lev1
lev1:
wait 5
pwmout 2, 199, 400
wait 5
low 2
goto main:
the switching does not work.
Many thanks.
Lez.