Page 29
MNSNV102005Ver1.0
Chapter 6: Communication Protocol
Chapter 6: Communication Protocol
Chapter 6: Communication Protocol
Chapter 6: Communication Protocol
Chapter 6: Communication Protocol
Appendix B: Contin
Appendix B: Contin
Appendix B: Contin
Appendix B: Contin
Appendix B: Continu
u
u
u
ued
ed
ed
ed
ed…
…
…
…
….......... (Sample T
(Sample T
(Sample T
(Sample T
(Sample Trrrrran
an
an
an
ansl
sl
sl
sl
slati
ati
ati
ati
atio
o
o
o
on routine in Vi
n routine in Vi
n routine in Vi
n routine in Vi
n routine in Visssssual BASIC)
ual BASIC)
ual BASIC)
ual BASIC)
ual BASIC)
Function LookUpOSDString(sTextMessage As String) As String
‘
‘ Look up chars and translate to message for OSD
‘
Dim iLoop As Integer
Dim sNewMess As String
Dim sChar As String
sNewMess = Space$(MAX_SCREEN_CHAR)
For iLoop = 1 To Len(sTextMessage)
sChar = Mid$(sTextMessage, iLoop, 1)
Select Case sChar
Case “0” To “9”
Mid$(sNewMess, iLoop, 1) = Chr$(Asc(sChar) - 48)
Case “A” To “Z”
Mid$(sNewMess, iLoop, 1) = Chr$(Asc(sChar) - 53)
Case “a” To “z”
Mid$(sNewMess, iLoop, 1) = Chr$(Asc(sChar) - 55)
Case “.”
Mid$(sNewMess, iLoop, 1) = Chr$(&H27)
Case “ “
Mid$(sNewMess, iLoop, 1) = Chr$(&HB)
Case “:”
Mid$(sNewMess, iLoop, 1) = Chr$(&H26)
Case “/”
Mid$(sNewMess, iLoop, 1) = Chr$(&H28)
Case “‘“
Mid$(sNewMess, iLoop, 1) = Chr$(&H29)
Case “-”
Mid$(sNewMess, iLoop, 1) = Chr$(&HA)
Case “?”
Mid$(sNewMess, iLoop, 1) = Chr$(&H70)
Case “*”
Mid$(sNewMess, iLoop, 1) = Chr$(&H5F)
Case “=”
Mid$(sNewMess, iLoop, 1) = Chr$(&H78)
Case “>”
Mid$(sNewMess, iLoop, 1) = Chr$(&H7A)
Case “<“
Mid$(sNewMess, iLoop, 1) = Chr$(&H7B)
Case “(“
Mid$(sNewMess, iLoop, 1) = Chr$(&H61)
Case “)”
Mid$(sNewMess, iLoop, 1) = Chr$(&H62)
Case Else
Mid$(sNewMess, iLoop, 1) = Chr$(&HB)
End Select
Next iLoop
LookUpOSDString = sNewMess
End Function
Summary of Contents for SmartNet-V
Page 4: ...Page 4 MNSNV102005Ver1 0...