Ignition Gazebo

API Reference

6.0.0~pre1
gui/plugins/joint_position_controller/JointPositionController.hh File Reference
#include <map>
#include <memory>
#include <string>
#include <ignition/gazebo/gui/GuiSystem.hh>
#include <ignition/gazebo/Types.hh>

Go to the source code of this file.

Functions

 Q_DECLARE_METATYPE (Entity) namespace ignition
 

Function Documentation

◆ Q_DECLARE_METATYPE()

Q_DECLARE_METATYPE ( Entity  )

Model holding information about joints

Constructor

Destructor

Static version of roleNames

Returns
A hash connecting a unique identifier to a role name.

Add a joint to the list.

Parameters
[in]_typeIdJoint to be added.
Returns
Newly created item.

Remove a joint from the list.

Parameters
[in]_entity

Clear all joints

Keep track of items in the list, according to joint entity.

Control position of all joints in the selected model. The model must have loaded an systems::JointPositionController for each joint to be controlled.

This plugin publishes position command messages (ignition::msgs::Double) on topics in the format /model/<model_name>/joint/<joint_name/0/cmd_pos.

Only the 1st axis of each joint is considered. Joints without axes are ignored.

When the lock button is checked, the model doesn't change even if it's deselected.

Configuration

<model_name>: Load the widget pointed at the given model, so it's not necessary to select it. If a model is given at startup, the plugin starts in locked mode.

Model entity

Model name

Locked

Constructor

Destructor

Callback in Qt thread when joint position changes.

Parameters
[in]_jointNameName of joint being commanded
[in]_posNew joint position

Callback in Qt thread when user requests a reset.

Get the model currently controlled.

Returns
Model entity ID.

Set the model currently controlled.

Parameters
[in]_entityModel entity ID.

Notify that entity has changed.

Get the name of model currently controlled.

Returns
ModelName, such as 'world' or 'model'

Set the name of model currently controlled.

Parameters
[in]_nameModelName, such as 'world' or 'model'.

Notify that model name has changed

Get whether the controller is currently locked on a model.

Returns
True for locked

Set whether the controller is currently locked on a model.

Parameters
[in]_lockedTrue for locked.

Notify that locked has changed.