![background image](http://html.mh-extra.com/html/amx/dvx-21xxhd/dvx-21xxhd_webconsole-and-programming-manual_2937827083.webp)
NetLinx Programming
83
NetLinx Integrated Controllers (Firmware v4)- WebConsole & Programming Guide
IR/Serial SEND_COMMANDs (Cont.)
Command
Description
SET MODE
Set the IR/Serial ports for IR or Serial-controlled devices to either
IR
,
Serial
, or
Data
mode.
Syntax:
SEND_COMMAND <DEV>, 'SET MODE <mode>'"
Variable:
mode = IR, SERIAL, or DATA.
Example:
SEND_COMMAND IR_1,"'SET MODE IR'"
Sets the IR_1 port to IR mode for IR control.
Note: The maximum baud rate for ports using SERIAL mode is 19200. Also, SERIAL mode works best when using a short
cable length (< 10 feet).
SP
Generate a single IR pulse. Use the '
CTON
' to set pulse lengths and the '
CTOF
' for time Off between pulses.
Syntax:
SEND_COMMAND <DEV>,"'SP',<code>"
Variable:
code = IR code value 1 - 252 (253-255 reserved).
Example:
SEND_COMMAND IR_1, "'SP',25"
Pulses IR code 25 on IR_1 device.
XCH
Transmit the selected channel IR codes in the format/pattern set by the '
XCHM
' send command.
Syntax:
SEND_COMMAND <DEV>,"'XCH <channel>'"
Variable:
channel = 0 - 9999.
Example:
For detailed usage examples, refer to the '
XCHM
' command.
Note: This command supports 4-digit channels.
XCHM
Changes the IR output pattern for the '
XCH
' send command.
Syntax:
SEND_COMMAND <DEV>,"'XCHM-<extended channel mode>'"
Variable:
extended channel mode = 0 - 4.
Example:
SEND_COMMAND IR_1,"'XCHM-3'"
Sets the IR_1 device's extended channel command to mode 3.
Mode 0 Example (default):
[x][x]<x><enter>
SEND_COMMAND IR_1,"'XCH-3'"
Transmits the IR code as 3-enter.
SEND_COMMAND IR_1,"'XCH-34'"
Transmits the IR code as 3-4-enter.
SEND_COMMAND IR_1,"'XCH-343'"
Transmits the IR code as 3-4-3-enter.
Mode 1 Example:
<x> <x> <x> <enter>
SEND_COMMAND IR_1,"'XCH-3'"
Transmits the IR code as 0-0-3-enter.
SEND_COMMAND IR_1,"'XCH-34'"
Transmits the IR code as 0-3-4-enter.
SEND_COMMAND IR_1,"'XCH-343'"
Transmits the IR code as 3-4-3-enter.
Mode 2 Example:
<x> <x> <x>
SEND_COMMAND IR_1,"'XCH-3'"
Transmits the IR code as 0-0-3.
SEND_COMMAND IR_1,"'XCH-34'"
Transmits the IR code as 0-3-4.
SEND_COMMAND IR_1,"'XCH-343'"
Transmits the IR code as 3-4-3.