Still won't work

Dependencies:   mbed wave_player 4DGL-uLCD-SE MMA8452

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers hardware.h Source File

hardware.h

00001 #ifndef HARDWARE_H
00002 #define HARDWARE_H
00003 
00004 /**
00005  * Structure that represents all the inputs to the game.
00006  * If additional hardware is added, new elements should be added to this struct.
00007  */
00008 struct GameInputs {
00009     int b1, b2, b3;     // Button presses
00010     double ax, ay, az;  // Accelerometer readings
00011 };
00012 
00013 /**
00014  * Initialize all the hardware.
00015  */
00016 int hardware_init();
00017 
00018 /**
00019  * Read all the user inputs. 
00020  * This is all input hardware interaction should happen.
00021  * Returns a GameInputs struct that has all the inputs recorded.
00022  * This GameInputs is used elsewhere to compute the game update.
00023  */
00024 GameInputs read_inputs();
00025 
00026 #endif // HARDWARE_H