DFPlayer MP3 hack

  • Thread starter Thread starter RetroNinja
  • Start date Start date
  • Replies Replies 5
  • Views Views 443

RetroNinja

Active member
Joined
Jul 23, 2022
Posts
232
Country
USA
Region
Las Vegas, NV
Has anyone ever tried to hack one of these for an Amiga? Granted in my mind every time I say Amiga I mean an A2000, so this means a Zorro card enabled MP3 player. It looks like these are self contained devices. You don't need an Ardurino to use it although that is a very popular scenario. They were on sale at Aliexpress for under $3 with free shipping so I ordered a couple. It's the dreamer in me, but is a $20 MP3 card a possibility? And just to be clear, I have 0 experience with hardware development and programming interfaces.

The device has a serial interface. The device has a LineOut. The device has a SpeakerOut.

Some things that come to mind
  • Zorro card
  • AmigaBASIC controlling it via serial commands
  • the output feeds to Paula
  • from Paula to speakers

???
  • LineIn or MIDI In to Paula?
    • the main reason is to use the already existing Amiga RCA output jacks
    • would Paula try to process an already processed signal (music)?
    • is there a pass-through option for Paula?
  • worse case add a couple RCA jacks to the SpeakerOut
    • is it mono though?
    • this would bypass Paula
  • any way to add this hardware as a source to one of the llama/hippo players?
  • finally a use for the Infernal Serial port?

The closest thing to a proof of concept project plan is to
  1. plug it into the serial port
  2. USB power adapter for DFplayer juice
  3. have ChatGPT generate AmigaBASIC code to control it
  4. plug a speaker directly into the SpeakerOut



1728659946320.png




1728659986049.png
 
A while back I made a small module to connect one of these players to the Amiga serial port and a simple program to control it.

It's really nothing special since there's no way to feed it MP3 data from the Amiga, it just reads MP3 (and I think .wav) files from a MicroSD card or a USB stick.

On my board I added a female USB port and a 3.5mm jack for the audio output, I think it's technically possible to feed that audio back into the Amiga from the "AUDI" pin of the serial port, but I chose not to do that since it's just a mono input. On the positive side since these modules require very little current you don't need an external power supply, I used a simple voltage regulator to convert 12V from the serial port to 5V and ran it this way :)

Unfortunately as far as I know there's no way to read MP3 metadata or filenames from the module to display them on the Amiga

amip.jpg

Here's a picture of the board I made

I wouldn't really recommend it as a "serious" MP3 player but it's a cool gadget, maybe it would be more useful as a Zorro card?
 
A while back I made a small module to connect one of these players to the Amiga serial port and a simple program to control it.

It's really nothing special since there's no way to feed it MP3 data from the Amiga, it just reads MP3 (and I think .wav) files from a MicroSD card or a USB stick.

On my board I added a female USB port and a 3.5mm jack for the audio output, I think it's technically possible to feed that audio back into the Amiga from the "AUDI" pin of the serial port, but I chose not to do that since it's just a mono input. On the positive side since these modules require very little current you don't need an external power supply, I used a simple voltage regulator to convert 12V from the serial port to 5V and ran it this way :)

Unfortunately as far as I know there's no way to read MP3 metadata or filenames from the module to display them on the Amiga



Here's a picture of the board I made

I wouldn't really recommend it as a "serious" MP3 player but it's a cool gadget, maybe it would be more useful as a Zorro card?


Impressive!

It's funny that you essentially made something better than my proof of concept.

Did you look at the DAC_L and DAC_R in detail? Theses would be the lines I would hope to feed/pass-through into the Amiga. I was also wondering about using a BBS-like interface to perform directory search and selection of files on the SD card.
 
A while back I made a small module to connect one of these players to the Amiga serial port and a simple program to control it.

It's really nothing special since there's no way to feed it MP3 data from the Amiga, it just reads MP3 (and I think .wav) files from a MicroSD card or a USB stick.

On my board I added a female USB port and a 3.5mm jack for the audio output, I think it's technically possible to feed that audio back into the Amiga from the "AUDI" pin of the serial port, but I chose not to do that since it's just a mono input. On the positive side since these modules require very little current you don't need an external power supply, I used a simple voltage regulator to convert 12V from the serial port to 5V and ran it this way :)

Unfortunately as far as I know there's no way to read MP3 metadata or filenames from the module to display them on the Amiga



Here's a picture of the board I made

I wouldn't really recommend it as a "serious" MP3 player but it's a cool gadget, maybe it would be more useful as a Zorro card?

Also, did you ever try FLAC files on the player? I've started migrating to that since it is lossless. Some descriptions say the player supports FLAC while others do not. I believe the ones I ordered are v3.0. I'm not clear on whether that is a manufacturer's revision or a DFPlayer hardware standard.
 
Did you look at the DAC_L and DAC_R in detail? Theses would be the lines I would hope to feed/pass-through into the Amiga.
On my board DAC_L and DAC_R are connected to the 3.5mm jack, not directly but through a capacitor and current limiting resistor. On some DFPlayer modules the amplifier chip is capable of driving headphones directly, while others use a different chip that can't and they only have line level output.

Apparently there are different models/revisions and they use slightly different chips, they don't even behave the same when you send them the same commands so it's kind of a pain to write software that works with all of them

If you're planning to test them with an Arduino try a different library if one doesn't work :)

Also, did you ever try FLAC files on the player?
I don't remember but I can test one later with a couple of different modules, maybe some support them and some don't
 
Unfortunately it looks like they only support MP3 and WAV, I tried a couple of FLAC files but they just skip over them
 
Back
Top Bottom