Go to Post FIRST is here to inspire you, to challenge you. Part of that process is giving you a task too hard, resources too little, people too many, time too short. - ebarker [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 11-02-2006, 21:09
Idaman323 Idaman323 is offline
In Theory, Our Robot Would Own.
FRC #1706
Team Role: Driver
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Wentzville, MO
Posts: 116
Idaman323 is an unknown quantity at this point
Default Code

Hey guys, I got Kevin's CMUCam code finnaly on the robot.. the weird thing is.. nothing moves. I have the pwm03 and 04 as p1_y and p2_y. and I left the pwm 01 for the pan and pwm 02 as the tilt under tracking.h. In the user_routines, I have it set on p3_y, p4_y. Am I suppose to do something with those? Or just leave them as that?... Also when the program is loaded.. on the window, it is saying "Searching..." or "P1 Y 127, X 127" Or any of those coordinates on it. The regular default code runs this fine, but when I load the camera code with all of those changes... nothing happens. Am I suppose to do anything special to make them run. Hmmm, Im confused.


Thanks,
Idaman323
__________________
TEAM 1706
2007 Judges Award, St. Louis (For our amazing ability to have bad luck)
2005 Rookie Inspiration Award, St. Louis
  #2   Spotlight this post!  
Unread 11-02-2006, 21:23
6600gt's Avatar
6600gt 6600gt is offline
Registered User
AKA: Lohit
FRC #0226 (Hammerhead)
Team Role: Alumni
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Troy, MI
Posts: 221
6600gt is a jewel in the rough6600gt is a jewel in the rough6600gt is a jewel in the rough
Re: Default Code

Quote:
Originally Posted by Idaman323
Hey guys, I got Kevin's CMUCam code finnaly on the robot.. the weird thing is.. nothing moves. I have the pwm03 and 04 as p1_y and p2_y. and I left the pwm 01 for the pan and pwm 02 as the tilt under tracking.h. In the user_routines, I have it set on p3_y, p4_y. Am I suppose to do something with those? Or just leave them as that?... Also when the program is loaded.. on the window, it is saying "Searching..." or "P1 Y 127, X 127" Or any of those coordinates on it. The regular default code runs this fine, but when I load the camera code with all of those changes... nothing happens. Am I suppose to do anything special to make them run. Hmmm, Im confused.


Thanks,
Idaman323
The default code is commented out. Just uncomment it and place it before putdata(&txdata). ALSO comment out the pwm01 = p1_y and pwm02 = p2_y.

make sure anything you put is before putdata(&txdata) in the void Process_Data_From_Master_uP(void)

you can modify the printf statements to display what you want. comment it out if you want to modify the camera variables in the "bells and wistles" version on the terminal window.

Last edited by 6600gt : 11-02-2006 at 21:25.
  #3   Spotlight this post!  
Unread 11-02-2006, 21:48
Idaman323 Idaman323 is offline
In Theory, Our Robot Would Own.
FRC #1706
Team Role: Driver
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Wentzville, MO
Posts: 116
Idaman323 is an unknown quantity at this point
Re: Default Code

Hmmm Im not sure I undetstand what you are talking about. You said place the uncommented code before putdata code and make sure it is in Process_Data_From_Master_uP... the problem is... it cant be in Process_Data_From_Master_uP because that is after putdata. Are you talking abotu Getdata? Because Get data is in the process data funtion. And what code are you talking about when you say it is commented out and in needs to be uncommented and stuck in the function. i dont know what code that is.

Thanks for the reply
__________________
TEAM 1706
2007 Judges Award, St. Louis (For our amazing ability to have bad luck)
2005 Rookie Inspiration Award, St. Louis
  #4   Spotlight this post!  
Unread 11-02-2006, 22:51
bombadier337's Avatar
bombadier337 bombadier337 is offline
1337 U53R
AKA: Shaver
None #1541 (MidloCANics)
Team Role: College Student
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Richmond VA
Posts: 123
bombadier337 is just really nicebombadier337 is just really nicebombadier337 is just really nicebombadier337 is just really nice
Send a message via AIM to bombadier337
Re: Default Code

I'm not looking at the code, so I'm doing this from memory but...

There is a routine in user_routines.c called default_routine, which is where all the mapping is done from the controls. This routine is all written, however, it is never called in process_data_from_master_up. Basically call default_routine() before the putdata(&txdata) call and it should do it. The better way to do it is find the comments saying something like "IFI default code" (it's a pretty big block of code), which is all commented out. It has the call to default_routine(), and a bunch of other stuff. If you uncomment all the and put the putdata(&txdata) call after that, you should be fine. Hope that helps!

If you have any questions my IM is on my profile, I'm on a lot and I'd be glad to help you as much as I can.
__________________
Midlothian High School - Team 1541
2005 Radioshack Innovation in Control - NASA/VCU Regional
2005 Rookie Inspiration - NASA/VCU Regional
  #5   Spotlight this post!  
Unread 12-02-2006, 01:12
Idaman323 Idaman323 is offline
In Theory, Our Robot Would Own.
FRC #1706
Team Role: Driver
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Wentzville, MO
Posts: 116
Idaman323 is an unknown quantity at this point
Re: Default Code

Okay cool, we got it driving with the camera code thanks to you guys. So the camera is hooked up. How do we get power to this beast now.. beast = camera. In the workbook it says power with the tree pin connecter, and it says use pwm outputs to power it. When we plugged in the camera to the output, the camera didn't come on. Is there code to put to power it, or does the wiring need to be different.
__________________
TEAM 1706
2007 Judges Award, St. Louis (For our amazing ability to have bad luck)
2005 Rookie Inspiration Award, St. Louis
  #6   Spotlight this post!  
Unread 12-02-2006, 17:14
Idaman323 Idaman323 is offline
In Theory, Our Robot Would Own.
FRC #1706
Team Role: Driver
 
Join Date: Feb 2005
Rookie Year: 2005
Location: Wentzville, MO
Posts: 116
Idaman323 is an unknown quantity at this point
Re: Default Code

So Right now I am powering the camera with the backup battery. I know thats not what it needs during the competition. So any help would be appreciated. Im still trying to get the camera to seach also. Do I just plug in the camera in right ports and it should track? Or do I need to call that funtion to start the tracking? Ill be working on that for a while so yah.
__________________
TEAM 1706
2007 Judges Award, St. Louis (For our amazing ability to have bad luck)
2005 Rookie Inspiration Award, St. Louis
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
Modified default code gives "code violation" scottmso Programming 8 10-02-2006 23:17
default camera code edit Windward Programming 8 25-01-2006 18:33
Team THRUST - Kevin's Code and Camera Code Combine Chris_Elston Programming 3 31-01-2005 22:28
heres the code. y this not working omega Programming 16 31-03-2004 15:18


All times are GMT -5. The time now is 13:18.

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