Go to Post Some High School students understand safety and can follow complex instructions. - DonRotolo [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 02-02-2006, 12:24
naor52 naor52 is offline
Registered User
FRC #1578
 
Join Date: Dec 2005
Location: ISREAL
Posts: 23
naor52 is an unknown quantity at this point
Question camera question

Can we use the camera to messure distance?
  #2   Spotlight this post!  
Unread 02-02-2006, 12:29
DjAlamose's Avatar
DjAlamose DjAlamose is offline
Registered User
AKA: Teh Albie
FRC #0279 (Tech Fusion)
Team Role: College Student
 
Join Date: Jan 2006
Rookie Year: 2003
Location: Toledo, OH
Posts: 343
DjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to beholdDjAlamose is a splendid one to behold
Send a message via AIM to DjAlamose
Re: camera question

Quote:
Originally Posted by naor52
Can we use the camera to messure distance?
Yes, the servos will give you an angle at which the camera is tilted at, with this, and some other dimensions, you can calculate the distance you are away from the target.
__________________
WHAT TIME IS IT????? 279!!


2006 GLR Safety Award (2nd year in a row)
2005 National Xerox Creativity Award
2005 National Curie Quarter Finalist w/ 1126 and 180
2005 Buckeye Regional Champs w/ 67 and 274
2005 Buckeye Regional GM Industrial Design Award
2005 Buckeye Regional Safety Award
2005 GLR Quarter Finalist
2005 GLR Xerox Creativity Award
2005 GLR Safety Award
2004 Nationals Curie Division Finalist
2004 GLR Champs
2004 Buckeye Delphi Driving Tomorrow Award
2004 Buckeye Quarter Finalist w/ 1001 and 869
2003 GM Industrial Design Award GLR
2001 National Champs
  #3   Spotlight this post!  
Unread 02-02-2006, 12:29
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: camera question

Indirectly, yes. If you know the actual size of what you're looking at, you can figure out how far away by how big it looks to the camera. Or if you know where it is relative to the camera mount's orientation, you can figure out its distance by how far away from center the camera needs to look in order to see it.

I figure many teams will be using the camera tilt angle and the known height of the vision target (plus a wee bit of trigonometry) to give an indication of the distance to the goal.
  #4   Spotlight this post!  
Unread 02-02-2006, 12:35
naor52 naor52 is offline
Registered User
FRC #1578
 
Join Date: Dec 2005
Location: ISREAL
Posts: 23
naor52 is an unknown quantity at this point
Re: camera question

How?
  #5   Spotlight this post!  
Unread 02-02-2006, 16:14
viewtyjoe viewtyjoe is offline
Code Monkey
AKA: Nathaniel Davis
no team
Team Role: Programmer
 
Join Date: Jan 2005
Rookie Year: 2003
Location: West Chester
Posts: 14
viewtyjoe is an unknown quantity at this point
Send a message via AIM to viewtyjoe
Re: camera question

If you know the tilt angle, the height of the camera, and the height of the center of the target, you can approximate the horizontal distance using the equation distance = (height from camera to target)(cot(tilt angle)).
  #6   Spotlight this post!  
Unread 02-02-2006, 19:38
Denz's Avatar
Denz Denz is offline
Registered User
FRC #0772 (Sabre Bytes Robotics)
Team Role: Programmer
 
Join Date: Jan 2006
Location: LaSalle, Ont, Canada
Posts: 66
Denz is on a distinguished road
Send a message via MSN to Denz
Re: camera question

is the tan function built in the program? how do I get it so I can type "tan (angle in radians)" and have it evaluate?
__________________
www.sabrerobotics.com
  #7   Spotlight this post!  
Unread 02-02-2006, 19:56
chris31 chris31 is offline
Team 2021 Captain
AKA: Chris Davidson
FRC #2021 (FA Robotics)
Team Role: Mentor
 
Join Date: Nov 2005
Rookie Year: 2006
Location: Atlanta, GA/ Fredericksburg,VA
Posts: 949
chris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond reputechris31 has a reputation beyond repute
Send a message via AIM to chris31
Re: camera question

Quote:
Originally Posted by Denz
is the tan function built in the program? how do I get it so I can type "tan (angle in radians)" and have it evaluate?
Yep, you should be able to just call it like that.
  #8   Spotlight this post!  
Unread 02-02-2006, 23:18
Denz's Avatar
Denz Denz is offline
Registered User
FRC #0772 (Sabre Bytes Robotics)
Team Role: Programmer
 
Join Date: Jan 2006
Location: LaSalle, Ont, Canada
Posts: 66
Denz is on a distinguished road
Send a message via MSN to Denz
Re: camera question

And that's built in to the camera function or in the default 2006 code?
__________________
www.sabrerobotics.com
  #9   Spotlight this post!  
Unread 03-02-2006, 00:07
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: camera question

See http://www.chiefdelphi.com/forums/sh...ghlight=math.h for information on the provided math library.
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
CMUCam2 GUI Tilt Question Idaman323 Programming 3 27-01-2006 02:01
Camera Calibration organgtool Programming 0 11-01-2006 23:56
Using camera PWM out Cuog Programming 2 28-11-2005 14:17
Trying to import Camera code into program without. Kingofl337 Programming 1 18-02-2005 00:43


All times are GMT -5. The time now is 01:35.

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