[Solved] Needing an MP3 record/play module that actually WORKS

I thought recording and playing MP3 files would be so common, a simple Arduino-compatible module for the purpose would be easy to find.

Not so.

Each I've purchased had wrong instructions, or no instructions, or missing board traces, or no library for recording, or a sky-high price, forcing me to give up and look for another.

Can anyone point me toward a simple MP3 module that actually plays, records, and has spi interface for an external SD Card module?

I don't think there is one. Handling MP3 encoding on an Arduino is far from simple.

I thought recording and playing MP3 files would be so common

Why did you think that? An Arduino has the processing power of a 1980s computer, they did not work with MP3. Just because their are mass produced dedicated systems to play MP3, does not mean you can do the same process on a 16MHz processor with 2K of working memory.

There are several audio (mp3 or wav) players you can control with arduino, I have been using for several projects in the past. But there are not so many which can record audio also.

Is there a special reason why you need to record in mp3 ? Recording in mp3 is a tricky thing and needs a lot more "power" than just playback (and I think there are also legal (patent) reasons ...).

If you are fine with recording in wav format this might be an option: VS1053 Codec + MicroSD Breakout - MP3/WAV/MIDI/OGG Play + Record [v4] : ID 1381 : $24.95 : Adafruit Industries, Unique & fun DIY electronics and kits

Other things I have done when needed to record audio under control of arduino: hacking a portable audio flash recorder, so that it can be controlled with an arduino like I wished.

Perhaps you can describe in more detail what you want to do.

You may be surprised to learn the ISO standard that defines MPEG layer 3 audio only specifies the decoding algorithm. There is no one specific, true way to encode sound to MP3 format. The idea is each "manufacturer" of encoding is free to "add value" by creating their own way of encoding. Only the process of decoding back to uncompressed audio is standardized.

About 16-20 years ago, in the very early days of MP3, the original Fraunhofer encoder was the only one that produced really good results. Xing published another, less expensive to license encoder which was widely used (due to the lower cost), and it used much less CPU time, but also produced significantly lower quality sound at all but the highest bitrates.

So when you ask for a MP3 encoder, especially one that will encode a live stream, you really need to be careful what you wish for. While this is possible with enough CPU power, most MP3 files are created by recoding to uncompressed files, which are then later encoded to MP3.

Obviously a 8 bit, 16 MHz microcontroller isn't nearly powerful enough, nor does it have enough memory, to implement even MP3 decoding.

But newer 32 bit microcontrollers are capable of MP3, at least decoding in real time. Encoding is still a good question. If you'd like to experiment, maybe this library would be a good start?

I used the Fraunhofer encoder for many years (I'm working with sound editing for more than 30 years) and it was quite a good tool. Did not know that the ISO standard that defines MPEG layer 3 audio only specifies the decoding algorithm. Very interesting, thank you for that information!

It is clear that 8bit µCs are not powerful enough for de/encode mp3, but what the TO was asking for was "a module" (I think he meant a "shield"). And there are some (at least decoding) and of course these shields have more powerful µCs on board than the arduino is, like the mp3 trigger or the wav trigger (both are players only, not recorders).

Yes but the OP states he has tried these and can not get them to work.

We could offer better advice in telling him how to get a specific module to work than this thrashing about.

Anyway he seems to have dissapeared so there is little point in taking this thread further.

True, Grumpy. I have "dissapeared"; but not without studying through and learning from each of your comments. They have truely been educational and I appreciate your sharing the knowledge with me.

Uxomm, by "module", I meant "breakout board" for an audio chip. I never use "shields", because there are 7 modules in my project and I need the freedom to jumper-connect them to my Adruino Uno in ways that avoid conflicts between these modules.

I have "dissapeared", because I've given up on finding an Audio Module. Instead, I'm programming a second (slave) ATmega328 to record and play the audio using WAV format instead of the far-too-difficult MP3 format. I'm doing so based on the Record and Play sketches by Amanda Ghassaei, and the Save As WAV sketch by David Patterson.

And the page at Creating a WAV (RIFF) file and Big and Little Endian were also helpful in grasping how to do it.

Again, thank you, everyone, for taking the time to present excellent information. :slight_smile:

Hello, there is MP3 audio recording module FN-RM01 that can meet your needs. Here is the link
http://www.aliexpress.com/item/MP3-Recorder-Module-and-MP3-Player-Module-Two-in-One-2015-NEW/32326106399.html?spm=2114.031010208.3.214.bcsA5B&ws_ab_test=201556_0,201527_0_71_72_73_74_75,0_0

flyrontech:
there is MP3 audio recording module FN-RM01 that can meet your needs.

Looks like the perfect choice (if it actually works as advertized). The price of $31.48 is misleading, since they sell them in lots of 2. The fine print above the price (hard to even see) says:

(2 pieces / lot , US $ 15.74 / piece )

Not a bad price.

In fact, I'm ordering a pair now, keeping my fingers crossed in hopes it really will be the perfect solution. Thank you, flyrontech!


I posted this topic more than four months ago; but I'm still dealing with the audio problem as I described in "How can I slow the ISR down just a little?"