Go to Post This is a once in a life time event for many of you guys. ENJOY it! - Tom Line [more]
Home
Go Back   Chief Delphi > Other > FIRST Tech Challenge
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rating: Thread Rating: 22 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 14-11-2012, 15:46
maths222 maths222 is offline
FTC FTA
AKA: Jacob Burroughs
no team
 
Join Date: Nov 2011
Rookie Year: 2010
Location: United States
Posts: 148
maths222 is a splendid one to beholdmaths222 is a splendid one to beholdmaths222 is a splendid one to beholdmaths222 is a splendid one to beholdmaths222 is a splendid one to beholdmaths222 is a splendid one to beholdmaths222 is a splendid one to behold
Re: FTC 2012 RobotC IR Sensor Programming and implementation

I use this code: https://hprobotics.googlecode.com/sv...IRController.h to get a more accurate reading from the sensor. Additionally, I use two controllers with the following code:


dir=IRGetACDir(IRSLeft)-(10-IRGetACDir(IRSRight));
if (dir<0)
{
leftSpeed(-50);
rightSpeed(50);
}
if (dir>0)
{
leftSpeed(50);
rightSpeed(-50);
}
if (dir==0)
{
leftSpeed(50);
rightSpeed(50);
}
__________________
--Jacob
Illinois FTC FTA
Reply With Quote
Reply


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 12:40.

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