Go to Post a robot that is broken shows that it has survived more than a robot that doesn't even have a scratch. - robot180 [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 20-02-2005, 12:43
roknjohn roknjohn is offline
Registered User
#1051
Team Role: Engineer
 
Join Date: Jan 2003
Location: Marion
Posts: 31
roknjohn is an unknown quantity at this point
Code runs only once, fails on reset

Having a weird problem, after downloading our code into the FRC, it runs without problems (all green flickers). However, when the reset button is pressed, or the bot is powered off and on, the Program State flickers red, and the RC Mode is solid yellow. Nothing will work until I download the code again.

The condition is not present when using the default code. Any ideas where to look in my code for the problem? Its puzzling that it runs perfect until the controller is reset.

Thanks.
  #2   Spotlight this post!  
Unread 20-02-2005, 12:48
SpeakerSilenced SpeakerSilenced is offline
Programming/Electrical Team Member
#0219 (Team Impact)
Team Role: Programmer
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Hackettstown, NJ
Posts: 28
SpeakerSilenced is an unknown quantity at this point
Send a message via AIM to SpeakerSilenced
Re: Code runs only once, fails on reset

Look at main.c, then follow each function in either user_routines.c or user_routines_fast.c also have you made the project and successfully built it before you uploaded it?
__________________
"I want to put a ding in the universe" - Steve Jobs
  #3   Spotlight this post!  
Unread 20-02-2005, 14:05
Mark McLeod's Avatar
Mark McLeod Mark McLeod is online now
Just Itinerant
AKA: Hey dad...Father...MARK
FRC #0358 (Robotic Eagles)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Hauppauge, Long Island, NY
Posts: 8,723
Mark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond reputeMark McLeod has a reputation beyond repute
Re: Code runs only once, fails on reset

You can try hooking up your PC to the dashboard port on the OI and running the IFI dashboard program. That will provide diagnostics in certain cases.
__________________
"Rationality is our distinguishing characteristic - it's what sets us apart from the beasts." - Aristotle
  #4   Spotlight this post!  
Unread 20-02-2005, 14:08
whakojacko's Avatar
whakojacko whakojacko is offline
Registered User
FRC #1072 (hrt)
Team Role: College Student
 
Join Date: Feb 2003
Rookie Year: 2003
Location: San Jose, California
Posts: 137
whakojacko is on a distinguished road
Send a message via AIM to whakojacko Send a message via MSN to whakojacko
Re: Code runs only once, fails on reset

what did you change?
__________________
Harker Robotics:1072
http://www.harker-robotics.org
  #5   Spotlight this post!  
Unread 20-02-2005, 19:03
bbene's Avatar
bbene bbene is offline
Team 754 Webmaster
AKA: Ben
FRC #0754 (Frostbyte)
Team Role: Webmaster
 
Join Date: Feb 2005
Rookie Year: 2003
Location: Marinette, WI
Posts: 8
bbene is an unknown quantity at this point
Send a message via AIM to bbene Send a message via MSN to bbene Send a message via Yahoo to bbene
Re: Code runs only once, fails on reset

We had this problem up until the end of working today. It happened after I updated our master code to version 10. Not even the Frc_default.hex with it would work. Then I tried the 2.4 default code version and there was no longer a code error. So now we just have to recode in all of our changes that we have made in the past 5 weeks.
__________________
Ben - Team 754 Webmaster/Former Student/College Mentor
Team Site
Personal Site
  #6   Spotlight this post!  
Unread 20-02-2005, 22:45
Ryan Cumings's Avatar
Ryan Cumings Ryan Cumings is offline
Programmer and University Rejected
#0134 (Team Discovery)
Team Role: Programmer
 
Join Date: Jan 2004
Rookie Year: 2000
Location: Pembroke, NH
Posts: 65
Ryan Cumings is an unknown quantity at this point
Send a message via AIM to Ryan Cumings
Re: Code runs only once, fails on reset

The problem might lie in the printf statements... We had this problem last week or the week before (build season is just a big blur). You should only be using \r for your new lines.
__________________
Suddenly being rejected from college feels right during the build season. Now I am a mentor.
  #7   Spotlight this post!  
Unread 21-02-2005, 14:06
Fat Alex's Avatar
Fat Alex Fat Alex is offline
Mr. super uber ultra Alex
AKA: Alex
#0060 (Bionic Bulldogs)
 
Join Date: Dec 2002
Rookie Year: 2002
Location: kingman
Posts: 29
Fat Alex is on a distinguished road
Send a message via MSN to Fat Alex
Re: Code runs only once, fails on reset

So whats the difference between "\r" and "\n" ?
__________________
Shake the hand that shook the world
  #8   Spotlight this post!  
Unread 21-02-2005, 20:24
AIBob's Avatar
AIBob AIBob is offline
AI Programmer
AKA: Bob Frank DOT org
FRC #0358 (Hauppauge Robotic Eagles)
Team Role: Alumni
 
Join Date: Jan 2005
Rookie Year: 2003
Location: Long Island, NY (in Binghamton now)
Posts: 297
AIBob is a splendid one to beholdAIBob is a splendid one to beholdAIBob is a splendid one to beholdAIBob is a splendid one to beholdAIBob is a splendid one to beholdAIBob is a splendid one to beholdAIBob is a splendid one to behold
Send a message via ICQ to AIBob Send a message via AIM to AIBob Send a message via MSN to AIBob Send a message via Yahoo to AIBob
Re: Code runs only once, fails on reset

Quote:
Originally Posted by Fat Alex
So whats the difference between "\r" and "\n" ?
the difference is three!
well that is if you subtract them in the code.
Each character has a different value.
"\n" is equivilent to character 10. so if you were to do char a=10, it would be the same as char a='\n'
"\r" is equivilent to character 13. so if you were to do char a=13, it would be the same as char a='\r'
So the difference is 13 - 10, and you would get three.
\r (carriage return) means to go the beginning of the line, and \n (line feed) means to go to the next line.
__________________
- from B B frank

Closed Thread


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
Out of the Box Camera Code russell Programming 9 21-10-2009 05:28
Code suddenly fails to initialize miketwalker Programming 11 19-02-2005 15:23
Team THRUST - Kevin's Code and Camera Code Combine Chris_Elston Programming 3 31-01-2005 22:28
Sourceforge for Code Repository and other stuff SilverStar Programming 9 15-01-2005 21:16
heres the code. y this not working omega Programming 16 31-03-2004 15:18


All times are GMT -5. The time now is 10:58.

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