added accelerometer api