Added sensor smoothing and orientation support

Sensor values for compass are now smoothed with a low-pass filter.

App now accounts for users placing phone in their pocket either normally
or upside-down.