Тёмный

Motion-activated Sound Effects with Arduino, PIR Sensor & MP3 Player 

Rachel De Barros
Подписаться 56 тыс.
Просмотров 10 тыс.
50% 1

My Arduino tutorial will show you how to create spooky sound effects triggered by motion using a PIR sensor, MP3 player, and Arduino Uno! Learn how to wire a PIR motion sensor and mp3 player module to an Arduino Uno and then write Arduino code examples with me to trigger a variety of sound effect based on motion.
🛠🎨 Join my Engineering Artists Discord Community for LIVE WORKSHOPS & COMMUNITY BUILDS (Zoom) ▶︎ racheldebarros.com/community
🔗 Full Tutorial: racheldebarros.com/trigger-so...
BUILD YOUR OWN Motion-activated MP3 Player Module with PIR Sensor and Arduino:
🛒 PIR Sensor: amzn.to/49CagWn
🛒 MP3 Player Module (I used DFRobot PlayerMini): amzn.to/49vEzgW
🛒 Speakers (I used 2W 8 Ohm): amzn.to/49lFRew
🛒 Arduino Uno: amzn.to/48jRlyr
🛒 Micro SD Card (DFRobot PlayerMini accepts 32 GB): amzn.to/4alUP5n
🛒 Breadboard: amzn.to/42FZZGk
🛒 Jumper Wires: amzn.to/42K4kbv
This is perfect for adding life to your DIY props, animatronics, robots, and more! In this Arduino tutorial, you'll learn:
▻ Meet the Components: Get to know the Arduino Uno, PIR (Passive Infrared) motion sensor, and the versatile MP3 player module. Learn about their functionalities and how they can be integrated to create dynamic sound effects triggered by motion.
▻ Wiring It All Together: A step-by-step guide on correctly connecting the PIR motion sensor and the MP3 player module to the Arduino Uno. Understand the wiring logic and how each component communicates with one another.
▻ Coding for Interactivity: Launch the Arduino IDE as I walk you through various code snippets and examples. Learn how to program your Arduino to detect motion with the PIR sensor and trigger specific sound files stored on your MP3 player module. From simple sound playback to more complex scenarios involving multiple sounds and conditions, I cover it all.
▻ Troubleshooting Tips: Encounter an issue? No worries! I share common pitfalls and their solutions to help you overcome any technical hurdles effortlessly.
🎬 VIDEO CHAPTERS: Motion-activated MP3 Player with Arduino Wiring & Code
0:00 Welcome
0:27 PIR Sensor Pinout
0:40 PIR Sensor Time Delay, Sensitivity & Trigger Mode
2:16 Breadboard Power & Ground
3:05 Wire a PIR Sensor to Arduino Uno
3:37 MP3 Player Module Pinout
4:21 Wire an MP3 Player to Arduino Uno
7:21 Arduino Code: Test PIR Sensor
13:15 Arduino Code: MP3 Player Set Up & Libraries
17:28 Arduino Code: Play Sound Track with Motion Detection
18:06 Arduino Code: Play Different Tracks with & without Motion Detection
18:41 Arduino Code: Play Tracks Sequentially with Motion Detection
22:38 Arduino Code: Play Tracks Randomly with Motion Detection
24:54 Get Full Tutorial with Code
25:10 Join the Community
💬 Have any questions or want to share your own experiences, tips and advice about using a PIR sensor to trigger sound effects from an mp3 player with Arduino? Drop a comment below - I love hearing from you!
🔔 If you find this video helpful, please hit that like button 👍 and consider subscribing to my channel for more props/animatronics/robot tutorials, tips, and tricks. Your support helps me create more content like this!
Some links included here are to affiliate sites. If you purchase something through them, I may earn a small commission - which costs you nothing! I am very grateful for your support when you use my links to make a purchase.
#arduino #pirsensor #mp3player #arduinotutorial #arduinocode #arduinoproject #props #animatronics

Наука

Опубликовано:

 

28 июн 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 52   
@martinlyne2294
@martinlyne2294 15 дней назад
Awesome tutorial. Really great how you've broken down each section.
@jamesmoon5632
@jamesmoon5632 2 месяца назад
What i love about your videos is you get straight into it and quickly tell us what we need precisely. Like the personality as well keep these coming as i love the content
@leeskelton9715
@leeskelton9715 Месяц назад
I’ve been looking for this video for six months. No one else has posted anything like this. Thank you very much for posting 😊
@electronics.unmessed
@electronics.unmessed 2 месяца назад
Good explanation, I am about to plan some projects using PIR sensors .. Thanks for sharing!
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Go for it!
@KEYESTUDIO_OFFICAL
@KEYESTUDIO_OFFICAL 2 месяца назад
Looking forward to your content!🥰
@nashaut7635
@nashaut7635 2 месяца назад
Hi Rachel. The resistor you've talked about @7:15 is not for "smoothing" things. The thing is the DFPlayer inputs are not 5V tolerant and you need logic level shifting to not destroy those inputs. It is indicated (though it does not really stand out) in the datasheet. Even though the entire module is powered with 5V, the inputs can only accept 3.3V maximum. A bare minimal level shifter (from a 5V output) is a 2/3 resistor divider, e.g. 1k / 2.2k ohms - you can also build one with a PNP transistor or a P-channel MOSFET. The 5V input (Rx) of the Arduino however can cope with the 3.3V level and take it as a logic one. However it is close to the minimal value for a logic one (see the datasheet of the ATmega328 for reference).
@user-xt8on4kf5o
@user-xt8on4kf5o 2 месяца назад
Love it! Thank you :) This is giving me creative inspiration.
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Go for it!
@jogosProgramEletronica
@jogosProgramEletronica 2 месяца назад
great explanation
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Glad it was helpful!
@mynameisprivate158
@mynameisprivate158 17 дней назад
As a complete noob to Arduino, I was able to get this project working pretty easily. Thank you for the clear plans and directions. I would love to install this in a prop I made but as it is using a breadboard it has very loose connections and the wiring is a mess. Could you make a video on how to make this for a more permanant install maybe using a nano or othe rmeans to be able to solder it together and make it more compact?
@SummersideDiver
@SummersideDiver 2 месяца назад
Yay - you just helped me get my crow audio working - my next feat is to get the code into Bottango so I can get my animatronic self sufficient! Thanks so much for sharing this info and helping our community
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Post your updates on Discord because I'd love to see how you implement Bottango with this!
@SummersideDiver
@SummersideDiver 2 месяца назад
@@RachelDeBarrosLive It’s a learning process, that’s for sure! I’m learning Arduino coding, Bottango, and how to work with servos and other hardware all at the same time. But who wants an easy way to learn?
@Xhilong
@Xhilong 2 месяца назад
Great Video and explanation. going to put this one to good use.
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Excellent! Let me know how you make out with your project!
@jackrichards1863
@jackrichards1863 2 месяца назад
Hey Rachel You are so nice. I really enjoy your tutorial. Seems like you shop at the randomest "T" shirt shop in Beverley Hills or some EXCLUSIVE venue to seek out those quirky cuts and phrases. I don't have a full grasp of Arduino code still but using your vid's as reference it is likely to present a road map of method . Thank you!
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Let me know how you make out. I actually get most of my tees from Amazon of all places! Three Amigos is one of my favorite movies - you can never have too many pinatas 🤣
@jackrichards1863
@jackrichards1863 2 месяца назад
@@RachelDeBarrosLive 😄 I will. Thanks for showing interest! I like that .
@denisx4808
@denisx4808 Месяц назад
Hi Rachel, I find your videos great! I particularly like how you really explain everything step by step. Question: Can you make a video about how you can create an animated mouth movement using Arduino of course. So a moving mouth that runs in sync with the voice? Needed it for my Halloween project 😁.
@alejandroveleiva664
@alejandroveleiva664 День назад
Hola cómo estás, te felicito por tu proyecto, sino te molesta este comentario, te conviene usar const int para declarar los pines así no ocupas espacio en la memoria saludos.
@hucobo
@hucobo 2 месяца назад
How nice that you can choose the track you want to play. Is it possible to play tracks of different lenghts?
@alleynecostin6709
@alleynecostin6709 2 месяца назад
Rachel you must have been trained by train the trainer program. Each step and explanation is spot on. great job. keep it going. Thank you.
@baguk21
@baguk21 2 месяца назад
well explained
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Thanks 😄
@DBB-KE5DUO
@DBB-KE5DUO 2 месяца назад
🎉😊 See me waving like a crazy person, too? You make this look so easy!! 🥳🥳🥳
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
😁 Put your hands in the air like you just don't care! 🥳
@conraddickinson24
@conraddickinson24 12 дней назад
You seem really knowledgeable about this stuff maybe you can help me with a project that I'm trying to figure out. I'm trying to set up a display where three witches perform the scene from Macbeth. Each witch would need to speak her lines in turn and then all three of them speaking the communal lines. I know I will need servo motors for the jaw movement and head movement but how do I sync everything together in a performance?
@solutionreplays6622
@solutionreplays6622 2 месяца назад
Great video, how/where did you learn to code? I want to learn but it can be daunting.
@donnadimitrova8268
@donnadimitrova8268 21 день назад
Thank you for the great video! I have one question: What if I want the 3-second sound to repeat if motion is still present? Meaning, that if a person stays for longer than a few seconds the same sound loops. Right now, I see the option sensor is detecting that motion is still present, but the MP3 player automatically turns off after the 3 seconds of the sound bite as played.
@leeskelton9715
@leeskelton9715 Месяц назад
Where is the video showing the downloading of the tracks to the MP3 player ?
@whoopzKERRY
@whoopzKERRY Месяц назад
thanks for sharing.. can you make it an IOT by connecting that device into smartphones using bluetooth? by the uSe of MIT APP INVENTOR can you make a video about the block code of that also? thankies
@HEATRACER24
@HEATRACER24 2 месяца назад
I love your shirt!!!
@KEYESTUDIO_OFFICAL
@KEYESTUDIO_OFFICAL 2 месяца назад
grateful!
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
The Three Amigos is a great movie - so many great lines!
@HEATRACER24
@HEATRACER24 2 месяца назад
@@RachelDeBarrosLive Little Neddy Kanickas
@charles8111
@charles8111 2 месяца назад
Will this work with an IR sensor as well
@BariumCobaltNitrog3n
@BariumCobaltNitrog3n 2 месяца назад
I might have missed it but does the PIR have a test mode like a full motion sensor? It only stays on for a couple seconds then resets. I have all these parts but the player and I was wondering about using sounds, so this is perfect. Can you use multiple sensors? Like one on the front and back with different audio outputs?
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
For the PIR sensor like the one I'm using, you can adjust the Time Delay, which is the length of time it remains HIGH before going LOW. To rock through the examples quickly, I set my Time Delay to the shortest time but you can increase the time so the sensor doesn't go LOW so fast. There's also a Sensitvity knob where you can adjust the distance it can sense (3-7 meters). You can certainly use more than one sensor and attach specific sounds to each.
@BariumCobaltNitrog3n
@BariumCobaltNitrog3n 2 месяца назад
@@RachelDeBarrosLive Ok so the shortest time is pretty short, usually it's at least a minute glavin! mm-hoy
@deceptionz187
@deceptionz187 11 дней назад
You're such a gorgeous nerd ❤❤❤❤❤❤❤❤❤❤❤
@TheUnofficialMaker
@TheUnofficialMaker 2 месяца назад
I don't see the link to the code.
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
I got a little behind and am working on the write-up now. The link will be there early this week! 👍
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
I just put it up: racheldebarros.com/trigger-sound-effects-with-arduino-pir-motion-sensor/ (also in the description)
@MyTube4Utoo
@MyTube4Utoo 2 месяца назад
@@RachelDeBarrosLive Thank You! New sub. here. Love your channel.
@ZenHulk
@ZenHulk 2 месяца назад
Please don't go anywhere. Tuesday i have to have a cornea transplant, no screens for 4 weeks, no typing maybe longer.
@trickstur5994
@trickstur5994 2 месяца назад
I hope everything went great for you.
@kurtdeschepper2631
@kurtdeschepper2631 2 месяца назад
Marry me!
@louiepauda6275
@louiepauda6275 2 месяца назад
Player! Affect, cereal assign you're not crazy, Ladie?
@joetkeshub
@joetkeshub 2 месяца назад
I just turned my subscription to "ALL". This is a great job Rachel! Great pedagogy! Great project! He-youtubers should worry... You're better than most of them!
@RachelDeBarrosLive
@RachelDeBarrosLive 2 месяца назад
Thank you for the feedback and let me know if there's any topic you'd like me to cover!
Далее
How to Use Arduino Interrupts The Easy Way
33:28
Просмотров 76 тыс.
Audio modules for electronics project
37:54
Просмотров 39 тыс.
Forget WiFi! This Wireless Method is WAY Better?
12:14
Просмотров 465 тыс.
Cheap and easy motor for props
6:02
Просмотров 13 тыс.
I built my own computer. by hand.
13:03
Просмотров 1,1 млн
How to Use Millis to Master Arduino Multi-tasking
50:17