Analog pin testing

This week we conducted the analogue pin testing for both of our codes to ensure they are both operating correctly and constantly reading a range of values. We are using a line sensor and an ultrasonic sensor, so we want the Microbit to read and tell us the light values and the distance away from an object the sumo bot is. Because the line sensor gives us a digital reading and not an analogue (either on the line,1, or off the line, 0) we could not complete the analogue pin testing for this code, but we did run it to ensure it was working correctly. As you can see below, the code is operating correctly and are reading a range of values. They are also triggering the motors to complete a task in each case. When the ultrasonic sensor reads values that are lower than a predetermined value, it will activate the servo motor to move the flipper arm up at 90 degrees.

Leave a comment

Design a site like this with WordPress.com
Get started