View Single Post
  #10   Spotlight this post!  
Unread 23-02-2006, 11:51
EHaskins EHaskins is offline
Needs to change his user title.
AKA: Eric Haskins
no team (CARD #6 (SCOE))
Team Role: College Student
 
Join Date: Jan 2006
Rookie Year: 2006
Location: Elkhorn, WI USA
Posts: 998
EHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond reputeEHaskins has a reputation beyond repute
Send a message via MSN to EHaskins
Re: How to test if the camera is locked on?

on my robot i have the user display show the camera confidence. i found it hovers between 175 and 225 when it has a good lock and drops below 10 when it has lost the light.

code to show confidence on the user display:

User_Mode_byte = T_packet_Data.confidence;

once you know what your camera is returning you could add more code to turn on an LED or whatever.

if (T_Packet_Data.confidence > 150)
{
Turn_On_LED;// add Signal code here
}
NOTE: if you put eather code sample in User_Rutiens.c add
#include "Tracking.h"

where Turn_On_LED is add your signaling code. you could even make the LED Flash at a verying rate depending on how confident the camera is.