
Brought to you by PCS Electronics, www.pcs-electronics.com
55
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "PTY"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Str$(PTY)
temp = LTrim(temp)
If Len(temp) = 1 Then temp = "0" & temp
If Len(temp) = 0 Then temp = "00"
MSComm1.Output = temp
'Sending TP
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "TP"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Str$(TP)
temp = LTrim(temp)
MSComm1.Output = temp
'Sending TA
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "TA"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Str$(TA)
temp = LTrim(temp)
MSComm1.Output = temp
MSComm1.Output = Chr$(2) 'Finish command
'Sending MS
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "MS"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Str$(MS)
temp = LTrim(temp)
MSComm1.Output = temp
MSComm1.Output = Chr$(2) 'Finish command
'Sending Did0
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "Did0"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Str$(DId0)
temp = LTrim(temp)
MSComm1.Output = temp
MSComm1.Output = Chr$(2) 'Finish command
'Sending AF0 (af number)
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "AF0"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Chr$(AFNum + 224 + 4)
MSComm1.Output = temp
MSComm1.Output = Chr$(2) 'Finish command
'Sending AF1
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "AF1"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = Chr$(AF1 + 4)
MSComm1.Output = temp
MSComm1.Output = Chr$(2) 'Finish command
'Sending RT
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "RT"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = RT & Chr$(13) & Chr$(13) & String(64, Chr(13))
If Len(temp) > 64 Then temp = Left(temp, 64)
MSComm1.Output = temp 'RT
MSComm1.Output = Chr$(2) 'Finish command
'Send PS
MSComm1.Output = Chr$(0) 'Start (0)
MSComm1.Output = "PS00"
MSComm1.Output = Chr$(1) 'End command and start of data (1)
temp = “your text”
MSComm1.Output = temp