Head Action Client Example

From sdk-wiki
Jump to: navigation, search

Summary

The Head Action Client Example moves the head through a set of head positions and velocities to showcase an interface for the Head Action Server.

Code Walkthrough

Head Action Client - Code Walkthrough

Quickstart

From an RSDK Shell, run the head_action_server.py from the baxter_interface package:

    $ rosrun baxter_interface head_action_server.py

And in a different terminal, run the head_action_client.py demo from the baxter_examples package:

    $ rosrun baxter_examples head_action_client.py

Baxter's head will pan left and right to the commanded angles at the commanded velocities.

Overview

Baxter's head can rotate left-to-right in a _pan motion. The pan motion swings Baxter's 'face' (a.k.a. screen) to a settable angle, rotating around the vertical axes of the head.

The head action client example is intended to be a simple demo that can be examined to demonstrate the use of the Head Trajectory Action Server. The non-interactive demo calls the pan() function which sets the head pan to a few preset angles, waiting in between each in order to give enough time for the head to move there.

For more information on Baxter's head, see Using the Head.

Interfaces

ROS APIs

See the API Reference page for details.

  • Head Action Client Interface: robot/head/head_action
              Topic                                [Message]
* /robot/head/head_action/status                   [actionlib_msgs/GoalStatusArray]
* /robot/head/head_action/cancel                   [actionlib_msgs/GoalID]
* /robot/head/head_action/result                   [control_msgs/SingleJointPositionActionResult]
* /robot/head/head_action/feedback                 [control_msgs/SingleJointPositionActionFeedback]
* /robot/head/head_action/goal                     [control_msgs/SingleJointPositionActionGoal]
* /rsdk_head_action_server/parameter_descriptions  [dynamic_reconfigure/ConfigDescription]
* /rsdk_head_action_server/parameter_updates       [dynamic_reconfigure/Config]

Documentation

Head Action Client - Code Walkthrough

Troubleshooting

For common issues specific to using the Head Action Client with Baxter, check out the Troubleshooting page.