Log in

View Full Version : camera jerks and does not lock on when tracking


kirkio
10-02-2006, 23:10
I've searched and have not been able to find anything like this.

I have Kevin's newest version of code loaded on my FRC and the camera is hooked up. When I hook up the camera, it goes through the jerky scanning motions, and then when it finally gets me data (pan/tilt angles etc) it does not lock on to the target, but rather does a very jerky scan process over again. This is no good to me if I am going to be using PAN_SERVO and TILT_SERVO to guide my robot. What's gone wrong?

Thanks.

X-Istence
10-02-2006, 23:20
Your values are turned backwards, in tracking.h you need to change 1 to -1, and -1 to 1, something about ROTATION_SIGN_DEFAULT, if you mounted the camera properly, those will be wrong, if you mounted it like in the instructions, it will be mounted upside down, and the code should work.

The jerky scanning is standard, change it in tracking.c if you want.

nehalita
10-02-2006, 23:43
Either what x-istence said or you switched your servos so that your pan servo is hooked up to the pwm meant for the tilt servo on the RC and the tilt servo is hooked up to the pwm meant for the pan servo on the RC.

hope one of those two solves your problem