This is the Mexican Standoff prototype made by Francisco Martin and Andrew Smith. Please refer to the following link for instructions on hardware hookup: https://developer.mbed.org/users/fomartin/notebook/mexican-standoff-reaction-game/
Dependencies: SDFileSystem mbed-rtos mbed wave_player 4DGL-uLCD-SE PinDetect
music.h
00001 #include "PinDetect.h" 00002 #include "SDFileSystem.h" 00003 #include "wave_player.h" 00004 #include "rtos.h" 00005 00006 class Music 00007 { 00008 private: 00009 wave_player *speaker; 00010 Thread *main_music_thread; 00011 00012 public: 00013 Music(wave_player &speaker_arg); 00014 00015 void playMainMusic(); //starts thread to play main music 00016 void stopMainMusic(); //ends thread to play main music 00017 00018 //add other audio clip methods here 00019 /* 00020 * 00021 * 00022 */ 00023 00024 protected: 00025 static void thread_helper(const void *args); 00026 void main_music(); //actually plays the main music on loop 00027 };
Generated on Fri Jul 22 2022 05:53:26 by 1.7.2