Measuring time between pulses
Archiver
Posts: 46,084
Hi All,
I am new to the group and have a need to record a series of pulses
and measure and record the time between those pulses. I expect up
to 10 pulses within say, 3 seconds of time.
Is there an easy way to accomplish this using a BS2SX?
Thanks
Don
I am new to the group and have a need to record a series of pulses
and measure and record the time between those pulses. I expect up
to 10 pulses within say, 3 seconds of time.
Is there an easy way to accomplish this using a BS2SX?
Thanks
Don
Comments
donaldscott_18@y... writes:
> I am new to the group and have a need to record a series of pulses
> and measure and record the time between those pulses. I expect up
> to 10 pulses within say, 3 seconds of time.
>
> Is there an easy way to accomplish this using a BS2SX?
>
With the BS2 I write
for x = 1 to 10
pulson pin, 0, result 'pulse width is stored in result,0 is low to
high
w(x) = result '1 is high to low
next
for x = 1 to 10
debug ? w(x), cr
next
You might have to modify this a bit - I'm not familar with the BS2SX
Sid
[noparse][[/noparse]Non-text portions of this message have been removed]
>I am new to the group and have a need to record a series of pulses
>and measure and record the time between those pulses. I expect up
>to 10 pulses within say, 3 seconds of time.
>Is there an easy way to accomplish this using a BS2SX?
>Thanks
>Don
How much resolution do you need in the timing of the pulses? The
reason I ask is that the Stamp will have to do the timing in a loop.
While the BS2sx does have builtin PULSIN and RCTIME commands that
have resolution to 0.8 microsecond, they are not able to time a pulse
much longer than 50 milliseconds (0.8 * 65536 microseconds).
I have some options for timing longer pulses posted at
http://www.emesystems.com/BS2speed.htm#longpulse
There is the option of using a loop in code that can resolve the time
to about 0.5 millisecond on a BS2sx, or there are solutions using
external support chips.
-- regards,
Tracy Allen
electronically monitored ecosystems
mailto:tracy@e...
http://www.emesystems.com