LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Writing bytes out of Serial Port

I'm trying to write an array of numeric (U8) bytes out of the serial
port. The serial routines though only support strings. Labview has a
routine which converts U8 into strings but only upto x7F (which is the
limit of ASCII) and not to xFF.

Anybody have a workaround to this ?
Thanks.
0 Kudos
Message 1 of 2
(2,544 Views)
I just tried the "byte array to string" function (under "conversion"
subpalette under "string" subpalette) and did not see this limitation.
You can put an array of U8 on the front panel, change the format to
display Hex, and type any hex code 0 to FF, and send this thru "byte array
to string" and then through "string to byte arry" to get the original
array back. Create an indicator for viewing the intermediate string and
pop up on the string indicator to change it to hex display. You will see
all the "characters" being translated faithfully.
- Vinny Recca

Ashish Khanna wrote:

> I'm trying to write an array of numeric (U8) bytes out of the serial
> port. The serial routines though only support strings. Labview has a
> routine which converts U8 into strings but
only upto x7F (which is the
> limit of ASCII) and not to xFF.
>
> Anybody have a workaround to this ?
> Thanks.
0 Kudos
Message 2 of 2
(2,544 Views)