LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Timer

Solved!
Go to solution

This weekend I must submit homework. But I don't know how to do it. Could you help me please ? 

 

Here is the task.

 

Create a VI to measure the obstacle course time. The obstacle course has a beginning and an end at the same place and is equipped with an optical wound with a photoresist. The name of the current competitor is written on the front panel. The timekeeping is triggered and stopped by interrupting the light flow through the optical gate. At the end of the run, the time in seconds, along with the rider's name, is added to the previous record of the text file "result.txt" in name-time format. After pressing the button on the front panel, the name of the competitor with the best time is displayed.

0 Kudos
Message 1 of 11
(3,265 Views)
Solution
Accepted by topic author MartinkoKlucar

Hi Martinko,

 

This weekend I must submit homework. But I don't know how to do it. Could you help me please ?

Some simple steps:

Learn the LabVIEW basics.

Examine the example VIs coming with LabVIEW.

Develop an algorithm - on a sheet of paper!

Then start to code your homework.

 

You still have 3 days to complete, so hurry up!

 

General advice: when you have specific question you need to ask in a specific way. We will not do your homework!

 

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 2 of 11
(3,249 Views)

You're right, I have some algorithm in my head, but I don't know how to start and stop time with a pulse.

0 Kudos
Message 3 of 11
(3,226 Views)

Hi Martinko,

 

how to start and stop time with a pulse.

Are you about a time machine? 😄

 

You surely want to measure the time between two pulses: you need a DAQ device, you need to read your "pulse" signal, find the pulses, and determine the time between them. What have you tried so far?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 4 of 11
(3,221 Views)

You're right, I have some algorithm in my head, but I don't know how to start and stop time with a pulse. I want to do it by shift register... I will count how many times the loop repeated and than I multiply it with time delay. But how I mentioned I don't know how start counting loops when the first pulse comes and end it with the second pulse.

0 Kudos
Message 5 of 11
(3,219 Views)

I tried to do it with some basic .... like if ... :DDD but ... its not good. But I will trie to measure duration between pulse...

0 Kudos
Message 6 of 11
(3,212 Views)

Hi Martinko,

 

I don't know how start counting loops when the first pulse comes and end it with the second pulse.

Each loop has a loop iterator: read it whenever you detect a pulse and store it in a shift register until there is a 2nd pulse…

 

Using shift registers and loop iterators are pretty basic stuff, so back to item 1 of my list above!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 7 of 11
(3,211 Views)

But how I Can find out which is first "rising edge" and how when its the second "rising edge" the it stops from one channel ?

0 Kudos
Message 8 of 11
(3,148 Views)

Hi Martinko,

 

you could count them - and keep the counter in a shift register…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 9 of 11
(3,135 Views)

Thanks... 

 

I had a lot of attempts but none worked (I feel so dump)... please could you show me the detection of pulse and measure time ? The other I think I can make it ,but I can't move without it..... 

 

Thanks for answer 🙂

0 Kudos
Message 10 of 11
(3,129 Views)