- Aug 19, 2016
- 14
- 15
Dual band WLAN speed boost
It is available and it is working on stock firmware. I found the reason why it is not available on xiaomi.eu build.
/product/priv-app/Settings/Settings.apk, com.android.settings.wifi.linkturbo.LinkTurboClient.isLinkTurboSupported:
So, in my opinion method `isGlobalShowMultiNetwork` should be patched and "Redmi K30 5G" should be added.
Missing 5G switch in `SIM cards & mobile networks`
I'm not sure if it is really important, because it is still available in network mode selector.
But it exists on stock firmware.
/system/priv-app/TeleService/TeleService.apk, com.android.phone.MiuiPhoneUtils.showFiveGSwitch:
`shouldEnableFiveGCapability` is true because ro.vendor.radio.5g = 1
`getFiveGSwitchType` return 2 because IS_INTERNATIONAL_BUILD, 2&1 = 0, so `showFiveGSwitch` return false
`showFiveGNetworkMode` return true in both builds because 2&2 = 2 and 3&2 = 2. It is used in network mode selector.
I did not find `getFiveGSwitchType` is used anywhere in other places, so in my opinion it could be just removed (and both calls to it in conditions).
It is available and it is working on stock firmware. I found the reason why it is not available on xiaomi.eu build.
/product/priv-app/Settings/Settings.apk, com.android.settings.wifi.linkturbo.LinkTurboClient.isLinkTurboSupported:
Java:
private static boolean isGlobalShowMultiNetwork() {
String str = Build.MODEL;
return str.contains("Mi 10") || str.contains("Redmi K20 Pro");
}
public static boolean isLinkTurboSupported() {
return (!miui.os.Build.IS_INTERNATIONAL_BUILD || isGlobalShowMultiNetwork()) && SystemProperties.getInt("ro.vendor.net.enable_sla", 0) == 1;
}
So, in my opinion method `isGlobalShowMultiNetwork` should be patched and "Redmi K30 5G" should be added.
Missing 5G switch in `SIM cards & mobile networks`
I'm not sure if it is really important, because it is still available in network mode selector.
But it exists on stock firmware.
/system/priv-app/TeleService/TeleService.apk, com.android.phone.MiuiPhoneUtils.showFiveGSwitch:
Java:
public static boolean shouldEnableFiveGCapability() {
return "andromeda".equals(miui.os.Build.DEVICE) || isMtk5gDevice() || SystemProperties.getInt("ro.vendor.radio.5g", 0) > 0;
}
public static int getFiveGSwitchType() {
return Build.IS_INTERNATIONAL_BUILD ? 2 : 3;
}
public static boolean showFiveGSwitch() {
return shouldEnableFiveGCapability() && (getFiveGSwitchType() & 1) == 1 && FiveGManager.is5GSwitchCarrierAvailable() && !FiveGManager.is5GSwitchClosedByCloud();
}
public static boolean showFiveGNetworkMode() {
return shouldEnableFiveGCapability() && (getFiveGSwitchType() & 2) == 2 && FiveGManager.is5GSwitchCarrierAvailable() && !FiveGManager.is5GSwitchClosedByCloud();
}
`shouldEnableFiveGCapability` is true because ro.vendor.radio.5g = 1
`getFiveGSwitchType` return 2 because IS_INTERNATIONAL_BUILD, 2&1 = 0, so `showFiveGSwitch` return false
`showFiveGNetworkMode` return true in both builds because 2&2 = 2 and 3&2 = 2. It is used in network mode selector.
I did not find `getFiveGSwitchType` is used anywhere in other places, so in my opinion it could be just removed (and both calls to it in conditions).