Kangaroo Doctor
When kangaroo-5c misbehaves, open http://kangaroo-5c:8001 first. Do this before you read logs, open the Web Commander or run ethercat slaves by hand.
kangaroo_doctor is a web page and command-line tool that shows what is wrong with kangaroo-5c and walks you through the fix. It starts automatically at boot on the robot as a PAL startup app.
- Code:
pal-policy-deployment/kangaroo_doctor/(scripts/kangaroo_doctor.py,scripts/gripper_left.py) - Full reference: the package's README. This page only covers the daily use.
Warning
The page has no login. Anyone on the robot network can use it, including the buttons that move the robot. Make sure the robot is safe to move before you press a button.
How to use it
Page: http://kangaroo-5c:8001
The browser tab icon shows the state, so you can keep the tab open in the background:
| Icon | Meaning |
|---|---|
| green | healthy |
| red | problem |
| amber | starting up, or an action is running |
| gray | page unreachable |
Command line: on the robot, or in the dev container. In the dev container it runs its commands over ssh as pal@kangaroo-5c.
rosrun kangaroo_doctor kangaroo_doctor.py status # motor list and what to do next
rosrun kangaroo_doctor kangaroo_doctor.py fix # guided: restart deployer → e-stop power cycle
rosrun kangaroo_doctor kangaroo_doctor.py homing # full_homing; if rejected, restart ros_bringup
rosrun kangaroo_doctor kangaroo_doctor.py gripper open|close # test the left gripper
Restart the page (on the robot):
pal-stop kangaroo_doctor; pal-start kangaroo_doctor
Log: ~/.ros/log/latest/kangaroo_doctor.pal.log/current
What it shows and detects
- Body map of all 32 EtherCAT slaves by motor name (e.g.
leg_right_5, not "slave 5"). Colors: on, off (PREOP), bus error/missing, drive error. Tap a motor to see its drive details: error codes, e-stop, temperatures, actual and absolute position. - E-stop pressed or waiting for re-arm.
- Deployer problems: deployer not running, a leftover deployer holding the bus, or motors that never switched on.
- Deployer stopped with an error while starting, e.g.
Ankle Transmission … outside the range of the actuator. In this state all motors still show OP, but the controller manager does not answer andchange_controllerstimes out. Without the doctor this looks healthy. - Configuration and controller problems: wrong
robot_type,joint_state_controllernot running (full homing then fails), and other non-OK entries from the Web Commander's diagnostics.
Buttons on the page
- Restart deployer
- E-stop power cycle (guided)
- Full homing
- Restart ros_bringup
- Open / Close left gripper
There is also a controller list where you can start, stop, load and unload controllers. Starting a controller stops the running controllers that use the same joints. The page warns you before stopping a controller leaves joints limp.
Standard recovery order
The page suggests the next step. Do the steps in this order:
- Restart deployer. This fixes most problems.
- E-stop power cycle, if a motor stays in error: hold the e-stop for 2–5 s, release it, then press the blinking button to re-arm. The page then restarts the deployer.
- Restart ros_bringup, if
full_homingis rejected. Then home again.
Left gripper check
Press Close left gripper with an empty jaw. The jaw must close fully. The result is one of:
| Result | Meaning |
|---|---|
| done | OK. |
| stopped partway | The gripper holds an object or is blocked (a cube stops the jaw at about 0.48). |
| DID NOT MOVE | Known fault: the gripper drive hangs, but the bus still looks fine. |
If the result is DID NOT MOVE, do these steps in order. After each step, check again with Close left gripper:
- E-stop power cycle.
- Reboot the robot.
- With the default controllers running (
gripper_left_controller), detach the gripper (this kills its motor) and reattach it. Then do the e-stop power cycle.
Deploying changes to it
cd /catkin_ws && catkin_make && source devel/setup.bash
rosrun pal_deploy deploy.py --package kangaroo_doctor kangaroo-5c
ssh pal@kangaroo-5c 'bash -ic "pal-stop kangaroo_doctor; pal-start kangaroo_doctor"'
If the deploy fails with CMake Error: The source … does not match the source … used to generate cache, delete the old build output from before the package moved, then deploy again:
rm -rf /catkin_ws/build_pal_deploy/kangaroo_doctor /catkin_ws/devel_pal_deploy/.private/kangaroo_doctor