I exprerienced oversleep even with an alarm clock because anyway I stop it with my hand when it rings and sleep back again. Here, I got an interesting idea "What if the alarm clock runs away from me when I try to touch and stop it?" It will definitely make me wake up to catch the running noisy alarm clock. Let's try!
What and How to MakeWe are going to make an alarm clock running away from you when you get close to it.
1. Put your smartphone with alarm set up on the box with casters.
2. Alarm clock rings on the time you set.
3. When you try to touch it with your hand to stop it, it will detect your hand and run away while maintaining some distances from you.
What To Prepare- obniz x 1
- Power Supply x 1
- GP2Y0A21YK0F (Infrared Distance Sensor) x 1
- DC Motor x 2
- Tire x 2
- Caster x 1
- Box x 1
( I used obniz AI Robot KIT this time)
What is obniz?Before we get into the project, let's look into obniz.
Here → obniz for DIY electronics
obniz is a cloud-connected IoT development board. You can program on the web browser of any smartphone or computer and the command is sent to obniz through the internet via obniz cloud. By connecting the obniz to the cloud through wifi, users can remotely control devices that are physically connected to obniz.
Thanks to this cloud based approach, you can program with Python, Javascript, or other languages you prefer and control hardware directly. You don't need to integrate firmware into the device side. Recording and analyzing data is also easy with obniz cloud service.
Want to control hardware things with your current Python or Javascript skill? Want to start IoT project but don't know where to start? Want to learn programming with languages you prefer?
obniz will help you broaden your viewpoint and develop both your SW and HW skills.
For more information, please visit our official website → Official Website
Where to get obniz board? → Amazon / Official Store
Step 1Assemble box, caster, and tires to make main body.
(If you use obniz AI Robot KIT, please refer to Preparation and Build page and follow until the step 5)
Step 2Connect parts to obniz board as below.
[obniz - Part]
0 - DC motor 1 OUT 1
1 - DC motor 1 OUT 2
7 - Infrared Distance Sensor Vcc
8 - Infrared Distance Sensor GND
9 - Infrared Distance Sensor signal
10 - DC motor 2 OUT 1
11 - DC motor 2 OUT 2
* Please pull out the jump wire of DC motor when you connect it
*Connect infrared sensor in the direction of being pulled out
Write the program that the alarm clock rings on the time and run away from you if you get close to it and try to turn it off.
(Enter your obniz ID to "OBNIZ_ID_HERE")
And prepare for alarm clock sound file and save it as "alarm_sound.mp3". Click "Repository" on obniz Developer's Console and upload it as a random file name.
Let's Try!
Comments