Hi Guys,

I'm reading a value from pulsin (pic12f675), I want to know if that value is greater than 150, but I also want to know if that value stays greater than 150 for over than 3 seconds.

--------------------
value var byte

loop:

PulsIn GPIO.0, 1, value

IF (value > 150) Then
'do something here
EndIF

GoTo loop

----------

The first part it's easy, the second part, well, still looking on how to do it.

I searched the forum, but no luck. Could someone give me a hand?

Thanks!

Daniel.