Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQ help in automated task

Solved!
Go to solution

I'm using LabView 2011, and I'm also using a USB-6008.  I'm using the analog output A01 and Ground to run those to a BNC cable (the other side of the cable has marked areas for ground and center so that i know where to put my wires coming from the DAQ) that is hooked up to a trigger.  I want to trigger an arm to move up when high potential is applied (5V) and then bring it back down when there is no potential.  I'm having a hard time getting that to actually work though.

 

I tested my signal output on the measurements program and I am seeing a signal being given out from 5V then to 0V so that's good.  I also tried making it a task and that's where I got stuck trying to make the task and actually make the arm move.  Any tips on what could be done?

0 Kudos
Message 1 of 17
(3,145 Views)

Hi,

 

I'd like to ask you what is the power consuption of the arm?

The maximum output current for this card is 10m Amps and maybe your arm needs more current.

 

 

Best Regards

Miguel Fonseca

Applications Engineer

National Instruments

http://www.ni.com/support

 

0 Kudos
Message 2 of 17
(3,136 Views)

Well right now, the arm VI looks like this.  Now I just need to do the loop to make it run for 210 seconds at .5 Hz which I'm currently working on, if you have any tips, that would be great.

0 Kudos
Message 3 of 17
(3,133 Views)

I'm having trouble assembling a working loop.  Any help?

0 Kudos
Message 4 of 17
(3,118 Views)

You don't really think that by passing a '5' to the DAQ Assistant is supposed to indicate it is supposed to output 5 volts, do you? Either pass it a T/F Boolean or a 1/0 (for a logic 1/logic 0). Your 5 is converted to binary and will be the binary pattern 0b0101. This will gnerate an error because the pattern requires 3 pins to be used.

0 Kudos
Message 5 of 17
(3,114 Views)

No, the 5 was just arbitrary so that I knew what value for myself I had.  I don't generate any errors when I run the VI, my arm moves up and down without any problems.  I'm just looking to try and create a loop.  While this runs, I'm running an experiment to cover light and uncover light.  My arm blocks the light for the 2 seconds and then unblocks it for 2 seconds.

0 Kudos
Message 6 of 17
(3,106 Views)

Well, you do have a loop. to make the switching automatic, you just need a shift register/feedback loop with a Boolean and an invert function. Use the Delay function or Wait (ms) to control the timing.

 

 

0 Kudos
Message 7 of 17
(3,102 Views)

Alright I see that does the trick for the automation, how do I incorporate the DAQ properly?  I tried to hook it up in the loop but it only just went with "1" and didn't go back to "0."  Also, can I add iterations of the up and down in this particular loop or do I have to change it to a for loop?

0 Kudos
Message 8 of 17
(3,089 Views)

I don't use the DAQ Assistant and use the DAQmx functions (DAQmx Write - Digital Boolean 1Line 1Point) directly but try connecting the Assistant where the Boolean is.

 

Yes, you can stop a while loop after x number of iterations or use a for loop.

0 Kudos
Message 9 of 17
(3,080 Views)

So here's what it looks like, I do get like I said previously, a "1" but after, I can't get a "0."

0 Kudos
Message 10 of 17
(3,075 Views)