From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Zaber return position function

That sounds strange, Anne. Did you try using the Highlight Execution button or the other techniques I recommended above? My guess is that you are not reading the responses as fast as the device is sending them, so they stack up in the receive buffer.

 

Don

0 Kudos
Message 11 of 13
(460 Views)

Don,

 

I used the highlight execution monitoring the read back. The program is the same as my last attachment.

Do you see anything in the program that can contribute to the issue?

Any device setting can reduce buffer load?

Can you flush the receive buffer?

 

Thanks,

Anne

0 Kudos
Message 12 of 13
(452 Views)

You can flush the receive buffer, Anne, but you might cause problems if it's in the middle of receiving a packet when you flush it. It's safer to use a while loop to just keep reading responses with the non-blocking read VI until it returns false, then use the Request VI to send a request and receive a response. That's equivalent to flushing the receive buffer, but won't leave you with half a response in the buffer.

 

Don

0 Kudos
Message 13 of 13
(447 Views)