Using Vagrant/VirtualBox to virtualize the RoboRIO?

Just wondering if anyone has used Vagrant or VirtualBox to virtualize the RoboRIO. I ask this because my team only has one, and we’d like to be able to program it (and test it) without being connected to the real thing. Does anyone have any pointers that they can give? We’ll probably also be installing the Java VM, which, if we have a FIRST system image properly installed and a correct network connection, should not be hard. If not, this’d make a good summer project :wink:

We could always build a test suite on top of our robot program, but that’s just not as groovy as virtualization.

I think virtualbox only does x86/64 virtualization, and doesn’t support ARM. QEMU should support ARM, but for it to be really useful you would need some sort of hardware interface that WPILib/etc could talk to. In that case, it’ll be easier (and lighter) to build a simulator instead.

Speaking of which, you might check out frcsim, its robot simulation for WPILib built on gazebo, a 3d robot simulation framework. I’ve gotten it working in Linux/OSX, but they haven’t released modeling tools to create your own 3d environment yet. There’s also little/no documentation. I expect they’ll be fixing it up more this summer. You can find some stuff about it in the WPILib repository (mirrored here), and there’s a sample project or two that come with the Eclipse plugins.

If you’re interested in other types of simulation, if you want to use python we have a Tk simulation interface and a new web based simulation interface that we’re working on too, that users will be able to easily create custom animation widgets for. I’m hoping someone will build a Java/C++ backend for it too, as the web piece isn’t python specific. Being able to run your code before you upload it to the robot is very nice and saves us lots of time. :slight_smile:

The test suite is definitely the way to go - why virtualize when your code will run on the JVM on any platform?

Both approaches have merit. The NI and WPI simulators that run the user code on a regular laptop or desktop against libraries that simulate the effects that would take place on the robot. This is much less intensive than running the entire linux OS and emulating an FPGA. And they give you physics engines to close the loop and let your code run with more fidelity.

Greg McKaskle