hi
I m tryng to send data from VB through serial communication using MAX232 and read them in a microcontroller. sofar i could manage to send ASCII charactores through VB. I need to send binary value through VB.Lets say if i press a command button i need to send '10001110' value to the microcontroller. what are the changes that i need to make in VB. if anyone can help me please.
my VB code is below
Private Sub Form_Load()
MSComm1.Settings = "2400,N,8,1"
MSComm1.InputLen = 1
MSComm1.CommPort = 2
MSComm1.PortOpen = True
MSComm1.RThreshold = 1
End Sub
Private Sub Form_Unload(Cancel As Integer)
Close #1
End Sub
Private Sub MSComm1_OnComm()
If MSComm1.CommEvent = comEvReceive Then
txtRx.Text = txtRx.Text & MSComm1.Input
End If
End Sub
Private Sub cmdtx_Click()
MSComm1.Output = txtTx.Text (123)
End Sub