Custom models for frcsim?

Haven’t found any documentation to do this. Of course, haven’t looked terribly hard either…

You will probably need to make a custom Gazebo Plugin that describes your robot’s kinematics and control signals. I also haven’t looked to terribly deep into it myself yet, but I have worked with Gazebo quite a bit in the past.

IIRC: You can define the structure of your robot in an XML type file where you specify each joint and link in your system, then write a c++ plugin that describes how to control each joint.

Right, the frcsim plugins provide generic functionality to control a joint, so ideally those are designed such that they will work with any general robot (for example, pacsim and gearsbot use the same binaries).

And yeah, I’m vaguely aware of the XML, but I’m not sure of the format, and I suspect there’s something one needs to do to create the world file… etc. I’d rather not have to reverse engineer it if FIRST has already provided tools to do these things (which, I feel like I read about them somewhere… maybe)

I haven’t seen anything else provided by FIRST. It would be pretty cool if someone would crate a world model of the areana and share it on CD though, eh? Perhaps I might take a look at doing that… :smiley:

The XML file is specific to Gazebo, It’s not that bad once you get into it but it has a pretty steep learning curve.

We aren’t officially supporting the addition of your own models to Gazebo. There is a plugin that was developed last summer supported by SolidWorks and OSRF and we will continue to work on it with the hope of making it available in the fall. The idea is that the model can be annotated with the sensor and actuator information for your robot, and the plugin exports the model with that information in URDF format that can be imported into Gazebo. Then a plugin for Gazebo allows the simulator edition of WPILib to talk to simulated model. Look for a beta in the spring or early summer that you can start playing with.


I will echo Brad - this is not yet supported, although it IS possible for enterprising teams. I built up a very simple FTC robot this way from a team’s CAD assemblies, but it wasn’t linked to the WPIlib code, which is more tricky.


It’s difficult to do at the moment, but could we throw together best practices for conforming to the robotmap.xml file, and let teams use the old CAD exporter, or the alpha version of the new exporter?

We’ll try to post something for people to play with, but with the understanding that it is not yet finished. Maybe sometime this week.