FIXED ISSUE - Trying to fix the BT calling issue

Michelsup

Senior Member
Jan 25, 2017
97
136
43
After many cul-de-sac due to my lack of brain power, I think I might got an hint on the issue. I might be completely wrong so please just tell me what you think.

When you do a call with BT the kmseg is like
<6>[12281.280844] taiko_codec taiko_codec: +[ES325]=es325_slim_hw_params()
<6>[12281.280850] taiko_codec taiko_codec: =[ES325]=es325_slim_hw_params(): stream_name = SLIM_PORT-1 Playback id = 0
<6>[12281.280857] es325_gen_slim es325-gen: =[ES325]=es325_switch_route() switch current es325_internal_route = 26 to new route = 4
<6>[12281.280863] es325_gen_slim es325-gen: =[ES325]=es325_switch_route(): final es325_internal_route_num = 4
<6>[12281.282034] taiko_codec taiko_codec: -[ES325]=es325_slim_hw_params()
<6>[12281.282543] SLIMBUS_0_TX: dpcm: open BE SLIMBUS_0_TX
<6>[12281.282553] es325_gen_slim es325-gen: +[ES325]=es325_wrapper_wakeup()
<6>[12281.282558] es325_gen_slim es325-gen: -[ES325]=es325_wrapper_wakeup()
<7>[12281.282564] msm8974_snd_startup(): substream = subdevice #0 stream = 1
<6>[12281.282569] Circuit-Switch Voice: dpcm: open FE Circuit-Switch Voice
<7>[12281.282613] msm_slim_0_tx_be_hw_params_fixup()
<6>[12281.282618] msm_slim_0_tx_be_hw_params_fixup: format = 2, rate = 48000, channels = 2
<7>[12281.282625] msm_snd_hw_params: taiko_tx1_tx_dai_id_1_ch=0
<6>[12281.282630] msm_snd_hw_params: msm_slim_0_tx_ch(2)user_set_tx_ch(2)tx_ch_cnt(2)
<6>[12281.282638] taiko_codec taiko_codec: taiko_es325_hw_params: dai_name = taiko_tx1 DAI-ID 1 rate 48000 num_ch 2
<6>[12281.282644] taiko_hw_params: dai_name = taiko_tx1 DAI-ID 1 rate 48000 num_ch 2
<6>[12281.282653] taiko_codec taiko_codec: +[ES325]=es325_slim_hw_params()
<6>[12281.282659] taiko_codec taiko_codec: =[ES325]=es325_slim_hw_params(): stream_name = (null) id = 1
<6>[12281.282665] es325_gen_slim es325-gen: =[ES325]=es325_switch_route() switch current es325_internal_route = 4 to new route = 4
<6>[12281.282671] taiko_codec taiko_codec: -[ES325]=es325_slim_hw_params()
>5]0E3514[]>>C hne apn
6[28.001 eoesi_eiec:<>121356]c_n ,hh0 6c_[]0 rh22smlsbt 6
<6>[12281.358639] msm_mainmi_a_vn vn , N_O_AM1<6>[12281.370071] es325_gen_slim es325-gen: =[ES325]=es325_remote_cfg_slim_tx: MDM<<<-[156][0]ES325[134][135]<<<-WCD channel mapping
<6>[12281.399675] es325_gen_slim es325-gen: =[ES325]=es325_set_VEQ_max_gain: volume=0, wakeup_cnt =2
<6>[12281.402314] es325_gen_slim es325-gen: =[ES325]=es325_set_VEQ_max_gain: volume=2, wakeup_cnt =2
<6>[12281.630635] Governor: enter mode 0x3
<6>[12281.913967] Governor: enter mode 0x1
<6>[12281.914804] es325_gen_slim es325-gen: =[ES325]=es325_set_VEQ_max_gain: volume=0, wakeup_cnt =2
<6>[12281.918024] SLIMBUS_0_TX: dpcm: close BE Circuit-Switch Voice
<7>[12281.925175] msm8974_snd_shudown(): substream = subdevice #0 stream = 1
<6>[12281.927660] es325_gen_slim es325-gen: =[ES325]=es325_remote_close_slim_tx() dai_id = 1, ch_tot = 1
ainmic_bias_event : Event 8, SND_SOC_DAPM:0
<6>[12281.943446] SLIMBUS_0_RX: dpcm: close BE Circuit-Switch Voice
So es325 is routing to route 4, which is

es325_internal_route_1mic_handset, /* [4]: 1-mic Handset NB (1-mic CT)(NS off) */
per
./kernel/samsung/msm8974/sound/soc/codecs/es325.c
I beleive this is wrong, as instead it should be something like route 21

es325_internal_route_1mic_headset_WB, /* [21]: 1-mic Headset WB (SW bypss) */
In fact the ES325 chip is not properly loaded to start with.

So the question is: shall we use ES325 or not ? (I think we should)

If the answer is positive, it would worth a try to load it properly.

What do you think?
 

rayman95

Senior Member
Jan 14, 2009
6,005
3,749
253
62
monaco
I can't mess too much with this phone, as it's "not mine".
so, someone with a BT headset should install a LA14.1 version, and made a call with it and get a kmseg log, to see if you're right or no????is it possible to get the log after the call and deconnected from BT device, like this I can maybe use the BT in my car...
 

Michelsup

Senior Member
Jan 25, 2017
97
136
43
so, someone with a BT headset should install a LA14.1 version, and made a call with it and get a kmseg log, to see if you're right or no????is it possible to get the log after the call and deconnected from BT device, like this I can maybe use the BT in my car...
You should see as well if the FW of ES325 is loaded at boot. I managed to get it right once but I ****ed up and I lost the right changes, what a noob! I can't figure out how to reimplement this manual hack.
 

rayman95

Senior Member
Jan 14, 2009
6,005
3,749
253
62
monaco
You should see as well if the FW of ES325 is loaded at boot. I managed to get it right once but I ****ed up and I lost the right changes, what a noob! I can't figure out how to reimplement this manual hack.
if weather is bad tomorrow, i will backup my 15.1 microG install and flash LA14.1 microG and try to see if this FW loads correctly...
 

Michelsup

Senior Member
Jan 25, 2017
97
136
43
es325_gen_slim es325-gen: =[ES325]=es325_set_VEQ_max_gain: volume=0, wakeup_cnt =2
If the wakeup_cnt =2 it means the firmware is loaded, so another cul-de-sac. Sorry to bug you with my errors. But...

If you do a call with the handset, you get

es325_gen_slim es325-gen: =[ES325]=es325_switch_route(): final es325_internal_route_num = 4
in par with

es325_internal_route_1mic_handset, /* [4]: 1-mic Handset NB (1-mic CT)(NS off) */
then when you switch to the speaker you get

es325_gen_slim es325-gen: =[ES325]=es325_switch_route() switch current es325_internal_route = 4 to new route = 3
in par with

es325_internal_route_1mic_speaker, /* [3]: 1-mic Speaker NB (1-mic FT)(NS off)(SW bypss) */
With BT on, you get

es325_gen_slim es325-gen: =[ES325]=es325_switch_route() switch current es325_internal_route = 4 to new route = 4
instead of

es325_internal_route_1mic_headset_WB, /* [21]: 1-mic Headset WB (SW bypss) */
So I don't know, as usual... ;)
 
  • Like
Reactions: Marvino.

rayman95

Senior Member
Jan 14, 2009
6,005
3,749
253
62
monaco
Yes please, the kmsg where you do a call with BT, the part with the es325 thingy.

and maybe an excerpt with the handset, as well. Thank you.
I don't have headset...the only BT device is in my car a radio with BT, but i can't get log directly in the car, so is it worth to move to LA14.1 and go in my car, made a call and get a log after????
 
  • Like
Reactions: Marvino.

cssr

Senior Member
Jun 4, 2013
317
224
0
Zachary
@Michelsup This is very different from rayman95's dmesg.txt. Pulled from 14.1. I just got a headset to test with. kmsg just gives me a lot of useless garbage ( samsung_dsi_panel_event_handler : unknown event ) repeatedly , maybe doing something wrong.
 

Attachments

Last edited: