LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Why can't I get the same size of data from using Bytes at Port in VISA property node.

hi~tst.

Please look into the attached VI below and let me know.
0 Kudos
Message 11 of 14
(718 Views)
Hi~tst.

Please look into the attached VI below and let me know.

It is my basic sample code to read data from device.
0 Kudos
Message 12 of 14
(718 Views)
This is my second code.
0 Kudos
Message 13 of 14
(717 Views)
I'm not sure. I never used serial in the same way you do, and I never used the Find Resource VI, so this is wild guessing - maybe the code running in your left loop is resetting the port after a few bytes were sent and that's why you're losing them. By that line of thought, this didn't happen before because your search for the other ports is what's slowing you down. I made a quick modification of your code to work according to what I suggested in my last post - once you found the port, you keep reading from it until there is an error. If this is still causing you trouble, you can try clearing the buffer before reading for the first time. Hope this helped.

___________________
Try to take over the world!
0 Kudos
Message 14 of 14
(705 Views)