Permalink
Browse files

added avon fidicial support

  • Loading branch information...
1 parent 6cab801 commit eb59ae81a9a1f322af452e5dfe934d5eb645c86d Richard Vaughan committed Nov 13, 2010
Showing with 8 additions and 7 deletions.
  1. +4 −4 avonstage/avonstage.cc
  2. +1 −0 libstage/model_fiducial.cc
  3. +1 −1 libstage/stage.hh
  4. +2 −2 worlds/everything.world
View
8 avonstage/avonstage.cc
@@ -303,13 +303,13 @@ int FiducialData( Stg::Model* mod, av_msg_t* data )
fd.fiducials[i].pose[1] = 0.0; // no azimuth in Stage
fd.fiducials[i].pose[2] = sf[i].range;
- fd.fiducials[i].geom.pose[0] = sf[i].pose_rel.x;
- fd.fiducials[i].geom.pose[1] = sf[i].pose_rel.y;
+ fd.fiducials[i].geom.pose[0] = 0.0; // sf[i].pose_rel.x;
+ fd.fiducials[i].geom.pose[1] = 0.0; // sf[i].pose_rel.y;
fd.fiducials[i].geom.pose[2] = 0.0;
fd.fiducials[i].geom.pose[3] = 0.0;
fd.fiducials[i].geom.pose[4] = 0.0;
- fd.fiducials[i].geom.pose[5] = sf[i].pose_rel.a;
-
+ fd.fiducials[i].geom.pose[5] = sf[i].geom.a;
+
fd.fiducials[i].geom.extent[0] = sf[i].geom.x;
fd.fiducials[i].geom.extent[1] = sf[i].geom.y;
fd.fiducials[i].geom.extent[2] = sf[i].geom.z;
View
1 libstage/model_fiducial.cc
@@ -207,6 +207,7 @@ void ModelFiducial::AddModelIfVisible( Model* him )
fid.bearing = dtheta;
fid.geom.x = hisgeom.size.x;
fid.geom.y = hisgeom.size.y;
+ fid.geom.z = hisgeom.size.z;
fid.geom.a = normalize( hispose.a - mypose.a);
//fid.pose_rel = hispose - this->GetGlobalPose();
View
2 libstage/stage.hh
@@ -2720,7 +2720,7 @@ namespace Stg
meters_t range; ///< range to the target
radians_t bearing; ///< bearing to the target
Pose geom; ///< size and relative angle of the target
- Pose pose_rel; /// relative pose of the target in local coordinates
+ //Pose pose_rel; /// relative pose of the target in local coordinates
Pose pose; ///< Absolute accurate position of the target in world coordinates (it's cheating to use this in robot controllers!)
Model* mod; ///< Pointer to the model (real fiducial detectors can't do this!)
int id; ///< the fiducial identifier of the target (i.e. its fiducial_return value), or -1 if none can be detected.
View
4 worlds/everything.world
@@ -50,11 +50,11 @@ puck( pose [-8.959 2.752 0 -101.643 ] color "orange" )
#
define trickedoutpioneer pioneer2dx
(
- ranger( alwayson 0 )
+ ranger( alwayson 1 )
sicklaser( pose [0.030 0 0 0 ] alwayson 1 )
- fiducial( range_max 8 range_max_id 5 )
+ fiducial( range_max 8 range_max_id 5 alwayson 1 )
fiducial_return 17
gripper_return 0

0 comments on commit eb59ae8

Please sign in to comment.