I tried to send one character at a time by using the textchanged event, but I ran into issues with the last character getting sent again after a carriage return or a space for some reason. I'd type something like run visutl and runn visutll would get sent. After trying to figure out what that was happening, I decided to just use the enterpressed event, but I had to send the bytes one at a time rather than just take the whole string, convert it to bytes a send it all. This seemed to slow things down enough to allow the host system to handle the characters one at a time. There still seems to be something funky with the carriage return at the end where the host seems to handle it for some commands just fine but not for others. I'm going to keep plugging away at this but if you see any obvious problems, please let me know.
Thanks for the help.
Sub EditText1_EnterPressed
If AStreams.IsInitialized = False Then Return
Dim I As Int
Dim IndText As String
Dim IndByte() As Byte
Dim BufferLength As Int
Dim buffer() As Byte
buffer = EditText1.Text.GetBytes("UTF8")
BufferLength = buffer.Length
'ToastMessageShow(BufferLength, False)
For I = 1 To EditText1.Text.Length
IndText = EditText1.Text.SubString2(I-1,I)
IndByte = IndText.GetBytes("UTF8")
Astreams.Write(IndByte)
'ToastMessageShow(IndText,False)
Next
'Astreams.Write(buffer)
Dim LineFeed () As Byte
LineFeed = Enter.GetBytes("UTF8")
EditText1.Text = ""
AStreams.Write(LineFeed)
End Sub