How do I use the accelerometer to get linear acceleration on Android? All of the solutions I have seen use the gyroscope to get the current orientation that the device is being held in. I want to use the accelerometer, which measures the force the phone is experiencing due to the user and gravity. My device (Moto G 2nd Generation) has a linear accelerometer, and the Android SDK mentions this exact sensor, so why can’t Unity use it? Or is there a variable I can read in Input that I haven’t tried?
I tried all of the functions in Input, but the acceleration points at a constant speed backwards and downwards, regardless of the device orientation.