Go to Post Rules from prior years DO NOT APPLY to this year! - dlavery [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 16-02-2006, 19:24
sjung9442 sjung9442 is offline
Student Mentor
FRC #0122 (NASA Knights)
Team Role: Programmer
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Hampton, VA
Posts: 17
sjung9442 is an unknown quantity at this point
ADC problem

All of our analog inputs appear to be outputting the same value, that of channel 1. We are using the ADC code from Kevin's site, integrated into his camera code. We don't know what is wrong with this code...
Can anyone help us? or had same problem?
  #2   Spotlight this post!  
Unread 16-02-2006, 20:06
steven114 steven114 is offline
Programming Wizard and Team Captain
AKA: Steven Schlansker
FRC #0114 (Eaglestrike)
Team Role: Programmer
 
Join Date: Feb 2004
Location: Los Altos, CA
Posts: 335
steven114 is a jewel in the roughsteven114 is a jewel in the roughsteven114 is a jewel in the rough
Send a message via AIM to steven114
Re: ADC problem

Posting the code that you're using is probably the best way to get help...
__________________
Shift to the left, shift to the right!
Pop up, push down, byte, byte, byte!
  #3   Spotlight this post!  
Unread 16-02-2006, 21:53
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: ADC problem

If you're using Kevin's ADC code, you cannot use the usual Get_Analog_Value() function. I don't have the files handy to check, but the proper function to use is documented in his code.

(You also need to make sure you've defined the proper number of analog channels; that too is documented.)
  #4   Spotlight this post!  
Unread 17-02-2006, 11:00
sjung9442 sjung9442 is offline
Student Mentor
FRC #0122 (NASA Knights)
Team Role: Programmer
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Hampton, VA
Posts: 17
sjung9442 is an unknown quantity at this point
Re: ADC problem

I can't put any code here because we don't even know what the problem is...
it's so sad that we don't even know the problem...
we used Get_ADC_Result(channel number) function from kevin's code to get the value. And we set it to the analog inputs we needed... but when we turn on the robot and try to get data, we are getting 1888 for all of them...
And when we change one thing, everything changes too.
  #5   Spotlight this post!  
Unread 17-02-2006, 11:12
Kevin Watson's Avatar
Kevin Watson Kevin Watson is offline
La Caņada High School
FRC #2429
Team Role: Mentor
 
Join Date: Jan 2002
Rookie Year: 2001
Location: La Caņada, California
Posts: 1,335
Kevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond reputeKevin Watson has a reputation beyond repute
Re: ADC problem

Quote:
Originally Posted by sjung9442
I can't put any code here because we don't even know what the problem is...
it's so sad that we don't even know the problem...
we used Get_ADC_Result(channel number) function from kevin's code to get the value. And we set it to the analog inputs we needed... but when we turn on the robot and try to get data, we are getting 1888 for all of them...
And when we change one thing, everything changes too.
Can you zip up your project and send it to me to look at. Also, what kind of sensors are you using on the analog inputs?

-Kevin
__________________
Kevin Watson
Engineer at stealth-mode startup
http://kevin.org
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
ADC code effecting motor outs??? Kyveck Programming 16 28-03-2006 15:12
adc code problem railerobotics Programming 6 24-01-2006 22:26
Need a realistic Statics Problem sanddrag Technical Discussion 10 05-12-2005 15:07
Programming Gyros goegan31 Programming 33 19-05-2003 20:05
The problem with scouting... archiver 2001 10 23-06-2002 23:49


All times are GMT -5. The time now is 11: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