![Elecrow Crowtail Starter Kit Скачать руководство пользователя страница 34](http://html1.mh-extra.com/html/elecrow/crowtail-starter-kit/crowtail-starter-kit_user-manual_2378765034.webp)
Download the program to micro:bit to see what happens.
Do you remember the thinking problem in experiment 11 ? Did you find the answer? If you
don't, rest assured that we will lead you to build such a smart, automatic door in this experi-
ment. The only difference is that in this section we will use delicate and magical ultrasonic
sensors.
Experiment 13 – Ultrasonic ranging smart door
Instruction
Learn how ultrasonic ranging sensor works and use it to make a smart door with servo and buzzer.
Learn how to get the distance from the ultrasonic ranging sensor.
Micro:bit x1
Crowtail-Base shield for Micro:bit x1
Crowtail-Ultrasonic Ranging Sensor x1
Crowtail-9G Servo x1
Crowtail-Buzzer x1
Crowtail-Cable x2
USB cable x1
Target
Required Parts
This HC-SR04 has stable performance and high ranging
accuracy. The process of ultrasonic ranging: Ultrasonic pulses
travel outward until they encounter an object, The object
causes the wave to be reflected back towards the unit. The
ultrasonic receiver would detect the reflected wave and stop
the timer. Now read the time of the counter, which is the
ultrasonic propagation time in the air. According to the formula: Distance = ECHO high level
time X ultrasonic velocity (Speed of Sound in air 340m/sec) / 2, you can calculate the distance
to the obstacle.
Hardware learning and connection
When you press button A on the micro: bit, the matrix LEDs will show you the
current temperature. When you press button B on the micro: bit, the matrix
LEDs will show you the current humidity.
Result
How to build a more comprehensive weather station so that we can get air quality,
temperature, humidity, ultraviolet information and more?
31