made input readings from the accelerometer work