LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Serial communication to read single character

Hi! List,
I want to read single character using serial communication(see the attached VI).
The initialization of the serial port is taken care.
TIA
0 Kudos
Message 1 of 3
(2,781 Views)
I'm not sure I can understand you. If you want to read just one single character why can't you do so by just passing 1 to the Serial Read function as the number of bytes to read?

The diagram of above VI doesn't make to much sense to me I have to admit.

Rolf K
Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
0 Kudos
Message 2 of 3
(2,781 Views)
Rolf is right. If you want to read a single character just wire 1 to the byte count of the serial read. But I guess you meant differently.

According to the code, data loss is inevitable. "Scan string for tokens" returns the first token, in your case, seperated by "\s \t \r \n" even if multiple tokens are available.

-Joe
0 Kudos
Message 3 of 3
(2,781 Views)