Log in

View Full Version : Problem uploading code to cRio


bf2416
01-02-2012, 21:42
Its me again, this time needing help with the cRio. I can connect the cRio to the computer and deploy code to the cRio, but when i log into the driver station user, the led for robot code is red.:confused: The cRio is correctly imaged for labview and the deployment dialog box automatically closes when the deployment is complete, just like it should. I need a little help.

Cecil
01-02-2012, 21:48
did you input your team number into the box on the setup tab? It needs to have the IP of 10.40.58.5 for it to work for you.

Also, make sure you are clicking the run button from Robot Main.vi, or nothing will work at all.

bf2416
01-02-2012, 21:54
The ip address was actually the first thing i checked, and i also deployed the code from the robot main.vi. I wasn't sure if this was a rookie programmer's mistake or not lol. I don't know much about programming, but i am learning as i go, but these little things frustrate me a little but oh well, happens.

Cecil
01-02-2012, 21:57
Hmm.. those are the only things I can think of to troubleshoot it. Have you tried building and running the code as startup? I know it does take longer, but if it works, then that would confuse me even more.

bf2416
01-02-2012, 22:02
What do you mean by "building and running the code as startup"? As I said, i am a rookie programmer still learning and getting used to all of the programming jargon. Lol:D

Cecil
01-02-2012, 22:26
In the project explorer, down at the bottom, there is a yellow icon next to what I believe to remember to be FRC Startup Program (or something of the like, its the one all the way down on the list). Click the plus symbol to the left of that, and a new thing will drop down. Right click on this new icon and click on "Build". Once that has happened, right click that icon again, and select "Run as Startup". This will load your code onto the robot and it will remain there until you overwrite it using the same method. Using the run button will only keep the code in the controllers memory until it is rebooted, where it will be deleted. This will make it permanent.

bf2416
02-02-2012, 07:12
Oh okay, I will try that when i get there today. Thanks for the help. I thought that when the code was run, it would stay on the cRio, but i guess i was wrong :rolleyes:

Cecil
02-02-2012, 14:17
It took us over 2 weeks when it was first released to finally find that one line in that obscure manual on some other site to realize that's what you have to do to keep it on there.. So don't feel bad about it.

bf2416
02-02-2012, 16:10
Thanks, Cecil, that worked. So everytime i need to deploy code i need to build and then run as startup? That makes sense. Thanks once again :D

Cecil
02-02-2012, 21:16
You can attempt to run the program from Robot Main.vi, as you were trying to do. Doing this, you can open up your code and do what is called a "probe" to see what values are being input or output from any wire. As I said though, this code will not remain on the controller after a reboot. The only way to permanently keep the code on the controller is using the Build and Run as Startup method. Good luck this year!

bf2416
03-02-2012, 08:04
Thanks for all the help.