After making sure that our program worked on the concrete floor we tried it in different situations. When we tried it with the car going uphill, it stopped short of the 10 feet mark by a foot. When we tried it with the car going downhill, it passed the 10 feet mark by 3/4 of a foot. The fact that the car is travelling downhill or uphill definitely matters because the car moves slower as it travels up and moves faster as it travels down the ramp.
We then replaced our "stop" block with a "coast" block to see the difference between the distances that the car would travel. In fact, when the car coasted at the end of 8.5 seconds, it passed the 10 feet mark by a couple of inches.
We then, using the shaft encoders, measured how many "counts" it took for the car to travel that distance. We created a program that printed "count a " and "count b" for 8.5 seconds.
"count a" was 3237 and "count b" was 3225. All of these measurements were taken on the flat concrete floor.
This is a picture of the program that allowed us to obtain the counts:
We then figured out how far was one "count". We divided 10 feet with the counts that we obtained and the result was that for both "count a" and "count b", the car moves .037 inches per count.
If the car were to skid, which means that the car would move but the wheels would not spin, the distance per count would increase.
If the car were to slip, which means that the car would not move but the wheels would still spin, the distance per count would decrease.
No comments:
Post a Comment