I made a 6-DOF arm using xacro , its moving in gazebo but when i use tf_echo , the orientation and position of a frame does not change overtime.
when arm moves in gazebo the orientation and position of a frame in a link should change over time.
but when i use rosrun tf tf_echo [frame1] [frame2] the position and orientation remain unchanged.
please help me out with this.
my model moves in gazebo but not in rviz..
thanks in advance
Here is my launch file
<?xml version="1.0"?>
<launch>
<group ns="/arm">
<param name="robot_description" command="$(find xacro)/xacro $(find robo_arm)/urdf/robo_dis.xacro"/>
<arg name="x" default="0"/>
<arg name="y" default="0"/>
<arg name="z" default="0.5"/>
<node name="mybot" pkg="gazebo_ros" type="spawn_model" output="screen"
args="-urdf -param robot_description -model arm -x $(arg x) -y $(arg y) -z $(arg z)" />
<rosparam command="load" file="$(find robo_arm)/config/joints.yaml" />
<node name="controller_spawner" pkg="controller_manager" type="spawner"
respawn="false" output="screen" ns="/arm"
args="--namespace=/arm
joint_state_controller
joint1_position_controller
joint2_position_controller
joint3_position_controller
joint4_position_controller
--timeout 60">
</node>
<node name="joint_state_publisher" pkg="joint_state_publisher" type="joint_state_publisher">
</node>
<!-- Combine joint values -->
<node name="robot_state_publisher" pkg="robot_state_publisher" type="robot_state_publisher"/>
</group>
Topic List
/arm/joint1_position_controller/command
/arm/joint1_position_controller/pid/parameter_descriptions
/arm/joint1_position_controller/pid/parameter_updates
/arm/joint1_position_controller/state
/arm/joint2_position_controller/command
/arm/joint2_position_controller/pid/parameter_descriptions
/arm/joint2_position_controller/pid/parameter_updates
/arm/joint2_position_controller/state
/arm/joint3_position_controller/command
/arm/joint3_position_controller/pid/parameter_descriptions
/arm/joint3_position_controller/pid/parameter_updates
/arm/joint3_position_controller/state
/arm/joint4_position_controller/command
/arm/joint4_position_controller/pid/parameter_descriptions
/arm/joint4_position_controller/pid/parameter_updates
/arm/joint4_position_controller/state
/arm/joint_states
/clock
/gazebo/link_states
/gazebo/model_states
/gazebo/parameter_descriptions
/gazebo/parameter_updates
/gazebo/set_link_state
/gazebo/set_model_state
/rosout
/rosout_agg
/tf
/tf_static
Does your model have a joint_state_controller to publish joint states to ROS? Have you loaded the corresponding URDF to the parameter server and setup the
robot_state_publisher
to publish thetf
data associated with the joint states? These are all steps that are usually followed to have a moving Gazebo model be reflected in the ROStf
tree. Without more information about your particular setup, it will be very challenging to provide much help on this question.The Gazebo ros_control tutorial has a good explanation and example of how these pieces are supposed to fit together.
sir, Please check my topic list and launch file...each link broadcasting tf data but when i move the joints by publising messages, tf data remains unchanges..its should changed.
Thanks a lot Sir, by removing node joint_state_publisher i am able to get desired results. thanks a lot
Excellent! I converted my comment to an answer since that turned out to be a correct guess.