Talking Arduino | Playing MP3 audio with Arduino | Arduino PCM audio without audio or mp3 module
Vložit
- čas přidán 1. 05. 2018
- Hello guys , in this video i've shown how to play any mp3 audio with your Arduino without any module you just need a speaker for that and if available then use a Audio amplifier as here i am using a transistor TIP 120 for amplification of audio but the Arduino can only play 16 bit PCM 8kHZ audio mp3 & that mp3 should be coded using a encoder software the only down side is the low memory of Arduino uno allows us to play a audio of approx 4-5 sec but you can use ARDUINO MEGA to solve this, well practically this concept is not of much use but its kind a educational & fun too , so try this & i hope you liked it if yes then don't forget to like the video & if you are new to my channel don't forget to subscribe.
Thanks for watching...
Like my Facebook page for updates-
/ electronicguru001
instructables guide link -
www.instructables.com/id/Talk...
DOWNLOAD Audacity -
www.audacityteam.org/download/
Download PCM.ZIP & Encoder software (file named as Arduino MP3.zip) -
drive.google.com/file/d/1LSb-...
or
github.com/shveytank/Arduino-MP3
Items to Buy (affiliate link) -
Arduino Uno-
www.banggood.com/UNO-R3-ATmeg...
Speaker -
www.banggood.com/2-Pcs-3-Inch...
www.banggood.com/50MM-0_5W-Cu...
www.banggood.com/3-Pair-4-Ohm...
TIP 120 transistor -
www.banggood.com/10pcs-TIP120...
www.banggood.com/30pcs-TIP120...
www.banggood.com/50pcs-TIP120...
Previous videos-
Neopixel ws2812 LED Strip or LED Ring 12bit with Arduino Tutorial
• Neopixel ws2812 LED St...
DIY Power Supply | Original Hiland 0-30V 2mA 3A Adjustable DC Regulated Power Supply Module DIY Kit
• DIY Power Supply | Ori...
Arduino OLED Clock using DS1307 ic | Arduino OLED clock project
• Arduino OLED Clock usi...
ESP 32 Getting Started with Arduino IDE -
• ESP 32 Getting Started...
Raspberry pi zero W Tutorials Announcement Video-
• Raspberry pi zero W & ...
How to use Digispark ATtiny85 smallest & cheapest Arduino compatible board
• How to use Digispark A...
DC 0 100V 0 10A Digital Ammeter Voltmeter with dual display
• DC 0 100V 0 10A Digita...
I2C LCD with Arduino | convert a SPI LCD to ko with PCF8574
• I2C LCD with Arduino |... - Věda a technologie
I've been searching for a very long time, across the galaxy, to find a tutorial about how to play audio sound without any SD card and MP3 module at all.
And now the journey has ended..
Thank you, my friend.
You get a new subscriber.
yes dear
Across the galaxy!! Epic line man😂😂
Yes I also search every where now I found it
great to hear that
I've been looking for this exact video for over a month. Thank you for going out of your way to make this. Your not talking to a wall
1:50 "we heard an italian person saying arduino dumelalu" xD
i always read demullahmove xD
i heard "arduino dwammelo oder"
Thank you very much for this video.I really appreciate this project.
Thank you very much. I´m having lot of fun! Great and easy video.
Your welcome buddy
Hi, thanks for the project. My Arduino Uno only plays like half second of the file, although it says "Sketch uses 4090 bytes (12%) of program storage space. Maximum is 32256 bytes."
Can you help? I'm new to Arduino.
sir, will voice recognition module recognizes only our voice or everybody's voice who give same command
How do I make it play louder? My speaker is connected to the TIP120 for power, but the volume is pretty low.
Thanks bro for this tutorial
Was looking for something like this for long...
Your welcome man 🙂
Thank you for this. I learned a lot from this short video.
hello sir i have a question i am trying to do the same job with stm32f4disco, after I changed the format of my audio file to 16 bit pcm, I managed to run the encoder and see the same window, but then I don't know what to do. Where can I find the series you created?
Do you know why I have a sound different when I put it on the card ? :(
Can the transmitter be replaced with a mini ampifier?
THANKS SO MUCH SIR!!!
Could it support speakers with 100 or 200w? Also, what kind of power source uses the system? Does it need to be connected to the electricity or does it need a battery?
Man, you're just more than awesome
Absolutely awesome! Thank you so much for this!
you solved my biggest problem
thanku so much
Your welcome brother 👍
hello,i have a question!
can i record wav files to micro sd?
bro im gettin very low voice when i place emmiter pin on GND ! IT PALYS WELL When pin placed no where!!? can u tell why?? Initially it was noting like this!
Thanks man....
Great video
this is what I need ! Really help in my project..
Great to hear that.
ok, can u tell me how to put short 2 or 3(only for 2 or 3 ms) mp3 because i am trying but "sketch to big" error is occur.
Why the number code I transferred only will give "bip-bip" inconsistent sound? But it work when it goes with default sound code. IDK what's going on...
Hi! Can I make it say more than one thing and move a motor at the same time?
Hey sir, can we do this without the transistor for the 8 OHM 0.5W speaker?
Hey hey :) I can't open AudioEncode, Windows tells me that javaw.exe is missing... Is it still working for you ? Thx
when i open encode.exe it says (on mac) this file can only be opened on windows
Excellent work, It would be nice if you play some Low Frequency ( Drum Beat, Bell Sound ) and Higg frequency Sound.
Is there a way u can make it play when powered up ? Like a start up sound
will voice module able to distinguish two different people if they are given the same command ? please Reply
Out of curiosity, why do you need the transistor in this circuit? If an arduino's output pins already supply 5v only when the logic says to, can't the transistor be omitted(removed)?
(I'm not much of a electronic component guy, I knew very little about it) Oh, well would it be possible then to amplify the speaker voltage as much as you like by telling the Arduino to turn on and leave on say 2,3, or 5 pins and connect them all to the connector pin so young getting 3 or 6 times the tiny amperage? (Assuming your not overloading your transistor). I tried a similar project reading from an SD card to play sound but it was so quiet. I put a stop to the project because I didn't have any amplifies it know how to make one.
Bhai yrr m ek robot project p kaam krr rha hu Usme mujhe chahiye ki jaose mne hello bola to bhi hyy sir bole fir mne kuch bhi bola to wo uska reply d kese Hoga ye..???? Plz bta doo
When I try the circuit, my speaker plays the music, but the speaker and the Arduino both get really hot and smell like burning? I'm guessing that isn't normal. Is it?!
sir,that is my question , can we play multiple mp3 without sd card.
When I use pro mini, instead of voice output the speaker got heated up very high instantly.
can i play audio by appending same array from usb serial 0 pin of arduino?
excuse me sir, can i use any transistor??? please reply soon, Why doesn't the encoder software says not correct java
Can't seem to make this work with an arduino Mega... is there any differences in code that would change things?
to run it on mega , you have to rewrite the library
can we use buzzer and leave using transistor?
hello can we play multiple mp3 in arduino without sd card
can i run 0.25 watt speaker???
how many different audio can be store in one program?
can i use a transistor other than TIP 120
It would be nice if we can store Mp3 in External EEPROM and interface with Arduino , this way large mp3 file can be palyed.
Yeah that can be done . 😊
Very interesting! I did not know you could do that with Arduino.
Thanks, that means a lot to me! Your videos are very educational too!
Hello , i want to try this project but i have a question about it:
can i use another transistor like TIP42C TO-220 TRANSISTOR
Yes you can, any transistor will work. Most of the transistor will work. It will just affect the audio quality/loudness but most of the transistor should work.
Can i connect this to arduino mega???????????? Which pin is used to connect with arduino mega?
How many watt speaker have you used
Need help!! When I try to open the audio encode application file, it gives me an error message saying that windows cannot find a flie called "javaw.exe" and than a message saying "Error calling ShellExecuteEx()". Thank you!
Okay install java in your pc
@@electronicGURU i have same problem pls help
😥
The encoding software won't install on Windows 10. Any help?
I see your sound example file was 13k in size..... i''m using a 9k file and keep getting when compling the sketch the following .. "Global variables use 24388 bytes (1190%) of dynamic memory, leaving -22340 bytes for local variables. Maximum is 2048 bytes." ...... ... the size of the data in the clipboard is massive.... compared to your pasted data which is a quick scroll back to start of sketch ... mine has scroller way over to right ....... could it be the software not running right ?? any ideas /tips ? i'm only importing 9k but the txt size of clipboard is 150k lol ?? super converting there !!!
What is the duration of your mp3 file? Is it properly encoded as i instructed?
To use one of the speakers with 12v, give a name
Hello, how about to raise the sound volume, could it?
from where you powered the arduino board???
Sir please tell me how i can play it with ldr as a switch
encodeaudio generate a byte array? i can do a simple java software that take byte array? is the same?
I think so.
Nice Video, thank you. I have a question when I'm adding PCM.h with Servo.h an error msg appears and it seems like I can't use these two libraries together (maybe because they're using the same timer). So any solution please?
Yes thats correct they use the same timer. You need to change the library.
Please send me the code so I can play on any pin other than 11. I did not understand the PCM.c library. Please help me because I want to run SPI as well in which pin 11 is being used. Mere changing pin number in PCM.c library did not work!
it is possible for earphone?
Great video, sir! I have 2 questions regarding the subject:
Can I implement more than 1 audio sample in the code (I would need 15 sound samples for a project, is it possible if I use Arduino Mega)?
Can I use potentiometers to control the sample message I want to receive according to certain analog values I want? (For example: If analogRead < 100 start playback(sample1..))
I would kindly appreciate your answer :)
Yes thats possible but as it can support only Arduino uno , so no can't use mega. And since it can play upto 4sec of sound so until and unless you use 1 seconds of 3 or 4 clips then you can do that. Otherwise its not possible. You have to go with some another approach.
Thank you very much for your answer!
Your welcome
i have a problem
arduino send me "clipboard coes not contain a string"
help me
Can I use it on arduino mega?
Hello, is there any way at all to get a pcm library to use on a the arduino mega? My mp3 is too long to play on the uno! (by 1 second! maybe i could decrease the sample rate to make the file smaller?) thanks
if there was a way to decrease the sample rate from 8000khz to 4000 or 6000 that would be awesome! thanks
Hello, thanks for this tutorial that is very self explainatory !
Can you recommend us between 4ohms or 8ohms with this setup please.
Well both will work but the one i use is 4ohm.
How to connect this circuit 12v horn
Hi i have a doubt . I need to play songs according to if conditions in arduino . Can i write the constant statement (outside setup and loop function that is written in the code) with audio code (128 167 .....)in those condition so that i can play various songs according to the if condition in loop condition?
Yes you can.!
@@electronicGURU i want to share the same code to my friend . So will it play in his arduino too fr the same code ?
Yes it will.
Great video
How can we make chanting box ?pls do it in your next project
I'm on a Mac and I can't use the audio encoder. Are there any alternatives for me?
Try this : tomeko.net/online_tools/file_to_hex.php?lang=en
It might help.
How you change text into mp3
Great 👍
Can anyone explain or do a new video for how to achieve this on the new Nano33BLEand Sense boards. I need to only play a few one and two word mp3 files and don't want to add an sd card module as trying to keep the project to bare minimum components
well this library won't work on nano 33 ble sense , as of now ut only supports atmega328 but if you have capability you can modify it for any mcu but that will take a lot of time & skill
Sir, my speaker is connected to a circuit and has three wires coming out of the circuit. I had salvaged it from an old toy. Can you tell me what the circuit is for? I was thinking it played the sound effects for the toy but I don't understand the three wires coming out of it.
electronic GURU I have sent you the pictures sir. Thanks.
thanks bro very useful
Your welcome buddy
Hi Great Video.Can you tell me why it works on the arduino uno and not the Mega?
"ArDuInO DuMeLaLu" *distorted smiley face here*
😀
@Piercodio heh
😁😂
tried your demo and worked great with my uno trying to use my mega and having issues is the pin 11 that we use on the uno different for the mega?
i too facing same issue with mega 2560
It won't work with mega
@@electronicGURUthis code can work with arduino nano...?
Want to ask something
Can use TIP31C instead of TIP120?
Is there any different about these 2 transistor?
@@electronicGURU thanks a lot bro.🖒🖒thanks for your helping
The encoder software is not working it is showing 'jovaw.exe' not available
can you make it that the sound play after pressing button not resset button just normal button connected to arduino pls
Yeah it can be done call the function in loop instead of setup and just put the function call inside if
what pins should i used to connect arduino mega 2560?
ive tried pin13 and pin 12 and pin11 but there's no sound coming out from the speaker
It will not work on any mcu other than atmega328p
Ahh ok thanks men, what should i do to make my arduino mega talk thanks a lot
Good tutorial. How can I make this library compatible for ESP32 chips?
sir, using voice recognition module if one person's voice command is dumped into arduino and if another person tells the same command will it accept? please reply
thank you sir and one last question is which voice recognition module will be the best
Thanks bro, it is working :)
Your welcome brother 👍
I can't open the encoder
After making this whole project . Does it work after disconnecting the cable from laptop???
Yes it does.
when I try to run EncodeAudio.exe there's an error that says "A Java Exception has occurred". I tried reinstalling java and everything, even allocating more memory but nothing has worked so far. Is there any fix?
Try to capture that exception i think we can handle the exception but we need exact exception name
czcams.com/video/66crhKstr70/video.html
can i connect this to the input in the sound amplifier to boost the sound?
I haven't tried but i think it will work
Sir I am unable to play any audio through arduino
Hi! I want to play a 22 second audio, Every thing is working but it only plays first 3-4 seconds of the audio. Even that I have put the delay of 22 seconds. What can I do t play full audio?
idk
hello!! i would like to thank you verrrrry much this is the only thing that worked!!!! but the sound is really really low, how can i make it louder
Is there a way I could make it play only when I press a button?
Yes you can add a pushbutton condition in the code.
Why is the transistor needed? Can you plug in the speaker directly to gpio?
Yes we can but the output which comes out from Arduino is very low power which won't be enough for speaker, even if we find a very small speaker and we plug it without the transistor then we will get a very low volume audio. So the transistor is just acting as an audio amplifier here and boosting the sound
Hi Sir, I have a question. What is the specifications of speakers used in the video?
its 4ohm 2 w
Encode audio software not opening in my pc. Any idea??
Install java
Sir encode audio is not opening in my pc
which audio converter you had used . pls send link!!
@@electronicGURU my converter did not work please updat asap and let me know when you do ...thank :)
Nice one
it gives error while running audio encoder it says javaw.exc is missing and when i install java it says java now installed correctly
please helppp
i am getting same error .. wht do u mean by installing java?
Seems to be the result if you do not have Java installed, or if it is out-of-date. Installing/Updating Java fixed the problem for me.
Thanks for sharing the details 😊👍