Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#include <Arduino.h>
#include <SoftwareSerial.h>
#include <JQ6500_Serial.h>
JQ6500_Serial mp3(2,3);
void setup(){
mp3.begin(9600);
mp3.reset();
pinMode(A0, INPUT_PULLUP);
pinMode(6, OUTPUT);
digitalWrite(6, LOW);
}
void loop(){
if(analogRead(A0) < 500){
mp3.play();
delay(1000);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment