This shows you the differences between two versions of the page.
hardware:cflink:lanbridge-cflink-protocol [2012/08/21 04:58] jarrod Replace CFLink code blocks for syntax highlighting |
hardware:cflink:lanbridge-cflink-protocol [2021/05/17 00:00] (current) jarrod |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== LANBridge CFLink Protocol ====== | + | ====== LAN Bridge CFLink Protocol ====== |
- | The following documentation is for the LANBridge device CFLink protocol messages.\\ | + | The following documentation is for the LAN Bridge device CFLink protocol messages.\\ |
- | The LANBridge also has an on-board RS232 port, for which documentation is available in the [[on-board-rs232-port-protocol|On-Board RS232 docs]]. | + | The LAN Bridge also has an on-board RS232 port, for which documentation is available in the [[on-board-rs232-port-protocol|On-Board RS232 docs]]. |
===== Common Definitions ===== | ===== Common Definitions ===== | ||
- | The following communication slots exist on a LANBridge: | + | The following communication slots exist on a LAN Bridge: |
* ''1'' = CFLink slot | * ''1'' = CFLink slot | ||
* ''2'' = On-board RS232 slot | * ''2'' = On-board RS232 slot | ||
- | * ''3'' = UDP Broadcasting slot (not available for subscriptions, can only be enabled/disabled via [[hardware:cflink:lanbridge-cflink-protocol#udb-udp-broadcasting-configuration|UDB command]] | + | * ''3'' = UDP Broadcasting slot (not available for subscriptions, can only be enabled/disabled via [[hardware:cflink:lanbridge-cflink-protocol#udb-udp-broadcasting-configuration|UDB command]]) |
* ''4'' - ''10'' = Reserved for future use | * ''4'' - ''10'' = Reserved for future use | ||
* ''11'' - ''20'' = Configurable as TCP or UDP communication | * ''11'' - ''20'' = Configurable as TCP or UDP communication | ||
+ | |||
+ | ===== Authentication ===== | ||
+ | |||
+ | By default, authentication on LAN Bridge is disabled. To enable it, use the [[#pwd-login-password|Configure Password command]]. | ||
+ | |||
+ | When authentication is enabled, the LAN Bridge will send a ''RLANATH'' command when first connecting. When this command has been sent, no other commands will be accepted until the correct username and password has been received. | ||
+ | |||
+ | If an incorrect login message is received, the LAN Bridge will respond with [[hardware:cflink:error-codes#lan-bridge-solo-error-codes|''RLANERR'' message, with error code 134]]. | ||
+ | |||
+ | Once successfully logged in, the LAN Bridge will reply with ''RLANWHO'' response to acknowledge that login is correct and the device will now respond to other commands. | ||
+ | |||
===== Queries ===== | ===== Queries ===== | ||
Line 36: | Line 47: | ||
// Request the details for the device at CFLink ID [02] | // Request the details for the device at CFLink ID [02] | ||
> [F2][02][F3]TCFXWHO[F4][F5][F5] | > [F2][02][F3]TCFXWHO[F4][F5][F5] | ||
- | // The Reply if a LANBridge is found | + | // The Reply if a LAN Bridge is found |
< [F2][02][F3]RLANWHO[F4]LANBridge:00000012:1.0.1:1.0.4:192.168.0.100:00.04.A3.19.D5.70[F5][F5] | < [F2][02][F3]RLANWHO[F4]LANBridge:00000012:1.0.1:1.0.4:192.168.0.100:00.04.A3.19.D5.70[F5][F5] | ||
</sxh> | </sxh> | ||
Line 42: | Line 53: | ||
==== CFG - Query Configuration ==== | ==== CFG - Query Configuration ==== | ||
- | The ''CFG'' query is used to obtain details about the configuration of a specific LANBridge unit. | + | The ''CFG'' query is used to obtain details about the configuration of a specific LAN Bridge unit. |
=== Data === | === Data === | ||
Line 56: | Line 67: | ||
</sxh> | </sxh> | ||
- | * **<IPADDRESS>** = The IPv4 address the LANBridge is currently assigned. | + | * **<IPADDRESS>** = The IPv4 address the LAN Bridge is currently assigned. |
- | * **<SUBNETMASK>** = The IPv4 subnet mask the LANBridge is currently assigned. | + | * **<SUBNETMASK>** = The IPv4 subnet mask the LAN Bridge is currently assigned. |
- | * **<GATEWAY>** = The IPv4 gateway the LANBridge is currently assigned. | + | * **<GATEWAY>** = The IPv4 gateway the LAN Bridge is currently assigned. |
- | * **<DNS>** = The IPv4 DNS the LANBridge is currently assigned. | + | * **<DNS>** = The IPv4 DNS the LAN Bridge is currently assigned. |
* **<DHCPMODE>** = DHCP mode disabled or enabled (''0'' or ''1''). | * **<DHCPMODE>** = DHCP mode disabled or enabled (''0'' or ''1''). | ||
* **<RS232MODE>** = The mode of the RS232 port (''PGM'' or ''232''). | * **<RS232MODE>** = The mode of the RS232 port (''PGM'' or ''232''). | ||
Line 89: | Line 100: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Query configuration of LANBridge on ID [02] | + | // Query configuration of LAN Bridge on ID [02] |
> [F2][02][F3]QLANCFG[F4][F5][F5] | > [F2][02][F3]QLANCFG[F4][F5][F5] | ||
// Configuration query reply | // Configuration query reply | ||
Line 130: | Line 141: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Query the configuration for slot 12 of LANBridge on ID [02] | + | // Query the configuration for slot 12 of LAN Bridge on ID [02] |
> [F2][02][F3]QLANSLT[F4]12[F5][F5] | > [F2][02][F3]QLANSLT[F4]12[F5][F5] | ||
// Reply when slot configured as a TCP Server | // Reply when slot configured as a TCP Server | ||
< [F2][02][F3]RLANSLT[F4]12:TCP:11:S:0.0.0.0:9602:0:10:1[F5][F5] | < [F2][02][F3]RLANSLT[F4]12:TCP:11:S:0.0.0.0:9602:0:10:1[F5][F5] | ||
- | // Query the configuration for slot 13 of LANBridge on ID [02] | + | // Query the configuration for slot 13 of LAN Bridge on ID [02] |
> [F2][02][F3]QLANSLT[F4]13[F5][F5] | > [F2][02][F3]QLANSLT[F4]13[F5][F5] | ||
// Reply when slot configured for UDP Unicast | // Reply when slot configured for UDP Unicast | ||
< [F2][02][F3]RLANSLT[F4]13:UDP:U:192.168.0.100:9601[F5][F5] | < [F2][02][F3]RLANSLT[F4]13:UDP:U:192.168.0.100:9601[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | ==== SLS - Query Slot Startup Command Configuration ==== | ||
+ | |||
+ | The ''SLS'' query returns the configuration of a specific communication slot's startup command. | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]QLANSLS[F4]<SLOT#>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<SLOT#>** = The communication slot number to request startup command configuration from | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | // If the slot has a startup command assigned: | ||
+ | < [F2]<ID>[F3]RLANSLS[F4]<SLOT#>:<DELAY>:<COMMAND>[F5][F5] | ||
+ | // If the slot has no startup command | ||
+ | < [F2]<ID>[F3]RLANSLT[F4]<SLOT#>:0:[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<SLOT#>** = The communication slot number being described. | ||
+ | * **<DELAY>** = The time (in 100ms resolution) to delay before sending the command data after each connection. eg. ''10'' = 1 second. | ||
+ | * **<COMMAND>** = The command data to send on startup. | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Query the startup configuration for slot 12 of LAN Bridge on ID [02] | ||
+ | > [F2][02][F3]QLANSLS[F4]12[F5][F5] | ||
+ | // Reply when the data 'Startup Command Data <Carriage Return>' is to be sent after a 1 second delay. | ||
+ | < [F2][02][F3]RLANSLS[F4]12:10:Startup Command Data\x0D[F5][F5] | ||
+ | |||
+ | // Query the configuration for slot 13 of LAN Bridge on ID [02] | ||
+ | > [F2][02][F3]QLANSLS[F4]13[F5][F5] | ||
+ | // Reply when no startup command is defined | ||
+ | < [F2][02][F3]RLANSLS[F4]13:0:[F5][F5] | ||
</sxh> | </sxh> | ||
Line 169: | Line 216: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Query subscription config for slot 12 of a LANBridge on CFLink ID [02] | + | // Query subscription config for slot 12 of a LAN Bridge on CFLink ID [02] |
> [F2][02][F3]QLANSUB[F4]12[F5][F5] | > [F2][02][F3]QLANSUB[F4]12[F5][F5] | ||
// Slot 12 is subscribed to CFLink Slot 0, to CFLink ID [03], Module 1. | // Slot 12 is subscribed to CFLink Slot 0, to CFLink ID [03], Module 1. | ||
Line 176: | Line 223: | ||
< [F2][02][F3]RLANSUB[F4]12:0:03:M1:TRLYSET:RRLYSTA[F5][F5] | < [F2][02][F3]RLANSUB[F4]12:0:03:M1:TRLYSET:RRLYSTA[F5][F5] | ||
- | // Query subscription config for slot 13 of a LANBridge on CFLink ID [02] | + | // Query subscription config for slot 13 of a LAN Bridge on CFLink ID [02] |
> [F2][02][F3]QLANSUB[F4]13[F5][F5] | > [F2][02][F3]QLANSUB[F4]13[F5][F5] | ||
// Slot 13 is subscribed to Slot 14 (possibly a TCP Client slot subscribed to a TCP Server) | // Slot 13 is subscribed to Slot 14 (possibly a TCP Client slot subscribed to a TCP Server) | ||
Line 183: | Line 230: | ||
==== TME - Real Time Clock status ==== | ==== TME - Real Time Clock status ==== | ||
- | The ''TME'' query will return the current configuration of the real time clock on-board the LANBridge. | + | The ''TME'' query will return the current configuration of the real time clock on-board the LAN Bridge. |
=== Data === | === Data === | ||
Line 195: | Line 242: | ||
=== Reply === | === Reply === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | < [F2]<ID>[F3]RLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>:<UTCTIMEZONESTR>[F5][F5] | + | < [F2]<ID>[F3]RLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>:<UTCTIMEZONESTR>:<NTP_SYNC>:<NTP_SERVER_ID>[F5][F5] |
</sxh> | </sxh> | ||
Line 205: | Line 252: | ||
* **<MINUTE>** = 2 digit minute (''00''-''59'') | * **<MINUTE>** = 2 digit minute (''00''-''59'') | ||
* **<SECOND>** = 2 digit second (''00''-''59'') | * **<SECOND>** = 2 digit second (''00''-''59'') | ||
- | * **<UTCTIMEZONE>** = ID from Timezone Lookup Table (2 digits, ''01''-''40'') | + | * **<UTCTIMEZONE>** = ID from [[#timezone-lookup-table|Timezone Lookup Table]] (2 digits, ''01''-''40'') |
* **<UTCTIMEZONESTR>** = String representation of the timezone | * **<UTCTIMEZONESTR>** = String representation of the timezone | ||
+ | * **<NTP_SYNC>** = Whether or not the unit is configured to sync to a time server. | ||
+ | * **<NTP_SERVER_ID>** = The time server that the unit is syncing to. Refer to list below. | ||
+ | |||
+ | Available time server IDs: | ||
+ | * ''1'' = pool.ntp.org | ||
+ | * ''2'' = europe.pool.ntp.org | ||
+ | * ''3'' = asia.pool.ntp.org | ||
+ | * ''4'' = oceania.pool.ntp.org | ||
+ | * ''5'' = north-america.pool.ntp.org | ||
+ | * ''6'' = south-america.pool.ntp.org | ||
+ | * ''7'' = africa.pool.ntp.org | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Query time from LANBridge on CFLink ID [02] | + | // Query time from LAN Bridge on CFLink ID [02] |
> [F2][02][F3]QLANTME[F4][F5][F5] | > [F2][02][F3]QLANTME[F4][F5][F5] | ||
// Reply | // Reply | ||
- | < [F2][02][F3]RLANTME[F4]2011:10:27:3:18:12:12:29:UTC+8.00[F5][F5] | + | < [F2][02][F3]RLANTME[F4]2011:10:27:3:18:12:12:29:UTC+8.00:1:4[F5][F5] |
</sxh> | </sxh> | ||
===== Configuration Messages ===== | ===== Configuration Messages ===== | ||
+ | |||
+ | ==== PWD - Login Password ==== | ||
+ | |||
+ | The ''PWD'' command configures a password that must be sent before any additional commands will be accepted. By default the password is disabled.\\ | ||
+ | To clear the login, you must first have issued the correct login/password, then send this command without any username or password data. | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]CLANPWD[F4]<USER>:<PASSWORD>[F5][F5] | ||
+ | </sxh> | ||
+ | * **<USER>** = The login username to set | ||
+ | * **<PASSWORD>** = The login password to set | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | // The reply is just an echo of the command in reply format, without the password . | ||
+ | < [F2]<ID>[F3]RLANPWD[F4]<USER>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Configure username as 'admin' and password as 'mysecretpass' of LAN Bridge on CFLink ID [02] | ||
+ | > [F2][02][F3]CLANPWD[F4]admin:mysecretpass[F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANPWD[F4]admin[F5][F5] | ||
+ | // Remove the login completely from LAN Bridge on CFLink ID [02] | ||
+ | > [F2][02][F3]CLANPWD[F4][F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANPWD[F4][F5][F5] | ||
+ | </sxh> | ||
==== IP4 - IPv4 Address ==== | ==== IP4 - IPv4 Address ==== | ||
- | The ''IP4'' command will configure the IPv4 address used by the LANBridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ | + | The ''IP4'' command will configure the IPv4 address used by the LAN Bridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ |
- | The change will not take effect until the LANBridge is rebooted. | + | The change will not take effect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 227: | Line 315: | ||
> [F2]<ID>[F3]CLANIP4[F4]<IPADDRESS>[F5][F5] | > [F2]<ID>[F3]CLANIP4[F4]<IPADDRESS>[F5][F5] | ||
</sxh> | </sxh> | ||
- | * **<IPADDRESS>** = The IPv4 Address to assign to the LANBridge | + | * **<IPADDRESS>** = The IPv4 Address to assign to the LAN Bridge |
=== Reply === | === Reply === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is just an echo of the command in reply format. | // The reply is just an echo of the command in reply format. | ||
- | // The change does not take effect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANIP4[F4][F5][F5] | < [F2]<ID>[F3]RLANIP4[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 238: | Line 326: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure IP Address of LANBridge on CFLink ID [02] | + | // Configure IP Address of LAN Bridge on CFLink ID [02] |
> [F2][02][F3]CLANIP4[F4]192.168.0.100[F5][F5] | > [F2][02][F3]CLANIP4[F4]192.168.0.100[F5][F5] | ||
// Reply | // Reply | ||
Line 246: | Line 334: | ||
==== SNM - Subnet Mask ==== | ==== SNM - Subnet Mask ==== | ||
- | The ''SNM'' (Subnet Mask) command will configure the subnet mask used by the LANBridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ | + | The ''SNM'' (Subnet Mask) command will configure the subnet mask used by the LAN Bridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ |
- | The change will not take effect until the LANBridge is rebooted. | + | The change will not take effect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 254: | Line 342: | ||
</sxh> | </sxh> | ||
- | * **<SUBNETMASK>** = The IPv4 Subnet Mask to assign to the LANBridge | + | * **<SUBNETMASK>** = The IPv4 Subnet Mask to assign to the LAN Bridge |
=== Reply === | === Reply === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is just an echo of the command in reply format. | // The reply is just an echo of the command in reply format. | ||
- | // The change does not take effect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANSNM[F4][F5][F5] | < [F2]<ID>[F3]RLANSNM[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 265: | Line 353: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure Subnet Mask of LANBridge on CFLink ID [02] | + | // Configure Subnet Mask of LAN Bridge on CFLink ID [02] |
> [F2][02][F3]CLANSNM[F4]255.255.255.0[F5][F5] | > [F2][02][F3]CLANSNM[F4]255.255.255.0[F5][F5] | ||
// Reply | // Reply | ||
Line 273: | Line 361: | ||
==== GTW - Default Gateway ==== | ==== GTW - Default Gateway ==== | ||
- | The ''GTW'' (Gateway) command will configure the default gateway used by the LANBridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ | + | The ''GTW'' (Gateway) command will configure the default gateway used by the LAN Bridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ |
- | The change will not take effect until the LANBridge is rebooted. | + | The change will not take effect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 281: | Line 369: | ||
</sxh> | </sxh> | ||
- | * **<GATEWAY>** = The IPv4 Gateway to assign to the LANBridge | + | * **<GATEWAY>** = The IPv4 Gateway to assign to the LAN Bridge |
=== Reply === | === Reply === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is just an echo of the command in reply format. | // The reply is just an echo of the command in reply format. | ||
- | // The change does not take effect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANGTW[F4][F5][F5] | < [F2]<ID>[F3]RLANGTW[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 292: | Line 380: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure Default Gateway of LANBridge on CFLink ID [02] | + | // Configure Default Gateway of LAN Bridge on CFLink ID [02] |
> [F2][02][F3]CLANGTW[F4]192.168.0.1[F5][F5] | > [F2][02][F3]CLANGTW[F4]192.168.0.1[F5][F5] | ||
// Reply | // Reply | ||
< [F2][02][F3]RLANGTW[F4][F5][F5] | < [F2][02][F3]RLANGTW[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | ==== DNS - Domain Name System Server ==== | ||
+ | |||
+ | The ''DNS'' (Domain Name System) command will configure the DNS Server used by the LAN Bridge if DHCP is disabled. It will be ignored if DHCP is enabled.\\ | ||
+ | The change will not take effect until the LAN Bridge is rebooted. | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]CLANDNS[F4]<DNS>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<DNS>** = The IPv4 DNS Server Address to assign to the LAN Bridge | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | // The reply is just an echo of the command in reply format. | ||
+ | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. | ||
+ | < [F2]<ID>[F3]RLANDNS[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Configure DNS of LAN Bridge on CFLink ID [02] | ||
+ | > [F2][02][F3]CLANDNS[F4]192.168.0.1[F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANDNS[F4][F5][F5] | ||
</sxh> | </sxh> | ||
==== DHC - DHCP Mode ==== | ==== DHC - DHCP Mode ==== | ||
- | The DHC (DHCP) command will configure the DHCP mode of the LANBridge.\\ | + | The DHC (DHCP) command will configure the DHCP mode of the LAN Bridge.\\ |
- | The change will not take affect until the LANBridge is rebooted. | + | The change will not take affect until the LAN Bridge is rebooted. |
DHCP Mode is enabled by default.\\ | DHCP Mode is enabled by default.\\ | ||
Line 315: | Line 430: | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is just an echo of the command in reply format. | // The reply is just an echo of the command in reply format. | ||
- | // The change does not take affect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take affect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANDHC[F4][F5][F5] | < [F2]<ID>[F3]RLANDHC[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 321: | Line 436: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Disable DHCP mode of LANBridge on CFLink ID [02] | + | // Disable DHCP mode of LAN Bridge on CFLink ID [02] |
> [F2][02][F3]CLANDHC[F4]0[F5][F5] | > [F2][02][F3]CLANDHC[F4]0[F5][F5] | ||
// Reply | // Reply | ||
Line 348: | Line 463: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Disable UDB mode of LANBridge on CFLink ID [02] | + | // Disable UDB mode of LAN Bridge on CFLink ID [02] |
> [F2][02][F3]CLANUDB[F4]0[F5][F5] | > [F2][02][F3]CLANUDB[F4]0[F5][F5] | ||
// Reply | // Reply | ||
Line 357: | Line 472: | ||
The ''SLT'' (Slot TCP) command is used to configure a communication slot for TCP communication.\\ | The ''SLT'' (Slot TCP) command is used to configure a communication slot for TCP communication.\\ | ||
- | The change will not take effect until the LANBridge is rebooted. | + | The change will not take effect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 377: | Line 492: | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is an echo of the command in reply format. | // The reply is an echo of the command in reply format. | ||
- | // The change does not take effect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANSLT[F4][F5][F5] | < [F2]<ID>[F3]RLANSLT[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 383: | Line 498: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure slot 11 to be a TCP Server, on LANBridge ID [02] | + | // Configure slot 11 to be a TCP Server, on LAN Bridge ID [02] |
> [F2][02][F3]CLANSLT[F4]11:S:0.0.0.0:9601:0:10:1[F5][F5] | > [F2][02][F3]CLANSLT[F4]11:S:0.0.0.0:9601:0:10:1[F5][F5] | ||
// Reply | // Reply | ||
Line 392: | Line 507: | ||
The ''SLU'' (Slot UDP) command is used to configure a communication slot for UDP communication.\\ | The ''SLU'' (Slot UDP) command is used to configure a communication slot for UDP communication.\\ | ||
- | The change will not take effect until the LANBridge is rebooted. | + | The change will not take effect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 410: | Line 525: | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is an echo of the command in reply format. | // The reply is an echo of the command in reply format. | ||
- | // The change does not take affect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take affect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANSLU[F4][F5][F5] | < [F2]<ID>[F3]RLANSLU[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 416: | Line 531: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure slot 12 to be UDP Unicast, on LANBridge ID [02] | + | // Configure slot 12 to be UDP Unicast, on LAN Bridge ID [02] |
> [F2][02][F3]CLANSLT[F4]12:U:192.168.0.101:9602[F5][F5] | > [F2][02][F3]CLANSLT[F4]12:U:192.168.0.101:9602[F5][F5] | ||
// Reply | // Reply | ||
Line 425: | Line 540: | ||
The ''SLO'' (Slot Off) command is used to disable a specific communication slot.\\ | The ''SLO'' (Slot Off) command is used to disable a specific communication slot.\\ | ||
- | The change will not take affect until the LANBridge is rebooted. | + | The change will not take affect until the LAN Bridge is rebooted. |
=== Data === | === Data === | ||
Line 437: | Line 552: | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is an echo of the command in reply format. | // The reply is an echo of the command in reply format. | ||
- | // The change does not take affect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take affect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANSLO[F4][F5][F5] | < [F2]<ID>[F3]RLANSLO[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 443: | Line 558: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Disable slot 13 on LANBridge ID [02] | + | // Disable slot 13 on LAN Bridge ID [02] |
> [F2][02][F3]CLANSLO[F4]13[F5][F5] | > [F2][02][F3]CLANSLO[F4]13[F5][F5] | ||
// Reply | // Reply | ||
< [F2][02][F3]RLANSLO[F4][F5][F5] | < [F2][02][F3]RLANSLO[F4][F5][F5] | ||
</sxh> | </sxh> | ||
+ | |||
+ | ==== SLS - Configure Slot Startup Command ==== | ||
+ | |||
+ | The ''SLS'' (Slot Startup) command is used to configure a communication slot startup command for TCP communication slots.\\ | ||
+ | The startup command is sent whenever a client connects (if TCP Server mode) or whenever the slot connects to a server (if TCP Client mode), with an adjustable delay.\\ | ||
+ | The startup command has no effect on UDP slots.\\ | ||
+ | The change will not take effect until the LAN Bridge is rebooted. | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]CLANSLS[F4]<SLOT#>:<DELAY>:<COMMAND>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<SLOT#>** = The slot number to configure the startup command for. Startup commands valid for slots ''11'' to ''20'' only. | ||
+ | * **<DELAY>** = The time (in 100ms resolution) to delay before the startup command is sent after each connection. eg. ''10'' = 1 second. Max allowed delay value is ''9999999'' (999999.9 seconds) | ||
+ | * **<COMMAND>** = The command data to send on startup. Maximum of 100 bytes is allowed for the startup command data. | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | // The reply is an echo of the command in reply format. | ||
+ | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. | ||
+ | < [F2]<ID>[F3]RLANSLS[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Configure slot 11 on LAN Bridge ID [02] to send a startup command 'Hello World <Carriage Return>' after a 1.5 second delay. | ||
+ | > [F2][02][F3]CLANSLS[F4]11:15:Hello World\x0D[F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANSLS[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Error === | ||
+ | |||
+ | * 134 = Invalid startup command settings. | ||
+ | * 135 = Invalid startup command delay format or value (0 to 9999999 only). | ||
+ | * 136 = Invalid command data length. Max data length is 100 bytes. | ||
+ | * 137 = Invalid slot number. Startup command only valid for slots 11-20. | ||
+ | ==== SLD - Delete Slot Startup Command ==== | ||
+ | |||
+ | The ''SLD'' (Slot Startup Delete) command is used to remove the startup command for a specific communication slot.\\ | ||
+ | The change will not take effect until the LAN Bridge is rebooted. | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]CLANSLD[F4]<SLOT#>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<SLOT#>** = The slot number to remove the startup command from. | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | // The reply is an echo of the command in reply format. | ||
+ | // The change does not take effect until the LAN Bridge is rebooted, so the reply will not contain any data. | ||
+ | < [F2]<ID>[F3]RLANSLD[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Remove the startup command from slot 11 on LAN Bridge ID [02]. | ||
+ | > [F2][02][F3]CLANSLD[F4]11[F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANSLD[F4][F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Error === | ||
+ | |||
+ | * 137 = Invalid slot number. | ||
==== SUB - Configure Slot Subscription ==== | ==== SUB - Configure Slot Subscription ==== | ||
- | The ''SUB'' (Subscription) command is used to configure a slot subscription. A subscription is a way to send/receive data between two communication slots on the LANBridge automatically.\\ | + | The ''SUB'' (Subscription) command is used to configure a slot subscription. A subscription is a way to send/receive data between two communication slots on the LAN Bridge automatically.\\ |
\\ | \\ | ||
When subscribing to the CFLink slot, a subscription can be refined to communicate only with a device at a specific CFLink ID and optionally which module.\\ | When subscribing to the CFLink slot, a subscription can be refined to communicate only with a device at a specific CFLink ID and optionally which module.\\ | ||
Line 477: | Line 660: | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// The reply is an echo of the command in reply format. | // The reply is an echo of the command in reply format. | ||
- | // The change does not take affect until the LANBridge is rebooted, so the reply will not contain any data. | + | // The change does not take affect until the LAN Bridge is rebooted, so the reply will not contain any data. |
< [F2]<ID>[F3]RLANSUB[F4][F5][F5] | < [F2]<ID>[F3]RLANSUB[F4][F5][F5] | ||
</sxh> | </sxh> | ||
Line 495: | Line 678: | ||
==== TME - Configure Real Time Clock ==== | ==== TME - Configure Real Time Clock ==== | ||
- | The TME command is used to set the time and date settings for the real time clock on-board the LANBridge. | + | The TME command is used to set the time and date settings for the real time clock on-board the LAN Bridge. |
=== Data === | === Data === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | > [F2]<ID>[F3]CLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>[F5][F5] | + | > [F2]<ID>[F3]CLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>:<NTP_SYNC>:<NTP_SERVER_ID>[F5][F5] |
</sxh> | </sxh> | ||
Line 509: | Line 692: | ||
* **<MINUTE>** = 2 digit minute (''00''-''59'') | * **<MINUTE>** = 2 digit minute (''00''-''59'') | ||
* **<SECOND>** = 2 digit second (''00''-''59'') | * **<SECOND>** = 2 digit second (''00''-''59'') | ||
- | * **<UTCTIMEZONE>** = ID from Timezone Lookup Table (2 digits, ''01''-''40'') | + | * **<UTCTIMEZONE>** = ID from [[#timezone-lookup-table|Timezone Lookup Table]] (2 digits, ''01''-''40'') |
+ | * **<NTP_SYNC>** = Whether or not to sync to a time server. | ||
+ | * **<NTP_SERVER_ID>** = The time server that the unit should syncing to. Refer to list below. | ||
+ | |||
+ | Available time server IDs: | ||
+ | * ''1'' = pool.ntp.org | ||
+ | * ''2'' = europe.pool.ntp.org | ||
+ | * ''3'' = asia.pool.ntp.org | ||
+ | * ''4'' = oceania.pool.ntp.org | ||
+ | * ''5'' = north-america.pool.ntp.org | ||
+ | * ''6'' = south-america.pool.ntp.org | ||
+ | * ''7'' = africa.pool.ntp.org | ||
=== Reply === | === Reply === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
// Reply with the data used to configure the time/date. | // Reply with the data used to configure the time/date. | ||
- | < [F2]<ID>[F3]RLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>[F5][F5] | + | < [F2]<ID>[F3]RLANTME[F4]<YEAR>:<MONTH>:<DATE>:<DAYOFWEEK>:<HOUR>:<MINUTE>:<SECOND>:<UTCTIMEZONE>:<UTCTIMEZONESTR>:<NTP_SYNC>:<NTP_SERVER_ID>[F5][F5] |
</sxh> | </sxh> | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Configure the real time clock on a LANBridge ID [02] | + | // Configure the real time clock on a LAN Bridge ID [02] |
- | > [F2][02][F3]CLANTME[F4]2011:12:27:3:18:12:12:29[F5][F5] | + | > [F2][02][F3]CLANTME[F4]2011:12:27:3:18:12:12:29:1:4[F5][F5] |
// Reply | // Reply | ||
- | < [F2][02][F3]RLANTME[F4]2011:12:27:3:18:12:12:29[F5][F5] | + | < [F2][02][F3]RLANTME[F4]2011:12:27:3:18:12:12:29:UTC+8.00:1:4[F5][F5] |
</sxh> | </sxh> | ||
Line 532: | Line 726: | ||
===== Transmission Messages ===== | ===== Transmission Messages ===== | ||
+ | |||
+ | ==== PWD - Authenticate Password ==== | ||
+ | |||
+ | The ''PWD'' (Password) command allows you to login to a LAN Bridge that has a login configured.\\ | ||
+ | No other commands will be accepted until the correct login details are entered if a login has been configured.\\ | ||
+ | |||
+ | === Data === | ||
+ | <sxh cflink; light: true> | ||
+ | > [F2]<ID>[F3]TLANPWD[F4]<USER>:<PASSWORD>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | * **<USER>** = The username to login with | ||
+ | * **<PASSWORD>** = The password to login with | ||
+ | |||
+ | === Reply === | ||
+ | <sxh cflink; light: true> | ||
+ | < [F2]<ID>[F3]RLANPWD[F4]<USER>[F5][F5] | ||
+ | </sxh> | ||
+ | |||
+ | === Example === | ||
+ | <sxh cflink; light: true> | ||
+ | // Login to LAN Bridge on CFLink ID [02] with username 'admin' and password 'mysecretpass' | ||
+ | > [F2][02][F3]TLANPWD[F4]admin:mysecretpass[F5][F5] | ||
+ | // Reply | ||
+ | < [F2][02][F3]RLANPWD[F4]admin[F5][F5] | ||
+ | </sxh> | ||
==== SND - Send Data ==== | ==== SND - Send Data ==== | ||
- | The ''SND'' (Send) command allows you to send data to a specific communication slot defined on the LANBridge.\\ | + | The ''SND'' (Send) command allows you to send data to a specific communication slot defined on the LAN Bridge.\\ |
Any other communication slots subscribed to the slot targeted by the ''SND'' command will also receive the data.\\ | Any other communication slots subscribed to the slot targeted by the ''SND'' command will also receive the data.\\ | ||
This command is not to be used to send data to the RS232 slot (Slot 1), instead use the [[on-board-rs232-port-protocol|''SPW'' Command]] common to all devices with an on-board RS232 port.\\ | This command is not to be used to send data to the RS232 slot (Slot 1), instead use the [[on-board-rs232-port-protocol|''SPW'' Command]] common to all devices with an on-board RS232 port.\\ | ||
Line 555: | Line 775: | ||
=== Example === | === Example === | ||
<sxh cflink; light: true> | <sxh cflink; light: true> | ||
- | // Send a command to an ethernet device connected to slot 11, for LANBridge on CFLink ID [02] | + | // Send a command to an ethernet device connected to slot 11, for LAN Bridge on CFLink ID [02] |
> [F2][02][F3]TLANSND[F4]11:Hello World!\x0D[F5][F5] | > [F2][02][F3]TLANSND[F4]11:Hello World!\x0D[F5][F5] | ||
// Reply | // Reply | ||
Line 565: | Line 785: | ||
* 100 = Invalid Slot Number | * 100 = Invalid Slot Number | ||
+ | ====== Timezone Lookup Table ====== | ||
+ | * ''01'' - UTC-1200 | ||
+ | * ''02'' - UTC-1100 | ||
+ | * ''03'' - UTC-1000 | ||
+ | * ''04'' - UTC-930 | ||
+ | * ''05'' - UTC-900 | ||
+ | * ''06'' - UTC-800 | ||
+ | * ''07'' - UTC-700 | ||
+ | * ''08'' - UTC-600 | ||
+ | * ''09'' - UTC-500 | ||
+ | * ''10'' - UTC-430 | ||
+ | * ''11'' - UTC-400 | ||
+ | * ''12'' - UTC-330 | ||
+ | * ''13'' - UTC-300 | ||
+ | * ''14'' - UTC-200 | ||
+ | * ''15'' - UTC-100 | ||
+ | * ''16'' - UTC-0 | ||
+ | * ''17'' - UTC+100 | ||
+ | * ''18'' - UTC+200 | ||
+ | * ''19'' - UTC+300 | ||
+ | * ''20'' - UTC+330 | ||
+ | * ''21'' - UTC+400 | ||
+ | * ''22'' - UTC+430 | ||
+ | * ''23'' - UTC+500 | ||
+ | * ''24'' - UTC+530 | ||
+ | * ''25'' - UTC+545 | ||
+ | * ''26'' - UTC+600 | ||
+ | * ''27'' - UTC+630 | ||
+ | * ''28'' - UTC+700 | ||
+ | * ''29'' - UTC+800 | ||
+ | * ''30'' - UTC+845 | ||
+ | * ''31'' - UTC+900 | ||
+ | * ''32'' - UTC+930 | ||
+ | * ''33'' - UTC+1000 | ||
+ | * ''34'' - UTC+1030 | ||
+ | * ''35'' - UTC+1100 | ||
+ | * ''36'' - UTC+1130 | ||
+ | * ''37'' - UTC+1200 | ||
+ | * ''38'' - UTC+1245 | ||
+ | * ''39'' - UTC+1300 | ||
+ | * ''40'' - UTC+1400 |