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: 

(Hex 0xBFFF003E) Could not perform operation because of I/O error

Very simple case that I have a device that can send out some message by uart when pressed a button.But every time there is  an error while it receive a 0x00:(Hex 0xBFFF003E) Could not perform operation because of I/O error.

See the code.I also tried in NI-MAX and get the same error.2016-11-30_214849.png2016-11-30_214546.png

0 Kudos
Message 1 of 2
(2,509 Views)

I see this all the time when reading for the first time from a device right after opening a comport. You might want to flush the buffer the first time to clear out any junk on the line.

Then you might want to trap errors and ignore the I/O error and try to read again. But you will need to stop your while loop by some other means.

Do not over look that the problem could be you and your device are not talking at the same speed. That will show up as an I/O error. Can you talk to your device with a terminal program? 

Omar
0 Kudos
Message 2 of 2
(2,484 Views)