7.LW3Programmer'sReference
HDMI-TPS-TX200series–User'sManual
115
Appliedfirmwarepackage:v1.3.2b3 | LDCsoftware:v2.5.7b2
7.18.
RS-232 Message Recognizer
DIFFERENCE:
ThiscommandisavailableonlyforSW4-TPS-TX240-PlusfromFWpackagev1.2.0b16.
ThistoolcanbeusedtorecognizemessagescomingfromtheRS-232port.Themessagecanbeusedasa
ConditioninEventmanageranddefineanActionforit.
Working Method
Amessagegotrecognizedfromtheincomingdata,ifoneofthefollowingoccurs:
▪
ThesetDelimiterHexisdetectedinthemessage,or
▪
ThesetTimeOuthasbeenelapsedsincereceivingthelastdatabit.
*Inthatcase,thenot-recognizeddataiskeptinthememory(upto128bytes).Ifthe
DelimiterHex
is detected
later, or the
TimeOut
parameter is set meanwhile, the data appears in the
Rx
,
RxHex, Hash
and
ActiveRx
,
ActiveRxHex, ActiveRxHash
properties.
7.18.1.
Enable the Recognizer
Command and Response
ç
SET·/MEDIA/UART/
<serial_port>
.RecognizerEnable=
<recognizer_enable>
æ
pw·/MEDIA/UART/
<serial_port>
.RecognizerEnable=
<recognizer_enable>
Parameters
Parameter
Parameterdescription
Values
Valuedescription
<serial_port>
Serialportnumber
P1, P2
<recognizer_enable>
Recognizermode
true
Recognizerisenabled
false
Recognizerisdisabled
Example
ç
SET/MEDIA/UART/P1.RecognizerEnable=true
æ
pw/MEDIA/UART/P1.RecognizerEnable=true
#recognizer #rs232recognizer
#rs-232recognizer
MESSAGE
saved in Rx property
MESSAGE
MESSAGE
saved in ActiveRx property
ActiveRx property is cleared
ActiveProperty
Timeout
MESSAGE
saved in Rx property
MESSAGE
saved in ActiveRx property
ActiveRx property is cleared
ActiveProperty
Timeout
with delimiter
Time
Delimiter
MESSAGE
TimeOut
with timeout
MESSAGE
no timeout,
no delimiter
*
7.18.2.
Set the Delimiter Hex
Thispropertystoresthedelimiterthatisbetweenthemessages(e.g.Cr,Lf,Space).Thevaluehastobein
hexformat(e.g.0D,0A,20).
Command and Response
ç
SET·/MEDIA/UART/RECOGNIZER.DelimiterHex=
<delimiter>
æ
pw·/MEDIA/UART/RECOGNIZER.DelimiterHex=
<delimiter>
Parameters
The
<delimiter>
parametercanbemax.8-characterlong(or16hexdigit)in
hex
format.
Example
ç
SET/MEDIA/UART/RECOGNIZER.DelimiterHex=3a
æ
pw/MEDIA/UART/RECOGNIZER.DelimiterHex=3a
7.18.3.
Set the Timeout
Whenthesettimeiselapsedafterthelastreceivedmessageanddelimiterwasnotdetected,thedevice
saves the data into the
Rx, RxHex, Hash
properties.Thetimeoutsettingisusefulifthereisnospecialoreasily
defineddelimiterintheincomingdata,butthereisatimegapbetweenthemessages.
Command and Response
ç
SET·/MEDIA/UART/RECOGNIZER.TimeOut=
<timeout>
æ
pw·/MEDIA/UART/RECOGNIZER.TimeOut=
<timeout>
Parameters
The
<timeout>
parametersetsthetimeoutvalueinmilliseconds:
0
means the timeout is disabled, min.
valueis10.
Example
ç
SET/MEDIA/UART/RECOGNIZER.TimeOut=20
æ
pw/MEDIA/UART/RECOGNIZER.TimeOut=20
... Password :
Login name :
...
Delimiter (hex format: 3A)
Stored string