Skip to content

Instantly share code, notes, and snippets.

@brettle
Last active January 15, 2017 19:06
Show Gist options
  • Save brettle/1af061a73baadcaa8859 to your computer and use it in GitHub Desktop.
Save brettle/1af061a73baadcaa8859 to your computer and use it in GitHub Desktop.

Getting FRCSim working on Fedora 22

These are my notes (as best I can remember) on getting FIRST Robotics Competition FRCSim simulator working on Fedora 22/23 in hopes of being able to build robot code and run it on the simulator.

Current Status

Gazebo plugins and gazebo_msgs build. Can run a simulation but joystick controls are messed up.

How To

Install Eclipse Java, FRC plugins, and precompiled simulation code

  1. Follow the standard instructions for setting up the environment for Java-based FRC programming.

  2. Download and install the lates FRC simulation code:

cd ~/wpilib
mkdir simulation
cd simulation
wget http://first.wpi.edu/FRC/roborio/maven/release/edu/wpi/first/wpilib/simulation/simulation/1.0.0/simulation-1.0.0.zip
unzip simulation-1.0.0.zip

Install gazebo

Install the version that comes with the distribution:

sudo dnf install gazebo gazebo-devel # and maybe others...

OR, download, build, and install a more recent version locally from the source at gazebosim.org.

Build the FRC gazebo plugins from source

cd ~
mkdir git
cd git
git clone https://usfirst.collab.net/gerrit/allwpilib
cd allwpilib
mkdir build
cd build
cmake -DSIMULATION_INSTALL_DIR=$PWD/install/simulation ..
make frc_gazebo_plugins

Install the plugins

cd ~/wpilib/simulation
mv plugins plugins-official
ln -s ~/git/allwpilib/build/install/simulation/plugins .
ln -s ~/git/allwpilib/simulation/frcsim ~/bin/frcsim # Or elsewhere in your path

Install models/worlds

Download frcsim-gazebo-models.zip from https://usfirst.collab.net/sf/frs/do/viewRelease/projects.wpilib/frs.simulation.frcsim_gazebo_models

Unzip it within $HOME/wpilib/siumulation.

Edit the build.properties in your robot code project. Change/set:

simulation.world.file=/home/yourusername/wpilib/simulation/worlds/GearsBotDemo.world

Setup a Joystick

Install joystick support:

sudo dnf install joystick-support

Reboot.

Connect a Sony Dual Shock3 controller over USB.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment