Collada Links/Bones In Gazebo?
Hi all, this is a additional question I recently asked about Attaching A Sensor To An Animated Actor.
This is based on the tutorial Make an animated model (actor). I want to use a animated collada (a walking man) and attach a sensor to his foot. In an answer, chapulina answers that actors can have links attached, just like models do. He gives the example:
<link name="box_link"> ... <sensor name="camera" type="camera"> <camera> </camera> <visualize>true</visualize> </sensor>
This works to some degree. I can attach a small box (visually representing the sensor) at a pose relative to the actor. As the actor walks, the box moves with the actor. However, I need it to move relative to a point on the actors foot. In my case, the box moves relative to the origin of the actor, not a point on his foot.
I have noticed that when the animated actor is in Gazebo that there are links listed for the actor. For example, there are links for his hips, neck, right leg, right foot, etc.. I also noticed that if I import the actor (walk.dae) into Blender that these links appear as bones in Blender. So, taking chapulina's suggestion, I modified his example and used a link listed in Gazebo: the "RightFoot" link. When I put this in the world file and start Gazebo, I'm given the warning:
Warning [parser.cc:778] XML Element[origin], child of element[joint] not defined in SDF. Ignoring[origin]. You may have an incorrect SDF file, or an sdformat version that doesn't support this element.
It appears to me that somehow the bones in Blender are loaded into the parameter server and Gazebo can see them. I do not list these in an SDF file anywhere, yet Gazebo sees them. If I try to insert a reference to one of these as a link for my actor in my world file I get an error message.
Can anyone explain this to me? If Gazebo sees these links (which are not defined in a SDF file), can I use one of these links and attach my sensor to this link? If so, how is this done?
Chapulina, thanks for the reply. I could not get an image into the comments section, so I used the answer section. Sorry if this is inappropriate.
From the image below, this is what I'm seeing: The white cube represents a visual for the sensor that I'm trying to attach to the foot. Currently, the sensor/box moves with the model, but does not move with the foot (which is what I want it to do). In the middle of the image (labeled "Gazebo"), I see the model has links that somehow are loaded into Gazebo. I do not have a URDF or SDF file that describes the model. In the world file, the actors "walk" and "animation" use the "walk.dae" file. If I import the "walk.dae" file ... (more)