DFRobot
Published

Jumping Noisy Frog

Imagine if you were born in the 80’s and 90’s and Arduino existed. What would you make?

BeginnerFull instructions provided1,002
Jumping Noisy Frog

Things used in this project

Hardware components

DFRobot Bluno Beetle controller
It not only supports USB programming, but also wireless programming method. With the V shaped gilded I/O interface, it is convenient to screw conductor wire on it, which could a good choice in the wearable market.
×1
DFRobot Analog Sound Sensor ( compatiable with Arduino)
×1
DFRobot DFPlayer - A Mini MP3 Player
×1
3.7V Battery
×1

Story

Read more

Schematics

Jumping noisy Frog circuit diagram

Code

Untitled file

C/C++
#include

#define SensorLED 13

int state = 0;

void setup()

{

pinMode(SensorLED, OUTPUT);

pinMode(SensorINPUT, INPUT);

pinMode(A0, OUTPUT);

pinMode(A1, inPUT);

Serial.begin (9600);

mp3_set_serial (Serial); //set Serial for DFPlayer-mini

mp3 module mp3_set_volume (50);

}

void loop()

{

int state = analogRead(A1);

Serial.println(state);

// state=0;

if (state > 20)

{

// Serial.println(state);

analogWrite(A0, 180);

mp3_next ();

delay(4000);

mp3_stop ();

analogWrite(A0, 0);

delay(2000);

}

else

{

analogWrite(A0, 0);

mp3_stop ();

delay(500);

}

}

Credits

DFRobot
67 projects • 158 followers
Empowering Creation for Future Innovators

Comments