4G or LTE: What is shown when?

From Android Wiki
LTE is visible in the notification bar
4G is visible in the notification bar

4G and LTE are terms, not only with Andorid, but also used by many network operators and help pages, which are mostly used as synonyms. Also for Android, it seems to be different from device to device, if the Symbol for an active mobile data connection shows an LTE or 4G icon in the notification bar. On this page we will show, how these different icons are choosed and what are the criteria for the selection.

Origin

Both symbols are used as synonyms and mostly describe the same thing, no matter, which icon/wordmark is used. The device, for both cases, is connected to a network which uses the LTE standard (Long Term Evolution) or called 4G for 4th generation network. The diffenrence, at least in europe, is only visual.

Technically, what is called LTE in europe is LTE-Advanced, or (like mentioned already) 4G, the network of the 4th generation. UMTS/HSPA is the network of the 3rd generation (3G) and GSM/GPRS/EDGE is the network of the 2nd generation (2G). The original LTE is something between 3G and 4G and technically would need a separate term, like 3.9G.[1]

In the 90s, the european already specified a gernal, transnationally network called GSM (former: Groupe Spécial Mobile – today: GSM or Global System for Mobile Communications (GSMC)), which was called the network of the 2nd generation (2G).[2] That's probably the reason why the US-based network operator AT&T displays 4G for an HSPA+ connection and 4G LTE for an actual LTE connection. GSM was, e.g., not well known in the U.S. and german carriers provided different devices, if the customer wanted to start a journey to the US.

4G or LTE: The ROM decides

If 4G or LTE is displayed in the notification area is decided by the currently installed operating system (ROM). Usually, this is done based on the network the phone is currently connected, to. To prevent a confusion of the customer, carriers can set that their users see a LTE icon instead of 4G. By default, if the carrier does not overwrite the value, the LTE icon is shown.

technical implementation

The notification bar is part of the SystemUI.apk, which is, fortunately, part of the AOSP project, which means, that the source code is available for the public.[3] The icons for displaying 4G or LTE are defined in the class TelephonyIcons:[4][5][6]

static final MobileIconGroup FOUR_G = new MobileIconGroup(
    "4G",
    TelephonyIcons.TELEPHONY_SIGNAL_STRENGTH,
    TelephonyIcons.QS_TELEPHONY_SIGNAL_STRENGTH,
    AccessibilityContentDescriptions.PHONE_SIGNAL_STRENGTH,
    0, 0,
    TelephonyIcons.TELEPHONY_NO_NETWORK,
    TelephonyIcons.QS_TELEPHONY_NO_NETWORK,
    AccessibilityContentDescriptions.PHONE_SIGNAL_STRENGTH[0],
    R.string.accessibility_data_connection_4g,
    TelephonyIcons.ICON_4G,
    true,
    TelephonyIcons.QS_DATA_4G
    );

static final MobileIconGroup LTE = new MobileIconGroup(
    "LTE",
    TelephonyIcons.TELEPHONY_SIGNAL_STRENGTH,
    TelephonyIcons.QS_TELEPHONY_SIGNAL_STRENGTH,
    AccessibilityContentDescriptions.PHONE_SIGNAL_STRENGTH,
    0, 0,
    TelephonyIcons.TELEPHONY_NO_NETWORK,
    TelephonyIcons.QS_TELEPHONY_NO_NETWORK,
    AccessibilityContentDescriptions.PHONE_SIGNAL_STRENGTH[0],
    R.string.accessibility_data_connection_lte,
    TelephonyIcons.ICON_LTE,
    true,
    TelephonyIcons.QS_DATA_LTE
    );

The icons are defined as vector graphics (since commit b3eb8919): 4G, as well as LTE. The decision, which icon should be used, happens in the MobileSignalController class:[7]

if (mConfig.show4gForLte) {
    mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE, TelephonyIcons.FOUR_G);
    if (mConfig.hideLtePlus) {
        mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE_CA,
                TelephonyIcons.FOUR_G);
    } else {
        mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE_CA,
                TelephonyIcons.FOUR_G_PLUS);
    }
} else {
    mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE, TelephonyIcons.LTE);
    if (mConfig.hideLtePlus) {
        mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE_CA,
                TelephonyIcons.LTE);
    } else {
        mNetworkToIconLookup.put(TelephonyManager.NETWORK_TYPE_LTE_CA,
                TelephonyIcons.LTE_PLUS);
    }
}

The configuration option show4gForLte is provided through the Config class in the file NetworkControllerImpl.java.[8] This boolean value is read from a PersistableBundle, which is provided by the CarrierConfigManager. This carrier-dependant configuration is part of Androids carrier configuration component. This component allows a privileged app since Android 6.0 verweis=Android/M "Marshmallow" to change specific, provider-dependant settings, without needing to change the operating system itself. With that, the values can be changed more dynamically and especially without the need to provide a system update.

An implementation of such a carrier configuration app is bundled with the AOSP as well, the CarrierConfig app. This app reads the configuration values for the carrier the phone is connected to, from files bundled with the app, as long as a configuration for the carrier exists.

In this configuration, for example, for the carrier Vodafone in Germany, the 4G icon is shown instead of the LTE one:[9]

<boolean name="show_4g_for_lte_data_icon_bool" value="true"/>

The carrier ID 25 is read from a Carrier ID list in Android, which is selected by the mobile network the phone is connected, to.[10]

As another example, AT&T with the carrier ID 1187 does not provide such a value (show_4g_for_lte_data_icon_bool) at all, therefore the default value (false) is used and the LTE icon, instead of 4G is shown.[11] This file is also the place, where it is configured, that AT&T is showing a 4G icon for a 3G network.[12]

See also

References

  1. 3,9G / 4G / LTE:
  2. GSM bzw Global System for Mobile_Communications (GSMC).
  3. platform/frameworks/base - Git at Google.
  4. android/platform_frameworks_base.
  5. android/platform_frameworks_base.
  6. android/platform_frameworks_base.
  7. Lua error: Internal error: The interpreter exited with status 127.
  8. Lua error: Internal error: The interpreter exited with status 127.
  9. Lua error: Internal error: The interpreter exited with status 127.
  10. Lua error: Internal error: The interpreter exited with status 127.
  11. Lua error: Internal error: The interpreter exited with status 127.
  12. Lua error: Internal error: The interpreter exited with status 127.