Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   C/C++ (http://www.chiefdelphi.com/forums/forumdisplay.php?f=183)
-   -   No Code Error (http://www.chiefdelphi.com/forums/showthread.php?t=80240)

bradleat 15-01-2010 11:54

No Code Error
 
I am using Windriver C++ and have installed all of the updates. My development PC has been set to the ip 10.14.14.6 (or whatever it was supposed to be, I am working from home right now). I have installed the Driver software on the development PC.

I compile the example code in Windriver and use the FIRST downloader to upload the code to the CRIO. It doesn't tell me if it worked, but I assume it doesn't because when I restart the cRIO I get the no Code error from the Driver software.

Any Help?

heydowns 15-01-2010 12:36

Re: No Code Error
 
This can happen for two reasons - you don't have code (sounds like you do) or the code is failing to execute.

First, check that the FIRST Downloader in Windriver is downloading the program you expect and that your team # is set properly. Both of these are set in Windows->Preferences->FIRST Downloader Preferences.

Failure to execute is often caused by a mismatch in version between what your code is compiled against (WPILib in Windriver) and the cRIO's FPGA image on the robot.

Have you downloaded and applied all updates to Windriver?
Have you imaged your cRIO with the latest C++ image version (version 19)?

Update everything, recompile, and re-download your code. Restart your robot. If you continue to have problems, it is helpful to either:
A. Undeploy the program, reboot the robot, and load your code using the Debug facility in Windriver -- this will give you the ability to get any errors back as the program is loaded, and also to know your code is getting there.

-or-

B. Attach a serial cable to your cRIO's serial port, turn on the "console out" DIP switch on the cRIO, reboot your robot and watch the console messages on a terminal program on your laptop. This can give further details.

bradleat 15-01-2010 16:46

Re: No Code Error
 
1 Attachment(s)
Well i get some error codes, I suppect they are related to hardware failure, but I have to rule out the software side first.

I attached a screen copy of the errors.

This error get thrown when I try to debug from Windriver following the instructions from the Getting Started with C.pdf document

bradleat 15-01-2010 19:35

Re: No Code Error
 
Does anybody know what this error is about?

Alan Anderson 16-01-2010 00:05

Re: No Code Error
 
You say you installed all the updates, but did you reimage the cRIO afterwards? I've never used C++ on an FRC robot (I'm a LabVIEW guy), but those errors make me think that you're trying to run 2010 code on a 2009 image. Make sure the cRIO is updated with v19.

bradleat 16-01-2010 02:06

Re: No Code Error
 
Quote:

Originally Posted by Alan Anderson (Post 900192)
You say you installed all the updates, but did you reimage the cRIO afterwards? I've never used C++ on an FRC robot (I'm a LabVIEW guy), but those errors make me think that you're trying to run 2010 code on a 2009 image. Make sure the cRIO is updated with v19.

Yes, v19 (the driver's station confirms). Windriver has also been updated (it doesn't communicate if it's not updated)

Mike Copioli 16-01-2010 12:55

Re: No Code Error
 
1 Attachment(s)
We had a similar problem, where we could load code to the robot. The driver station indicated communication, but no robot code.

We tried reimaging to v19 a second time, as well as updating the workbench a second time with no positive results. One of our programmers found that the update.cmd file, found in WorkbenchUpdate20100107.exe, only installs the update to the default filepath. You can change the install paths for the update to your actual install directory. You can change update.cmd to install to the correct directory, or you can copy the contents of the update to your Windriver directory and overwrite the old files. The first method you need to run update.cmd after you make the change.

Below is the snapshot of the change we made in notepad++.

bradleat 16-01-2010 23:47

Re: No Code Error
 
Well mine is in the defualt install path, I am just going to try another computer setup and see if I can narrow the problem down (computer, cRIO, installation error, my presence) etc

zombiezen 19-01-2010 22:16

Re: No Code Error
 
I'm having exactly the same problem. I have re-installed everything at least three times and installed all updates, but the execution fails with the same error message as previously described.

Just out of curiosity, what operating system are you on? I'm on Windows 7, but I don't think that should affect anything.

bradleat 19-01-2010 22:19

Re: No Code Error
 
Well I have narrowed it down to an install error, not a Windows 7 inherent error. So check for problems caused by installation (maybe UAC or the like), i am using the classmate with a Windriver install for now.

However the only project I can build (and not all the time correctly, (random error that aren't part of the ISO C++ Standard) is the sample project, so i blame this level of malfunctioning on FIRST.

bradleat 19-01-2010 22:25

Re: No Code Error
 
Well I have narrowed it down to an install error, not a Windows 7 inherent error. So check for problems caused by installation (maybe UAC or the like), i am using the classmate with a Windriver install for now.

However the only project I can build (and not all the time correctly, (random error that aren't part of the ISO C++ Standard) is the sample project, so i blame this level of malfunctioning on FIRST.

TheDominis 19-01-2010 23:16

Re: No Code Error
 
Quote:

Originally Posted by bradleat (Post 902736)
Well I have narrowed it down to an install error, not a Windows 7 inherent error. So check for problems caused by installation (maybe UAC or the like), i am using the classmate with a Windriver install for now.

However the only project I can build (and not all the time correctly, (random error that aren't part of the ISO C++ Standard) is the sample project, so i blame this level of malfunctioning on FIRST.

I too blame this magic "FIRST" creature.

What do you mean that it doesn't build correctly? The same code built multiple times gives errors? I don't think that the code would be compiled again if unchanged.

heydowns 20-01-2010 10:14

Re: No Code Error
 
Quote:

Originally Posted by bradleat (Post 899932)
Well i get some error codes, I suppect they are related to hardware failure, but I have to rule out the software side first.

I attached a screen copy of the errors.

This error get thrown when I try to debug from Windriver following the instructions from the Getting Started with C.pdf document

Unresolved symbols dealing with the FPGA at runtime is usually caused by a mismatch between the running cRIO image version (which contains the FPGA image and the runtime binary library that completes the binary built in WindRiver) and the version of WPILibary on your development computer that your binary is compiled against.
Less often it can be caused by other issues.
You said you narrowed it to "an install error". Could you be more specific about what you found to help others that may be encountering the same issue?

CardcaptorRLH85 20-01-2010 18:17

Re: No Code Error
 
I have a question, does anyone have actual compiling code for this year using the ItreativeRobot class yet? While the rest of the team is building the physical robot I'm trying to figure out this years WPILib by porting the code from our 2009 bot to 2010. I've completely pulled the camera sections and updated my Dashboard/DriverStation methods to the versions used in the 2010 Vision Example. However, I still get a persistent No Code Error on the Robot when trying to use this code. I'm thinking that I may have some small thing that has been left behind not being caught by the compiler. Since I can't find a 2010 IterativeRobot example included in the WindRiver examples I'm in need of some (working) IterativeRobot based code. Thanks a bunch ^_^

byteit101 20-01-2010 19:23

Re: No Code Error
 
There is a semi random error in the WR updater, it extracts the files to a temporary folder, but doesn't move them to the actual folder. this might be whats happening.
I think the update folder is in C:\ so look around (or search CD)

bcieslak 20-01-2010 23:37

Re: No Code Error
 
You can add us to the no code error issue too.
we are running the wind river tools
We tried deploying the default code and it seemed to download ok but the driver station said no robot code..
Crio has the v19 image...we updated the workbench to the latest update 20100107 . we cant check error messages via the serial port because the crio is not talking back to the laptop for some reason.

Here's the catch..we also tried using a laptop with last years tools on it and we were able down load and run the default program

Any Clues??? I sure didn't plan spending the first three weeks of build season getting the tools to work...:mad:

Brian
Team 1714
Sr Firmware Engineer
Rockwell Automation

jhersh 21-01-2010 01:31

Re: No Code Error
 
Quote:

Originally Posted by bradleat (Post 899932)
Well i get some error codes, I suppect they are related to hardware failure, but I have to rule out the software side first.

I attached a screen copy of the errors.

This error get thrown when I try to debug from Windriver following the instructions from the Getting Started with C.pdf document

Based on your screen shot, the WPILib you are linking against is expecting FPGA version 2010 revision 1.1.0 (which has GUID E0037A37F5C5D7F6A40E3C03D3CE51DD, which you can see in the missing symbols). This version was shipped on the DVD distribution for 2010. The cRIO image v19 includes FPGA version 2010 revision 1.3.0 (which has GUID AD9A5591CC64E4DF756D77D1B57A549E).

jhersh 21-01-2010 01:35

Re: No Code Error
 
Quote:

Originally Posted by bcieslak (Post 903613)
we cant check error messages via the serial port because the crio is not talking back to the laptop for some reason.

Have you tried the new NetConsole interface? It allows you to see the console without a serial port (which is especially handy if you are using the serial port to run your Black Jaguars!)

Quote:

Originally Posted by bcieslak (Post 903613)
Here's the catch..we also tried using a laptop with last years tools on it and we were able down load and run the default program

If last year's code runs on the robot, then you haven't updated the image to v19 successfully.

SteveD 21-01-2010 09:14

Re: No Code Error
 
We are having the same error. We are using labview. It connects to the robot and it successfully deploys code, but on the driver station says no code

Greg McKaskle 21-01-2010 09:53

Re: No Code Error
 
Quote:

Originally Posted by SteveD (Post 903790)
We are having the same error. We are using labview. It connects to the robot and it successfully deploys code, but on the driver station says no code

Are you logging out of developer and quitting LV in order to run the DS? Quitting LV aborts any cRIO code it is debugging.

Another thing that can cause this is having the wrong cRIO image, v19 is the latest, and the diagnostics tab on the DS will show the version.

Greg McKaskle

Bryscus 21-01-2010 09:59

Re: No Code Error
 
We had a similar issue last year getting a No Code error. This happened because we did not pack the data correctly to send to the dashboard. I think there was a specific sequence used and the dashboard won't accept the data packets if it's not correct...

If this issue persists, one might want to try taking out the data packing code altogether and try to get it to run.

bcieslak 21-01-2010 11:06

Re: No Code Error
 
Quote:

Originally Posted by jhersh (Post 903689)
Have you tried the new NetConsole interface? It allows you to see the console without a serial port (which is especially handy if you are using the serial port to run your Black Jaguars!)



If last year's code runs on the robot, then you haven't updated the image to v19 successfully.

Hi Joe, I was starting to suspect that...I had another mentor reimage the Crio and he asssured me it was complete but I am starting to have my doubts...Is there an easy way to check the version that is running in the Crio?

I am also not sure that he installed the labview update. Since we are running wind river he may have thought we didn't need it...What would be the effect of not updating that?


thanks again...
Brian

Alan Anderson 21-01-2010 11:15

Re: No Code Error
 
Quote:

Originally Posted by bcieslak (Post 903866)
I am also not sure that he installed the labview update. Since we are running wind river he may have thought we didn't need it...What would be the effect of not updating that?

If you didn't update LabVIEW, you didn't get the v19 image that comes with the updated imaging tool.

Mark McLeod 21-01-2010 11:34

Re: No Code Error
 
1 Attachment(s)
Quote:

Originally Posted by bcieslak (Post 903866)
Is there an easy way to check the version that is running in the Crio?

The cRIO image version is displayed on the Driver Station at the bottom of the Diagnostics tab.
So it's easy to double check.

jhersh 21-01-2010 23:15

Re: No Code Error
 
Quote:

Originally Posted by bcieslak (Post 903866)
Hi Joe, I was starting to suspect that...I had another mentor reimage the Crio and he asssured me it was complete but I am starting to have my doubts...Is there an easy way to check the version that is running in the Crio?

I am also not sure that he installed the labview update. Since we are running wind river he may have thought we didn't need it...What would be the effect of not updating that?

Like Mark said... Driver Station Diagnostics tab.

You can tell if the update worked by looking at the version of the image that the imaging tool is trying to send to the cRIO when you enable formatting the controller.

zombiezen 22-01-2010 01:47

Re: No Code Error
 
I ended up figuring out the issue on mine, hopefully this helps others:

My target install machine is running Windows 7. According to a Windows guy I know, Microsoft changed the security API for a few different things going from Vista to 7, especially concerning a feature called UAC. UAC does not allow programs to write directly to the C: drive, so certain programs will not function properly.

One of these programs that fails (silently) is the WindRiver installer.

The solution? Log into an adminstrator account, go to Control Panel -> User Accounts and Family Safety -> User Account. Choose "User Account Control" settings (the infamous UAC). Slide the bar to the bottom, and restart your computer. You have now disabled UAC; you can enable it later (probably after build season).

Now for the fun part. Remove WindRiver entirely (i.e. blow away the C:\WindRiver directory). Pop in the WindRiver install DVD and run the setup program. It should install significantly faster. After that, run the update program on the same disk, then install the latest WPI updates. Once you've done that, everything should work properly.

Hope that helps!

bcieslak 22-01-2010 09:55

Re: No Code Error
 
Yippeee!! everything is finally working....We re-imaged the Crio, made sure 'ALL' the updates were applied to the driver station and the development laptop, compiled then downloaded the BuiltinDefaultCode.out file. Then we added Joe's accelerometer code and fixed the I2C.cpp file. and all still worked.

We had some problems with the IterativeDemo but I we'll revisit that later. The BuiltinDefaultcode is what we will base our robot code on.

Thanks to all especially Joe Hersch for all the info and his patience..They don't pay you enough...Every one should send Joe a Starbucks gift card so he can buy enough coffee to keep him awake when he sending those responses at 3 AM..:ahh:

Brian C

KickNazer 24-01-2010 15:45

Re: No Code Error
 
Quote:

Originally Posted by bcieslak (Post 903613)
You can add us to the no code error issue too.
we are running the wind river tools
We tried deploying the default code and it seemed to download ok but the driver station said no robot code..
Crio has the v19 image...we updated the workbench to the latest update 20100107 . we cant check error messages via the serial port because the crio is not talking back to the laptop for some reason.

Here's the catch..we also tried using a laptop with last years tools on it and we were able down load and run the default program

Any Clues??? I sure didn't plan spending the first three weeks of build season getting the tools to work...:mad:

Brian
Team 1714
Sr Firmware Engineer
Rockwell Automation

We are having i believe, the same issue. We installed Wind River Workbench 3.0 and LabView on 3 separate computers and our atom we received this year in our kickoff kit. All of the computers are updated with the following...

WorkbenchUpdate20100107.exe
WPILibSource20100107.zip
NetConsoleClient_1.0.0.4.zip
FRCLabVIEWUpdate2.0for2010.zip
FRCLabVIEWUpdate1.0for2010.zip
DSUpdate1.0for2010.zip

The cRIO was successfully imaged with v19 on a wired connection. We used "VxWorks Downloadable Kernal Module Sample Project" named "Default Robot Main Program" as the code to test our connection with though our router we received in our kickoff kit last year as a rookie team. It built fine and we had set our team number correct in workbench options as well. When we downloaded the .out file onto our cRIO using a wired connection through the router it said it was successful and went fast. When we logged into our driver staion in the atom it said the cRIO image was v19 and everything was green expect it said "No Robot Code." Last year we had a similar issue when the downlao to the cRIO would say done successfully wasn't actually. The way we fixed it last year was by another team's programmer working on it and doing a couple, more updates.

Did we miss some updates? How can we fix it? Did we use the wrong build in workbench?

Also, what does the atom's static IP have to be to run the driver station. And what are all of the other IP's we need for other components like the cRIO (just to double check).

Ad finally, Do we have to use the blue router from last years kit to run the station or is it possible/allowed to set up ad-hoc or something o nthe atom to host the single to the robot?

Thanks! Love the forum!

slavik262 26-01-2010 11:26

Re: No Code Error
 
Quote:

Originally Posted by zombiezen (Post 904466)
UAC does not allow programs to write directly to the C: drive, so certain programs will not function properly.

I love Windows 7 and Vista (call me a Micro$oft fanboy; I don't care), but UAC was the one thing I couldn't stand on both Vista and 7. It's the first thing I shut off when I get a new computer with either OS on it. It fixes so many problems instantly...


All times are GMT -5. The time now is 12:26.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi