10. Input devices¶
Reguirements¶
Group project¶
Probe an input device’s analog levels and digital signals
The members of the group:
- Achille
- Anssi
- Jari
- Hannu
Individual project¶
Measure something: add a sensor to a microcontroller board that you have designed and read it
Individual project¶
In my final project I have used Strain Gauge sensors. But now I want to get to know Ultrasonic Sensor HC-SR04.
I fabricated two PCB versions. Now I use version 2. It very good board also in Embedded programming, Input devices and Output devices weeks. I have documented the work in Embedded programming week.
Research¶
The sensors are Transducers, a device which send signal to Microcontroller. The sensor are devices which meter some physical phenomenon and send an output signal to Microcontroller. It is possible that a signal have to change with some other device before microcontroller can process a signal. A sensor signal could be analog or binary. A sensor could be also Passive or Active Sensor.
The processed sensor signals
Ultrasonic Sensor¶
Ultrasonic Sensor measure distance based on ultasonic echo. I used Ultrasonic Sensor HC-SR04 which analog active sensor.
Installation and programming¶
I installed Ultrasonic Sensor HC-SR04 to my Final project PCB (version 2) by using jump wires. This is documented in Embedded programming week - board
I programmed Microcontroller ATtiny1614 in PCB with Arduino programmer. I copy code for Ultrasonic Sensor HC-SR04 from page https://arduinogetstarted.com/tutorials/arduino-ultrasonic-sensor and edited it. This is documented in Embedded programming week - programming
Test¶
I tested accuracy of Ultrasonic Sensor to set a object differet distances from sensor.
The distance to test object is 15 cm
The distance to test object is 10 cm
The distance to test object is 5 cm
It was surprise for me how accuracy Ultrasonic Sensor HC-SR04 is.
Reflection¶
I learned a lot of sensor technique as I documented in Research.
Problem and problem-solving¶
I had some problems in installation. It was litle challenging to install sensor to PCB with jump wires but at last I succeed that.
Useful links¶
- ArduinoGetStarted.com / arduino-ultrasonic-sensor
- Howtomechatronics.com / ultrasonic-sensor-hc-sr04/
Hero Video¶
This video is hero video for weeks: Embedded programming, Output device and Input device