2009 Programs
Turn Based on Distance PDF Print E-mail
Written by Joey   
Wednesday, 10 March 2010 18:08
Turn Based on Distance
 
We were having some trouble on our third mission getting back to base. We could not find the right distance to turn because the direction the robot was facing after tripping the truck varied so much. Previously we went past the truck until we found the black line, and then followed it for far enough to be facing the south wall. The problem was, if tripping the truck turned the robot too far to the south then the robot would follow the line part way around the curve rather than using the straight part of the line to get pointed at the south wall. This was a solution that the team thought up and tested to see if we could mitigate the variation problem, and it did. We used the algebra formula for slope "y=mx+b" and wrote a program to solve it. First we measured the distance the robot traveled from the truck release lever to the black line on 15 runs. Then we measured the angle it would have to turn to be going straight south in each of those 15 tests. We made a spreadsheet using the distance we had gone and the angle of the robot to the wall. We made a chart to calculate the formula for the turn using the spreadsheet software's built in linear regression. The formula turned out to be y=0.11x+72.14. This allowed our robot to vary when it hit the truck, but still get a right angle to when it backed up to the wall. The turn amount needed to get the wall varied directly with the distance to the wall. This meant that our robot is consistent at being almost square when it hits the wall, no matter where the robot was before. 
Attachments:
Download this file (m3 changing turn d.png)m3 changing turn d.png[ ]45 Kb11/03/10 18:25
Last Updated on Friday, 12 March 2010 20:23
 
Cougar Smart Move Programs PDF Print E-mail
Written by Jamie Diamond   
Thursday, 21 January 2010 21:17

Our Master Program

Our Mission Programs 

 
 
 
 
Mission 4 - there is no mission 4
 
 
Mission 6 - NE Corner, aka Timmy and Friends
  Dim lights Embed Embed this video on your site

Our Function MyBlocks 

 
 
 
 
 
Last Updated on Thursday, 18 March 2010 21:55
 


Copyright © 2018 cougarrobot.com. All Rights Reserved.
Joomla! is Free Software released under the GNU/GPL License.