LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

powering a rotary encoder

I have 2009  LAbview. I used a DAQ asist block and and I connected the DAQ to the encoder. I have to select the acquisition mode of the DAQ. I SELECTED "on demand" mode. now when I run the it and I rotate the encoder shaft, I can see the position(angle). BUT now I need to use this position in the labview as feed back to control a system. However I dont know what kind of data quisition I should use for this purpose. there are 4 choises: "1 sample on demand", 1 sample( hw timed)", N sample and continues. If I put any thing other than "1 sample on demand", it cant work and ask for an external clock! 

and If I want to use "on demand" mode then I cant subtract it a simulated sine signal(at the rate of 10k). I attached a pic of my code. please take a look.

Next I used to a block to align and actually ,make the output of NI the same rate as 10k but when I cant! 

 

 

Download All
0 Kudos
Message 11 of 12
(377 Views)

Well, I can see you're on the right track in general but to be honest, I don't ever use DAQ Assistants, Dynamic Data or Express VIs so I don't really know how to work with them the way you're doing.  Perhaps an NI Guy or someone who knows the Express stuff will check it out.  If not, I can help you after converting it to real LabVIEW code.  In the mean time, if you want to stick with the Express VIs, read up on them and see if they have the capabilities that you need. 

LabVIEW Pro Dev & Measurement Studio Pro (VS Pro) 2019 - Unfortunately now moving back to C#, .NET, Python due to forced change to subscription model by NI. 8^{
0 Kudos
Message 12 of 12
(362 Views)