LabVIEW Interface for Arduino Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA resource hog?

So I have the arduino UNO receiving boolean signals to control an actuator. Works great. I also have another .VI that is grabbing live streaming telemetry from a racing simulation program which works great also. I then merge the code with the desire to ultimately control the actuator as if it is a shock. The arduino code works fine but now the telemetry code slows to a creep and very rarely refreshes and updates. I use highlight execution and everything seems fine. If this worked, the next step was to grab one of the telemetry variables and use it for the signal input. At this point, I am still using the boolean inputs. Again, they still work fine.

Is the visa resource taking over the majority of process execution time? Tried to slow it down but i am still a newbie at both Labview and Arduino much less interfacing them together.

Any obvious problems with the code shown here? The flat sequence in the front was just an attempt to control timing of the initialization execution. I added the code picture as a file in case it was too small to deal with here. And the flat sequence inside the while loop was there for the same reason.

Thanks in advance for any help.......

2014-03-09_11-48-49.jpg

2014-03-09_11-50-01.jpg

0 Kudos
Message 1 of 3
(3,136 Views)

Often it's the communication speed with the Arduino that will limit the execution of your code.  However, you also need to realize that the fastest that that code can run is 10ms (because of the timeout on the Dequeue Element).  Also, with two timing functions in the same loop, you might experience strange timing behavior.

0 Kudos
Message 2 of 3
(2,804 Views)

Thanks for the response.

I have eliminated the both flat sequences and also the timing delay. I was adjusting the dequeue timing with varying results but none of them good or even better. I believe it is a conflict with the visa calling of some sort. Any thoughts on how to test and or seperate the two issues. Either aspect works great without the other.

Thanks.

0 Kudos
Message 3 of 3
(2,804 Views)