Go to Post The greatest lesson we can teach our kids is how to win. - AdamHeard [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

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Spotlight this post!  
Unread 06-02-2017, 09:29
FuzzyLogic FuzzyLogic is offline
Registered User
FRC #3792 (Army Ants)
Team Role: Programmer
 
Join Date: Feb 2017
Rookie Year: 2016
Location: Missouri
Posts: 1
FuzzyLogic is an unknown quantity at this point
Re: How to calculate target distance?

Another way to calculate distance is to look at the height of the object within a the camera's field of view. Very close to the tower the vision target is at the top of the image, and as you back up it lowers to the middle of the image.

You can either use an empirical function to determine distance (beware, it's not linear though) or use geometry. Our team uses geometry and it's been pretty successful. We typically calculate within 1-3 inches of the actual distance.

This method is also easy to calibrate. Although the pixels-to-distance function isn't linear, the error in the calculation is. Finding the slope of the line allows you to adjust the angle constant in the formula.
Reply With Quote
 


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


All times are GMT -5. The time now is 22:47.

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