Downloading code DS says "No Code"

We successfully completed all the benchtop testing, updated the Driver’s Station firmware with windriver and reimaged the cRIO.

We are attempting to download just the basic code (no modifications), and are running into some issues. First, we download the code, and we noticed that no “completed” or “deployed” message is shown, so we were unsure if it was finished.

We can power it on, get it connected and it will work. But then when we try to download new code the DS displays “Battery: No Code,” and the joysticks do nothing.

When we download the code, we download it with WindRiver and then reset the robot. Then, on the DS, it should display “Battery: No Comms” for about ten seconds. Then, for another few seconds, it will display “Battery: No Code”. Then it displays “Battery: 0.0V” for us. When that message is up, the joysticks start working.

For us it just stays on “No code” and never displays a Battery voltage and the joysticks dont work.

You are resetting the robot after downloading the code, right?

And you’re downloading the .out file to the robot, not the .cpp file, right?

Yes we’re resetting the robot and downloading the correct file

We’ve had this problem a few times with our bot. It’s usefull to have a serial connection to a terminal on the programming computer. During boot-up, if it says it “unloads” your code, there is probably part of the code the cRio didnt like. Generally, for my team, it was because of an “inline” function.

Is there a document that tells how to use the serial interface, and what information the interface yields?

Directions are found in the Control System Manual Chapter 5 Configuration in section 5.4.1, **cRIO Console Serial Connection to Laptop **

Thanks. There is also a more detailed account at NI for those following this thread:

One important item that is easily overlooked is that you MUST:

Build your project first, Select the Window menu, Select preferences…,

FIRST Downloader Preferences.

  1. Team Number
  2. the file to download to the Robot: (This file will have the same name as your project with the extension .out) Browse for this file in the workspace/projectname/(usually Debug) … directory

Only after you select the correct .out file will your code download. This section does NOT change when you change projects, you must remember to change this setting every time you change to a different project name.

We had a very similar issue before. If the cRio does not like the code, it will display the “No Code” message. Have you updated your WPILIB files yet? There is an update for WindRiver on the FIRST website that will upgrade your library files to the new revision. My understanding is that it might change some of the example projects. If the examples have the wrong code format, it might not be compatible with the cRio updates.

Go here: and download the workbench updates.

I think that if you can download code your connection and transfer are solid. It just sounds like it’s a code problem.

Its not just that it doesn’t like the code, or using the wrong file in the download. Use the Rs-232 link to see exactly what the error is. This is most helpful.