A ros2_control layer implementation for ROBOTIS Dynamixel actuators. See layered_hardware to understand the layered scheme.
- sends commands to ROBOTIS Dynamixel actuators within
write()
function - fetches actuators' states within
read()
function - switches actuators' operating modes within
perform_command_mode_swtich()
function when controllers using associated interfaces activate
<layer_name> (yaml, required)
- map of parameter names and values for this layer
<layer_name>.serial_interface (string, default: '/dev/ttyUSB0')
- path to Usb2Dynamixel device
<layer_name>.baudrate (int, default: 115200)
- baudrate for Usb2Dynamixel device
<layer_name>.actuators (map<string, map>, required)
- map of parameters for each actuator
<layer_name>.actuators.<actuator_name>.id (int, required)
- id of the dynamixel actuator
<layer_name>.actuators.<actuator_name>.torque_constant (double, required)
- torque constant for conversion between current and torque in N*m/A
- ex. if the actuator's stall torque & current are 10.6 N*m & 4.4 A at the operating voltage, it would be 2.41 (= 10.6 / 4.4)
<layer_name>.actuators.<actuator_name>.operating_mode_map (map<string, string>, required)
- map to actuator's operating mode names from associated interface names (typically joint interfaces)
- possible operating mode names are 'clear_multi_turn', 'current_based_position', 'current', 'extended_position', 'reboot', 'torque_disable', & 'velocity'
<param name="example_dynamixel_actuator_layer">
serial_interface: /dev/serial/by-id/...
baudrate: 1000000
actuators:
example_dynamixel_1:
id: 1
torque_constant: 2.41
operating_mode_map:
example_joint_1/position: extended_position
...
example_dynamixel_2:
id: 2
...
</param>
- if you feel slow communication speed with actuators, try adjusting the latency timer for your usb-serial device according to this comment