Created
October 20, 2015 16:22
-
-
Save jazzyjackson/8996d6519b7cd0cbf965 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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