Skip to content

Commit

Permalink
sample example update for ROSCon
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre Desreumaux committed May 10, 2019
1 parent 3c3a086 commit 5f5fd94
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 21 deletions.
25 changes: 13 additions & 12 deletions config/sample.yaml
Expand Up @@ -3,36 +3,37 @@ dynamixel_controllers:
type: joint_state_controller/JointStateController
publish_rate: 10

pos_controller:
type: position_controllers/JointPositionController
joint: arm_joint_2
traj_controller:
type: position_controllers/JointTrajectoryController
joints:
- arm_joint_2

vel_controller:
type: velocity_controllers/JointVelocityController
joint: arm_joint_1

dynamixel_control:
serial_interface: /dev/ttyUSB0
loop_frequency: 50
cycle_time_error_threshold: 0.1
baudrate: 1000000 # in bauds
read_timeout: 0.05 # in seconds
scan_timeout: 0.05 # in seconds
loop_frequency: 500
cycle_time_error_threshold: 0.002
baudrate: 3000000 # in bauds
read_timeout: 0.005 # in seconds
scan_timeout: 0.005 # in seconds
# Cofniguration of the servos
servos:
arm_joint_1:
# hardware ID of the actuator
id: 2
offset: 3.14159265359
# offset to be added, in radians, to the position of an actuator
offset: 4.5 # in rad
#max-speed: 4.0 # in rad
command_interface: velocity
arm_joint_2:
id: 1
# max joint speed
# it shoud NOT be used for actuators in velocity mode
max-speed: 4 # in rad/s
offset: 3.1 # in rad/s
# this actuator is set in reverse mode for the speed and position
reverse: true
#reverse: false
# default mode
default_command_interface: position

4 changes: 2 additions & 2 deletions launch/sample.launch
Expand Up @@ -31,8 +31,8 @@
<!-- Start a controller for our dummy robot -->
<node name="controller" pkg="controller_manager" type="spawner"
respawn="false" output="screen" clear_params="true"
args="/dynamixel_controllers/vel_controller
/dynamixel_controllers/pos_controller
args="/dynamixel_controllers/traj_controller
/dynamixel_controllers/vel_controller
/dynamixel_controllers/joint_state_controller" />
</group>
</launch>
14 changes: 7 additions & 7 deletions urdf/sample.urdf
Expand Up @@ -39,12 +39,12 @@
<axis xyz="1 0 0"/>

<!-- Joint limits -->
<limit lower="-3.1415" upper="3.1415" velocity="10" effort="100"/>
<limit lower="-10.1415" upper="10.1415" velocity="10" effort="100"/>
<!-- Soft limits -->
<safety_controller k_position="3"
k_velocity="1000"
soft_lower_limit="-3.1415"
soft_upper_limit="3.1415" />
soft_lower_limit="-10.1415"
soft_upper_limit="10.1415" />
</joint>

<joint name="arm_joint_2" type="revolute">
Expand All @@ -54,12 +54,12 @@
<axis xyz="1 0 0"/>

<!-- Joint limits -->
<limit lower="-3.1415" upper="3.1415" velocity="5" effort="100"/>
<limit lower="-3.1415" upper="3.1415" velocity="10" effort="100"/>
<!-- Soft limits -->
<safety_controller k_position="3"
k_velocity="1000"
soft_lower_limit="-2.1415"
soft_upper_limit="2.1415" />
soft_lower_limit="-3.1415"
soft_upper_limit="3.1415" />
</joint>

<joint name="arm_joint_3" type="revolute">
Expand All @@ -76,4 +76,4 @@
soft_lower_limit="-3.1415"
soft_upper_limit="3.1415" />
</joint>
</robot>
</robot>

0 comments on commit 5f5fd94

Please sign in to comment.