From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

DASYLab

cancel
Showing results for 
Search instead for 
Did you mean: 

How to reset timer dasylab

Please can you help.   I have a machine that has a 5v trip switch.  When the switch is clicked dasylab reads other channels and writes data to file.  I have

fitted encoder that has to many pulses so I want dasylab to write to file on every say 10th pulse.  

 

The old system was easy as dasy lab took reading for each trip switch.   Please can anyone help

0 Kudos
Message 1 of 12
(6,564 Views)

I woul duse a counter with raising TTL and use either a trigger or action to trigger every 10 pulses and use an action to reset the counter.

 

Which versio DASYLab do you have?  with which options?

Tom Rizzo
InSyS Corp.
www.insyscorp.com
Your DASYLab integrator
0 Kudos
Message 2 of 12
(6,563 Views)

Thanks.  I do not use counter at the moment because it take 1 reading each time trip switch activated.    Now I need to take 1 sample after 10 pulses I assumed I needed counter ?   I use version 7 dasylab but have version 11 demo to use and will purchase  Many thanks

0 Kudos
Message 3 of 12
(6,560 Views)

Correct, you will need the counter module,

 

Please download versiuon 12 it is the newest one.

Tom Rizzo
InSyS Corp.
www.insyscorp.com
Your DASYLab integrator
0 Kudos
Message 4 of 12
(6,555 Views)

The Statistics group has a Counter module that will allow you to count the edges.

 

For counting every 10, I would set up the counter to count the edges, which will output an increasing value. Then use the Arithmetic-1 channel and a constant - module to do Modulo 10. This will output 1,2,3,4,5,6,7,8,9,0,1,2,3,4,5,6,7,8,9,0.... the fall from 9 to 0 looks like a Falling edge, which you can then use to trigger the write.

Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.
0 Kudos
Message 5 of 12
(6,552 Views)

Many thanks I will download 12.    What actions  (module) will I use to reset counter ? 

0 Kudos
Message 6 of 12
(6,549 Views)

If you're using CJ mode, you will not need to reset it.  But in the action, when you trig between 9 and 0, you can select the counter module and detect falling edges, the select reset counter as the action

Tom Rizzo
InSyS Corp.
www.insyscorp.com
Your DASYLab integrator
0 Kudos
Message 7 of 12
(6,544 Views)

See my previous response... I think that Tom and I stepped on each other.

 

Counter can count up forever, and use Modulo arithmetic to create a stair that falls every 10 pulses.... this falling edge can then be used by a Combi Trigger module to create the rising edge that you need for the relay to release the value. 

Measurement Computing (MCC) has free technical support. Visit www.mccdaq.com and click on the "Support" tab for all support options, including DASYLab.
Message 8 of 12
(6,542 Views)

Ok I think I understand.  Just off to try it  Many Thanks

0 Kudos
Message 9 of 12
(6,540 Views)

Gents  I am feeling pretty stupid about this one.  I am in construction. Can you give me an idiots step by step  ie

 

1: Drag Counter module  (count falling edges)

2: Drag arithmetic module and enter ?

3

4

5

 

I have bits from trigger

I have bits before counter

 

Very sorry

0 Kudos
Message 10 of 12
(6,532 Views)