Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
#include <PCM.h>
const unsigned char ghost[] PROGMEM = {
131, 128, 128, 124, 124, 124, //your sound here
};
void setup(){
pinMode(A0, INPUT_PULLUP);
}
void loop()
{
if(digitalRead(A0) == LOW){
startPlayback(ghost, sizeof(ghost));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.