Hook in to the new radio API to find out when the radio
is active and use that to track its state in batter stats.
We also still have the data being tracked from the kernel's
emulation, and continue to use that if we don't get data from
the radio.
Currently this monitoring is turned off until some issues
in the radio can be fixed that are providing bad data.
Also add a new API to get estimated drain and charge times.
Change-Id: Ifc4900fabb8f848f9cda361dce698664ea75f175
Also added DataConnectionRealTimeInfo structure which passed as a
parameter to onDataConnectionRealTimeInfoChanged.
Change-Id: Iadcbf9765af57c125bcdf74e3fc652ed6c8f7d42
* commit '8ee4491dc80943429cd79d0c7b87c28056067a58':
Added a private apis jar that includes explicitly supported APIs that are not useful for 3rd party developers.
* commit 'e05077d78c9abde054a754db53e71c647b9a705c':
Added a private apis jar that includes explicitly supported APIs that are not useful for 3rd party developers.
The first set of these APIs is for telephony:
Added some APIs to ITelephony and created a first party framework for them
toggleHold()
merge()
mute(boolean mute)
playDtmfTone(char digit, boolean timedShortCode)
stopDtmfTone()
swap()
addListener(ITelephonyListener listener)
removeListener(ITelephonyListener listener)
Bug: 13302451
Change-Id: Iefec5688c26a1b4fe77f5643eba6e1690a057ee6
The Android code base defines call disconnect codes in three places:
- android.telephony.DisconnectCause
- android.internal.telephony.Connection.DisconnectCause
- com.android.services.telephony.common.Call.DisconnectCause
This CL consolidates the code to use the integer codes from
android.telephony.DisconnectCause everywhere.
Change-Id: I84a3fd5182a51d07fc7d81076e4b2c15ff26c61c
Remove the recently added RIL_REQUEST_SET_RADIO_MODE command and update
the definition of the RIL_REQUEST_NV_RESET_CONFIG parameter.
Also remove some accidentally added debug log lines.
Bug: 12864208
Change-Id: I6f035d6900c9fcb1427bad62057d7b4a1d3cd99c
Add new RIL commands and generic code cleanups.
The only changes required for OMA DM support are the
addition of five new methods in ITelephony.aidl for
reading/writing NV items and performing NV config and
radio resets (requires MODIFY_PHONE_STATE), along with
the new RIL request IDs in RILConstants.java.
Bug: 12864208
Change-Id: I958d2571580d98a49936ef2e6822e5ac086acbe2
Added new AndroidManifest permission:
android.permission.READ_PRECISE_PHONE_STATE
Added the following PhoneStateListeners and corresponding broadcast intents:
onPreciseCallStateChanged(PreciseCallState callState);
onPreciseDataConnectionStateChanged(PreciseDataConnectionState dataConnectionState);
broadcastPreciseCallStateChanged(int ringingCallState, int foregroundCallState, int backgroundCallState,
int disconnectCause, int preciseDisconnectCause)
broadcastPreciseDataConnectionStateChanged(int state, int networkType, String apnType, String apn,
String reason, LinkProperties linkProperties, String failCause)
Added TelephonyManager intent actions with their extras and constants:
public static final String ACTION_PRECISE_CALL_STATE_CHANGED = "android.intent.action.PRECISE_CALL_STATE";
public static final String ACTION_PRECISE_DATA_CONNECTION_STATE_CHANGED = "android.intent.action.PRECISE_DATA_CONNECTION_STATE_CHANGED";
public static final int PRECISE_CALL_STATE_*
Moved public static final int DISCONNECT_CAUSE_* from PreciseCallState.java to a new class DisconnectCause.java
Moved public static final int PRECISE_DISCONNECT_CAUSE_* from PreciseCallState.java to a new class PreciseDisconnectCause.java
Change-Id: If3b88c679507c529b746046c4a17cf6d9974bd09
Expose the folowing commands in ITelephony.aidl and TelephonyManager:
- iccOpenLogicalChannel
- iccCloseLogicalChannel
- iccTransmitApduLogicalChannel
Also add a new SIM_COMMUNICATION permission (maked as dangerous) to control
access to the above commands.
Change-Id: I89c08adc6f9738907e3b547c749f3cc61f300710
Unhide the following methods:
PhoneNumberFormattingTextWatcher(String countryCode)
formatNumber(String phoneNumber, String defaultCountryIso)
formatNumber(String phoneNumber, String phoneNumberE164, String defaultCountryISO)
formatNumberToE164(String phoneNumber, String defaultCountryIso)
(The previous 3 formatting methods use an instance of PhoneNumberUtil to do the formatting)
isLocalEmergencyNumber(String number, Context context)
isVoicemailNumber(String number)
replaceUnicodeDigits(String number)
normalizeNumber(String phoneNumber)
Deprecate the following methods. These formatting-related methods don't use
PhoneNumberUtil to perform the formatting, and so are considered broken:
formatNumber(String source)
formatNumber(String source, int defaultFormattingType)
getFormatTypeForLocale(Locale locale)
formatNumber(Editable text, int defaultFormattingType)
formatNanpNumber(Editable text)
formatJapaneseNumber(Editable text)
Change-Id: Ibf854092b7db05f7e3e9401cc909c9f1ed4997b0
These are APIs for the new ThirdPartyPhone feature.
Note, these APIs can't actually be used yet on master for two reasons:
- initiating a call from a 3rd party app isn't possible yet because
the TelephonyManager APIs aren't being added to master.
- the TeleService implementation of these APIs aren't being added to
master.
Also, these APIs will be removed and the final ones will be added
once they're ready to be merged into master.
Change-Id: Ie783290451da448a011f813983e55b12047b5d99
For CDMA networks, convert "+" prefix to "011" if the home network
is using the North American Numbering Plan (NANP). New method is
only used for MO SMS messages.
Bug: 11360679
Change-Id: I534e0322b566de3fb49d7333bfcf62cfbfafb78a
Add supplyPinReportResult & supplyPukReportResult that
returns the result code and attempts remaining.
Display "Attempts remaining" in Keyguard
Bug: 9928717
Change-Id: Ibad0635dd1375fabce11ba2b7b9f95f8868489e6
Fix CountryDetector NPE by calling CallerInfo.getCurrentCountryIso() which
checks for potential nulls.
Bug:11291034
Change-Id: I0a4412c432551c64ec30652d69636442653ee337
Telephony framework expects Lte rsrp and rsrq, as well
as dbm and ecio values for cdma and evdoe to be negative.
RIL Interface provides positive values.
Fix that by changing the constructor from Parcel to
also multiply by -1
Writing to parcel also modified for consistency
Bug: 10440827
Change-Id: I6a8112a5b343c5e6c6dc12332a6e9a489b093cc1
Add RIL_REQUEST_IMS_REGISTRATION_STATE, RIL_REQUEST_IMS_SEND_SMS, and
RIL_UNSOL_RESPONSE_IMS_NETWORK_STATE_CHANGED. Add FORMAT_UNKNOWN to
SmsConstants.
Bug: 9626411
Change-Id: I87ca9841b4ace931c55e2d379fe6d7589b2dc8a5
Signed-off-by: Ed Tam <etam@google.com>
Internal method CallerInfo.getCurrentCountryIso() can throw NPE
if the country detector's detectCountry() method returns null.
Add code to check that the Country is not null before calling
getCountryIso() on it. Change fallback logic to call
locale.getCountry() whenever countryIso was not assigned.
Bug: 10607906
Change-Id: I08fe3f4d942f67c37a2e6ff0b067fe32ad8a6fa5