Counter/Timer

cancel
Showing results for 
Search instead for 
Did you mean: 

Two Counter (Finit Saples) Controlled by 3rd Counter.

Solved!
Go to solution

Hi,
This is my first consultation in this forum and I hope it is not the last!
My sutuation is this:
I generate three frequency-dependent signals, called in my case F0, F0_NOT and Ping_Rate.
- F0 and F0_NOT are a pulse train at a frequency Fx and a duty cycle of 40%.
- F0_NOT is delayed 50% of the Fx period.
- The third signal is a train of pulses that controls the previous ones and serves as a control for other instruments.
- The parameters that can be varied are the Fx Frequency, the number of pulses in F0 and F0_NOT and the frequency of Ping_rate.

To generate the signals I have a PXIe-1071 and a PXI-6602 module. I am using counters 0,2 and 4 for each signal.
The problem I face:
I generated this VI from the different examples I have found but I still have a long way to go to understand this of the counters. The three signals are generated well but the problem is that when I enter the loop the signals F0 and F0_NOT are only generated in the first start and from there only the Ping_Rate signal remains.
I expected that every time the Ping_Rate pulse was activated, the task of the other two signals would be executed.
The question I have, is that I am missing so that the F0 and F0_NOT signals are executed while the Pin_Rate signal is executing?
Thank you in advance for your valuable help.

Note: On the images, Yellow is F0, Pink is F0_NOT and Blues is Ping_Rate.

Download All
0 Kudos
Message 1 of 4
(2,203 Views)

If I understand you right, I think that all you need is to add a DAQmx Trigger Property node to both F0 and F0_NOT configs to set the "Retriggerable" property to True.

 

By default, triggered tasks will trigger once and only once.  The Retriggerable property is needed to let the hardware do all the retriggering work.  (Though counter output tasks generally support retriggering, not all other task types or boards support retriggering.  Sometimtes it's sufficient to stop and restart the task in software between distinct triggerings.  But this always leaves open the possibility of missing a trigger during the time it takes to do the stop and restart.  So the hardware method is more reliable, when available)

 

 

-Kevin P

ALERT! LabVIEW's subscription-only policy coming to an end (finally!). Permanent license pricing remains WIP. Tread carefully.
0 Kudos
Message 2 of 4
(2,184 Views)

HI Kevin,

 

Thank you for your prompt response ..

 

After uploading this question I continued searching the forum and I found a solution that you had already given in another very similar case, which applied and worked for me as you say.


Only, because I use a signal with a time delay F0_NOT, this after the first trigger started at the same time as F0, so when I wanted to activate the property "CO.EnabelinitialDelayOnretrigger" I got an error about which module or the task did not support this property.


Fortunately I have a different PXIe-6366 module that can support it and it worked very well..


I appreciate your time and thank you.

 

Regards.

0 Kudos
Message 3 of 4
(2,155 Views)
Solution
Accepted by topic author Navico

Just for the record.. I upload the modified and working VI.

 

Thanks again.

0 Kudos
Message 4 of 4
(2,148 Views)