07
This is a Robot model car crash or collision switch sensor module for
Arduino, it normally outputs a logic HIGH signal, but when the sensor
crash something such as the wall, the on-board switch will be pressed,
and the module outputs a logic LOW signal. This module can be
installed into any mobile platform to achieve collision detection function
via 4 pin sensor cable and Arduino sensor expansion board connector.
Do you know why the car opens the airbag immediately after the
impact? In fact, the collision sensor is used to detect collisions in the
car, so we will simulate a car detection project in this lesson, which will
be absolutely cool if installed in your own smart car.
Lesson 2 – Collision experiment
Introduction
Arduino Uno/Crowduino Uno x1
Crowtail - Motor Base Shield x1
Crowtail - Collision Sensor x1
Crowtail - LED x1
Crowtail - Buzzer x1
Crowtail - Cable x3
Required Parts
STEP1:
Plug the Crowtail-Motor Base Shield
onto the Arduino or Crowduino board.
Hardware Connection
STEP2:
Connect the Crowtail-Collision
Sensor to the D3 port of the Crowtail-Motor
Base Shield. Connect the Crowtail-LED and
Crowtail-Buzzer to the D5 and D6 ports of
the Crowtail-Motor Base Shield. The
complete connection is as follows.
Open the
P02_Collision_Experiment
with
Arduino IDE and upload it.
When you press the onboard switch, you can see the red indicator light on the collision sensor, led
and buzzer will work for 0.5 seconds, when you release the switch, the red indicator light on the
board Off, led and buzzer no longer light up and beep.
What will you see
Содержание Crowtail Deluxe Kit
Страница 47: ......