3/13/2013 Wednesday
Tasks:
1.) Moving arm to a fixed point (vertical)
a.) It was not difficult to move the arm to a fixed point using bang/bang control, but bang/bang control did not let us re-locate the arm to a different place. The arm was stuck at the fixed point after one trial of moving the arm away from the point.
b.) Programming the proportional control required more thought and was more challenging, but the arm moved in smoother motions. We were also able to re-locate the arm away from the fixed point as many times as we wanted. *We let the fixed point be at 100 (which we checked using "forever" --> "print" --> "count a") to avoid worrying about negative numbers for the error.
We used the equation from last week: error = set point goal - actual reality (error = what we want - what we actually get). Another equation we considered was: change in power = gain x error. We were able to experiment and change the gain value to control the power and error. This allowed for smoother movements.
2.) Making one wheel follow another (using manual movement)
At first, we decided to manually move the arm connected to motor b to make sure the arm connected to motor a followed. Again, we used proportional control and used the error and power equations mentioned above.
Example: If b was more positive than a (the arm connected to motor b had a higher/more positive number than the arm connected to motor a), the error was the difference of arm b and arm a. We set the gain value as 7. Then, the program commanded arm a to move forward (FWD2) to arm b's position (count).
We then added "talk to b" --> "motor on" to make sure the wheel connected to motor b constantly ran (and the wheel connected to motor a would follow, causing the car to move in a straight or straighter line).
3.) We did not finish this task.
From Wednesday's class, I learned the advantages of using proportional control versus using bang/bang control, which is very limiting.
No comments:
Post a Comment