Code: Select all
#include <VoiceShield.h> // includes the library necessary to use the voice shield
VoiceShield vs(80); // creates an instance of the voiceshield class with the name vs divided into 80 sound bytes *note* 240s are available, so the sound bytes are (240s/80) = 3s each.
void setup() // The program wouldn’t compile without a void setup…so here’s my empty void setup….
{
}
void loop(){ // The loop that tests all of my sounds. I’ve left the clips that refused to work here as vestigial functions. Oh well.
ahahaha();
//preparing(); //doesn’t work (playings the next clip as well)
dispensing();
goodbye();
hello();
hello2();
//hellofriend(); //doesn’t work (plays the next clip as well)
isanyonethere();
//iseeyou(); // doesn’t work (just won’t play)
pleaseputmedown();
putmedown();
pleasestop();
thereyouare();
unknownerror();
whoa();
shuttingdown();
}
// All of the void functions that I can call to get certain sounds to play.
void ahahaha (){
vs.ISDPLAY_to_EOM(0);
}
void preparing (){
vs.ISDPLAY_to_EOM(1);
}
void dispensing (){
vs.ISDPLAY_to_EOM(2);
}
void goodbye (){
vs.ISDPLAY_to_EOM(3);
}
void hello (){
vs.ISDPLAY_to_EOM(4);
}
void hello2 (){
vs.ISDPLAY_to_EOM(5);
}
void hellofriend (){
vs.ISDPLAY_to_EOM(6);
}
void isanyonethere (){
vs.ISDPLAY_to_EOM(7);
}
void iseeyou (){
vs.ISDPLAY_to_EOM(8);
}
void pleaseputmedown (){
vs.ISDPLAY_to_EOM(9);
}
void putmedown (){
vs.ISDPLAY_to_EOM(10);
}
void pleasestop (){
vs.ISDPLAY_to_EOM(11);
}
void thereyouare (){
vs.ISDPLAY_to_EOM(12);
}
void unknownerror (){
vs.ISDPLAY_to_EOM(13);
}
void whoa (){
vs.ISDPLAY_to_EOM(14);
}
void shuttingdown (){
vs.ISDPLAY_to_EOM(15);
}