Merge "CDMA MO SMS follow on DC feature"
am: 80da44e958
Change-Id: I133c60baf131a5d0762090334afd8449279794a6
This commit is contained in:
commit
44eaabad25
6 changed files with 97 additions and 2 deletions
|
@ -642,9 +642,9 @@ c9273429fcf98d797d3bb07fdba6f1be95bf960f9255cde169fd1ca4db85f856 android.hardwar
|
|||
# BEGIN Radio HAL Merge Conflict Avoidance Buffer - STOPSHIP if present
|
||||
##
|
||||
275a01e456f3c988ac9736d26ceaf3e95fb7b3c333a8a7fe983de6bae39df58a android.hardware.radio@1.5::types
|
||||
c1f45964562445008d3c5b4a6c1694cfe5d14a453ad00d9157cc82585979ac0c android.hardware.radio@1.5::IRadio
|
||||
7a0a3382cca78d13a55e856b14b7fb025987f52c2adeab5747cd584391cd3cc7 android.hardware.radio@1.5::IRadio
|
||||
20d52e66fd548f89bcb98cda42749a591ce8f439a2a7148617adac0c967ad937 android.hardware.radio@1.5::IRadioIndication
|
||||
838c7b1420874a1a7d0bb3568fef9c8347d11ac8fd439ca2b5c50720cfa8c195 android.hardware.radio@1.5::IRadioResponse
|
||||
c7b4a0debd3bb8815a463d11194487c7eef81bca584f558d7ba74c34b18d7e3f android.hardware.radio@1.5::IRadioResponse
|
||||
55f0a15642869ec98a55ea0a5ac049d3e1a6245ff7750deb6bcb7182057eee83 android.hardware.radio.config@1.3::types
|
||||
b27ab0cd40b0b078cdcd024bfe1061c4c4c065f3519eeb9347fa359a3268a5ae android.hardware.radio.config@1.3::IRadioConfig
|
||||
742360c775313438b0f82256eac62fb5bbc76a6ae6f388573f3aa142fb2c1eea android.hardware.radio.config@1.3::IRadioConfigIndication
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
package android.hardware.radio@1.5;
|
||||
|
||||
import @1.2::DataRequestReason;
|
||||
import @1.0::CdmaSmsMessage;
|
||||
import @1.4::IRadio;
|
||||
import @1.4::DataProfileInfo;
|
||||
import @1.5::AccessNetwork;
|
||||
|
@ -257,4 +258,15 @@ interface IRadio extends @1.4::IRadio {
|
|||
* Response function is IRadioResponse.supplySimDepersonalizationResponse()
|
||||
*/
|
||||
oneway supplySimDepersonalization(int32_t serial, PersoSubstate persoType, string controlKey);
|
||||
|
||||
/**
|
||||
* Send an SMS message. Identical to sendCdmaSms,
|
||||
* except that more messages are expected to be sent soon.
|
||||
*
|
||||
* @param serial Serial number of request.
|
||||
* @param sms Cdma Sms to be sent described by CdmaSmsMessage in types.hal
|
||||
*
|
||||
* Response callback is IRadioResponse.sendCdmaSMSExpectMoreResponse()
|
||||
*/
|
||||
oneway sendCdmaSmsExpectMore(int32_t serial, CdmaSmsMessage sms);
|
||||
};
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
package android.hardware.radio@1.5;
|
||||
|
||||
import @1.0::RadioResponseInfo;
|
||||
import @1.0::SendSmsResult;
|
||||
import @1.4::IRadioResponse;
|
||||
import @1.5::BarringInfo;
|
||||
import @1.5::SetupDataCallResult;
|
||||
|
@ -194,4 +195,35 @@ interface IRadioResponse extends @1.4::IRadioResponse {
|
|||
*/
|
||||
oneway supplySimDepersonalizationResponse(RadioResponseInfo info,
|
||||
PersoSubstate persoType, int32_t remainingRetries);
|
||||
|
||||
/**
|
||||
* @param info Response info struct containing response type, serial no. and error
|
||||
* @param sms Response to sms sent as defined by SendSmsResult in types.hal
|
||||
*
|
||||
* Valid errors returned:
|
||||
* RadioError:NONE
|
||||
* RadioError:RADIO_NOT_AVAILABLE
|
||||
* RadioError:SMS_SEND_FAIL_RETRY
|
||||
* RadioError:NETWORK_REJECT
|
||||
* RadioError:INVALID_STATE
|
||||
* RadioError:INVALID_ARGUMENTS
|
||||
* RadioError:NO_MEMORY
|
||||
* RadioError:REQUEST_RATE_LIMITED
|
||||
* RadioError:INVALID_SMS_FORMAT
|
||||
* RadioError:SYSTEM_ERR
|
||||
* RadioError:FDN_CHECK_FAILURE
|
||||
* RadioError:ENCODING_ERR
|
||||
* RadioError:INVALID_SMSC_ADDRESS
|
||||
* RadioError:MODEM_ERR
|
||||
* RadioError:NETWORK_ERR
|
||||
* RadioError:INTERNAL_ERR
|
||||
* RadioError:REQUEST_NOT_SUPPORTED
|
||||
* RadioError:INVALID_MODEM_STATE
|
||||
* RadioError:NETWORK_NOT_READY
|
||||
* RadioError:OPERATION_NOT_ALLOWED
|
||||
* RadioError:NO_RESOURCES
|
||||
* RadioError:CANCELLED
|
||||
* RadioError:SIM_ABSENT
|
||||
*/
|
||||
oneway sendCdmaSmsExpectMoreResponse(RadioResponseInfo info, SendSmsResult sms);
|
||||
};
|
||||
|
|
|
@ -986,4 +986,48 @@ TEST_F(RadioHidlTest_v1_5, setRadioPower_1_5_emergencyCall_cancalled) {
|
|||
EXPECT_EQ(RadioResponseType::SOLICITED, radioRsp_v1_5->rspInfo.type);
|
||||
EXPECT_EQ(serial, radioRsp_v1_5->rspInfo.serial);
|
||||
EXPECT_EQ(RadioError::NONE, radioRsp_v1_5->rspInfo.error);
|
||||
}
|
||||
|
||||
/*
|
||||
* Test IRadio.sendCdmaSmsExpectMore() for the response returned.
|
||||
*/
|
||||
TEST_F(RadioHidlTest_v1_5, sendCdmaSmsExpectMore) {
|
||||
serial = GetRandomSerialNumber();
|
||||
|
||||
// Create a CdmaSmsAddress
|
||||
CdmaSmsAddress cdmaSmsAddress;
|
||||
cdmaSmsAddress.digitMode = CdmaSmsDigitMode::FOUR_BIT;
|
||||
cdmaSmsAddress.numberMode = CdmaSmsNumberMode::NOT_DATA_NETWORK;
|
||||
cdmaSmsAddress.numberType = CdmaSmsNumberType::UNKNOWN;
|
||||
cdmaSmsAddress.numberPlan = CdmaSmsNumberPlan::UNKNOWN;
|
||||
cdmaSmsAddress.digits = (std::vector<uint8_t>){11, 1, 6, 5, 10, 7, 7, 2, 10, 3, 10, 3};
|
||||
|
||||
// Create a CdmaSmsSubAddress
|
||||
CdmaSmsSubaddress cdmaSmsSubaddress;
|
||||
cdmaSmsSubaddress.subaddressType = CdmaSmsSubaddressType::NSAP;
|
||||
cdmaSmsSubaddress.odd = false;
|
||||
cdmaSmsSubaddress.digits = (std::vector<uint8_t>){};
|
||||
|
||||
// Create a CdmaSmsMessage
|
||||
android::hardware::radio::V1_0::CdmaSmsMessage cdmaSmsMessage;
|
||||
cdmaSmsMessage.teleserviceId = 4098;
|
||||
cdmaSmsMessage.isServicePresent = false;
|
||||
cdmaSmsMessage.serviceCategory = 0;
|
||||
cdmaSmsMessage.address = cdmaSmsAddress;
|
||||
cdmaSmsMessage.subAddress = cdmaSmsSubaddress;
|
||||
cdmaSmsMessage.bearerData =
|
||||
(std::vector<uint8_t>){15, 0, 3, 32, 3, 16, 1, 8, 16, 53, 76, 68, 6, 51, 106, 0};
|
||||
|
||||
radio_v1_5->sendCdmaSmsExpectMore(serial, cdmaSmsMessage);
|
||||
|
||||
EXPECT_EQ(std::cv_status::no_timeout, wait());
|
||||
EXPECT_EQ(RadioResponseType::SOLICITED, radioRsp_v1_5->rspInfo.type);
|
||||
EXPECT_EQ(serial, radioRsp_v1_5->rspInfo.serial);
|
||||
|
||||
if (cardStatus.base.base.cardState == CardState::ABSENT) {
|
||||
ASSERT_TRUE(CheckAnyOfErrors(
|
||||
radioRsp_v1_5->rspInfo.error,
|
||||
{RadioError::INVALID_ARGUMENTS, RadioError::INVALID_STATE, RadioError::SIM_ABSENT},
|
||||
CHECK_GENERAL_ERROR));
|
||||
}
|
||||
}
|
|
@ -293,6 +293,8 @@ class RadioResponse_v1_5 : public ::android::hardware::radio::V1_5::IRadioRespon
|
|||
|
||||
Return<void> sendCdmaSmsResponse(const RadioResponseInfo& info, const SendSmsResult& sms);
|
||||
|
||||
Return<void> sendCdmaSmsExpectMoreResponse(const RadioResponseInfo& info, const SendSmsResult& sms);
|
||||
|
||||
Return<void> acknowledgeLastIncomingCdmaSmsResponse(const RadioResponseInfo& info);
|
||||
|
||||
Return<void> getGsmBroadcastConfigResponse(
|
||||
|
|
|
@ -421,6 +421,11 @@ Return<void> RadioResponse_v1_5::sendCdmaSmsResponse(const RadioResponseInfo& /*
|
|||
return Void();
|
||||
}
|
||||
|
||||
Return<void> RadioResponse_v1_5::sendCdmaSmsExpectMoreResponse(const RadioResponseInfo& /*info*/,
|
||||
const SendSmsResult& /*sms*/) {
|
||||
return Void();
|
||||
}
|
||||
|
||||
Return<void> RadioResponse_v1_5::acknowledgeLastIncomingCdmaSmsResponse(
|
||||
const RadioResponseInfo& /*info*/) {
|
||||
return Void();
|
||||
|
|
Loading…
Reference in a new issue