For the upcoming fall classic FRC competition, our team did our first power-up check today. The test ran smoothly and everything worked fine. After turning off the robot and then turning it back on, without re-downloading code or changing anything on the robot, the driver station displayed “No Robot Code” and would not run. This program is the exact code that we used last FRC season, and was confirmed to be operational. Because it worked today and then suddenly stopped working without any apparent cause, this is a list of troubleshooting solutions we have tried so far:
Software Tests:
-Run full program (which was just working a moment ago)
-Run program with complex/potentially breakable functions commented out
-Run empty workspace (hello world)
-Run code from previous years (2012, 2013)
-Check Driver Station Launch Viewer
-Re-Install latest FRC WindRiver C++ update
-Re-Install latest WPILib update
-Re-Install latest National Instruments update
Firmware Tests:
-Run code on new cRIO
-Re-image cRIO with latest image (2014)
Hardware Tests:
-Unplug/replug ethernet cable
-Use new ethernet cable
-Run code using wireless connection
-Turn robot off then on
-Ensure battery is fully charged
-Check wiring system for breakages/disconnections
-Redo wiring system (just to be sure)
…
Any suggestions on what else we can try or what the problem may be?
-Run code from previous years (2012, 2013)
-Run program with complex/potentially breakable functions commented out
Did these work? If the first one did and the second one didn’t, have you tried copying the code to a new file and deploying that?
Hardware Tests:
-Unplug/replug ethernet cable
-Use new ethernet cable
-Run code using wireless connection
-Turn robot off then on
-Ensure battery is fully charged
-Check wiring system for breakages/disconnections
-Redo wiring system (just to be sure)
I’m not seeing “use a different computer to deploy” here. It’s not a likely solution, but weirder things have happened.
It is probably something silly. These things usually are.
On the DS setup tab do you have the right language selected? (not sure if this really matters) On the DS diagnostic tab, Do you have robot coms? Does it have the Crio version? right side of page. If it has these things then your com path to the crio is probably good. I would start looking for odd settings in your compiler tool chain.
Unfortunately neither of those worked when we tried them. We just tried deploying from an older computer (we just got new ones) and it yielded the same result. We also tried deploying the code from WindRiver as well as from FileZilla. Nothing has worked so far. Thank you for the advice.
Check the placement of the modules on the cRIO and re-re-check that all wires going into and coming out of it are totally secured. Check the lights, too. Also, if you have another, try deploying it onto a different cRIO because at this point it seems like it’s a robot-side problem.
Oh, thank you for clarifying. I enabled the net console, and here is the report on startup (For some reason I am unable to simply copy and paste the report, so I just took a screenshot)
UPDATE-1: We discovered that WPILib was the problem, and that it was not installed correctly. On a different laptop that WPILib was not installed on yet we correctly installed it. Now the NetConsole is giving us the same errors plus more. From the look of it, it is possible that we are either including our WPILib incorrectly in code or that we are defining our variables wrong. Here is the NetConsole report:
UPDATE-2: We fixed the “Relocation does not fit in 24-bit” problem through a different thread by adding in -mlongcall into our build options. Now the only remaining issue is the WPILib. Here is the new NetConsole report:
As it stands now, the cRIO is able to load any program that does not use WPILib in code. Empty workspaces are fine. However, we are still unable to figure out why objects made from the WPILib (i.e. Talon) are registered as “undefined symbols” in the net console. The code compiles/builds without any errors, it is the cRIO that will not load the FRC_UserProgram.out file if it include WPILib.
Unfortunately, I can’t… I have been using custom linux based build environments and unsupported GCC cross compilers that I built myself for years. Hopefully someone else will be able to take my diagnostic and help you figure out what to do with it with WindRiver…
Conceptually, you want to add WPILib.a to the link command. Not sure the magic key strokes to do that.
My guess is that the following diff to your .wrproject did it.
Hey Austin, thank you so much for your help. I’m one of the other head programmers for the team and I got it to work by getting onto the IDE and adding WPILib.a file to the library from the project settings. I’ll post exact instructions for other when I get back into robotics in a few days.
Also nowadays is there an easy way to compile directly with Linux(specifically Debian or Arch Linux)? Or would I have to go ahead and write up a custom environment too?