Fixing Screen Rotation Problem after 5.0 upgrade

Geryw

New member
Mar 23, 2017
1
0
0
I have same no rotation and no gyroscope on my AND my wife's S5 all of a sudden. Interesting, her Galaxy Tab S2 also stopped rotating too. It also has Android 6.0.1 software. Samsung seems to have a major software problem.
 

theclockwork

New member
Apr 13, 2017
1
0
0
I am not a member here, but I have this same issue and have been researching everyone else's progress and it sounds like you guys are hot on the trail here. I might have a lead for you, I found a Tread on another forum, and they think it has to do with the google maps update that came with Marshmallow, and their internal rotation programming for the Map App which runs in the background. I am not a phone guy but you folks who are digging down might be able to make heads or tails of it.
 

Don Carnage

Senior Member
Mar 23, 2013
107
336
103
I am not a member here, but I have this same issue and have been researching everyone else's progress and it sounds like you guys are hot on the trail here. I might have a lead for you, I found a Tread on another forum, and they think it has to do with the google maps update that came with Marshmallow, and their internal rotation programming for the Map App which runs in the background. I am not a phone guy but you folks who are digging down might be able to make heads or tails of it.
Could you provide a link to this? It would be an interesting read.
 

Ammarti86

New member
Aug 15, 2016
4
0
0
After digging for a while I found different events that are fired in the log. As long as the gyro is still working, there will be this log lines if you change screen orientation:

03-20 23:33:32.117 364-572/? D/Sensorhubs: readContextData: 1, 1, 7, -1
03-20 23:33:32.117 875-1283/? D/SensorHubManager: onGetSensorHubDataLocked: library(4) = 1, 1, 7, -1
03-20 23:33:32.127 875-1282/? D/CAE: onGetSensorHubData(SensorHubParserProvider.java:92) - onGetSensorHubData Event [event buffer len :4], AP_WAKEUP
03-20 23:33:32.127 875-1282/? I/CAE: parse(SensorHubParserProvider.java:188) - buffer size = 4
03-20 23:33:32.127 875-1282/? I/CAE: parse(SensorHubParserProvider.java:199) - 1, 1, 7, -1,
03-20 23:33:32.127 875-1282/? D/CAE: display(ContextProvider.java:375) - ================= AUTO_ROTATION =================
03-20 23:33:32.127 875-1282/? I/CAE: display(ContextProvider.java:391) - Angle=[-1]
03-20 23:33:32.127 875-1286/? D/SContextService: updateSContext() : event = Auto Rotation
03-20 23:33:32.127 875-875/? V/WindowOrientationListener: OrientationSensorJudge.onSContextChanged, Rotation: -1


Then there will be the bad guy which immediately stops the release of the event above:

03-20 23:35:12.957 364-572/? D/Sensorhubs: readEvents: 2, 1, -43
03-20 23:35:12.957 875-1283/? D/SensorHubManager: onGetSensorHubDataLocked: library(3) = 2, 1, -43
03-20 23:35:12.957 875-1282/? D/CAE: onGetSensorHubData(SensorHubParserProvider.java:92) - onGetSensorHubData Event [event buffer len :3], AP_WAKEUP
03-20 23:35:12.957 875-1282/? I/CAE: parse(SensorHubParserProvider.java:188) - buffer size = 3
03-20 23:35:12.957 875-1282/? I/CAE: parse(SensorHubParserProvider.java:199) - 2, 1, -43,
03-20 23:35:12.957 875-1282/? D/CAE: parse(PowerResetNotiParser.java:96) - ================= Noti (Power) =================
03-20 23:35:12.957 875-1282/? I/CAE: parse(PowerResetNotiParser.java:97) - Noti Type : SensorHub Reset
03-20 23:35:12.967 875-1282/? V/CAE: enable(PedometerRunner.java:996)
03-20 23:35:12.967 875-1282/? I/CAE: sendCmdToSensorHub(SensorHubCommManager.java:162) - -79, 3, -70, 90, 1,
03-20 23:35:12.967 875-1282/? D/SensorHubManager: SendSensorHubData: send data = -79, 3, -70, 90, 1
03-20 23:35:12.967 364-364/? D/Sensorhubs: sendContextData: -79, 3, -70, 90, 1
03-20 23:35:12.977 875-1282/? V/CAE: enable(ActivityTrackerBatchRunner.java:428)
03-20 23:35:12.977 875-1282/? I/CAE: sendCmdToSensorHub(SensorHubCommManager.java:162) - -79, 26, 2, 0, 0, 0, 0, 0, 4, -80, 22, 35, 12,
03-20 23:35:12.977 875-1282/? D/SensorHubManager: SendSensorHubData: send data = -79, 26, 2, 0, 0, 0, 0, 0, 4, -80, 22, 35, 12
03-20 23:35:12.977 364-573/? D/Sensorhubs: sendContextData: -79, 26, 2, 0, 0, 0, 0, 0, 4, -80, 22, 35, 12
03-20 23:35:12.987 875-1282/? V/CAE: enable(AutoRotationRunner.java:158)
03-20 23:35:12.987 875-1282/? I/CAE: sendCmdToSensorHub(SensorHubCommManager.java:162) - -79, 7, 0, 0,
03-20 23:35:12.987 875-1282/? D/SensorHubManager: SendSensorHubData: send data = -79, 7, 0, 0
03-20 23:35:12.987 364-1284/? D/Sensorhubs: sendContextData: -79, 7, 0, 0


After this, the gyro is dead, no orientation changes anymore.

I tried this several times, for the last try I even searched the log for 2, 1, -43 then pulled the plug when the search bar got green and voila the gyro was done when I checked the phone. This is definitely the reason.

Now I need to find out what exactly is happening there which will be less pretty. Any help appreciated.
From the log, it seems like the SensorHub, or at least the Communication Manager portion, is having trouble with the ContextData. Would it be possible to run the debugger again in different orientations to get a base for comparison?

Might be worth looking into java:158 and java:162 to see if there are protocol boundaries. Without unpacking the source package, I'm only theorizing.
 
Jun 18, 2011
7
0
0
Fixed it

Based on what theclockwork said, I tried to uninstall Google Maps but you can only turn it off in marshmallow not uninstall it.

So I turned it off and did a standard restart. Now my screen rotation works perfectly even after turning the screen off with the power button for several minutes. This has been a persistent issues for my phone for about a year now with no solutions. Now it works.

I will update if the non rotation happens again. This definitely seems to be a software issue with Google Maps.
 

walkingTarget

New member
Oct 8, 2011
3
0
0
Portland, OR
I can confirm that removing Google Maps restored rotation for me as well... for about 15 seconds.

Overjoyed to have rotation again, I pulled out a VR viewer and inserted the phone. Then the phone buzzed and rotation stopped. Also, curiously, Google Maps reappeared. I disabled it again and reset the phone to no avail. :crying:
 

OldMage

Member
Oct 15, 2010
15
0
0
PDX/Vanc,WA area
Glad to find this, will try it on my T-Mobile SM-G900T which is giving me fits over rotation. It's recently been nuked & flashed back to T-Mo's stock PE1 because Wi-Fi calling is missing after PE1. It is rooted w/ Magisk and running current TWRP recovery.

Odd thing is, I have NO trouble w/ my bone-stock, work-issued G900P (Sprint) running QD1.
 
Our Apps
Get our official app!
The best way to access XDA on your phone
Nav Gestures
Add swipe gestures to any Android
One Handed Mode
Eases uses one hand with your phone