08-29-2016 01:00 PM
Hello everyone,
Right now I am trying to use a VISA that before seemed to work fine, but as I increased the cycles in my main program, it seems to slow down sometimes, giving an error. Basically it controls a motor. I first send data to tell how much to move the motor with the X-move.vi and then I keep checking the position with the VI GetPosition.vi until it reaches the expected value.
But sometimes the first VI takes longer and gives an error, that makes the following VI to say it is in the position "0".
I believe it might be a problem about memory, but I don't know anymore what to try.
Could you please give me some help?
Thank you!
08-29-2016 01:14 PM
These look like they would be subVI's be used in another VI that would have a loop around them. Is that true?
If so, why are you opening the com port and configuring it on each call of these subVI's.
Com ports should be configured once before a loop starts, and closed after a loop ends. In between, it should be just VISA reads and writes.
09-05-2016 08:24 AM
I actually found it was some conflict of parallel loops that used these VI unnecessarily "simultaneously". But I also want to solve that situation of opening and configuring all the time, as in the beginning I didn't understand so well about these so it got badly programmed. Thank you for the answer 🙂