Project:Java-Rako/Published API: Difference between revisions
(Created page with '=TCP/IP= In the following examples the NetBios name for the bridge is assumed to be 'rakobridge' (the default). This name can be changed using the web interface or the IP address…') |
|||
(7 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{Project}} | |||
=TCP/IP= | =TCP/IP= | ||
In the following examples the NetBios name for the bridge is assumed to be 'rakobridge' | In the following examples the NetBios name for the bridge is assumed to be '''rakobridge''' | ||
(the default). This name can be changed using the web interface or the IP address of the | (the default). This name can be changed using the web interface or the IP address of the | ||
bridge can be used. | bridge can be used. | ||
Line 6: | Line 8: | ||
==Telnet== | ==Telnet== | ||
A Telnet type interface is available on port 9761. This does not require a login. The | A Telnet type interface is available on port 9761. This does not require a login. The | ||
protocol is the same as the | protocol is the same as the [http://www.rakocontrols.com/downloads/rakors232commandsummary.pdf Rako RS232 Command Summary]. This interface is used by | ||
Rasoft so CANNOT be used at the same time. | Rasoft so CANNOT be used at the same time. | ||
Line 21: | Line 23: | ||
The example would send Scene 1 command to room 5, channel 4. If channel is omitted it will default to 0 meaning all channels. A page containing the phrase "Success!" is returned. | The example would send Scene 1 command to room 5, channel 4. If channel is omitted it will default to 0 meaning all channels. A page containing the phrase "Success!" is returned. | ||
=UDP/IP= | |||
UDP packets can be sent to port 9761 with the following format: | UDP packets can be sent to port 9761 with the following format: | ||
Latest revision as of 22:17, 5 February 2011
Published API
| |
---|---|
QR code |
TCP/IP
In the following examples the NetBios name for the bridge is assumed to be rakobridge (the default). This name can be changed using the web interface or the IP address of the bridge can be used.
Telnet
A Telnet type interface is available on port 9761. This does not require a login. The protocol is the same as the Rako RS232 Command Summary. This interface is used by Rasoft so CANNOT be used at the same time.
The interface can be used by typing:
telnet rakobridge 9761
HTTP
Requests can be made via the web interface by submitting a HTTP GET request in the following format:
http://rakobridge/rako.cgi?room=5&ch=4&com=3
The example would send Scene 1 command to room 5, channel 4. If channel is omitted it will default to 0 meaning all channels. A page containing the phrase "Success!" is returned.
UDP/IP
UDP packets can be sent to port 9761 with the following format:
0 | 1 | 2 | 3 | 4 | 5 | 6 ... | n |
"R" | #Bytes to follow | Room# high | Room# low | Channel # | Instruction | 0-7 bytes | CRC |
Sum of these bytes must equal zero.
The reply is either "AOK" or "AERROR"