Revision: 7388
http://playerstage.svn.sourceforge.net/playerstage/?rev=7388&view=rev
Author: rtv
Date: 2009-03-08 05:30:35 +0000 (Sun, 08 Mar 2009)
Log Message:
-----------
demo...
Modified Paths:
--------------
code/branches/federation/stage/examples/gzfed/gzwander.cc
code/branches/federation/stage/examples/gzfed/stage.world
Modified: code/branches/federation/stage/examples/gzfed/gzwander.cc
===================================================================
--- code/branches/federation/stage/examples/gzfed/gzwander.cc 2009-03-08
05:30:33 UTC (rev 7387)
+++ code/branches/federation/stage/examples/gzfed/gzwander.cc 2009-03-08
05:30:35 UTC (rev 7388)
@@ -219,16 +219,20 @@
vel.x, vel.y, vel.z, vel.a );
- static int skip = 10;
+
+ static int last_second = 0;
- if( --skip == 0 )
+ int now_second = mod->GetWorld()->SimTimeNow() / 1e5;
+
+ if( last_second < now_second )
{
+ printf( "%d seconds - pushing state\n", now_second );
// tell gazebo the new position
gzPush( robot->gazeboid,
pose.x, pose.y, pose.z+0.146, 0,0, pose.a,
vel.x, vel.y, vel.z, 0,0, vel.a );
- skip = 10;
+ last_second = now_second;
}
return 0; // run again
Modified: code/branches/federation/stage/examples/gzfed/stage.world
===================================================================
--- code/branches/federation/stage/examples/gzfed/stage.world 2009-03-08
05:30:33 UTC (rev 7387)
+++ code/branches/federation/stage/examples/gzfed/stage.world 2009-03-08
05:30:35 UTC (rev 7388)
@@ -41,7 +41,7 @@
name "r0"
pose [ 0.892 0.800 0 56.500 ]
- sicklaser()
+ sicklaser( samples 180 )
ctrl "gzwander"
)
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Playerstage-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/playerstage-commit