Connection and events commands¶
The calls that connect a program to the robot, report the connection, and register functions the client calls when something happens.
connect()first. It checks that the robot speaks this client's protocol.- Callbacks run on the client's own receiving thread. Keep them short, and never wait for the robot inside one.
| Command | What it does | Runs |
|---|---|---|
connect |
Connect to the robot and check its command protocol version. | In the client |
disconnect |
Close the connection to the robot. | In the client |
connected |
Whether the client is connected to the robot. | In the client |
on_error |
Set a function to call when the robot sends an error event. | In the client |
on_status_change |
Set a function to call each time the robot's status arrives. | In the client |
on_motion_complete |
Set a function to call when a queued command of this client finishes. | In the client |
on_motion_error |
Set a function to call when a queued command of this client fails. | In the client |
remote_ip |
Return the robot's IP address on this connection. | In the client |
local_ip |
Return this computer's IP address on the route to the robot. | In the client |
local_label |
Return this connection's address as the robot names it. | In the client |
Found a mistake on this page? Edit it on GitHub · Report it · Get help