Loading telephony/java/com/android/internal/telephony/ITelephony.aidl +94 −0 Original line number Diff line number Diff line Loading @@ -554,6 +554,18 @@ interface ITelephony { */ IccOpenLogicalChannelResponse iccOpenLogicalChannel(String AID); /** * Opens a logical channel to the ICC card for a particular subId. * * Input parameters equivalent to TS 27.007 AT+CCHO command. * * @param subId user preferred subId. * @param AID Application id. See ETSI 102.221 and 101.220. * @return an IccOpenLogicalChannelResponse object. */ IccOpenLogicalChannelResponse iccOpenLogicalChannelUsingSubId(int subId, String AID); /** * Closes a previously opened logical channel to the ICC card. * Loading @@ -565,6 +577,19 @@ interface ITelephony { */ boolean iccCloseLogicalChannel(int channel); /** * Closes a previously opened logical channel to the ICC card for a * particular subId. * * Input parameters equivalent to TS 27.007 AT+CCHC command. * * @param subId user preferred subId. * @param channel is the channel id to be closed as retruned by a * successful iccOpenLogicalChannel. * @return true if the channel was closed successfully. */ boolean iccCloseLogicalChannelUsingSubId(int subId, int channel); /** * Transmit an APDU to the ICC card over a logical channel. * Loading @@ -585,6 +610,28 @@ interface ITelephony { String iccTransmitApduLogicalChannel(int channel, int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over a logical channel for a * particular subId. * * Input parameters equivalent to TS 27.007 AT+CGLA command. * * @param subId user preferred subId. * @param channel is the channel id to be closed as retruned by a * successful iccOpenLogicalChannel. * @param cla Class of the APDU command. * @param instruction Instruction of the APDU command. * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU * is sent to the SIM. * @param data Data to be sent with the APDU. * @return The APDU response from the ICC card with the status appended at * the end. */ String iccTransmitApduLogicalChannelUsingSubId(int subId, int channel, int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over the basic channel. * Loading @@ -603,6 +650,26 @@ interface ITelephony { String iccTransmitApduBasicChannel(int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over the basic channel for a particular * subId. * * Input parameters equivalent to TS 27.007 AT+CSIM command. * * @param subId user preferred subId. * @param cla Class of the APDU command. * @param instruction Instruction of the APDU command. * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU * is sent to the SIM. * @param data Data to be sent with the APDU. * @return The APDU response from the ICC card with the status appended at * the end. */ String iccTransmitApduBasicChannelUsingSubId(int subId, int cla, int instruction, int p1, int p2, int p3, String data); /** * Returns the response APDU for a command APDU sent through SIM_IO. * Loading @@ -617,6 +684,22 @@ interface ITelephony { byte[] iccExchangeSimIO(int fileID, int command, int p1, int p2, int p3, String filePath); /** * Returns the response APDU for a command APDU sent through SIM_IO * for a particular subId. * * @param subId user preferred subId. * @param fileID * @param command * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. * @param filePath * @return The APDU response. */ byte[] iccExchangeSimIOUsingSubId(int subId, int fileID, int command, int p1, int p2, int p3, String filePath); /** * Send ENVELOPE to the SIM and returns the response. * Loading Loading @@ -1005,4 +1088,15 @@ interface ITelephony { *@hide */ ModemActivityInfo getModemActivityInfo(); /** * Get ATR (Answer To Reset; as per ISO/IEC 7816-4) from SIM card */ byte[] getAtr(); /** * Get ATR (Answer To Reset; as per ISO/IEC 7816-4) from SIM card * for a particular subId. */ byte[] getAtrUsingSubId(int subId); } telephony/java/com/android/internal/telephony/RILConstants.java +2 −1 Original line number Diff line number Diff line Loading @@ -77,7 +77,7 @@ public interface RILConstants { int SIM_SAP_MSG_SIZE_TOO_SMALL = 34; int SIM_SAP_CONNECT_OK_CALL_ONGOING = 35; int LCE_NOT_SUPPORTED = 36; /* Link Capacity Estimation (LCE) not supported */ int INVALID_PARAMETER = 37; /* NETWORK_MODE_* See ril.h RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE */ int NETWORK_MODE_WCDMA_PREF = 0; /* GSM/WCDMA (WCDMA preferred) */ Loading Loading @@ -335,6 +335,7 @@ cat include/telephony/ril.h | \ int RIL_REQUEST_STOP_LCE = 133; int RIL_REQUEST_PULL_LCEDATA = 134; int RIL_REQUEST_GET_ACTIVITY_INFO = 135; int RIL_REQUEST_SIM_GET_ATR = 136; int RIL_UNSOL_RESPONSE_BASE = 1000; int RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED = 1000; Loading Loading
telephony/java/com/android/internal/telephony/ITelephony.aidl +94 −0 Original line number Diff line number Diff line Loading @@ -554,6 +554,18 @@ interface ITelephony { */ IccOpenLogicalChannelResponse iccOpenLogicalChannel(String AID); /** * Opens a logical channel to the ICC card for a particular subId. * * Input parameters equivalent to TS 27.007 AT+CCHO command. * * @param subId user preferred subId. * @param AID Application id. See ETSI 102.221 and 101.220. * @return an IccOpenLogicalChannelResponse object. */ IccOpenLogicalChannelResponse iccOpenLogicalChannelUsingSubId(int subId, String AID); /** * Closes a previously opened logical channel to the ICC card. * Loading @@ -565,6 +577,19 @@ interface ITelephony { */ boolean iccCloseLogicalChannel(int channel); /** * Closes a previously opened logical channel to the ICC card for a * particular subId. * * Input parameters equivalent to TS 27.007 AT+CCHC command. * * @param subId user preferred subId. * @param channel is the channel id to be closed as retruned by a * successful iccOpenLogicalChannel. * @return true if the channel was closed successfully. */ boolean iccCloseLogicalChannelUsingSubId(int subId, int channel); /** * Transmit an APDU to the ICC card over a logical channel. * Loading @@ -585,6 +610,28 @@ interface ITelephony { String iccTransmitApduLogicalChannel(int channel, int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over a logical channel for a * particular subId. * * Input parameters equivalent to TS 27.007 AT+CGLA command. * * @param subId user preferred subId. * @param channel is the channel id to be closed as retruned by a * successful iccOpenLogicalChannel. * @param cla Class of the APDU command. * @param instruction Instruction of the APDU command. * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU * is sent to the SIM. * @param data Data to be sent with the APDU. * @return The APDU response from the ICC card with the status appended at * the end. */ String iccTransmitApduLogicalChannelUsingSubId(int subId, int channel, int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over the basic channel. * Loading @@ -603,6 +650,26 @@ interface ITelephony { String iccTransmitApduBasicChannel(int cla, int instruction, int p1, int p2, int p3, String data); /** * Transmit an APDU to the ICC card over the basic channel for a particular * subId. * * Input parameters equivalent to TS 27.007 AT+CSIM command. * * @param subId user preferred subId. * @param cla Class of the APDU command. * @param instruction Instruction of the APDU command. * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU * is sent to the SIM. * @param data Data to be sent with the APDU. * @return The APDU response from the ICC card with the status appended at * the end. */ String iccTransmitApduBasicChannelUsingSubId(int subId, int cla, int instruction, int p1, int p2, int p3, String data); /** * Returns the response APDU for a command APDU sent through SIM_IO. * Loading @@ -617,6 +684,22 @@ interface ITelephony { byte[] iccExchangeSimIO(int fileID, int command, int p1, int p2, int p3, String filePath); /** * Returns the response APDU for a command APDU sent through SIM_IO * for a particular subId. * * @param subId user preferred subId. * @param fileID * @param command * @param p1 P1 value of the APDU command. * @param p2 P2 value of the APDU command. * @param p3 P3 value of the APDU command. * @param filePath * @return The APDU response. */ byte[] iccExchangeSimIOUsingSubId(int subId, int fileID, int command, int p1, int p2, int p3, String filePath); /** * Send ENVELOPE to the SIM and returns the response. * Loading Loading @@ -1005,4 +1088,15 @@ interface ITelephony { *@hide */ ModemActivityInfo getModemActivityInfo(); /** * Get ATR (Answer To Reset; as per ISO/IEC 7816-4) from SIM card */ byte[] getAtr(); /** * Get ATR (Answer To Reset; as per ISO/IEC 7816-4) from SIM card * for a particular subId. */ byte[] getAtrUsingSubId(int subId); }
telephony/java/com/android/internal/telephony/RILConstants.java +2 −1 Original line number Diff line number Diff line Loading @@ -77,7 +77,7 @@ public interface RILConstants { int SIM_SAP_MSG_SIZE_TOO_SMALL = 34; int SIM_SAP_CONNECT_OK_CALL_ONGOING = 35; int LCE_NOT_SUPPORTED = 36; /* Link Capacity Estimation (LCE) not supported */ int INVALID_PARAMETER = 37; /* NETWORK_MODE_* See ril.h RIL_REQUEST_SET_PREFERRED_NETWORK_TYPE */ int NETWORK_MODE_WCDMA_PREF = 0; /* GSM/WCDMA (WCDMA preferred) */ Loading Loading @@ -335,6 +335,7 @@ cat include/telephony/ril.h | \ int RIL_REQUEST_STOP_LCE = 133; int RIL_REQUEST_PULL_LCEDATA = 134; int RIL_REQUEST_GET_ACTIVITY_INFO = 135; int RIL_REQUEST_SIM_GET_ATR = 136; int RIL_UNSOL_RESPONSE_BASE = 1000; int RIL_UNSOL_RESPONSE_RADIO_STATE_CHANGED = 1000; Loading