PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to Measure Frequency to RPM NI-DAQmx Tasks

Solved!
Go to solution

 

Hello,

 

I am trying to measure frequency using NI DAQmx task and then convert this to an RPM if at all possible.

 

I have the following hardware options at my disposal.

 

I have SCXI 1126 Module along with a SCXI 1327 terminal, as well as a PXI 6289 Multifunction DAQ.

 

I have wired in a mag sensor to ai7 on my 1126 and when I pass a metallic object I get a amplitude of 6  - 8  so I am able to read the mag sensor.

 

What I am trying to do is to somehow convert this analog measurement into a RPM while only utilizing the NI DAQmx task.

 

Any help would be appreciated.

Tim
0 Kudos
Message 1 of 4
(6,220 Views)

Hi Smooth,

 

In your screenshot, you can see the output graph varies from 0-7 or so. That plot is already scaled by the software to be in Hz.

I'm not sure how you have your mag sensor set up, but if it gets one pulse, or outputs one cycle of a sine wave for every revolution, you would multiply the output in Hz by 60 to get rpm. If you had more the one pulse or cycle per revolution, you would multiply by revolutions per cycle.

 

(Cycles/Second ) *(60 seconds/1 minute)*(1 revolution/1 cycle)=revolutions/minute

 

You can set this up using a custom scale. Select the drop-down next to <No Scale> and use "Create New..." you can then plug in the equation above to get an output that is scaled to rpm.

 

I hope this helps clear things up.

 

Regards,

 

0 Kudos
Message 2 of 4
(6,199 Views)

 

So I would select new in "Custom Scaling"

 

Then would I select linear?

 

Your calculations are simple but I am unsure if this would give me the desired result.  From my attachment I am seeing an input amplitude of 6 Hz for each pulse.  What I mean by this is that every time I bring a ferrous object near my mag pick up I get a pulse, this is what I was trying to illustrate in the attachment.  The analog pulse comes in a 6 Hz so I would simply multiple this pulse by 60 (assuming I get one pulse per rotation) to get RPM?

 

How would this make sense if I only input one pulse for a long duration of time? 

 

I have notice the amplitude of the pulse input increases with increased pulse frequency.  Does this mean the lowest RPM I can record is 360 RPM?  

Tim
0 Kudos
Message 3 of 4
(6,189 Views)
Solution
Accepted by topic author smoothdurban

Hi Smooth,

 

Yes, you would select linear, then put in the result of that calculation for the slope.

 

The manual recommends a minimum input frequency of at least 15 Hz for the lowest range setting. This card isn't really designed to measure frequency for a single pulse in a long period of time.

 

So the lowest RPM (assuming one pulse per revolution) that we recommend measuring with the 1126 is 900 RPM. If you need to measure lower rpm, and you can't increase the number of pulses per revolution, you might consider either reading the signal in as an analog waveform, or if it's a digital pulse, using a counter based task. That way you could use whatever method you want to handle the situation where there is only one pulse in a long while.

0 Kudos
Message 4 of 4
(6,179 Views)