Arduino nano and MP3 player module

Hi,
I want to connect mp3 player module to Arduino nano. So, there are no buttons or anything like that, I want it to play music directly when it is connected to some sort of power. (This is a part of a bigger project, but for now I just need to make it play one song).
But but bu, for some reason it does not work. It prints "Connecting to DFPlayer Mini failed!", but everything is connected as it should be. So if anyone knows what is wrong?
I have connected:

  1. Both MP3 players GNDs to one GND of an Arduino
  2. VCC to 5V
  3. TX to pin 11, RX to pin 10
  4. and ofc speaker to spk_1 and spk_2

Here is the code:

#include "SoftwareSerial.h"
#include "DFRobotDFPlayerMini.h"

static const uint8_t PIN_MP3_TX = 10;
static const uint8_t PIN_MP3_RX = 11;
SoftwareSerial softwareSerial(PIN_MP3_RX, PIN_MP3_TX);

DFRobotDFPlayerMini player;

void setup() {
Serial.begin(9600);
softwareSerial.begin(9600);
if (player.begin(softwareSerial)) {
Serial.println("OK");
player.volume(30);
player.play(1);
} else {
Serial.println("Connecting to DFPlayer Mini failed!");
}
}

void loop() {
}

3 posts were merged into an existing topic: Failed connecting Arduino nano to MP3 player module