Message Sending Via Rs-232 Serial Port; Using Hexadecimal Codes - Lightware RAP-B511-EU-K User Manual

Room automation panel
Table of Contents

Advertisement

 
7. LW3 Programmers' Reference
7.14.2.2. Sending a UDP Text (ASCII-format)
The command is for sending a text message in ASCII-format via UDP-protocol. This method does not allow
escaping or inserting control characters.
Command and Response
Ý CALL·/MEDIA/ETHERNET:udpText(<IP_address>:<port_no>=<text>)
Ü mO·/MEDIA/ETHERNET:udpText
Example
Ý CALL /MEDIA/ETHERNET:udpText(192.168.0.20:9988=open)
Ü mO /MEDIA/ETHERNET:udpText
The 'open' text is sent to the indicated IP:port address.
7.14.2.3. Sending a UDP Binary Message (HEX-format)
The command is for sending a binary message in Hexadecimal format via UDP protocol. This method does
not allow escaping or inserting control characters.
Command and Response
Ý CALL·/MEDIA/ETHERNET:udpBinary(<IP_address>:<port_no>=<HEX_message>)
Ü mO·/MEDIA/ETHERNET:udpBinary
Example
Ý CALL /MEDIA/ETHERNET:udpBinary(192.168.0.20:9988=433030)
Ü mO /MEDIA/ETHERNET:udpBinary
The '433030' message is sent to the indicated IP:port address.
INFO: There is no need to insert a space or other separator character between the binary messages.
7.14.3. Message Sending via RS-232 Serial Port
7.14.3.1. Sending a Message (ASCII-format) via RS-232
The command is for sending a command message in ASCII-format. This method allows escaping the control
characters. For more information see the
Command and Response
Ý CALL·/MEDIA/UART/P1:sendMessage(<message>)
Ü mO·/MEDIA/UART/P1:sendMessage
Example
Ý CALL /MEDIA/UART/P1:sendMessage(PWR0)
Ü mO /MEDIA/UART/P1:sendMessage
The 'PWR0' message is sent out via the P1 serial port.
Escaping
section.
RAP-B511 series – User's Manual
7.14.3.2. Sending a Text (ASCII-format) via RS-232
The command is for sending a command message in ASCII-format. This method does not allow escaping the
control characters.
Command and Response
Ý CALL·/MEDIA/UART/P1:sendText(<message>)
Ü mO·/MEDIA/UART/P1:sendText
Example
Ý CALL /MEDIA/UART/P1:sendText(open)
Ü mO /MEDIA/UART/P1:sendText
The 'open' text is sent out via the P1 serial port.
7.14.3.3. Sending a Binary Message (HEX-format) via RS-232
The command is for sending a command message in Hexadecimal-format. This method does not allow
escaping the control characters.
Command and Response
Ý CALL·/MEDIA/UART/P1:sendBinaryMessage(<message>)
Ü mO·/MEDIA/UART/P1:sendBinaryMessage
Example
Ý CALL /MEDIA/UART/P1:sendBinaryMessage(433030)
Ü mO /MEDIA/UART/P1:sendBinaryMessage
The '433030' message is sent out via the P1 serial port.
7.14.4. Using Hexadecimal Codes
Hexadecimal codes can be inserted in the ASCII message when using:
sendMessage command: CALL /MEDIA/UART/P1:sendMessage(C00\x0D)
tcpMessage command:
CALL /MEDIA/ETHERNET:tcpMessage(C00\x0D)
udpMessage command: CALL /MEDIA/ETHERNET:udpMessage(C00\x0D)
C00: the message.
\x: indicates that the following is a hexadecimal code.
0D: the hexadecimal code (Carriage Return).
61

Advertisement

Table of Contents
loading

Table of Contents