- Home /
Unity accelerometer and screen/device orientation issue
I'm using Input.acceleration
in "landscape left" orientation. I need it to act the same in "landscape right" orientation.
When I'm testing via the Unity Remote 4, all axes get "converted" by the device orientation automatically and it acts as it should, no matter the orientation.
The problems arise when I create the Android build: If I run the game in "landscape left", axes are working fine. When I flip the running app in "landscape right", the X axis gets inverted, and Y goes from - to +. Z axis is ok. Everything also works if i run the app while in "landscape right", but same happens when I turn the device to "landscape left"
I recently installed Unity 5.1.2 and axis conversion thing worked in 4.6!
Does anyone have a clue if it's a bug, or it's standard "new" behaviour? Does anyone have a workaround for this?
Thanks!
So far "quick fix" of changing orientation while running android app: - while in app change to another orientation to the one app started in - press menu key to return to main android page - long press menu key to display list of appssee the applications list, select your running application - accelerometer axis recalculated :)
I'm working on a checking mechanism in code, I'll share it when I'm done.
Until the bug gets fixed I created a workaround, see this forum post:
Your answer
![](https://koobas.hobune.stream/wayback/20220611235303im_/https://answers.unity.com/themes/thub/images/avi.jpg)