Closed piwats closed 8 years ago
This is on cm-13-20160131.
I have a way to reproduce it:
Prerequisites:
turn off music player, headset not inserted.
insert headset.
Action 1: Volume Up:
logcat:
02-01 16:50:22.774 1138 1411 I vol.Events: writeEvent active_stream_changed STREAM_RING
02-01 16:50:22.776 1138 1411 I vol.Events: writeEvent key STREAM_RING 5
02-01 16:50:22.784 1138 1138 I vol.Events: writeEvent show_dialog volume_changed keyguard=false
02-01 16:50:22.922 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_VOLUME_UP, scanCode=258, metaState=0, flags=0x8, repeatCount=0, eventTime=1484501, downTime=1484341, deviceId=2, source=0x101 }
02-01 16:50:22.922 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : Not Mapped: 24
02-01 16:50:25.782 1138 1138 I vol.Events: writeEvent dismiss_dialog timeout
02-01 16:50:25.784 1138 1411 I vol.Events: writeEvent active_stream_changed UNKNOWN_STREAM_-1
Action 1 result: Volume goes up. (Telephone symbole and volume shifter are shown)
Action 2: Middle button/pause or call button:
02-01 16:53:49.922 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=256, metaState=0, flags=0x8, repeatCount=0, eventTime=1691501, downTime=1691311, deviceId=2, source=0x101 }
02-01 16:53:49.922 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : Not Mapped: 79
Action 2 result: Nothing happens.
**Action 3: Volume down:***
Pressing the volume down button results in no action in logcat. However dmesg gives this out:
[ 1644.644592] arizona 1-001a: Failed to get valid MICDET value
[ 1645.364963] arizona 1-001a: Failed to get valid MICDET value
[ 1645.694965] arizona 1-001a: Failed to get valid MICDET value
[ 1645.983800] arizona 1-001a: Failed to get valid MICDET value
[ 1646.404150] arizona 1-001a: Failed to get valid MICDET value
This is logged every time the volume down button is pressed.
Now I start the built in music player. No music is played at this moment.
Action 1: Volume Up: Music volume goes up (A note symbol with a shifter is shown)
Action 2: Pause button: nothing happens A long pressing of this button results in this in dmesg:
02-01 17:04:36.033 741 1718 I ActivityManager: START u0 {act=android.speech.action.WEB_SEARCH flg=0x10800000} from uid 1000 on display 0
Action 3: Volume down: nothing happens However a long pressing on the volume down button results in this in dmesg:
[ 2269.713889] arizona 1-001a: Button level 64 out of range
Now I let the player play a music track.
Action 1: Volume Up: works.
Action 2: pause: nothing.
Action 3: Volume Down: suddenly it starts to work. Logcat:
02-01 17:07:52.156 1138 1411 I vol.Events: writeEvent level_changed STREAM_MUSIC 4
02-01 17:07:52.161 1138 1411 I vol.Events: writeEvent active_stream_changed STREAM_MUSIC
02-01 17:07:52.163 1138 1411 I vol.Events: writeEvent key STREAM_MUSIC 4
02-01 17:07:52.174 1138 1138 I vol.Events: writeEvent show_dialog volume_changed keyguard=false
02-01 17:07:52.183 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_VOLUME_DOWN, scanCode=261, metaState=0, flags=0x8, repeatCount=0, eventTime=2533761, downTime=2533571, deviceId=2, source=0x101 }
02-01 17:07:52.184 1688 1688 D EmojiAltPhysicalKeyDetector: onKeyUp() : Not Mapped: 25
02-01 17:07:53.668 1138 1138 I vol.Events: writeEvent dismiss_dialog timeout
02-01 17:07:53.669 1138 1411 I vol.Events: writeEvent active_stream_changed UNKNOWN_STREAM_-1
Now, if I disconnect the headset and connect it again, the very same behavior comes up, that is the volume down button doesn't work, the arizona 1-001a: Failed to get valid MICDET value
error can be seen in dmesg, and if you start the steps from playing music all over you should get the idea, it repeats.
In recent builds double tap seems to work without any flaws. Thus I have to assume the problems with double tap were upstream related.
seems to be somehow fixed by upstream.
closing :)
This issue was moved to bq-dev/android_device_bq_piccolo#45
Headset controls (buttons) for volume up/down sometimes stop working.
Coincidentally, double tap stops working at the same time.
When I turn on the display by the power on button, and reconnect the headset again, all is fine and everything seems to work again.
This odd behaviour I haven't seen in CM12.
I guess that double tap and headset controls are controlled by input, so this is the way to go. I'll try to logcat/dmesg it, if possible.