[Xiaomi Redmi Note 3 Themes, Apps, and Mods] AgentBuBu:
DESCRIPTION

This mode sets the earpiece as a secondary speaker, making media playing sound better.

This mod makes the sound stereo, the earpiece will act as left, whereas the main speaker will act as right. If you don't believe me, test it on youtube.

INSTALLATION

First of all, i'm not responsible for any bricked devices.

Due to diversity of ROMs and mixer_paths files, i decided to snip the installation part into a single method.

YOU NEED ROOT FOR THIS.

All you can do is to copy/paste the code i generated into the destinated file. If you flash the zip u'r gonna mess up with ur audio mod.

STEP 1.

Download ES File Explorer and QuickEdit Text Editor.

STEP 2.

Open ES File, locate mixer_paths.xml ( may contain additional numbers and letters to the file name ), make a copy and paste it somewhere in your internal storage ( i.e Downloads )

STEP 3.

Open QuickEdit, from the top folder icon select the file you copied above, open it, press on top menu button then search and type <path name="speaker"> ;

STEP 4.

Replace from first ctl name to the last one the following code :

( Doesn't modify volume of the main speaker )

<ctl name="SLIM RX0 MUX" value="AIF_MIX1_PB" />
<ctl name="SLIM RX1 MUX" value="AIF_MIX1_PB" />
<ctl name="SLIM_0_RX Channels" value="Two" />
<ctl name="RX INT0_1 MIX1 INP0" value="RX0" />
<ctl name="RX INT6_2 MUX" value="RX1" />
<ctl name="RX0 Digital Volume" value="95" />
<ctl name="COMP6 Switch" value="1" />

( Balances both speaker for a better stereo experience, it will sound lower, can be fixed by enabling Extra Loud in v4a tho )

<ctl name="SLIM RX0 MUX" value="AIF_MIX1_PB" />
<ctl name="SLIM RX1 MUX" value="AIF_MIX1_PB" />
<ctl name="SLIM_0_RX Channels" value="Two" />
<ctl name="RX INT0_1 MIX1 INP0" value="RX0" />
<ctl name="RX INT6_2 MUX" value="RX1" />
<ctl name="SpkrLeft COMP Switch" value="1" />
<ctl name="SpkrRight COMP Switch" value="1" />
<ctl name="SpkrLeft BOOST Switch" value="1" />
<ctl name="SpkrRight BOOST Switch" value="1" />
<ctl name="SpkrLeft VISENSE Switch" value="1" />
<ctl name="SpkrRight VISENSE Switch" value="1" />
<ctl name="SpkrLeft SWR DAC_Port Switch" value="1" />
<ctl name="SpkrRight SWR DAC_Port Switch" value="1" />
<ctl name="RX0 Digital Volume" value="95" />

It should look like this :

View attachment 4115519

STEP 5.

After you saved the new mixer_paths.xml, open ES File again enable root permission by sliding from the left side, locate the new mixer_paths.xml, copy it, go to system>etc, locate the old mixer_paths.xml, delete it, paste the new one.

STEP 6.

Reboot. ( IT WON'T TAKE EFFECT WITHOUT REBOOTING )

BUGS

You tell me.

IMPORTANT NOTES

The mod responds to v4a, however, selecting panning 100% left side won't output the sound only through the earpiece as intended.

If, after reboot, it still doesn't work as expected, follow this procedure :

open back Es File, go to the mixer_paths file that you just edited, long-press on it>more>permissions ( you need root enabled in the file explorer ) and set them as shown in the picture below :

View attachment 4118409

I'm looking for improving the mod. If you feel you can bring any help i'd be very pleased.

Please search through the thread before asking the same question 100th time, thank you.

Credits :
[MENTION=6614145]bloodytolits[/MENTION] ( for sharing file permissions issue )