Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

stop writing data

Once I start the analog voltage generation to power a motor, the motor does not stop running. How do I stop the voltage generation besides entering 0 as the input voltage? Thank you.  
0 Kudos
Message 1 of 6
(3,524 Views)

Generating a 0 volts on the AO channel would be the sure shot way of stopping your motor.

Which DAQ card are you using?? are you using LabVIEW??

There is a Reset Device function which will return the device to its initialized state

See if using this function will bring your AO to 0V ( I do not have DAQ card with me. Hence I could not try it and suggest)

 

0 Kudos
Message 2 of 6
(3,509 Views)

Are you running open loop or closed loop?  If open loop, you should be fine with setting the voltage to 0 and letting the motor coast down.  If closed loop, you may need to consider the effect that a velocity step command will have on your motion system.

Unfortunately, it isn't always trivial to figure out what voltage you're presently generating so you can ramp your way down to 0 more gently.  IMHO, your best bet would be to wire your AO over to an AI channel so you can read your output voltage when it's time to ramp to 0.

FYI, here's an old thread I got into once that related somewhat to the need/desirability to ramp gently to 0.  Late in the thread I highlighted a "wishlist" for some DAQmx properties that ought to be available.  Like the ability to query an AO task for the value being output at the DAC, preferably any time but certainly whenever the task is stopped.  It's also possible this ability has been added as I haven't checked again for the last several DAQmx versions.

-Kevin P.

ALERT! LabVIEW's subscription-only policy came to an end (finally!). Unfortunately, pricing favors the captured and committed over new adopters -- so tread carefully.
0 Kudos
Message 3 of 6
(3,504 Views)
Kevin, there is no waveform buffer generation.vi in the
Attachment output_volt_special.vi (81 kb)
 
Therefore I can't see it.
 
I have another problem, I am trying to control the motor by generate 5V from LabView. The encoder of the motor displays exactly the position of the shaft at a specific time. I think every time the index channel of the encoder displays a pulse, the motor is at the same place. Is there a way to use LabView to control the motor so that the shaft returns to its initial position? Thank you very much. I am using LabView, my DAQ card is PCI-6014.
0 Kudos
Message 4 of 6
(3,481 Views)
I don't quite understand what is open loop or close loop. I need to power the motor so that every time the shaft crosses 0 to 35 degrees, it display two cursors, I need to do this using the encoder signal. the channel index of encoder diplay a pulse everytime the shaft crosses 0 degree. Channel A display 500 pulses/turn, by counting the pulses in channel A, I will be able to figure out exactly the position of the shaft in terms of degrees at a specific time.  I am very new to LabView and I don't understand a lot of terms like buffer size. Could you please tell me how to do this? Thank you.
0 Kudos
Message 5 of 6
(3,478 Views)
Hey chen56,

There is no simple way to set the analog output to zero other than updating the buffer with a zero value or resetting the device. Is there any reason you do not want to update the output buffer with a zero value?

If you want to ramp down the value you will need to make an array of the ramp values and update the analog write with it. You can use the Ramp Pattern.vi to generate values for your ramp.

Cheers
Malay Duggar
NI
0 Kudos
Message 6 of 6
(3,470 Views)