Go to Post Finally I wish everyone here on ChiefDelphi good luck and more importantly a fun build season. - mechanicalbrain [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 18-01-2009, 16:17
2roy999 2roy999 is offline
Registered User
FRC #1937
 
Join Date: Dec 2008
Location: Modi'in
Posts: 3
2roy999 is an unknown quantity at this point
cRIO has no code

hello,

I tried to download my C++ code to the cRIO and I got error message. After that, I turn on the cRIO and on the driver station was written "battery: no code". What should I do to fix the problem?

thank you,
team 1937
Reply With Quote
  #2   Spotlight this post!  
Unread 18-01-2009, 16:20
360skier 360skier is offline
RTFM!!
AKA: Eric A.
FRC #1334 (Red Devils)
Team Role: Programmer
 
Join Date: Dec 2008
Rookie Year: 2008
Location: Oakville, Ontario
Posts: 45
360skier is an unknown quantity at this point
Re: cRIO has no code

Are you using the default code? If not, then you need to make sure you make a call to START_ROBOT_CLASS() or something of similar name. Otherwise the cRIO doesn't know which file to use as a robot class.
Reply With Quote
  #3   Spotlight this post!  
Unread 18-01-2009, 16:22
ShotgunNinja's Avatar
ShotgunNinja ShotgunNinja is offline
Programming Mentor, FRC 4247
AKA: Nicholas Iannone
FRC #4247 (CougarBOTS)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2006
Location: Milwaukee, WI
Posts: 160
ShotgunNinja is a jewel in the roughShotgunNinja is a jewel in the roughShotgunNinja is a jewel in the roughShotgunNinja is a jewel in the rough
Re: cRIO has no code

Hey, I don't really have an answer for you, but I just want to say that I've been using LabVIEW and I have the same problem. I think that you might have to go into your code and actually put in a call to update the Driver Station with the battery voltage. I haven't looked into it yet but I believe that there is a function (or subVI for LabVIEW) for retrieving the battery voltage, and one for sending that to the Driver Station.

Hope this helps!
__________________
Team #2970 Alum
Team #1652 Alum
2006: School Mascot for Team 1652
2007-2008: Programmer for Team 1652 (Robot Mafia)
2009: Programmer on Team 1652 (Robot Mafia), Programmer on Team 2970 (eSchool eBots)
2010-2016: Volunteer, Wisconsin Regional
2017: Programming Mentor, FRC 4247 (CougarBOTS, Obama SCTE, Milwaukee, WI)
Reply With Quote
  #4   Spotlight this post!  
Unread 18-01-2009, 16:24
360skier 360skier is offline
RTFM!!
AKA: Eric A.
FRC #1334 (Red Devils)
Team Role: Programmer
 
Join Date: Dec 2008
Rookie Year: 2008
Location: Oakville, Ontario
Posts: 45
360skier is an unknown quantity at this point
Re: cRIO has no code

Not too sure about the LabView API, but C++ should do that automatically provided you put the jumper on the analog breakout.
Reply With Quote
  #5   Spotlight this post!  
Unread 18-01-2009, 16:59
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,752
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: cRIO has no code

I believe both environments will do that if you start with a template.

Greg McKaskle
Reply With Quote
  #6   Spotlight this post!  
Unread 18-01-2009, 17:27
EHaskins EHaskins is offline
Needs to change his user title.
AKA: Eric Haskins
no team (CARD #6 (SCOE))
Team Role: College Student
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Elkhorn, WI USA
Posts: 998
EHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond repute
Send a message via MSN to EHaskins
Re: cRIO has no code

When you debug code of the robot it is not stored permanently, so when you reset it there is no user code. I'm guessing this is what happened.

Make sure that you've read and understand pages 20-26 of the C/C++ Programming Guide.

You may be having a different issue, but without more detail about the error message I can't know.

The battery voltage monitoring and reporting code is located in the WPILib code, so unless you're running a modified version then it should report a voltage. Even if you broke that part of the code it would report 0.0 volts not NO CODE.
__________________
Eric Haskins KC9JVH
Reply With Quote
  #7   Spotlight this post!  
Unread 18-01-2009, 23:17
heydowns's Avatar
heydowns heydowns is offline
Registered User
AKA: Jeff Downs
FRC #1511 (Rolling Thunder)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Ra-Cha-Cha
Posts: 142
heydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond reputeheydowns has a reputation beyond repute
Re: cRIO has no code

No code can mean you have unresolved symbols in your program. See:
http://www.chiefdelphi.com/forums/sh...ad.php?t=70693
for more details.

Best way to diagnose is to hook up serial console as detailed in the control system manual. Watch the console as the cRIO boots.

If you have configured program debugging, you can undeploy, reboot, then load your code through the debugging mechanism. This will tell you right away if you have unresolved symbols (and what they are). You can also look at a console this way (right click remote target, Target Tools, Console)
Reply With Quote
  #8   Spotlight this post!  
Unread 19-01-2009, 02:01
Blair Frank's Avatar
Blair Frank Blair Frank is offline
Writer and Alumnus
FRC #0852 (Athenian Robotics Collective)
Team Role: Alumni
 
Join Date: Jan 2007
Rookie Year: 2006
Location: Walla Walla, WA
Posts: 49
Blair Frank is a jewel in the roughBlair Frank is a jewel in the roughBlair Frank is a jewel in the roughBlair Frank is a jewel in the rough
Re: cRIO has no code

We've found that the DS needs to be set to "disabled" in order for the code update to take, and that usually works.

Best of Luck!
-Blair
__________________
Proud alumnus of Team 852, the Athenian Robotics Collective.

Pneumatics in a nutshell: Put together an elaborate series of pipes, canisters, cylinders, valves and hoses; then fill that system with highly pressurized air, and hope that it doesn't blow up in your face.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
"Battery: No Code" after uploading .out file to cRIO knine143 FRC Control System 1 20-12-2008 22:14
cRIO - motor controller code (esp. victor) ericand Programming 8 06-12-2008 22:09
Team 166 Has Open Sourced Its Code platypus Programming 13 09-02-2008 16:03
Does anyone has code for accelerometer? sjung9442 Programming 2 30-01-2006 21:37
Has anyone craked the code yet Jeremy General Forum 2 09-01-2004 14:12


All times are GMT -5. The time now is 15:06.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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