Many smartphones and tables contain an accelerometer to determine which way the device is facing. This is how they can automatically rotate the screen and dim the screen when you set the phone down. You get to make something similar!
Use an acceleromoter to determine when your project is facing up with no other motion (e.g. shaking or tilting). When this condition is met, turn on an LED. Otherwise, turn off the LED.
Hint: If you are using the simulator, the project is always facing "up." You'll only be able to test the condition of shaking or not shaking the accelerometer.