Skip to content

yoshito-n-students/layered_hardware_unitree

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

layered_hardware_unitree

A ros2_control layer implementation for Unitree actuators. See layered_hardware to understand the layered scheme.

Layer plugin: layered_hardware_unitree/UnitreeActuatorLayer

  • sends commands to Unitree actuators within write() function
  • fetches actuators' states within read() function
  • switches actuators' operation modes within perform_command_mode_swtich() function when controllers using associated interfaces activate

Hardware parameters

<layer_name> (yaml, required)

  • map of parameter names and values for this layer

<layer_name>.serial_interface (string, default: '/dev/ttyUSB0')

  • path to USB-serial converter for Unitree actuators

<layer_name>.actuators (map<string, map>, required)

  • map of parameters for each actuator

<layer_name>.actuators.<actuator_name>.id (int, required)

  • id of the Unitree actuator

<layer_name>.actuators.<actuator_name>.motor_type (string, required)

  • actuator's type name like 'A1', 'B1', & 'GO-M8010-6'

<layer_name>.actuators.<actuator_name>.pos_gain (double, default: 0.1)

  • control gain for actuator position (Kp)

<layer_name>.actuators.<actuator_name>.vel_gain (double, default: 0.05)

  • control gain for actuator velocity (Kd)

<layer_name>.actuators.<actuator_name>.operating_mode_map (map<string, string>, required)

  • map to actuator's operation mode names from associated interface names (typically joint interfaces)
  • possible operation mode names are 'brake', 'position', 'torque' & 'velocity'

Example of parameter description

<param name="example_unitree_actuator_layer">
    serial_interface: /dev/serial/by-id/...
    actuators:
        example_unitree_1:
            id: 1
            motor_type: GO-M8010-6
            operating_mode_map:
                example_joint_1/position: position
                ...
        example_unitree_2:
            id: 2
            ...
</param>

Example

About

A ros_control layer implementation for Unitree actuators

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published