top of page
Search
  • Writer's pictureIfrim Ciprian

DFPlayer Issues and Audio Playback

Updated: May 20, 2022

Now that the audio files have been created, and the I2C protocol between the Nicla Sense and Xiao Sense has been implemented, the next objective was to get the correct audio to play when it was necessary.


However, I immediately run into an issue:

The issue is that the files are playing sometimes randomly, rather than the file I want.


Another issue was a slight buzzing when the audio file is being played:



In order to fix the slight buzzing, I made sure of 2 things:

  1. There is a 1kohm resistor between the TX and RX of the DFPlayer and Nicla Sense ME

  2. The battery has to be higher than 3.25 volts.


As for the files playing randomly, it seems that if there is a large amount of files present, the DFPlayer starts having issues, even thought they advertise it as a module capable of 150 000 files being present on the SD CARD.


I have tried 4GB, 8GB, 32GB cards, different speeds, FAT, FAT32 and EXFAT formats.

I have tried with files being wav or mp3, of different sample rates, different kbits quality.

Nothing worked.


Then I checked the UART communication and the BUSY PIN to see if the voltage is higher than 3.3v, which is the level at which the Nicla Sense ME works at.

Although the DFPlayer Mini is a 3-6v module, its logic is 3.3v, so there should be no issue.


So here are some images with my testing:

The DFPlayer's high represents 3.34 volts, meanwhile the low is 0.04 volts. So it seems there is a leak of 0.04 volts, but this was not what was causing the issues.


So, thanks to the following Java application: https://github.com/jonnieZG/SDCardRecorder

I was able to just copy each file individually from the folders, in order to the SD card, and name them from 0001 to last.


I also saw that the best files are wav, 16bit at 44100mhz. So took the files that were already 16bit wav, and changed them from 48khz to 44.1khz for the best performance.


This fixed the issue, however, it took a long time to diagnose.

Here is the system working on a breadboard:


And then moved over to the Nicla Sense ME:


Here is some phrases for a full output:


And here is the system output based on the voice command received through I2C:


3 views0 comments

Recent Posts

See All
bottom of page