LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview timer for light gates

Hi everyone,

 

I am completely new to using Labview, but was requested to use it by my supervisor to log timer data from a pair of light gates. I'll quickly set out the problem.

 

I currently use 2 light gates to measure walking speed for my research (think school-level physics simplicity). They are currently linked to a basic timer and the time manually logged. It has been requested that this logging be done automatically by a PC in order to ensure data security. So now the wires from the light gates instead feed into an NI USB DAQ.

 

I basically need a timer that will read the signals from the DAQ and start/stop the timer whenever a signal is received (that way the system can walk with a subject moving in either direction). If possible the timer would then write the time recorded to a file and save it. I can manually reset the system after each trial, so a reset button but not an automatic reset function is neccessary, unless it is easy to do?

 

Are there any programs already written that could accomplish this, or ones that I can adapt for this purpose?

 

If anymore information on the problem is required to help answer it, please let me know. I'm knew to this area of research and the software used within it and am not sure what information is required to fully define a problem.

 

Regards

 

Richard

 

0 Kudos
Message 1 of 4
(3,642 Views)

RichardM5422 wrote:
It has been requested that this logging be done automatically by a PC in order to ensure data security.

<START NITPICK>

Well, technically, that does nothing for data security. It's more of a repeatability and accuracy issue.

<END NITPICK>

 

There are several solutions to your goal. What kind of USB DAQ do you have? Some have timers, some don't, so the solution will depend on what you've got. Have you installed DAQmx (the software required to control the DAQ device from LabVIEW)? There are lots of examples that get installed with it, so that's the first place I'd look.

0 Kudos
Message 2 of 4
(3,629 Views)

Richard,

 

I have something similar to what you seem to be asking which I wrote in 1999.  It is still being used regularly, mostly to time turtles, insects, salamanders, and similar animals.  In 1997 we put together a system which tracked the position of a runner along a linear path and controlled a visual image according to the subject's distance from the image.  These systems used 4 to 16 gates.

 

As smercurio_fc asked, please specify your hardware.   What kind of timing accuracy and resolution do you want?  Will the displays be on the computer screen or external?  If external, how will you connect to them?  Do you have a specific file format or can you modify the files?

 

Lynn

0 Kudos
Message 3 of 4
(3,612 Views)

I'll try and answer all the questions below :

 

The DAQ is a USB-6215, and I've included the link to it on the NI website.

 

https://www.ni.com/en-us/shop/model/usb-6215.html

 

From reading the data sheet, I think the DAQ has two timer/counters built in.

 

Accuracy should be ± 1 Sec. in 24 hours, and the resolution should be 0.01s.

 

The counter will be displayed on the computer screen.

 

As for the file format, anything that can be read by Matlab would be ideal. If the timer were to just record the time measured, and write it as a single number to a txt file and save this, that would be fine.

 

johnsold, this system you use sounds like a very advanced version of mine. I've tried to keep mine as simple (and cheap) as possible, as all I need is a measure of the subjects walking speed at the midpoint of the trial.

 

PS, apologies for two horrendous spelling typo's in my first post, no matter how many times I proof-read I always miss something.

0 Kudos
Message 4 of 4
(3,587 Views)