Go to Post trust me, confused machines aren't fun to be around. - [527]phil [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 04-01-2008, 19:31
wt200999's Avatar
wt200999 wt200999 is offline
Texas Instruments
AKA: Will Toth
FRC #3005 (Robochargers)
Team Role: Mentor
 
Join Date: Mar 2006
Rookie Year: 2004
Location: Dallas, Texas
Posts: 323
wt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud of
Send a message via MSN to wt200999
Robot Controller reset issue when pwm value changes

I am having a troublesome issue. Whenever I have something in my code change the value of the pwm the controller seems to keep resetting non-stop. When it is in regular user mode it resets every couple of seconds. There is nothing touching the three prog/reset pins. It only does this when I change the value of the pwm or am in regular user mode. This does happen in auton as well when I change the pwm.
I have been trying to get interrupts to work with my gear tooth sensor and my friend has been working with the camera. I don't know exactly how long this has been doing this for. I have tried loading the default code to the bot again with no luck as well. Any help would be greatly appreciated, thank you.
  #2   Spotlight this post!  
Unread 04-01-2008, 19:55
tseres's Avatar
tseres tseres is offline
obsessed with FIRST...
FRC #1565 (Think Tank Tech)
Team Role: Leadership
 
Join Date: Apr 2007
Rookie Year: 2007
Location: Cambridge, ON
Posts: 305
tseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of light
Re: Robot Controller reset issue when pwm value changes

have you tried a master reset with the master code from ifi? this is different from the default code.
__________________


  #3   Spotlight this post!  
Unread 04-01-2008, 20:55
JBotAlan's Avatar
JBotAlan JBotAlan is offline
Forever chasing the 'bot around
AKA: Jacob Rau
FRC #5263
Team Role: Mentor
 
Join Date: Sep 2004
Rookie Year: 2004
Location: Riverview, MI
Posts: 723
JBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond reputeJBotAlan has a reputation beyond repute
Send a message via AIM to JBotAlan Send a message via Yahoo to JBotAlan
Re: Robot Controller reset issue when pwm value changes

You say it is resetting every couple of seconds; if this is the case, are your attempts to reprogram it successful? It makes it through the entire download without resetting? What do the LEDs look like on the RC? Are they all blinking green when connected to an OI and enabled?

It sounds like you have a really dead battery. If you haven't checked it already, replace it with a fresh one. Changing PWM values means changing motor speeds, which often causes a hefty draw on the battery. If you have no backup battery and a really low main battery, this will reset the controller.

If you already tried that, disconnect *everything* except the two power wires. See if that fixes it. Then start plugging items in, one by one, until you find the culprit.

If, with everything unplugged except power, it is still resetting, contact IFI and see if they can give you any hints.

JBot
__________________
Aren't signatures a bit outdated?
  #4   Spotlight this post!  
Unread 04-01-2008, 21:33
ay2b's Avatar
ay2b ay2b is offline
Registered User
AKA: Andy
FRC #2928
Team Role: Mentor
 
Join Date: Mar 2004
Rookie Year: 1994
Location: Seattle, WA
Posts: 211
ay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant futureay2b has a brilliant future
Re: Robot Controller reset issue when pwm value changes

In your interrupt handler, are you clearing the interrupt flag? Are you clearing it in all cases (i.e. for every interrupt type)? Resetting seems a little odd to me, but I've seen cases where forgetting to clear the interrupt flag will cause it to run for a few seconds, and then freeze/crash/red-light-of-death. You said this correlates to changing a PWM value; you also said you have a gear-tooth sensor installed. If the motor is not running, you would be getting no interrupts. As soon as you change the PWM value, the motor starts running. This causes the gear-tooth sensor to start triggering interrupts. If you don't clear the interrupt flag in your interrupt handler, this will basically cause the system to overload, trying to repeatedly process the interrupt. In my experience, this resulted in a crash; in your case, maybe it's resulting in a reset.

Or maybe you have some other problem.
__________________

2011 - SD Quarterfinalists (980), LA Quarterfinalists (980)
2010 - LA (2404) Finalists (980), AZ Motorola Quality (980)
2009 - LA Semifinalists (980); Las Vegas Quarterfinalists (980); SD (2404); IRI #1 Seed, Finalist (980)
2008 - SD Quarterfinalists (980), LA Champions (980), LA Rookie Inspiration Award (2404); CalGames Finalists
2007 - So.Cal Finalists (980), SD Quarterfinalists (980); CalGames Finalists
2006 - So.Cal Regional Champion (4), Toronto Judge's Award Day 1 (4)
2005 - SVR Champions, Delphi "Driving Tomorrow's Technology" (980); AZ Xerox Creativity (980); So.Cal Finalists, RadioShack Innovation in Control (980); Championship Archimedes Division Semifinalists; IRI Finalists (980)
2004 - So.Cal Regional Champions, Leadership in Controls (980); AZ GM Industrial Design (980); Championship Galileo Division #2 Seed; IRI Champions
2003 - PNW Semi-finalists (488)
2002 - PNW Finalists (488)
2000 - X-bot / 488 - Mentor / Founder
1994 - Sunny Delight - Driver - champion
  #5   Spotlight this post!  
Unread 04-01-2008, 22:15
wt200999's Avatar
wt200999 wt200999 is offline
Texas Instruments
AKA: Will Toth
FRC #3005 (Robochargers)
Team Role: Mentor
 
Join Date: Mar 2006
Rookie Year: 2004
Location: Dallas, Texas
Posts: 323
wt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud ofwt200999 has much to be proud of
Send a message via MSN to wt200999
Re: Robot Controller reset issue when pwm value changes

I am clearing the flag, regularly it has all happy green lights. I took out the part in my auton what changed the pwm's and kept the geartooth in, and I manually moved the wheel to see if I was getting anything. I still wasnt getting anything on the geartooth but it was not resetting.
The program gets on the thing fine, maybe I have to put the master code on it again, I shall try that Monday when I get back to school as well as the new battery, although I tested that and it said I had 12v coming out of it.
The reason I say it is resetting is when I do change the pwm the lights just flash a lot, and my terminal has that standard startup message <IFI Initialized...>. The flashes on the controller go between what it looks like when you press reset and when they are all green. I do get a couple of printf's before it resets, but only sometimes and only a couple.
I will give these suggestions a try on Monday when I get back to school. Thank you
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
Camera won't initialize when reset from RC - reset from OI and Power-up works, krunal Programming 7 15-01-2007 00:13
Last min suggestions on Robot controller issue? Rombus Technical Discussion 7 11-03-2006 19:57
Dividing PWM value - easy question jgannon Programming 1 04-02-2004 22:57
Robot Controller Reset Problems. Joe P Electrical 8 26-04-2003 11:56
Visibility of Robot Controller and Reset Button Tracy Rules/Strategy 1 17-02-2003 07:36


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

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