Push to reboot (PTR) is a controllable power strip that utilizes off-the-shelf analog two-way radios for long range communication. A PTR network consists of a "controller" radio capable of sending DTMF tones and up to 9 individually addressable "nodes" that are each comprised of an analog radio attached to a PTR power strip that has 4 controllable AC outlets called "ports".
All communication within a network occurs on a single simplex frequency. Nodes are controlled by broadcasting DTMF "messages" from a controller radio. Each message begins with a
* character and ends with a
# character; message length refers to the payload between these delimiters.
To keep things simple the PTR protocol only has 2 message types: authentication and command. Authentication messages are 6 digit HOTP codes that can be generated using any RFC 4226 compatible generator (like Google Authenticator). Command messages are 3 character strings in the format
<node><port><action>. The following are descriptions of command fields:
|node||0-9||Destination node that command is intended for.|
0 is used to send a command to all nodes.
|port||0-4||Destination port that action will be performed on.|
0 is used to perform an action on all ports.
|action||A-D||Action to perform on port.|
Action letters are assigned verbs to make entering commands by hand easier. The following are descriptions of each action:
|A||Activate||Turn the port(s) on.|
|B||(re)Boot||Turn the port(s) off, delay, then turn the port(s) on.|
|C||Call||Turn the port(s) off, delay, then turn the port(s) off.|
|D||Deactivate||Turn the port(s) off.|
The delay for reboot (B) and call (C) actions (along with other settings) can be configured via a serial command line on the PTR device.
Authentication must be performed before each command message. The following is a sequence diagram of the PTR protocol:
Action confirmation tones are beeps send from node to controller to verify that a command was received and acted upon. No confirmation tone is sent if a command is sent to all nodes -- doing so would cause all the nodes to broadcast on the same frequency simultaneously. Reboot (B) and call (C) actions are long running and utilize 2 confirmation tones: one at the beginning of the action and one at the end of the action. No commands can be issued while a node is busy performing an action.
Authentication messages are dynamic and must be entered by hand on the front keypad of a radio, but command messages are static and short enough (with delimiters) to be placed into the PTT-ID field of a channel. In theory a zone within a radio could be dedicated to telecommand where each channel represents a different command to be sent using the PTT button (hence the name "push to reboot").