Hi,
Your program jumps to the same location whatever the pulsewidth is:
Change the the second If statement toCode:ReadPWM: PulsIn GPIO.3, 1,Pulselen ' pin 4 - read high pulse length, times out after .65535 seconds pause 15 If Pulselen < 50 Then GoTo Blink '<----HERE...... If Pulselen > 50 Then GoTo Blink '<----and HERE..... GoTo ReadPWM
HTHCode:If Pulselen > 50 then Goto Solid
/Henrik Olsson.
Bookmarks