Page 38
Anhang | ASCII Communication with Sensor
optoNCDT ILR2250
A 3
ASCII Communication with Sensor
A 3.1
General
The ASCII commands can be sent to the sensor via the RS422 interface. All commands, inputs and error reports are in
English. A command always consists of the command name and zero or several parameters that are separated with a
space and end in LF. If spaces are used in parameters, the parameter must be placed in quotation marks, e.g. “Pass-
word with space”.
Example: Switching on output via RS422
OUTPUT RS422
Note:
Must contain LF, but can also be CR LF.
Explanation:
LF
Line feed (hex 0A)
CR
Carriage return (hex 0D)
Enter (depending on system, hex 0A or hex 0D0A)
The currently set parameter value is reset if a command is invoked without parameters.
The entry formats are:
<Command name> <Parameter1> [<Parameter2> […]]
<Command name> <Parameter1> <Parameter2> ... <Parameter...>
or a combination thereof.
Parameters in [] brackets are optional and require you to enter the preceding parameter.
Successive parameters without [] brackets are required, i.e. no parameter can be omitted. Alternative entries for param-
eter values are separated by “|”, e.g. the values “a”, "b” or “c” can be set for “a|b|c”. Parameter values in <> brackets
can be selected from a value range.
Explanations on the format:
“a | b”
Parameter value can be set to the value “a” or “b”.
“ P1 P2”
Both parameters “P1” and “P2” must be set.
“ P1 [P2 [P3]]”
The parameters “P1”, “P2” and “P3” can be set, whereby “P2” can only be set if “P1” is set and “P3”
can only be set if “P1” and “P2” are set.
“<a>”
Parameter value is within a value range of “... to ...” , see parameter description.
Parameter values without angle brackets can only be discrete values, see parameter description. Round brackets should
be interpreted as a grouping, i.e. for better comprehensibility, “P1 P2|P3” is written as “(P1 P2)|P3”.
Example without []:
„PASSWD <Old password> <New password> <New password>“
-
All 3 parameters must be entered in order to change the password.
The output format is:
<Command name> <Parameter1> [<Parameter2> […]]
The response can be used again without changes as a command for setting the password. Optional parameters are only
returned as well if this is necessary. For example, for the data selection additional values command, only the activated
output values are returned.
After a command is processed, a line break and a prompt (“->”) is always returned. In the event of an error, an error
message beginning with “Exxx”, where xx stands for a unique error number, comes before the prompt. Moreover, instead
of error messages, warning messages (“Wxxx”) may be output. Warnings are structured analogously to error messages.
In the case of warning messages, the command has been executed.
For support requests regarding the sensor, the responses to the commands GETINFO and PRINT are helpful because
they contain the sensor settings.