Quantcast
Channel: xda-developers - Android Software and Hacking General [Developers Only]
Viewing all articles
Browse latest Browse all 3614

Hands Free Google (Voice) Search vs Voice Dialer

$
0
0
I really would like to the the regular voice search started if i have my sleeping (display off) and push the call button on my bluethooth headset.
instead i get the very stop old voice dailer.



this article states that they changed it in search 3.2 (i'm currently running search 3.4).

http://www.androidpolice.com/2014/02...ooth-headsets/

it is correct that if the device is on and the screen unlocked i get, as expected, the new voice search command input
BUT if the device is sleeping it still trigger the ****TY **** COMMAND input (and ruins my idea of heads free via headset)
(the left screenshot in the article above)

Logcat output with device turned off and pushing button on headset....

Code:

E/bt-rfcomm(14656): PORT_DataInd, p_port:0x7580a77c, p_data_co_callback is null
D/HeadsetStateMachine(14656): processVrEvent: state=1 mVoiceRecognitionStarted: false mWaitingforVoiceRecognition: false isInCall: false
I/ActivityManager(  649): START u0 {act=android.intent.action.VOICE_COMMAND flg=0x10000000 cmp=com.google.android.googlequicksearchbox/com.google.android.voicesearch.handsfree.HandsFreeActivity} from pid 14656
I/Timeline(12527): Timeline: Activity_launch_request id:com.google.android.googlequicksearchbox time:8718723
I/ActivityManager(  649): START u0 {act=android.intent.action.VOICE_COMMAND flg=0x10000000 cmp=com.google.android.googlequicksearchbox/com.google.android.voicesearch.handsfree.HandsFreeActivityLegacy} from pid 12527
D/PhoneStatusBar(  774): disable: < expand icons alerts ticker system_info back* home* RECENT clock* search >
W/IInputConnectionWrapper(12527): showStatusIcon on inactive InputConnection
I/Timeline(12527): Timeline: Activity_idle id: android.os.BinderProxy@41970ba0 time:8718822
I/Timeline(12527): Timeline: Activity_idle id: android.os.BinderProxy@41970ba0 time:8718823
I/Timeline(  649): Timeline: Activity_windows_visible id: ActivityRecord{4230fb80 u0 com.google.android.googlequicksearchbox/com.google.android.voicesearch.handsfree.HandsFreeActivityLegacy t62} time:8718842
I/PowerManagerService(  649): Waking up from sleep...
E/PowerHAL(  649): sync_thread: failed to send: No such file or directory
D/SurfaceFlinger(  198): Screen acquired, type=0 flinger=0xb7a31450
I/Timeline(12527): Timeline: Activity_idle id: android.os.BinderProxy@41970ba0 time:8718915
I/WindowManager(  649): No lock screen! windowToken=android.os.BinderProxy@4238a600
V/audio_hw_primary(  201): adev_set_parameters: enter: screen_state=on
D/audio_hw_extn(  201): audio_extn_set_anc_parameters: anc_enabled:0
V/audio_hw_primary(  201): adev_set_parameters: exit with code(-2)
I/audio_a2dp_hw(  201): adev_set_parameters: state 5
I/audio_a2dp_hw(  201): out_set_parameters: state 5
I/str_params(  201): key: 'screen_state' value: 'on'
I/AudioRouter(12527): ROUTE_NONE->ROUTE_BLUETOOTH_REQUIRED
I/MediaFocusControl(  649):  AudioFocus  requestAudioFocus() from android.media.AudioManager@419e12c0fiw@419e4228
I/AudioRouter(12527): BT required, starting SCO
V/Avrcp  (14656): New genId = 69, clearing = 1
I/BluetoothController(12527): Starting VR
D/BluetoothHeadset(12527): startVoiceRecognition()
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/HeadsetStateMachine(14656): isBluetoothVoiceDialingEnabled mRemoteBrsf: 187supported: 8
D/HeadsetStateMachine(14656): Voice recognition started successfully
D/HeadsetStateMachine(14656): Initiating audio connection for Voice Recognition
V/audio_hw_primary(  201): adev_set_parameters: enter: A2dpSuspended=true
D/audio_hw_extn(  201): audio_extn_set_anc_parameters: anc_enabled:0
V/audio_hw_primary(  201): adev_set_parameters: exit with code(-2)
I/audio_a2dp_hw(  201): adev_set_parameters: state 5
I/audio_a2dp_hw(  201): out_set_parameters: state 5
I/str_params(  201): key: 'A2dpSuspended' value: 'true'
I/audio_a2dp_hw(  201): check_a2dp_stream_started: state 5
W/bt-btm  (14656): BTM Remote does not support 3-EDR eSCO
D/BluetoothManager(  948): mReceiver: HEADSET_AUDIO_STATE_CHANGED_ACTION
D/BluetoothManager(  948): ==> new state: 11
D/AudioRouter(  948): onBluetoothIndicationChange false
D/AudioRouter(  948): calculateModeFromCurrentState EARPIECE
D/BluetoothManager(  948): isBluetoothAvailable()...
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothManager(  948): state = 2for headset: B4:52:7E:FA:DF:29
D/BluetoothManager(  948):  ==> true
D/SmartKey Service(12553): isPlaying false
D/SmartKey Service(12553): state = IDDLE
I/GCoreUlr( 1263): Starting service, intent=Intent { act=com.google.android.location.reporting.ACTION_LOCATION_STATUS cmp=com.google.android.gms/com.google.android.location.reporting.service.DispatchingService (has extras) }, extras=Bundle[{status=LocationStatus[cell status: STATUS_SUCCESSFUL, wifi status: STATUS_TIMED_OUT_ON_SCAN, elapsed realtime ns: 24652606874646]}]
D/SmartKey Service(12553): isPlaying false
D/SmartKey Service(12553): state = IDDLE
D/GCoreUlr( 1263): Throttling analytics event: entity, ApiMetadataStore:save_attempt, 1
D/GCoreUlr( 1263): Throttling analytics event: entity, ApiMetadataStore:saved, 1
D/HeadsetStateMachine(14656): Set sample rate: 8000
V/audio_hw_primary(  201): adev_set_parameters: enter: bt_samplerate=8000
D/audio_hw_extn(  201): audio_extn_set_anc_parameters: anc_enabled:0
V/audio_hw_primary(  201): adev_set_parameters: exit with code(-2)
I/audio_a2dp_hw(  201): adev_set_parameters: state 4
I/audio_a2dp_hw(  201): out_set_parameters: state 4
I/str_params(  201): key: 'bt_samplerate' value: '8000'
D/BluetoothManager(  948): mReceiver: HEADSET_AUDIO_STATE_CHANGED_ACTION
D/BluetoothManager(  948): ==> new state: 12
D/AudioRouter(  948): onBluetoothIndicationChange false
D/AudioRouter(  948): calculateModeFromCurrentState EARPIECE
D/BluetoothManager(  948): isBluetoothAvailable()...
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothManager(  948): state = 2for headset: B4:52:7E:FA:DF:29
D/BluetoothManager(  948):  ==> true
D/AudioFlinger(  201): start(4097), calling pid 15786 session 395
D/AudioFlinger(  201): ? => ACTIVE (4097) on thread 0xb8c4d728
D/audio_hw_primary(  201): out_set_parameters: enter: usecase(1: low-latency-playback) kvpairs: routing=32
V/audio_hw_primary(  201): out_set_parameters: exit: code(0)
V/audio_hw_primary(  201): start_output_stream: enter: usecase(1: low-latency-playback) devices(0x20)
D/audio_hw_primary(  201): select_devices: out_snd_device(10: bt-sco-headset) in_snd_device(0: )
V/audio_hw_primary(  201): enable_snd_device: snd_device(10: bt-sco-headset)
V/audio_hw_primary(  201): enable_audio_route: enter: usecase(1)
V/audio_hw_primary(  201): enable_audio_route: apply mixer path: low-latency-playback bt-sco
V/audio_hw_primary(  201): enable_audio_route: exit
V/audio_hw_primary(  201): start_output_stream: Opening PCM device card_id(0) device_id(14)
V/audio_hw_primary(  201): start_output_stream: exit

device on and unlocked is like this....

Code:

D/HeadsetStateMachine(14656): processVrEvent: state=1 mVoiceRecognitionStarted: false mWaitingforVoiceRecognition: false isInCall: false
I/ActivityManager(  649): START u0 {act=android.intent.action.VOICE_COMMAND flg=0x10000000 cmp=com.google.android.googlequicksearchbox/com.google.android.voicesearch.handsfree.HandsFreeActivity} from pid 14656
I/HotwordWorker(12527): #onHotwordDetectorStopped(false)
I/MicrophoneInputStream(12527): mic_close ela@418be178
V/audio_hw_primary(  201): in_standby: enter
I/ActivityManager(  649): START u0 {act=android.speech.action.WEB_SEARCH flg=0x34000000 pkg=com.google.android.googlequicksearchbox cmp=com.google.android.googlequicksearchbox/.SearchActivity (has extras)} from pid 12527
V/audio_hw_primary(  201): stop_input_stream: enter: usecase(4: audio-record)
V/audio_hw_primary(  201): disable_audio_route: enter: usecase(4)
V/audio_hw_primary(  201): disable_audio_route: reset mixer path: audio-record
V/audio_hw_primary(  201): disable_audio_route: exit
V/audio_hw_primary(  201): disable_snd_device: snd_device(37: voice-rec-mic) refcnt=0
V/audio_hw_primary(  201): stop_input_stream: exit: status(0)
V/audio_hw_primary(  201): in_standby: exit:  status(0)
I/Timeline(12527): Timeline: Activity_launch_request id:com.google.android.googlequicksearchbox time:9488919
V/audio_hw_primary(  201): adev_close_input_stream
V/audio_hw_primary(  201): in_standby: enter
V/audio_hw_primary(  201): in_standby: exit:  status(0)
I/ActivityManager(  649): START u0 {act=android.intent.action.MAIN flg=0x34000000 pkg=com.google.android.googlequicksearchbox cmp=com.google.android.googlequicksearchbox/com.google.android.velvet.ui.VelvetActivity (has extras)} from pid 12527
I/HotwordRecognitionRnr(12527): Stopping hotword detection.
I/HotwordRecognitionRnr(12527): Hotword detection finished
I/Velvet.Presenter(12527): setupFromIntent(Intent { act=android.intent.action.MAIN flg=0x34400000 pkg=com.google.android.googlequicksearchbox cmp=com.google.android.googlequicksearchbox/com.google.android.velvet.ui.VelvetActivity (has extras) })
I/AudioRouter(12527): ROUTE_NONE->ROUTE_BLUETOOTH_REQUIRED
I/MediaFocusControl(  649):  AudioFocus  requestAudioFocus() from android.media.AudioManager@419e12c0fiw@419e4228
I/AudioRouter(12527): BT required, starting SCO
V/Avrcp  (14656): New genId = 73, clearing = 1
I/BluetoothController(12527): Starting VR
D/BluetoothHeadset(12527): startVoiceRecognition()
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/HeadsetStateMachine(14656): isBluetoothVoiceDialingEnabled mRemoteBrsf: 187supported: 8
D/HeadsetStateMachine(14656): Voice recognition started successfully
D/HeadsetStateMachine(14656): Initiating audio connection for Voice Recognition
V/audio_hw_primary(  201): adev_set_parameters: enter: A2dpSuspended=true
D/audio_hw_extn(  201): audio_extn_set_anc_parameters: anc_enabled:0
V/audio_hw_primary(  201): adev_set_parameters: exit with code(-2)
I/audio_a2dp_hw(  201): adev_set_parameters: state 5
I/audio_a2dp_hw(  201): out_set_parameters: state 5
I/str_params(  201): key: 'A2dpSuspended' value: 'true'
I/audio_a2dp_hw(  201): check_a2dp_stream_started: state 5
W/bt-btm  (14656): BTM Remote does not support 3-EDR eSCO
D/BluetoothManager(  948): mReceiver: HEADSET_AUDIO_STATE_CHANGED_ACTION
D/BluetoothManager(  948): ==> new state: 11
D/AudioRouter(  948): onBluetoothIndicationChange false
D/AudioRouter(  948): calculateModeFromCurrentState EARPIECE
D/BluetoothManager(  948): isBluetoothAvailable()...
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
I/MicrophoneInputStream(12527): mic_starting ela@41b8bdf8
V/Zygote  (19412): Switching descriptor 33 to /dev/null
V/Zygote  (19412): Switching descriptor 10 to /dev/null
I/ActivityManager(  649): Start proc android.process.acore for content provider com.android.providers.contacts/.ContactsProvider2: pid=19412 uid=10003 gids={50003, 3003, 1028, 1015}
D/BluetoothManager(  948): state = 2for headset: B4:52:7E:FA:DF:29
D/BluetoothManager(  948):  ==> true
I/Timeline(  649): Timeline: Activity_windows_visible id: ActivityRecord{420ba150 u0 com.google.android.googlequicksearchbox/com.google.android.velvet.ui.VelvetActivity t58} time:9489060
D/SmartKey Service(12553): isPlaying false
D/SmartKey Service(12553): state = IDDLE
W/GLSUser ( 1233): GoogleAccountDataService.getToken()
D/ActivityThread(19412): handleBindApplication:android.process.acore
D/ActivityThread(19412): setTargetHeapUtilization:0.75
D/ActivityThread(19412): setTargetHeapMinFree:524288
I/Timeline(12527): Timeline: Activity_idle id: android.os.BinderProxy@4193cb28 time:9489151
D/HeadsetStateMachine(14656): Set sample rate: 8000
V/audio_hw_primary(  201): adev_set_parameters: enter: bt_samplerate=8000
D/audio_hw_extn(  201): audio_extn_set_anc_parameters: anc_enabled:0
V/audio_hw_primary(  201): adev_set_parameters: exit with code(-2)
I/audio_a2dp_hw(  201): adev_set_parameters: state 4
I/audio_a2dp_hw(  201): out_set_parameters: state 4
I/str_params(  201): key: 'bt_samplerate' value: '8000'
D/BluetoothManager(  948): mReceiver: HEADSET_AUDIO_STATE_CHANGED_ACTION
D/BluetoothManager(  948): ==> new state: 12
D/AudioRouter(  948): onBluetoothIndicationChange false
D/AudioRouter(  948): calculateModeFromCurrentState EARPIECE
D/BluetoothManager(  948): isBluetoothAvailable()...
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothAdapterService(1103761344)(14656): getState(): mAdapterProperties: com.android.bluetooth.btservice.AdapterProperties@41ca1508
D/BluetoothManager(  948): state = 2for headset: B4:52:7E:FA:DF:29
D/BluetoothManager(  948):  ==> true



if the device is locked he falls back to the
com.google.android.googlequicksearchbox/com.google.android.voicesearch.handsfree.HandsFree ActivityLegacy
act****TITY

any help ?!


Running CM 11-20140504-SNAPSHOT-M6-Mako (Nexus 4... but i'd say you figured that out yourself by now)

Viewing all articles
Browse latest Browse all 3614

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>