Andrew Cowan
Senior Member
Hi all.
I am trying to measure the spped of an axle.
I have a slotted optoisolator, with a stripy disc going through it.
Looking at the signal on a scope, as the axle turns, a sine wave is produced.
I tried to use the COUNT command to measure the number per 200ms, but it gives very erratic results. I think this is due to the input being a sine wave - it looks for a low to high transition every 10uS. In a sine wave, there is never a definite low to high change - it is a slow variable process so it usually misses it.
When it should have been getting around 200 counts, it was getting 10 or so.
I haven't tried using PULSIN, but I imagine it would have the same problem.
In that case, I would need to make the signal digital. The complex way is using an op-amp. Would a schmitt trigger or something be an easier way?
Thanks for any suggestions,
A
I am trying to measure the spped of an axle.
I have a slotted optoisolator, with a stripy disc going through it.
Looking at the signal on a scope, as the axle turns, a sine wave is produced.
I tried to use the COUNT command to measure the number per 200ms, but it gives very erratic results. I think this is due to the input being a sine wave - it looks for a low to high transition every 10uS. In a sine wave, there is never a definite low to high change - it is a slow variable process so it usually misses it.
When it should have been getting around 200 counts, it was getting 10 or so.
I haven't tried using PULSIN, but I imagine it would have the same problem.
In that case, I would need to make the signal digital. The complex way is using an op-amp. Would a schmitt trigger or something be an easier way?
Thanks for any suggestions,
A