View Single Post
  #2   Spotlight this post!  
Unread 01-01-2017, 11:19
DaveFrederick's Avatar
DaveFrederick DaveFrederick is offline
Registered User
FRC #1895
 
Join Date: Jan 2009
Location: Manassas,VA
Posts: 36
DaveFrederick is a jewel in the roughDaveFrederick is a jewel in the roughDaveFrederick is a jewel in the rough
Re: FRCSim, Gazebo v7, and GearsBot example

I noticed that some of the sensors files need to be renamed.
( e.g., cp libencoder.so libgz_encoder.so )

See lesson learned #4 below.
Watch for errors on startup and create copies of the files as required.
Stick with FRCSIM. I think this will be an important tool once we learn and document how to use it.

Dave Frederick
Team 1895 Mentor

==============================================


Limitations:
1) The FRCSIM can take a few tries to start.
2) Joystick methods are not working correctly (getX(), getY() and getZ() )
Use: Robot.oi.joystick1.getRawAxis(0)
// Robot.driveTrainSubSystem.ArcadeDrive(Robot.oi.joy stick1.getY(),Robot.oi.joystick1.getX());
Robot.driveTrainSubSystem.ArcadeDrive(Robot.oi.joy stick1.getRawAxis(0), Robot.oi.joystick1.getRawAxis(1));

Notes: Joystick
- Axis 0 - Left(-) and Right(+)
- Axis 1 - forward (-) and Back (+)
- Axis 2 - Rotate forward (-) and Back (+)
Seems like getX(), getY() and getZ() are not working - wrong order
3) The Analog Gyro does not support the “setSensitivity” method. Comment out in RoboMap.
4) Needed to rename a few sensors (one Time).
/home/robot/wpilib/simulation/plugins/
cp libencoder.so libgz_encoder.so
cp libgyro.so libgz_gyro.so
Reply With Quote