View Single Post
  #3   Spotlight this post!  
Unread 09-12-2009, 01:12
jamie_1930's Avatar
jamie_1930 jamie_1930 is offline
Registered User
FRC #2228 (Cougartech)
Team Role: Student
 
Join Date: Feb 2008
Rookie Year: 2008
Location: Rush-Henrietta
Posts: 371
jamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to beholdjamie_1930 is a splendid one to behold
Re: [FTC]: IR sensor

Quote:
Originally Posted by rzoeller View Post
We are using two very briefly in autonomous to line up our shooter. Does anyone know how to use the IR seeker to measure distance in ROBOTC?
I suppose you could mount it on it's side and then it just becomes trigonometry, but the problem will be the large range that is given will make it difficult to triangulate. Also make sure to encorporate the actual sensor values into your design so that it fires when the sensor reads an even number, that should increase accuracy a little more.

IR Seeker Information

I support the ambition of this design idea, but it's not practical for competition. At Clarkson we found that the majority of robots had no autonomous at all so if you can put balls in the low goal your already ahead of the curve, but if you can put them in the high goal reliably (like our alliance partners harley) you become a sure finalist). From what I've seen, from harley's program you can score in the high goal with completely time based programming, if you make sure to have the right time values. I suggest that you set all time values to variables in your programming so that you can change them quickly. The program will most likely look somewhat like this. Also if you do time based instead of seeker based for competition I would encourage doing so after competition to prepare for the future.

int forward_1 = 0500;
int forward_2 = 1500;
int turn90 = 0250;
int motorspeed = 25;

motor[A] = motorspeed;
motor[b] = motorspeed;
wait1Msec(forward_1);
motor[A] = -motorspeed;
motor[b] = motorspeed;
wait1Msec(turn90);
motor[A] = motorspeed;
motor[b] = motorspeed;
wait1Msec(forward_2);
motor[A] = 0;
motor[b] = 0;

FIRE!!

The time values are my estimates, but you should change the motorspeed and time values in order to best fit your robot. Also remember you need to test and test for this, but if it's done, and works, you should jump up to the top of the ranks. In addition just cause your at competition doesn't mean you can't tinker. At Clarkson we started off sitting in autonomous and by the end of the day were getting all 8 balls in the low goal (only place our design allowed).

Good Luck!

Last edited by jamie_1930 : 09-12-2009 at 01:15.
Reply With Quote