LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

30 second counter for detecting peaks

Hello,

I want to count number of peaks detected in a 30sec interval from a pulse signal acquired using DAQ.I made this programme and in this each second is almost taking 12 sec's more as compared to the real clock second.As a total it taking more than what I need(30sec).In real time the sinesimalutesignal vi will replaced with the DAQAssistant.And also the programme is not always running when the run is clicked but rather running sometimes.

Can some help me with this.

thanks in Advance.

0 Kudos
Message 1 of 2
(2,106 Views)

Hi PatanGova,

 

I am not sure if I understand your question properly. However, I took a quick look at your program and modified it a bit. I removed the outer while-loop and the case structure and added some error handling and initialization. I also removed the 1 sec timing in your loop, because if you open the simulated signal express vi, then under timing you can choose "simulate acquisition timing" to run the loop in the rate specified by the signal collection rate (1000 Hz with 1000 samples equals one second worth of data).

 

What happens now is that you generate a sine wave with the frequency of your choice. You will collect 1000 samples for every loop cycle, executed once every 1 second. You count the number of peaks in real-time and also the total after the 30 second countdown.

 

Please tell me if this helped anything or try to specify your question again.


0 Kudos
Message 2 of 2
(2,035 Views)