Native RoboRIO Emulator?

I just came across this article on Hackaday: A Xilinx Zynq Linux FPGA Board For Under $20? The Windfall Of Decommissioned Crypto Mining | Hackaday

These are basically cheap secondhand controller boards with Zynq-7010s, similar to the Z7020 in a roboRIO. These boards should definitely be able to run the FRC roboRIO OS; they may or may not be able to use the FRC FPGA image (the difference between the 7010 and 7020 is a bigger Artix). If not, it should be possible to create a smaller FPGA image with less functionality.

I just ordered a handful. When they arrive in a month or so, I’ll post updates. For our team, at least, being able to run robot code on a $10 dev board instead of a $500 roboRIO would be a huge benefit.

1 Like

Any thoughts on what the development toolchain would look like for making an FPGA image? I’ve worked with Altera’s products, and bit with Labview deploying to sbRIO boards - not sure if this will be similar?

Even if it’s not directly applicable to roboRIO images, I’m very down with a $10 FPGA development board.

if I’m reading this right, perhaps it’s as simple as dropping the bitstream for the device at the right memory location?

My only firsthand experience is with LabVIEW FPGA code for cRIOs (those old cRIO-FRCs are still useful!). However, the roboRIO is basically a myRIO in a slightly squashed package, so I think it should be easy enough to follow myRIO tutorials to generate the bitstream.

Yep, quite possibly. One of the last things I did before our school shut down was to SSH into a roboRIO and copy off a bunch of artifacts, including all the /dev/mtd* that get mounted, so that should provide some insight. (I could probably extract the same information from the image file, but there’s nothing like looking at a running system.)

1 Like

Sweet, makes sense. Just ordered one too to fiddle with. Great find, thanks!

Have you thought about any DRM NI might have put into the RoboRIO hardware/software? I haven’t done much work with FPGAs besides babysitting computers while they’re synthesizing, but surely they must have something in there to prevent you from booting the RIO image. Definitely keep us updated!

I can’t speak to the FPGA side, but the OS runs fine on QEMU: GitHub - robotpy/roborio-vm: Scripts to create QEMU virtual machine from the RoboRIO image file

Although since that involves emulating an entirely different architecture, it runs pretty slow, in my experience.

Quick update: I received my boards, and I have the RIO kernel and root FS running, albeit in a weird boot configuration (I’m using the original u-boot in NAND flash, then loading the kernel over TFTP from the u-boot shell and telling it to use a root FS on an SD card).

admin@NI-roboRIO-03057a46:~# uname -a
Linux NI-roboRIO-03057a46 4.14.87-rt49-cg-7.0.0f0-xilinx-zynq-189 #1 SMP PREEMPT RT Fri Mar 15 19:11:24 UTC 2019 armv7l GNU/Linux
admin@NI-roboRIO-03057a46:~# ls /
C@                        bin/                      etc/                      media/                    run/                      usr/
README_File_Paths.txt     boot/                     home/                     mnt/                      sbin/                     var/
README_File_Transfer.txt  c/                        lib/                      opt/                      sys/
VISION/                   dev/                      lost+found/               proc/                     tmp@

I’m currently working on making a CAN-enabled FPGA image (in Vivado, not LabVIEW).

There are lots of little problems to work out in Linux; for example, FRCNetComm is apparently trying to use fw_printenv to retrieve system settings from a small UBI filesystem on the flash chip.

I’ll post a writeup when I have something closer to a usable project.


FWIW, there is a version of the LabVIEW runtime available via the 32bit raspberry pi 3 libraries. I vent down this rabbit hole at one point. I ended up settling for an Intel based system for what I needed to do.

This is interesting though. Please try to thoroughly document the findings as this could prove to be very much worthwhile. Excellent discoveries!

Also, Apache Thrift might be useful to look up.

Mine came in yesterday as well. Feeding 12v into the 6pin labeled “12V” and “Gnd” yields no measurable current draw. I’m guessing at least that particular chunk of the board was DOA.

To power the board through that connector, you need to solder D21: GitHub - xjtuecho/EBAZ4205: A 5$ Xilinx ZYNQ development board. (Although I just used a jumper instead of a diode, and it worked fine)

1 Like

And here I was about to give up, thanks! I am indeed missing D24.