The micro:bit sensor car
Engineers (Advanced), mission M8 Robots & Control, lesson 4 of 6.
Hook
This car decides by itself when to stop. Code it!
Fair test
Program: drive until distance < 15 cm, then stop. Measure stopping distances at 3 speeds.
Bonus challenge
Add a sound when it spots a wall.
The build
micro:bit Sensor Car: A two-motor car with an ultrasonic distance sensor. Builders code it with MakeCode blocks to stop before a wall.