Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Control output hang using Express Vi

Working on this
Download All
0 Kudos
Message 1 of 3
(2,934 Views)
Working on this project to control an H-bridge motor using a sensor that detects the input from a digital line. Input detects whether on a white or black part of the strip. This is a passed through a comparator to get a digital input and Adjusts every five degrees. The output has two control outputs. One for counterclockwise and clockwise. The thing works if you repeatedly run skipcolor but when run the whole VI. The motor will only ouput from the control lines once. Then it hangs. It won't output during the skip color white phase. Moving just that part of the circuit to another vi the same problem occurs. I am using the PCI-MIO-16E controller.
0 Kudos
Message 2 of 3
(2,933 Views)

Hi excetara2,

I don’t see anything in your code that would cause it to stop updating. One potential problem I see is that the entire program is software timed. This could cause problems with motor control because Windows is not deterministic. Your code will not always run at a consistent speed. I’d be happy to offer some advice about ways around this if you can tell me a little more about your overall goal for this project.  How do you want the motor to behave if everything is working properly?

Thanks,

Nathan
NI Chief Hardware Engineer
0 Kudos
Message 3 of 3
(2,895 Views)