111fccf17Sopenharmony_ci/* 211fccf17Sopenharmony_ci * Copyright (C) 2021 Huawei Device Co., Ltd. 311fccf17Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 411fccf17Sopenharmony_ci * you may not use this file except in compliance with the License. 511fccf17Sopenharmony_ci * You may obtain a copy of the License at 611fccf17Sopenharmony_ci * 711fccf17Sopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 811fccf17Sopenharmony_ci * 911fccf17Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software 1011fccf17Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 1111fccf17Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 1211fccf17Sopenharmony_ci * See the License for the specific language governing permissions and 1311fccf17Sopenharmony_ci * limitations under the License. 1411fccf17Sopenharmony_ci */ 1511fccf17Sopenharmony_ci 1611fccf17Sopenharmony_ci#ifndef OHOS_HRIL_ENUM_H 1711fccf17Sopenharmony_ci#define OHOS_HRIL_ENUM_H 1811fccf17Sopenharmony_ci 1911fccf17Sopenharmony_ci#define HRIL_VERSION 1 2011fccf17Sopenharmony_ci#define HRIL_VERSION_MIN 1 2111fccf17Sopenharmony_ci#define HRIL_MAX_CDMA_MESSAGE_LEN 255 2211fccf17Sopenharmony_ci#define HRIL_MAX_CDMA_ADDRESS_LEN 36 2311fccf17Sopenharmony_ci 2411fccf17Sopenharmony_ci#ifndef TRUE 2511fccf17Sopenharmony_ci#define TRUE 1 2611fccf17Sopenharmony_ci#define FALSE 0 2711fccf17Sopenharmony_ci#endif 2811fccf17Sopenharmony_ci 2911fccf17Sopenharmony_ci#define PARAMETER_SIZE 128 3011fccf17Sopenharmony_ci 3111fccf17Sopenharmony_citypedef enum { 3211fccf17Sopenharmony_ci HRIL_SIM_SLOT_0, 3311fccf17Sopenharmony_ci HRIL_SIM_SLOT_1, 3411fccf17Sopenharmony_ci HRIL_SIM_SLOT_2, 3511fccf17Sopenharmony_ci HRIL_SIM_SLOT_3, 3611fccf17Sopenharmony_ci} HRilSimSlotId; 3711fccf17Sopenharmony_ci 3811fccf17Sopenharmony_citypedef enum { 3911fccf17Sopenharmony_ci HRIL_ERR_NULL_POINT = -1, 4011fccf17Sopenharmony_ci HRIL_ERR_SUCCESS = 0, 4111fccf17Sopenharmony_ci HRIL_ERR_GENERIC_FAILURE, 4211fccf17Sopenharmony_ci HRIL_ERR_INVALID_PARAMETER, 4311fccf17Sopenharmony_ci HRIL_ERR_MEMORY_FULL, 4411fccf17Sopenharmony_ci HRIL_ERR_CMD_SEND_FAILURE, 4511fccf17Sopenharmony_ci HRIL_ERR_CMD_NO_CARRIER, 4611fccf17Sopenharmony_ci HRIL_ERR_INVALID_RESPONSE, 4711fccf17Sopenharmony_ci HRIL_ERR_REPEAT_STATUS, 4811fccf17Sopenharmony_ci HRIL_ERR_NETWORK_SEARCHING, 4911fccf17Sopenharmony_ci HRIL_ERR_NETWORK_SEARCHING_INTERRUPTED, 5011fccf17Sopenharmony_ci HRIL_ERR_MODEM_DEVICE_CLOSE, 5111fccf17Sopenharmony_ci 5211fccf17Sopenharmony_ci // network error 5311fccf17Sopenharmony_ci HRIL_ERR_NO_SIMCARD_INSERTED, 5411fccf17Sopenharmony_ci HRIL_ERR_NEED_PIN_CODE, 5511fccf17Sopenharmony_ci HRIL_ERR_NEED_PUK_CODE, 5611fccf17Sopenharmony_ci HRIL_ERR_NETWORK_SEARCH_TIMEOUT, 5711fccf17Sopenharmony_ci HRIL_ERR_PINPUK_PASSWORD_NOCORRECT, 5811fccf17Sopenharmony_ci HRIL_ERR_INVALID_MODEM_PARAMETER = 50, 5911fccf17Sopenharmony_ci HRIL_ERR_HDF_IPC_FAILURE = 65535, 6011fccf17Sopenharmony_ci} HRilErrNumber; 6111fccf17Sopenharmony_ci 6211fccf17Sopenharmony_ci/* From 3GPP TS 27.007 V4.3.0 (2001-12) ATD%s%s */ 6311fccf17Sopenharmony_citypedef enum { 6411fccf17Sopenharmony_ci HRIL_CALL_ACTIVATE = 0, 6511fccf17Sopenharmony_ci HRIL_CALL_HOLDING = 1, 6611fccf17Sopenharmony_ci HRIL_CALL_DIALING = 2, /* MO call */ 6711fccf17Sopenharmony_ci HRIL_CALL_ALERTING = 3, /* MO call */ 6811fccf17Sopenharmony_ci HRIL_CALL_INCOMING = 4, /* MT call */ 6911fccf17Sopenharmony_ci HRIL_CALL_WAITING = 5 /* MT call */ 7011fccf17Sopenharmony_ci} HRilCallState; 7111fccf17Sopenharmony_ci 7211fccf17Sopenharmony_citypedef enum { 7311fccf17Sopenharmony_ci HRIL_CALL_FAIL_NO_VALID_NUMBER = 1, 7411fccf17Sopenharmony_ci HRIL_CALL_FAIL_NO_LINE_TO_TARGET_ADDRESS = 3, 7511fccf17Sopenharmony_ci HRIL_ERR_CALL_CAUSE = 5 7611fccf17Sopenharmony_ci} HRilLastCallErrorCode; 7711fccf17Sopenharmony_ci 7811fccf17Sopenharmony_citypedef enum { 7911fccf17Sopenharmony_ci HRIL_CALL_MODE_CS_ONLY = 1, 8011fccf17Sopenharmony_ci HRIL_CALL_MODE_CS_1ST_PS_2ND, 8111fccf17Sopenharmony_ci HRIL_CALL_MODE_PS_1ST_CS_2ND, 8211fccf17Sopenharmony_ci HRIL_CALL_MODE_PS_ONLY, 8311fccf17Sopenharmony_ci} HRilVoiceCallMode; 8411fccf17Sopenharmony_ci 8511fccf17Sopenharmony_citypedef enum { 8611fccf17Sopenharmony_ci HRIL_RADIO_POWER_STATE_UNAVAILABLE = -1, 8711fccf17Sopenharmony_ci HRIL_RADIO_POWER_STATE_OFF = 0, 8811fccf17Sopenharmony_ci HRIL_RADIO_POWER_STATE_ON = 1, 8911fccf17Sopenharmony_ci} HRilRadioState; 9011fccf17Sopenharmony_ci 9111fccf17Sopenharmony_citypedef enum { 9211fccf17Sopenharmony_ci HRIL_DSDS_MODE_V2 = 0, 9311fccf17Sopenharmony_ci HRIL_DSDS_MODE_V3 = 1, 9411fccf17Sopenharmony_ci} HRilDsdsMode; 9511fccf17Sopenharmony_ci 9611fccf17Sopenharmony_citypedef enum { HRIL_CALL_VOICE, HRIL_CALL_DATA, HRIL_CALL_FAX } HRilCallMode; 9711fccf17Sopenharmony_ci 9811fccf17Sopenharmony_citypedef enum { 9911fccf17Sopenharmony_ci NO_REG_MT_NO_SEARCH = 0, 10011fccf17Sopenharmony_ci REG_MT_HOME = 1, 10111fccf17Sopenharmony_ci NO_REG_MT_SEARCHING = 2, 10211fccf17Sopenharmony_ci REG_MT_REJECTED = 3, 10311fccf17Sopenharmony_ci REG_MT_UNKNOWN = 4, 10411fccf17Sopenharmony_ci REG_MT_ROAMING = 5, 10511fccf17Sopenharmony_ci REG_MT_EMERGENCY = 6, 10611fccf17Sopenharmony_ci} HRilRegStatus; 10711fccf17Sopenharmony_ci 10811fccf17Sopenharmony_citypedef enum { 10911fccf17Sopenharmony_ci REG_NOT_NOTIFY = 0, /* AT command: +CREG,+CGREG,+CEREG,+C5GREG,n=0,Turn off notify function */ 11011fccf17Sopenharmony_ci REG_NOTIFY_STAT_ONLY, /* AT command: +CREG,+CGREG,+CEREG,+C5GREG,n=1,notify data format type 1 */ 11111fccf17Sopenharmony_ci REG_NOTIFY_STAT_LAC_CELLID, /* AT command: +CREG,+CGREG,+CEREG,+C5GREG,n=2,notify data format type 2 */ 11211fccf17Sopenharmony_ci} HRilRegNotifyMode; 11311fccf17Sopenharmony_ci 11411fccf17Sopenharmony_ci// 3GPP TS 27.007 V3.9.0 (2001-06) 7.11 Call forwarding number and conditions +CCFC 11511fccf17Sopenharmony_citypedef enum { 11611fccf17Sopenharmony_ci CALL_FORWARD_REASON_UNCONDITIONAL, 11711fccf17Sopenharmony_ci CALL_FORWARD_REASON_MOBILE_BUSY, 11811fccf17Sopenharmony_ci CALL_FORWARD_REASON_NO_REPLY, 11911fccf17Sopenharmony_ci CALL_FORWARD_REASON_NO_REACHABLE, 12011fccf17Sopenharmony_ci CALL_FORWARD_REASON_ALL_CF, /* all call forwarding (refer 3GPP TS 22.030 [19]) */ 12111fccf17Sopenharmony_ci CALL_FORWARD_REASON_ALL_CCF, /* all conditional call forwarding */ 12211fccf17Sopenharmony_ci} CallForwardReasonType; 12311fccf17Sopenharmony_ci 12411fccf17Sopenharmony_ci// 3GPP TS 27.007 V3.9.0 (2001-06) 7.11 Call forwarding number and conditions +CCFC 12511fccf17Sopenharmony_citypedef enum { 12611fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_VOICE = 1, 12711fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_DATA = 2, 12811fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_FAX = 4, 12911fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_SMS = 8, /* short message service */ 13011fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_DCS = 16, /* data circuit sync */ 13111fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_DCAS = 32, /* dedicated packet access */ 13211fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_DPA = 64, /* all conditional call forwarding */ 13311fccf17Sopenharmony_ci CALL_FORWARD_CLASS_X_DPADA = 128, /* dedicated PAD access */ 13411fccf17Sopenharmony_ci} CallForwardClassX; 13511fccf17Sopenharmony_ci 13611fccf17Sopenharmony_ci// 3GPP TS 27.007 V3.9.0 (2001-06) 7.11 Call forwarding number and conditions +CCFC 13711fccf17Sopenharmony_citypedef enum { 13811fccf17Sopenharmony_ci CALL_FORWARD_MODE_DISABLE, 13911fccf17Sopenharmony_ci CALL_FORWARD_MODE_ENABLE, 14011fccf17Sopenharmony_ci CALL_FORWARD_MODE_QUERY_STATUS, 14111fccf17Sopenharmony_ci CALL_FORWARD_MODE_REGISTRATION, 14211fccf17Sopenharmony_ci CALL_FORWARD_MODE_ERASURE, 14311fccf17Sopenharmony_ci} CallForwardMode; 14411fccf17Sopenharmony_ci 14511fccf17Sopenharmony_ci// 3GPP TS 27.007 V3.9.0 (2001-06) Call related supplementary services +CHLD 14611fccf17Sopenharmony_ci// 3GPP TS 27.007 V3.9.0 (2001-06) 7.22 Informative examples 14711fccf17Sopenharmony_citypedef enum { 14811fccf17Sopenharmony_ci TYPE_HANG_UP_HOLD_WAIT = 1, 14911fccf17Sopenharmony_ci TYPE_HANG_UP_ACTIVE = 2, 15011fccf17Sopenharmony_ci} HRilCallSupplementType; 15111fccf17Sopenharmony_ci 15211fccf17Sopenharmony_citypedef enum { 15311fccf17Sopenharmony_ci HRIL_RESPONSE = 0, 15411fccf17Sopenharmony_ci HRIL_NOTIFICATION = 1, 15511fccf17Sopenharmony_ci} ReportType; 15611fccf17Sopenharmony_ci 15711fccf17Sopenharmony_citypedef enum { 15811fccf17Sopenharmony_ci HRIL_UNLOCK_SUCCESS = 0, 15911fccf17Sopenharmony_ci HRIL_UNLOCK_PASSWORD_ERR = 1, 16011fccf17Sopenharmony_ci HRIL_UNLOCK_OTHER_ERR = 2, 16111fccf17Sopenharmony_ci} PinPukResultType; 16211fccf17Sopenharmony_ci 16311fccf17Sopenharmony_citypedef enum { 16411fccf17Sopenharmony_ci HRIL_REPORT_ERR_TYPE_NONE = 0, 16511fccf17Sopenharmony_ci HRIL_REPORT_ERR_TYPE_GENERIC, 16611fccf17Sopenharmony_ci HRIL_REPORT_ERR_TYPE_CME, 16711fccf17Sopenharmony_ci HRIL_REPORT_ERR_TYPE_CMS, 16811fccf17Sopenharmony_ci} ReportErrorType; 16911fccf17Sopenharmony_ci 17011fccf17Sopenharmony_citypedef enum { 17111fccf17Sopenharmony_ci NETWORK_TYPE_UNKNOWN = 0, /* indicates no cell information */ 17211fccf17Sopenharmony_ci NETWORK_TYPE_GSM, 17311fccf17Sopenharmony_ci NETWORK_TYPE_CDMA, 17411fccf17Sopenharmony_ci NETWORK_TYPE_WCDMA, 17511fccf17Sopenharmony_ci NETWORK_TYPE_TDSCDMA, 17611fccf17Sopenharmony_ci NETWORK_TYPE_LTE, 17711fccf17Sopenharmony_ci NETWORK_TYPE_NR 17811fccf17Sopenharmony_ci} RatType; /* Radio Access Technology */ 17911fccf17Sopenharmony_ci 18011fccf17Sopenharmony_citypedef enum { 18111fccf17Sopenharmony_ci HRIL_SIM_NOT_READY = -1, 18211fccf17Sopenharmony_ci HRIL_SIM_NOT_INSERTED = 0, 18311fccf17Sopenharmony_ci HRIL_SIM_READY = 1, 18411fccf17Sopenharmony_ci HRIL_SIM_PIN, 18511fccf17Sopenharmony_ci HRIL_SIM_PUK, 18611fccf17Sopenharmony_ci HRIL_SIM_PIN2, 18711fccf17Sopenharmony_ci HRIL_SIM_PUK2, 18811fccf17Sopenharmony_ci HRIL_PH_NET_PIN, 18911fccf17Sopenharmony_ci HRIL_PH_NET_PUK, 19011fccf17Sopenharmony_ci HRIL_PH_NET_SUB_PIN, 19111fccf17Sopenharmony_ci HRIL_PH_NET_SUB_PUK, 19211fccf17Sopenharmony_ci HRIL_PH_SP_PIN, 19311fccf17Sopenharmony_ci HRIL_PH_SP_PUK 19411fccf17Sopenharmony_ci} HRilSimState; 19511fccf17Sopenharmony_ci 19611fccf17Sopenharmony_citypedef enum { 19711fccf17Sopenharmony_ci HRIL_PIN_STATE_UNKNOWN, 19811fccf17Sopenharmony_ci HRIL_PIN_NOT_VERIFIED, 19911fccf17Sopenharmony_ci HRIL_PIN_VERIFIED, 20011fccf17Sopenharmony_ci HRIL_PIN_DISABLED, 20111fccf17Sopenharmony_ci HRIL_PIN_BLOCKED_ENABLED, 20211fccf17Sopenharmony_ci HRIL_PIN_BLOCKED_PERM 20311fccf17Sopenharmony_ci} HRilSimPinState; 20411fccf17Sopenharmony_ci 20511fccf17Sopenharmony_citypedef enum { 20611fccf17Sopenharmony_ci HRIL_NETWORK_AUTO = 0, 20711fccf17Sopenharmony_ci HRIL_NETWORK_GSM = 1, 20811fccf17Sopenharmony_ci HRIL_NETWORK_WCDMA = 2, 20911fccf17Sopenharmony_ci HRIL_NETWORK_LTE = 3, 21011fccf17Sopenharmony_ci HRIL_NETWORK_LTE_WCDMA = 4, 21111fccf17Sopenharmony_ci HRIL_NETWORK_LTE_WCDMA_GSM = 5, 21211fccf17Sopenharmony_ci HRIL_NETWORK_WCDMA_GSM = 6, 21311fccf17Sopenharmony_ci HRIL_NETWORK_CDMA = 7, 21411fccf17Sopenharmony_ci HRIL_NETWORK_EVDO = 8, 21511fccf17Sopenharmony_ci HRIL_NETWORK_EVDO_CDMA = 9, 21611fccf17Sopenharmony_ci HRIL_NETWORK_WCDMA_GSM_EVDO_CDMA = 10, 21711fccf17Sopenharmony_ci HRIL_NETWORK_LTE_EVDO_CDMA = 11, 21811fccf17Sopenharmony_ci HRIL_NETWORK_LTE_WCDMA_GSM_EVDO_CDMA = 12, 21911fccf17Sopenharmony_ci HRIL_NETWORK_TDSCDMA = 13, 22011fccf17Sopenharmony_ci HRIL_NETWORK_TDSCDMA_GSM = 14, 22111fccf17Sopenharmony_ci HRIL_NETWORK_TDSCDMA_WCDMA = 15, 22211fccf17Sopenharmony_ci HRIL_NETWORK_TDSCDMA_WCDMA_GSM = 16, 22311fccf17Sopenharmony_ci HRIL_NETWORK_LTE_TDSCDMA = 17, 22411fccf17Sopenharmony_ci HRIL_NETWORK_LTE_TDSCDMA_GSM = 18, 22511fccf17Sopenharmony_ci HRIL_NETWORK_LTE_TDSCDMA_WCDMA = 19, 22611fccf17Sopenharmony_ci HRIL_NETWORK_LTE_TDSCDMA_WCDMA_GSM = 20, 22711fccf17Sopenharmony_ci HRIL_NETWORK_TDSCDMA_WCDMA_GSM_EVDO_CDMA = 21, 22811fccf17Sopenharmony_ci HRIL_NETWORK_LTE_TDSCDMA_WCDMA_GSM_EVDO_CDMA = 22, 22911fccf17Sopenharmony_ci HRIL_NETWORK_NR = 31, 23011fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE = 32, 23111fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_WCDMA = 33, 23211fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_WCDMA_GSM = 34, 23311fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_EVDO_CDMA = 35, 23411fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_WCDMA_GSM_EVDO_CDMA = 36, 23511fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_TDSCDMA = 37, 23611fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_TDSCDMA_GSM = 38, 23711fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_TDSCDMA_WCDMA = 39, 23811fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_TDSCDMA_WCDMA_GSM = 40, 23911fccf17Sopenharmony_ci HRIL_NETWORK_NR_LTE_TDSCDMA_WCDMA_GSM_EVDO_CDMA = 41, 24011fccf17Sopenharmony_ci} HRilPreferredNetworkType; 24111fccf17Sopenharmony_ci 24211fccf17Sopenharmony_citypedef enum { 24311fccf17Sopenharmony_ci HRIL_USIM_INVALID = 0, 24411fccf17Sopenharmony_ci HRIL_USIM_VALID = 1, 24511fccf17Sopenharmony_ci HRIL_USIM_CS_INVALID = 2, 24611fccf17Sopenharmony_ci HRIL_USIM_PS_INVALID = 3, 24711fccf17Sopenharmony_ci HRIL_USIM_CS_PS_INVALID = 4, 24811fccf17Sopenharmony_ci HRIL_ROM_SIM = 240, 24911fccf17Sopenharmony_ci HRIL_NO_USIM = 255, 25011fccf17Sopenharmony_ci} HRilSimStatus; 25111fccf17Sopenharmony_ci 25211fccf17Sopenharmony_citypedef enum { 25311fccf17Sopenharmony_ci HRIL_SIM_CARD_UNLOCK = 0, 25411fccf17Sopenharmony_ci HRIL_SIM_CARD_LOCK = 1, 25511fccf17Sopenharmony_ci} HRilSimLockStatus; 25611fccf17Sopenharmony_ci 25711fccf17Sopenharmony_citypedef enum { 25811fccf17Sopenharmony_ci HRIL_NO_ROAM = 0, 25911fccf17Sopenharmony_ci HRIL_ROAMING = 1, 26011fccf17Sopenharmony_ci HRIL_ROAM_UNKNOWN = 2, 26111fccf17Sopenharmony_ci} HRilRoamStatus; 26211fccf17Sopenharmony_ci 26311fccf17Sopenharmony_citypedef enum { 26411fccf17Sopenharmony_ci HRIL_NO_SRV_SERVICE = 0, 26511fccf17Sopenharmony_ci HRIL_RESTRICTED_SERVICE = 1, 26611fccf17Sopenharmony_ci HRIL_SERVICE_VALID = 2, 26711fccf17Sopenharmony_ci HRIL_REGIONAL_SERVICE = 3, 26811fccf17Sopenharmony_ci HRIL_ENERGY_SAVING_SERVICE = 4, 26911fccf17Sopenharmony_ci} HRilSrvStatus; 27011fccf17Sopenharmony_ci 27111fccf17Sopenharmony_citypedef enum { 27211fccf17Sopenharmony_ci HRIL_NO_DOMAIN_SERVICE = 0, 27311fccf17Sopenharmony_ci HRIL_CS_SERVICE = 1, 27411fccf17Sopenharmony_ci HRIL_PS_SERVICE = 2, 27511fccf17Sopenharmony_ci HRIL_CS_PS_SERVICE = 3, 27611fccf17Sopenharmony_ci HRIL_CS_PS_SEARCHING = 4, 27711fccf17Sopenharmony_ci HRIL_CDMA_NOT_SUPPORT = 255, 27811fccf17Sopenharmony_ci} HRilSrvDomain; 27911fccf17Sopenharmony_ci 28011fccf17Sopenharmony_citypedef enum { 28111fccf17Sopenharmony_ci HRIL_NO_SYSMODE_SERVICE = 0, 28211fccf17Sopenharmony_ci HRIL_GSM_MODE = 1, 28311fccf17Sopenharmony_ci HRIL_CDMA_MODE = 2, 28411fccf17Sopenharmony_ci HRIL_WCDMA_MODE = 3, 28511fccf17Sopenharmony_ci HRIL_TDSCDMA_MODE = 4, 28611fccf17Sopenharmony_ci HRIL_WIMAX_MODE = 5, 28711fccf17Sopenharmony_ci HRIL_LTE_MODE = 6, 28811fccf17Sopenharmony_ci HRIL_LTE_CA_MODE = 7, 28911fccf17Sopenharmony_ci HRIL_NR_MODE = 8, 29011fccf17Sopenharmony_ci} HRilSysMode; 29111fccf17Sopenharmony_ci 29211fccf17Sopenharmony_citypedef enum { 29311fccf17Sopenharmony_ci HRIL_ACT_NO_SERVICE = 0, 29411fccf17Sopenharmony_ci HRIL_ACT_GSM = 1, 29511fccf17Sopenharmony_ci HRIL_ACT_GPRS = 2, 29611fccf17Sopenharmony_ci HRIL_ACT_EDGE = 3, 29711fccf17Sopenharmony_ci HRIL_ACT_IS95A = 21, 29811fccf17Sopenharmony_ci HRIL_ACT_IS95B = 22, 29911fccf17Sopenharmony_ci HRIL_ACT_CDMA2000_1X = 23, 30011fccf17Sopenharmony_ci HRIL_ACT_EVDO_REL0 = 24, 30111fccf17Sopenharmony_ci HRIL_ACT_EVDO_RELA = 25, 30211fccf17Sopenharmony_ci HRIL_ACT_EVDO_RELB = 26, 30311fccf17Sopenharmony_ci HRIL_ACT_HYBRID_CDMA2000_1X = 27, 30411fccf17Sopenharmony_ci HRIL_ACT_HYBRID_EVDO_REL0 = 28, 30511fccf17Sopenharmony_ci HRIL_ACT_HYBRID_EVDO_RELA = 29, 30611fccf17Sopenharmony_ci HRIL_ACT_HYBRID_EVDO_RELB = 30, 30711fccf17Sopenharmony_ci HRIL_ACT_WCDMA = 41, 30811fccf17Sopenharmony_ci HRIL_ACT_HSDPA = 42, 30911fccf17Sopenharmony_ci HRIL_ACT_HSUPA = 43, 31011fccf17Sopenharmony_ci HRIL_ACT_HSPA = 44, 31111fccf17Sopenharmony_ci HRIL_ACT_HSPAP = 45, 31211fccf17Sopenharmony_ci HRIL_ACT_DC_HSPAP = 46, 31311fccf17Sopenharmony_ci HRIL_ACT_TDSCDMA = 61, 31411fccf17Sopenharmony_ci HRIL_ACT_802_16E = 81, 31511fccf17Sopenharmony_ci HRIL_ACT_LTE = 101, 31611fccf17Sopenharmony_ci HRIL_ACT_LTE_CA, 31711fccf17Sopenharmony_ci HRIL_ACT_NR, 31811fccf17Sopenharmony_ci} HRilVoiceSubMode; 31911fccf17Sopenharmony_ci 32011fccf17Sopenharmony_citypedef enum { 32111fccf17Sopenharmony_ci RADIO_TECHNOLOGY_UNKNOWN = 0, 32211fccf17Sopenharmony_ci RADIO_TECHNOLOGY_GSM = 1, 32311fccf17Sopenharmony_ci RADIO_TECHNOLOGY_1XRTT = 2, 32411fccf17Sopenharmony_ci RADIO_TECHNOLOGY_WCDMA = 3, 32511fccf17Sopenharmony_ci RADIO_TECHNOLOGY_HSPA = 4, 32611fccf17Sopenharmony_ci RADIO_TECHNOLOGY_HSPAP = 5, 32711fccf17Sopenharmony_ci RADIO_TECHNOLOGY_TD_SCDMA = 6, 32811fccf17Sopenharmony_ci RADIO_TECHNOLOGY_EVDO = 7, 32911fccf17Sopenharmony_ci RADIO_TECHNOLOGY_EHRPD = 8, 33011fccf17Sopenharmony_ci RADIO_TECHNOLOGY_LTE = 9, 33111fccf17Sopenharmony_ci RADIO_TECHNOLOGY_LTE_CA = 10, 33211fccf17Sopenharmony_ci RADIO_TECHNOLOGY_IWLAN = 11, 33311fccf17Sopenharmony_ci RADIO_TECHNOLOGY_NR = 12, 33411fccf17Sopenharmony_ci RADIO_TECHNOLOGY_INVALID = 65535, 33511fccf17Sopenharmony_ci} HRilRadioTech; 33611fccf17Sopenharmony_ci 33711fccf17Sopenharmony_ci/* reference 3GPP TS 24.008 V17.4.0 (2021-09) 33811fccf17Sopenharmony_ci * Unsuccessful PDP context activation initiated by the MS */ 33911fccf17Sopenharmony_citypedef enum { 34011fccf17Sopenharmony_ci HRIL_PDP_ERR_NONE = 0, 34111fccf17Sopenharmony_ci HRIL_PDP_ERR_RETRY, 34211fccf17Sopenharmony_ci HRIL_PDP_ERR_UNKNOWN = 65535, /* Unknown error */ 34311fccf17Sopenharmony_ci HRIL_PDP_ERR_OPERATOR_DETERMINED_BARRING = 8, /* Operator Determined Barring---No need to retry */ 34411fccf17Sopenharmony_ci HRIL_PDP_ERR_SHORTAGE_RESOURCES = 26, /* insufficient resources */ 34511fccf17Sopenharmony_ci HRIL_PDP_ERR_MISSING_OR_UNKNOWN_APN, /* missing or unknown APN---No need to retry */ 34611fccf17Sopenharmony_ci HRIL_PDP_ERR_UNKNOWN_PDP_ADDR_OR_TYPE, /* unknown PDP address or PDP type---No need to retry */ 34711fccf17Sopenharmony_ci HRIL_PDP_ERR_USER_VERIFICATION, /* user authentication failed---No need to retry */ 34811fccf17Sopenharmony_ci HRIL_PDP_ERR_ACTIVATION_REJECTED_GGSN, /* activation rejected by GGSN, Serving GW or PDN GW---No need to retry */ 34911fccf17Sopenharmony_ci HRIL_PDP_ERR_ACTIVATION_REJECTED_UNSPECIFIED, /* activation rejected, unspecified */ 35011fccf17Sopenharmony_ci HRIL_PDP_ERR_SERVICE_OPTION_NOT_SUPPORTED, /* service option not supported---No need to retry */ 35111fccf17Sopenharmony_ci HRIL_PDP_ERR_REQUESTED_SERVICE_OPTION_NOT_SUBSCRIBED, /* requested service option not subscribed 35211fccf17Sopenharmony_ci * ---No need to retry */ 35311fccf17Sopenharmony_ci HRIL_PDP_ERR_SERVICE_OPTION_TEMPORARILY_OUT_OF_ORDER, /* service option temporarily out of order */ 35411fccf17Sopenharmony_ci HRIL_PDP_ERR_NSAPI_ALREADY_USED, /* NSAPI already used---No need to retry */ 35511fccf17Sopenharmony_ci HRIL_PDP_ERR_IPV4_ONLY_ALLOWED = 50, /* PDP type IPv4 only allowed---No need to retry */ 35611fccf17Sopenharmony_ci HRIL_PDP_ERR_IPV6_ONLY_ALLOWED, /* PDP type IPv6 only allowed---No need to retry */ 35711fccf17Sopenharmony_ci HRIL_PDP_ERR_IPV4V6_ONLY_ALLOWED = 57, /* PDP type IPv4v6 only allowed---No need to retry */ 35811fccf17Sopenharmony_ci HRIL_PDP_ERR_NON_IP_ONLY_ALLOWED, /* PDP type non IP only allowed---No need to retry */ 35911fccf17Sopenharmony_ci HRIL_PDP_ERR_MAX_NUM_OF_PDP_CONTEXTS = 65, /* maximum number of PDP contexts reached---No need to retry */ 36011fccf17Sopenharmony_ci HRIL_PDP_ERR_APN_NOT_SUPPORTED_IN_CURRENT_RAT_PLMN, /* requested APN not supported in current RAT 36111fccf17Sopenharmony_ci * and PLMN combination */ 36211fccf17Sopenharmony_ci HRIL_PDP_ERR_PROTOCOL_ERRORS = 95, /* #95 - 111: protocol errors---No need to retry */ 36311fccf17Sopenharmony_ci HRIL_PDP_ERR_APN_RESTRICTION_VALUE_INCOMPATIBLE = 112, /* APN restriction value incompatible 36411fccf17Sopenharmony_ci * with active PDP context */ 36511fccf17Sopenharmony_ci HRIL_PDP_ERR_MULT_ACCESSES_PDN_NOT_ALLOWED = 113, /* Multiple accesses to a PDN connection not allowed */ 36611fccf17Sopenharmony_ci} HRilPdpErrorReason; 36711fccf17Sopenharmony_ci 36811fccf17Sopenharmony_citypedef enum { 36911fccf17Sopenharmony_ci HRIL_EVENT_COUNT_0 = 0, 37011fccf17Sopenharmony_ci HRIL_EVENT_COUNT_1, 37111fccf17Sopenharmony_ci HRIL_EVENT_COUNT_2, 37211fccf17Sopenharmony_ci HRIL_EVENT_COUNT_3, 37311fccf17Sopenharmony_ci HRIL_EVENT_COUNT_4 37411fccf17Sopenharmony_ci} HRilSendEventCount; 37511fccf17Sopenharmony_ci 37611fccf17Sopenharmony_citypedef enum { HRIL_SIM_TYPE_UNKNOWN = 0, HRIL_SIM_TYPE_SIM, HRIL_SIM_TYPE_USIM } HRilSimType; 37711fccf17Sopenharmony_ci 37811fccf17Sopenharmony_citypedef enum { HRIL_UNNEED_ACK = 0, HRIL_NEED_ACK } HRilAckTypes; 37911fccf17Sopenharmony_ci 38011fccf17Sopenharmony_citypedef enum { 38111fccf17Sopenharmony_ci NOTIFICATION_FILTER_ALL = -1, 38211fccf17Sopenharmony_ci NOTIFICATION_FILTER_NONE = 0, 38311fccf17Sopenharmony_ci NOTIFICATION_FILTER_SIGNAL_STRENGTH = 1, 38411fccf17Sopenharmony_ci NOTIFICATION_FILTER_NETWORK_STATE = 2, 38511fccf17Sopenharmony_ci NOTIFICATION_FILTER_DATA_CALL = 4, 38611fccf17Sopenharmony_ci NOTIFICATION_FILTER_LINK_CAPACITY = 8, 38711fccf17Sopenharmony_ci NOTIFICATION_FILTER_PHYSICAL_CHANNEL_CONFIG = 16 38811fccf17Sopenharmony_ci} HRilNotificationFilter; 38911fccf17Sopenharmony_ci 39011fccf17Sopenharmony_citypedef enum { 39111fccf17Sopenharmony_ci POWER_SAVE_MODE, 39211fccf17Sopenharmony_ci CHARGING_STATE, 39311fccf17Sopenharmony_ci LOW_DATA_STATE 39411fccf17Sopenharmony_ci} HRilDeviceStateType; 39511fccf17Sopenharmony_ci 39611fccf17Sopenharmony_citypedef enum { 39711fccf17Sopenharmony_ci HRIL_SERVING_CELL_UNKNOWN, 39811fccf17Sopenharmony_ci HRIL_SERVING_CELL_PRIMARY, 39911fccf17Sopenharmony_ci HRIL_SERVING_CELL_SECONDARY 40011fccf17Sopenharmony_ci} HRilCellConnectionStatus; 40111fccf17Sopenharmony_ci 40211fccf17Sopenharmony_citypedef enum { 40311fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_PHASE_INITIAL, /* LM is configured is initial value and value after COMPLETE. */ 40411fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_PHASE_CHECK, /* CHECK is sent before UPDATE and indicates that an UPDATE will be 40511fccf17Sopenharmony_ci * forthcoming with these same parameters. */ 40611fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_PHASE_UPDATE, /* UPDATE is sent after all LM's receive CHECK and returned success, 40711fccf17Sopenharmony_ci * if any CHECK's fail no UPDATE will be sent. */ 40811fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_PHASE_NOTIFY, /* NOTIFY is sent with HNOTI_SIM_RADIO_PROTOCOL_UPDATED. */ 40911fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_PHASE_COMPLETE /* COMPLETE is sent after all previous phases have completed. 41011fccf17Sopenharmony_ci * If an error occurs in any previous commands the 41111fccf17Sopenharmony_ci * and fields will be the prior configuration thus 41211fccf17Sopenharmony_ci * restoring the configuration to the previous value. An error returned 41311fccf17Sopenharmony_ci * by this command will generally be ignored or may cause that logical 41411fccf17Sopenharmony_ci * modem to be removed from service */ 41511fccf17Sopenharmony_ci} HRilRadioProtocolPhase; 41611fccf17Sopenharmony_ci 41711fccf17Sopenharmony_citypedef enum { 41811fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_UNKNOWN = 1 << RADIO_TECHNOLOGY_UNKNOWN, 41911fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_GSM = 1 << RADIO_TECHNOLOGY_GSM, 42011fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_1XRTT = 1 << RADIO_TECHNOLOGY_1XRTT, 42111fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_WCDMA = 1 << RADIO_TECHNOLOGY_WCDMA, 42211fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_HSPA = 1 << RADIO_TECHNOLOGY_HSPA, 42311fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_HSPAP = 1 << RADIO_TECHNOLOGY_HSPAP, 42411fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_TD_SCDMA = 1 << RADIO_TECHNOLOGY_TD_SCDMA, 42511fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_EVDO = 1 << RADIO_TECHNOLOGY_EVDO, 42611fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_EHRPD = 1 << RADIO_TECHNOLOGY_EHRPD, 42711fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_LTE = 1 << RADIO_TECHNOLOGY_LTE, 42811fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_LTE_CA = 1 << RADIO_TECHNOLOGY_LTE_CA, 42911fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_IWLAN = 1 << RADIO_TECHNOLOGY_IWLAN, 43011fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_TECH_NR = 1 << RADIO_TECHNOLOGY_NR 43111fccf17Sopenharmony_ci} HRilRadioProtocolTech; 43211fccf17Sopenharmony_ci 43311fccf17Sopenharmony_citypedef enum { 43411fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_STATUS_NONE, 43511fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_STATUS_SUCCESS, 43611fccf17Sopenharmony_ci HRIL_RADIO_PROTOCOL_STATUS_FAIL 43711fccf17Sopenharmony_ci} HRilRadioProtocolStatus; 43811fccf17Sopenharmony_ci 43911fccf17Sopenharmony_citypedef enum { 44011fccf17Sopenharmony_ci TTY_MODE_OFF = 0, 44111fccf17Sopenharmony_ci TTY_MODE_FULL, 44211fccf17Sopenharmony_ci TTY_MODE_HCO, 44311fccf17Sopenharmony_ci TTY_MODE_VCO 44411fccf17Sopenharmony_ci} TTYMode; 44511fccf17Sopenharmony_ci 44611fccf17Sopenharmony_citypedef enum { 44711fccf17Sopenharmony_ci CARD_POWER_DOWN = 0, 44811fccf17Sopenharmony_ci CARD_POWER_UP, 44911fccf17Sopenharmony_ci CARD_POWER_UP_PASS_THROUGH 45011fccf17Sopenharmony_ci} CardPowerState; 45111fccf17Sopenharmony_ci 45211fccf17Sopenharmony_ci#endif // OHOS_HRIL_ENUM_H 453