ndev = New SerialPort
ndev.PortName = ComboBoxEx1.SelectedItem.ToString
ndev.BaudRate = 115200
ndev.Parity = Parity.None
ndev.DataBits = 8
ndev.StopBits = 1
ndev.Open()
ndev.DiscardInBuffer()
ndev.DiscardOutBuffer()
ndev.WriteLine(TextBox1.Text)
Wait(50000)
ndev.Close()
I'm trying to write more than 255 characters, but it's causing serial communicatiob to hang. But when I cut the string to 255 characters before I write to serial port, it is going through. What seems to be my mistake? I tried coolterminal and send the whole data and it works. My baud rate is correct. I can't figure out what's causing the issue.
//WHOLE DATA NEED TO BE SEND
syscfg add PxCl 0x05007A7F 0x001E0032 0x41E7E560 0x41926C57 0x42C80000 0x41D0D254 0x415B6A16 0x43160000 0x41D0D254 0x415B6A16 0x43160000 0x435C0D91 0x3FDF9485 0x44998AE1 0x449963D7 0x4499923D 0x449A270A 0x41F6381D 0x41F90D84 0x420746A8 0x420C1E35 0x42200000 0x430BE189 0x4215F74C 0x42480000 0x43C29B9D 0x43C1D4FE 0x46132649 0x4379272B 0x1E358A47 0x1A081F02 0x45A56BC6 0x439B949C 0x458F375C 0x00000002 0x70000000
// I CAN ONLY SEND THIS, ANY CHARACTER ADDED WILL CAUSE SERIAL TO HANG
syscfg add PxCl 0x05007A7F 0x001E0032 0x41E7E560 0x41926C57 0x42C80000 0x41D0D254 0x415B6A16 0x43160000 0x41D0D254 0x415B6A16 0x43160000 0x435C0D91 0x3FDF9485 0x44998AE1 0x449963D7 0x4499923D 0x449A270A 0x41F6381D 0x41F90D84 0x420746A8 0x420C1E35