Snapdragon® Telematics Application Framework (TelAF) Interface Specification
taf_sim_common.h File Reference
#include "legato.h"

Go to the source code of this file.

Macros

#define IFGEN_TAF_SIM_PROTOCOL_ID   "1bf8e2e6d7dcd853d8db5a4aa2c228f4"
 
#define IFGEN_TAF_SIM_MSG_SIZE   276
 
#define TAF_SIM_INSERTED   0
 
#define TAF_SIM_BLOCKED   3
 
#define TAF_SIM_POWER_DOWN   8
 
#define TAF_SIM_EXTERNAL_SLOT_1   1
 
#define TAF_SIM_EXTERNAL_SLOT_2   2
 
#define TAF_SIM_PIN_MIN_LEN   4
 
#define TAF_SIM_PIN_MAX_LEN   8
 
#define TAF_SIM_PIN_MAX_BYTES   9
 
#define TAF_SIM_PUK_MAX_LEN   8
 
#define TAF_SIM_PUK_MAX_BYTES   9
 
#define TAF_SIM_IMSI_LEN   15
 
#define TAF_SIM_IMSI_BYTES   16
 
#define TAF_SIM_RESPONSE_MAX_BYTES   256
 
#define TAF_SIM_PHONE_NUM_MAX_LEN   17
 
#define TAF_SIM_PHONE_NUM_MAX_BYTES   18
 
#define TAF_SIM_ICCID_LEN   20
 
#define TAF_SIM_ICCID_BYTES   21
 
#define TAF_SIM_EID_LEN   32
 
#define TAF_SIM_EID_BYTES   33
 
#define TAF_SIM_APDU_MAX_BYTES   255
 
#define TAF_SIM_FILE_ID_LEN   4
 
#define TAF_SIM_FILE_ID_BYTES   5
 
#define TAF_SIM_DATA_MAX_BYTES   100
 
#define TAF_SIM_PATH_MAX_LEN   100
 
#define TAF_SIM_PATH_MAX_BYTES   101
 
#define TAF_SIM_AID_MAX_LEN   4
 
#define TAF_SIM_FPLMN_MAX_LISTS   1
 
#define TAF_SIM_FPLMN_MAX_OPERATORS_PER_LIST   5
 

Typedefs

typedef struct taf_sim_FPLMNList * taf_sim_FPLMNListRef_t
 
typedef struct taf_sim_NewStateHandler * taf_sim_NewStateHandlerRef_t
 
typedef struct taf_sim_AuthenticationResponseHandler * taf_sim_AuthenticationResponseHandlerRef_t
 
typedef struct taf_sim_IccidChangeHandler * taf_sim_IccidChangeHandlerRef_t
 
typedef void(* taf_sim_NewStateHandlerFunc_t) (taf_sim_Id_t slotId, taf_sim_States_t state, void *contextPtr)
 
typedef void(* taf_sim_AuthenticationResponseHandlerFunc_t) (taf_sim_Id_t slotId, taf_sim_LockResponse_t responsetype, le_result_t result, void *contextPtr)
 
typedef void(* taf_sim_IccidChangeHandlerFunc_t) (taf_sim_Id_t simId, const char *LE_NONNULL iccid, void *contextPtr)
 

Enumerations

enum  taf_sim_States_t {
  TAF_SIM_PRESENT = 0, TAF_SIM_ABSENT = 1, TAF_SIM_READY = 2, TAF_SIM_RESTRICTED = 3,
  TAF_SIM_BUSY = 4, TAF_SIM_ERROR = 5, TAF_SIM_STATE_UNKNOWN = 6, TAF_SIM_ERROR_UNKNOWN = 7,
  TAF_SIM_ERROR_POWER_DOWN = 8, TAF_SIM_ERROR_POLL_ERROR = 9, TAF_SIM_ERROR_NO_ATR_RECEIVED = 10, TAF_SIM_ERROR_VOLT_MISMATCH = 11,
  TAF_SIM_ERROR_PARITY_ERROR = 12, TAF_SIM_ERROR_POSSIBLY_REMOVED = 13, TAF_SIM_ERROR_TECHNICAL_PROBLEMS = 14, TAF_SIM_ERROR_NULL_BYTES = 15,
  TAF_SIM_ERROR_SAP_CONNECTED = 16, TAF_SIM_ERROR_CMD_TIMEOUT = 17
}
 
enum  taf_sim_Id_t {
  TAF_SIM_EMBEDDED = 0, TAF_SIM_SLOT_ID_1 = 1, TAF_SIM_SLOT_ID_2 = 2, TAF_SIM_REMOTE = 3,
  TAF_SIM_UNSPECIFIED = 4, TAF_SIM_ID_MAX = 5
}
 
enum  taf_sim_LockType_t {
  TAF_SIM_PIN1 = 0, TAF_SIM_PIN2 = 1, TAF_SIM_PUK1 = 2, TAF_SIM_PUK2 = 3,
  TAF_SIM_FDN = 4
}
 
enum  taf_sim_LockResponse_t { TAF_SIM_CHANGE_PIN = 0, TAF_SIM_UNLOCK_BY_PIN = 1, TAF_SIM_UNLOCK_BY_PUK = 2, TAF_SIM_SET_LOCK = 3 }
 
enum  taf_sim_AppType_t {
  TAF_SIM_APPTYPE_UNKNOWN = 0, TAF_SIM_APPTYPE_SIM = 1, TAF_SIM_APPTYPE_USIM = 2, TAF_SIM_APPTYPE_RUIM = 3,
  TAF_SIM_APPTYPE_CSIM = 4, TAF_SIM_APPTYPE_ISIM = 5
}
 
enum  taf_sim_Manufacturer_t {
  TAF_SIM_OBERTHUR = 0, TAF_SIM_GEMALTO = 1, TAF_SIM_G_AND_D = 2, TAF_SIM_MORPHO = 3,
  TAF_SIM_VALID = 4, TAF_SIM_MANUFACTURER_MAX = 5
}
 
enum  taf_sim_Command_t {
  TAF_SIM_READ_BINARY = 176, TAF_SIM_READ_RECORD = 178, TAF_SIM_GET_RESPONSE = 192, TAF_SIM_UPDATE_BINARY = 214,
  TAF_SIM_UPDATE_RECORD = 220, TAF_SIM_COMMAND_MAX = 221
}
 

Functions

LE_SHARED bool ifgen_taf_sim_HasLocalBinding (void)
 
LE_SHARED void ifgen_taf_sim_InitCommonData (void)
 
LE_SHARED void ifgen_taf_sim_CleanupCommonData (le_msg_SessionRef_t _ifgen_sessionRef)
 
LE_SHARED le_result_t ifgen_taf_sim_OpenSession (le_msg_SessionRef_t _ifgen_sessionRef, bool isBlocking)
 
LE_SHARED taf_sim_NewStateHandlerRef_t ifgen_taf_sim_AddNewStateHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_NewStateHandlerFunc_t handlerPtr, void *contextPtr)
 
LE_SHARED void ifgen_taf_sim_RemoveNewStateHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_NewStateHandlerRef_t handlerRef)
 
LE_SHARED taf_sim_AuthenticationResponseHandlerRef_t ifgen_taf_sim_AddAuthenticationResponseHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_AuthenticationResponseHandlerFunc_t handlerPtr, void *contextPtr)
 
LE_SHARED void ifgen_taf_sim_RemoveAuthenticationResponseHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_AuthenticationResponseHandlerRef_t handlerRef)
 
LE_SHARED bool ifgen_taf_sim_IsPresent (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId)
 
LE_SHARED taf_sim_States_t ifgen_taf_sim_GetState (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId)
 
LE_SHARED bool ifgen_taf_sim_IsReady (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId)
 
LE_SHARED le_result_t ifgen_taf_sim_GetICCID (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *iccid, size_t iccidSize)
 
LE_SHARED le_result_t ifgen_taf_sim_GetIMSI (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *imsi, size_t imsiSize)
 
LE_SHARED le_result_t ifgen_taf_sim_GetHomeNetworkOperator (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *nameStr, size_t nameStrSize)
 
LE_SHARED le_result_t ifgen_taf_sim_GetSubscriberPhoneNumber (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *phoneNumberStr, size_t phoneNumberStrSize)
 
LE_SHARED le_result_t ifgen_taf_sim_GetHomeNetworkMccMnc (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
 
LE_SHARED taf_sim_Id_t ifgen_taf_sim_GetSelectedCard (le_msg_SessionRef_t _ifgen_sessionRef)
 
LE_SHARED le_result_t ifgen_taf_sim_SelectCard (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId)
 
LE_SHARED le_result_t ifgen_taf_sim_EnterPIN (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_LockType_t lockType, const char *LE_NONNULL pin)
 
LE_SHARED le_result_t ifgen_taf_sim_ChangePIN (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_LockType_t lockType, const char *LE_NONNULL oldpin, const char *LE_NONNULL newpin)
 
LE_SHARED int32_t ifgen_taf_sim_GetRemainingPINTries (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId)
 
LE_SHARED le_result_t ifgen_taf_sim_GetRemainingPUKTries (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, uint32_t *remainingPukTriesPtrPtr)
 
LE_SHARED le_result_t ifgen_taf_sim_Unlock (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_LockType_t lockType, const char *LE_NONNULL pin)
 
LE_SHARED le_result_t ifgen_taf_sim_Lock (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_LockType_t lockType, const char *LE_NONNULL pin)
 
LE_SHARED le_result_t ifgen_taf_sim_Unblock (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_LockType_t lockType, const char *LE_NONNULL puk, const char *LE_NONNULL newpin)
 
LE_SHARED le_result_t ifgen_taf_sim_GetEID (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, char *eid, size_t eidSize)
 
LE_SHARED le_result_t ifgen_taf_sim_SetAutomaticSelection (le_msg_SessionRef_t _ifgen_sessionRef, bool enable)
 
LE_SHARED le_result_t ifgen_taf_sim_GetAutomaticSelection (le_msg_SessionRef_t _ifgen_sessionRef, bool *enablePtr)
 
LE_SHARED le_result_t ifgen_taf_sim_OpenLogicalChannel (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, taf_sim_AppType_t apptype, uint8_t *channelPtrPtr)
 
LE_SHARED le_result_t ifgen_taf_sim_CloseLogicalChannel (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t slotId, uint8_t channel)
 
LE_SHARED le_result_t ifgen_taf_sim_SendApduOnChannel (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, uint8_t channel, const uint8_t *commandApduPtr, size_t commandApduSize, uint8_t *responseApduPtr, size_t *responseApduSizePtr)
 
LE_SHARED le_result_t ifgen_taf_sim_SendApdu (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, const uint8_t *commandApduPtr, size_t commandApduSize, uint8_t *responseApduPtr, size_t *responseApduSizePtr)
 
LE_SHARED le_result_t ifgen_taf_sim_SendCommand (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, taf_sim_Command_t command, const char *LE_NONNULL fileIdentifier, uint8_t p1, uint8_t p2, uint8_t p3, const uint8_t *dataPtr, size_t dataSize, const char *LE_NONNULL path, uint8_t *sw1Ptr, uint8_t *sw2Ptr, uint8_t *responsePtr, size_t *responseSizePtr)
 
LE_SHARED le_result_t ifgen_taf_sim_LocalSwapToEmergencyCallSubscription (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, taf_sim_Manufacturer_t manufacturer)
 
LE_SHARED le_result_t ifgen_taf_sim_LocalSwapToCommercialSubscription (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, taf_sim_Manufacturer_t manufacturer)
 
LE_SHARED le_result_t ifgen_taf_sim_SetPower (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, le_onoff_t power)
 
LE_SHARED le_result_t ifgen_taf_sim_Reset (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId)
 
LE_SHARED le_result_t ifgen_taf_sim_IsEmergencyCallSubscriptionSelected (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, bool *isEcsPtr)
 
LE_SHARED taf_sim_IccidChangeHandlerRef_t ifgen_taf_sim_AddIccidChangeHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_IccidChangeHandlerFunc_t handlerPtr, void *contextPtr)
 
LE_SHARED void ifgen_taf_sim_RemoveIccidChangeHandler (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_IccidChangeHandlerRef_t handlerRef)
 
LE_SHARED taf_sim_FPLMNListRef_t ifgen_taf_sim_CreateFPLMNList (le_msg_SessionRef_t _ifgen_sessionRef)
 
LE_SHARED le_result_t ifgen_taf_sim_AddFPLMNOperator (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_FPLMNListRef_t fplmnListRef, const char *LE_NONNULL mcc, const char *LE_NONNULL mnc)
 
LE_SHARED le_result_t ifgen_taf_sim_GetFirstFPLMNOperator (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_FPLMNListRef_t fplmnListRef, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
 
LE_SHARED le_result_t ifgen_taf_sim_GetNextFPLMNOperator (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_FPLMNListRef_t fplmnListRef, char *mccPtr, size_t mccPtrSize, char *mncPtr, size_t mncPtrSize)
 
LE_SHARED taf_sim_FPLMNListRef_t ifgen_taf_sim_ReadFPLMNList (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId)
 
LE_SHARED void ifgen_taf_sim_DeleteFPLMNList (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_FPLMNListRef_t fplmnListRef)
 
LE_SHARED le_result_t ifgen_taf_sim_WriteFPLMNList (le_msg_SessionRef_t _ifgen_sessionRef, taf_sim_Id_t simId, taf_sim_FPLMNListRef_t fplmnListRef)
 
LE_SHARED le_result_t ifgen_taf_sim_GetSlotCount (le_msg_SessionRef_t _ifgen_sessionRef, int32_t *countPtr)
 

Macro Definition Documentation

◆ IFGEN_TAF_SIM_PROTOCOL_ID

#define IFGEN_TAF_SIM_PROTOCOL_ID   "1bf8e2e6d7dcd853d8db5a4aa2c228f4"

◆ IFGEN_TAF_SIM_MSG_SIZE

#define IFGEN_TAF_SIM_MSG_SIZE   276

◆ TAF_SIM_INSERTED

#define TAF_SIM_INSERTED   0

Legacy state support.

◆ TAF_SIM_BLOCKED

#define TAF_SIM_BLOCKED   3

◆ TAF_SIM_POWER_DOWN

#define TAF_SIM_POWER_DOWN   8

◆ TAF_SIM_EXTERNAL_SLOT_1

#define TAF_SIM_EXTERNAL_SLOT_1   1

Legacy slot ID support.

◆ TAF_SIM_EXTERNAL_SLOT_2

#define TAF_SIM_EXTERNAL_SLOT_2   2

◆ TAF_SIM_PIN_MIN_LEN

#define TAF_SIM_PIN_MIN_LEN   4

PIN length.

◆ TAF_SIM_PIN_MAX_LEN

#define TAF_SIM_PIN_MAX_LEN   8

◆ TAF_SIM_PIN_MAX_BYTES

#define TAF_SIM_PIN_MAX_BYTES   9

◆ TAF_SIM_PUK_MAX_LEN

#define TAF_SIM_PUK_MAX_LEN   8

PUK length.

◆ TAF_SIM_PUK_MAX_BYTES

#define TAF_SIM_PUK_MAX_BYTES   9

◆ TAF_SIM_IMSI_LEN

#define TAF_SIM_IMSI_LEN   15

◆ TAF_SIM_IMSI_BYTES

#define TAF_SIM_IMSI_BYTES   16

◆ TAF_SIM_RESPONSE_MAX_BYTES

#define TAF_SIM_RESPONSE_MAX_BYTES   256

◆ TAF_SIM_PHONE_NUM_MAX_LEN

#define TAF_SIM_PHONE_NUM_MAX_LEN   17

◆ TAF_SIM_PHONE_NUM_MAX_BYTES

#define TAF_SIM_PHONE_NUM_MAX_BYTES   18

◆ TAF_SIM_ICCID_LEN

#define TAF_SIM_ICCID_LEN   20

◆ TAF_SIM_ICCID_BYTES

#define TAF_SIM_ICCID_BYTES   21

◆ TAF_SIM_EID_LEN

#define TAF_SIM_EID_LEN   32

◆ TAF_SIM_EID_BYTES

#define TAF_SIM_EID_BYTES   33

◆ TAF_SIM_APDU_MAX_BYTES

#define TAF_SIM_APDU_MAX_BYTES   255

◆ TAF_SIM_FILE_ID_LEN

#define TAF_SIM_FILE_ID_LEN   4

◆ TAF_SIM_FILE_ID_BYTES

#define TAF_SIM_FILE_ID_BYTES   5

◆ TAF_SIM_DATA_MAX_BYTES

#define TAF_SIM_DATA_MAX_BYTES   100

◆ TAF_SIM_PATH_MAX_LEN

#define TAF_SIM_PATH_MAX_LEN   100

◆ TAF_SIM_PATH_MAX_BYTES

#define TAF_SIM_PATH_MAX_BYTES   101

◆ TAF_SIM_AID_MAX_LEN

#define TAF_SIM_AID_MAX_LEN   4

◆ TAF_SIM_FPLMN_MAX_LISTS

#define TAF_SIM_FPLMN_MAX_LISTS   1

◆ TAF_SIM_FPLMN_MAX_OPERATORS_PER_LIST

#define TAF_SIM_FPLMN_MAX_OPERATORS_PER_LIST   5

Typedef Documentation

◆ taf_sim_FPLMNListRef_t

typedef struct taf_sim_FPLMNList* taf_sim_FPLMNListRef_t

◆ taf_sim_NewStateHandlerRef_t

typedef struct taf_sim_NewStateHandler* taf_sim_NewStateHandlerRef_t

Reference type used by Add/Remove functions for EVENT 'taf_sim_NewState'

◆ taf_sim_AuthenticationResponseHandlerRef_t

typedef struct taf_sim_AuthenticationResponseHandler* taf_sim_AuthenticationResponseHandlerRef_t

Reference type used by Add/Remove functions for EVENT 'taf_sim_AuthenticationResponse'

◆ taf_sim_IccidChangeHandlerRef_t

typedef struct taf_sim_IccidChangeHandler* taf_sim_IccidChangeHandlerRef_t

Reference type used by Add/Remove functions for EVENT 'taf_sim_IccidChange'

◆ taf_sim_NewStateHandlerFunc_t

typedef void(* taf_sim_NewStateHandlerFunc_t) (taf_sim_Id_t slotId, taf_sim_States_t state, void *contextPtr)

Handler for SIM card state changes.

◆ taf_sim_AuthenticationResponseHandlerFunc_t

typedef void(* taf_sim_AuthenticationResponseHandlerFunc_t) (taf_sim_Id_t slotId, taf_sim_LockResponse_t responsetype, le_result_t result, void *contextPtr)

Handler for PIN PUK changes.

◆ taf_sim_IccidChangeHandlerFunc_t

typedef void(* taf_sim_IccidChangeHandlerFunc_t) (taf_sim_Id_t simId, const char *LE_NONNULL iccid, void *contextPtr)

Handler for ICCID change events.

Enumeration Type Documentation

◆ taf_sim_States_t

Defines SIM card states.

Enumerator
TAF_SIM_PRESENT 

SIM card is present.

TAF_SIM_ABSENT 

SIM card is absent.

TAF_SIM_READY 

SIM card is present and ready to use.

TAF_SIM_RESTRICTED 

SIM card is present but not usable due to carrier restrictions.

TAF_SIM_BUSY 

Not supported.

TAF_SIM_ERROR 

SIM card has error; either card is removed or not readable.

TAF_SIM_STATE_UNKNOWN 

SIM card state is unknown.

TAF_SIM_ERROR_UNKNOWN 

Unknown error; not supported.

TAF_SIM_ERROR_POWER_DOWN 

Power down; not supported.

TAF_SIM_ERROR_POLL_ERROR 

Poll error; not supported.

TAF_SIM_ERROR_NO_ATR_RECEIVED 

No ATR received; not supported.

TAF_SIM_ERROR_VOLT_MISMATCH 

Volt mismatch; not supported.

TAF_SIM_ERROR_PARITY_ERROR 

Parity error; not supported.

TAF_SIM_ERROR_POSSIBLY_REMOVED 

Unknown, possibly removed; not supported.

TAF_SIM_ERROR_TECHNICAL_PROBLEMS 

Card returned technical problems; not supported.

TAF_SIM_ERROR_NULL_BYTES 

Card returned NULL bytes; not supported.

TAF_SIM_ERROR_SAP_CONNECTED 

Terminal in SAP mode; not supported.

TAF_SIM_ERROR_CMD_TIMEOUT 

Command timeout error; not supported.

◆ taf_sim_Id_t

Defines slot ID of the SIM card.

Enumerator
TAF_SIM_EMBEDDED 

Not supported.

TAF_SIM_SLOT_ID_1 

SIM inserted in slot 1.

TAF_SIM_SLOT_ID_2 

SIM inserted in slot 2.

TAF_SIM_REMOTE 

Not supported.

TAF_SIM_UNSPECIFIED 

Slot II is unspecified; use the current selected slot ID.

TAF_SIM_ID_MAX 

◆ taf_sim_LockType_t

Defines all types of card locks using in PIN management APIs.

Enumerator
TAF_SIM_PIN1 

Lock type is PIN1.

TAF_SIM_PIN2 

Lock type is PIN2.

TAF_SIM_PUK1 

Lock type is pin unblocking key 1.

TAF_SIM_PUK2 

Lock type is pin unblocking key 2.

TAF_SIM_FDN 

Lock type is fixed dialing number.

◆ taf_sim_LockResponse_t

Enumerator
TAF_SIM_CHANGE_PIN 

Change PIN.

TAF_SIM_UNLOCK_BY_PIN 

Unlock PIN.

TAF_SIM_UNLOCK_BY_PUK 

Unlock PUK.

TAF_SIM_SET_LOCK 

Set lock.

◆ taf_sim_AppType_t

Defines all types of UICC applications, such as SIM, RUIM, USIM, CSIM and ISIM.

Enumerator
TAF_SIM_APPTYPE_UNKNOWN 

Unknown application type.

TAF_SIM_APPTYPE_SIM 

UICC application type is SIM.

TAF_SIM_APPTYPE_USIM 

UICC application type is USIM.

TAF_SIM_APPTYPE_RUIM 

UICC application type is RSIM.

TAF_SIM_APPTYPE_CSIM 

UICC application type is CSIM.

TAF_SIM_APPTYPE_ISIM 

UICC application type is ISIM.

◆ taf_sim_Manufacturer_t

Card manufacturer.

Enumerator
TAF_SIM_OBERTHUR 

Oberthur.

TAF_SIM_GEMALTO 

Gemalto.

TAF_SIM_G_AND_D 

G&D.

TAF_SIM_MORPHO 

Morpho.

TAF_SIM_VALID 

Valid.

TAF_SIM_MANUFACTURER_MAX 

Indicates the last item.

◆ taf_sim_Command_t

SIM commands. Refer to TS 11.11 9.1.

Enumerator
TAF_SIM_READ_BINARY 

Reads a transparent elementary file.

TAF_SIM_READ_RECORD 

Reads a file record.

TAF_SIM_GET_RESPONSE 

Gets response.

TAF_SIM_UPDATE_BINARY 

Updates a transparent elementary file.

TAF_SIM_UPDATE_RECORD 

Updates a file record.

TAF_SIM_COMMAND_MAX 

Indicates the last item.

Function Documentation

◆ ifgen_taf_sim_HasLocalBinding()

LE_SHARED bool ifgen_taf_sim_HasLocalBinding ( void  )

Get if this client bound locally.

◆ ifgen_taf_sim_InitCommonData()

LE_SHARED void ifgen_taf_sim_InitCommonData ( void  )

Init data that is common across all threads

◆ ifgen_taf_sim_CleanupCommonData()

LE_SHARED void ifgen_taf_sim_CleanupCommonData ( le_msg_SessionRef_t  _ifgen_sessionRef)

Cleanup the data of a session

◆ ifgen_taf_sim_OpenSession()

LE_SHARED le_result_t ifgen_taf_sim_OpenSession ( le_msg_SessionRef_t  _ifgen_sessionRef,
bool  isBlocking 
)

Perform common initialization and open a session

◆ ifgen_taf_sim_AddNewStateHandler()

LE_SHARED taf_sim_NewStateHandlerRef_t ifgen_taf_sim_AddNewStateHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_NewStateHandlerFunc_t  handlerPtr,
void *  contextPtr 
)

Add handler function for EVENT 'taf_sim_NewState'

SIM card state change event.

Parameters
[in]handlerPtrState change handler.
[in]contextPtr

◆ ifgen_taf_sim_RemoveNewStateHandler()

LE_SHARED void ifgen_taf_sim_RemoveNewStateHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_NewStateHandlerRef_t  handlerRef 
)

Remove handler function for EVENT 'taf_sim_NewState'

Parameters
[in]handlerRef

◆ ifgen_taf_sim_AddAuthenticationResponseHandler()

LE_SHARED taf_sim_AuthenticationResponseHandlerRef_t ifgen_taf_sim_AddAuthenticationResponseHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_AuthenticationResponseHandlerFunc_t  handlerPtr,
void *  contextPtr 
)

Add handler function for EVENT 'taf_sim_AuthenticationResponse'

Authentication response.

Parameters
[in]handlerPtrAuthentication response handler.
[in]contextPtr

◆ ifgen_taf_sim_RemoveAuthenticationResponseHandler()

LE_SHARED void ifgen_taf_sim_RemoveAuthenticationResponseHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_AuthenticationResponseHandlerRef_t  handlerRef 
)

Remove handler function for EVENT 'taf_sim_AuthenticationResponse'

Parameters
[in]handlerRef

◆ ifgen_taf_sim_IsPresent()

LE_SHARED bool ifgen_taf_sim_IsPresent ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId 
)

Checks whether SIM card is present or absent.

Returns
  • True – SIM card present.
  • False – SIM card absent.
Parameters
[in]slotIdSlot ID.

◆ ifgen_taf_sim_GetState()

LE_SHARED taf_sim_States_t ifgen_taf_sim_GetState ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId 
)

Gets the state of the SIM card for the given slotId.

Returns
Current of SIM card state.
Parameters
[in]slotIdSlot ID.

◆ ifgen_taf_sim_IsReady()

LE_SHARED bool ifgen_taf_sim_IsReady ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId 
)

Checks whether the SIM card is ready or not

Returns
  • True – SIM card is present and ready to use, i.e., unlocked.
  • False – SIM card is absent or restricted to use, i.e., locked.
Parameters
[in]slotIdSlot ID.

◆ ifgen_taf_sim_GetICCID()

LE_SHARED le_result_t ifgen_taf_sim_GetICCID ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  iccid,
size_t  iccidSize 
)

Retrieves the SIM's ICCID.

Returns
  • LE_OK ICCID was read successfully.
  • LE_OVERFLOW Buffer size is too small.
  • LE_BAD_PARAMETER Invalid parameters.
  • LE_FAULT Failed to retrieve the ICCID.
Parameters
[in]slotIdSlot ID.
[out]iccidICC ID as output.
[in]iccidSize

◆ ifgen_taf_sim_GetIMSI()

LE_SHARED le_result_t ifgen_taf_sim_GetIMSI ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  imsi,
size_t  imsiSize 
)

Retrieves the IMSI for the SIM.

Returns
  • LE_OVERFLOW Buffer size is too small.
  • LE_BAD_PARAMETER Invalid parameters.
  • LE_FAULT Failed to retrieve the IMSI.
  • LE_OK IMSI retrieved successfully.
Parameters
[in]slotIdSlot ID.
[out]imsiIMSI as output.
[in]imsiSize

◆ ifgen_taf_sim_GetHomeNetworkOperator()

LE_SHARED le_result_t ifgen_taf_sim_GetHomeNetworkOperator ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  nameStr,
size_t  nameStrSize 
)

Retrieves the name of the carrier on which this subscription is made.

Returns
  • LE_OVERFLOW Buffer size is too small.
  • LE_BAD_PARAMETER Invalid parameters.
  • LE_FAULT Failed to retrieve the carrier name.
  • LE_OK Carrier name retrieved successfully.
Parameters
[in]slotIdSlot ID.
[out]nameStrNetwork name as output.
[in]nameStrSize

◆ ifgen_taf_sim_GetSubscriberPhoneNumber()

LE_SHARED le_result_t ifgen_taf_sim_GetSubscriberPhoneNumber ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  phoneNumberStr,
size_t  phoneNumberStrSize 
)

Retrieves the phone number for the SIM subscription.

Returns
  • LE_OVERFLOW Buffer size is too small.
  • LE_BAD_PARAMETER Invalid parameters.
  • LE_FAULT Failed to retrieve the phone number.
  • LE_OK Phone number retrieved successfully.
Parameters
[in]slotIdSlot ID.
[out]phoneNumberStrPhone number as output.
[in]phoneNumberStrSize

◆ ifgen_taf_sim_GetHomeNetworkMccMnc()

LE_SHARED le_result_t ifgen_taf_sim_GetHomeNetworkMccMnc ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  mccPtr,
size_t  mccPtrSize,
char *  mncPtr,
size_t  mncPtrSize 
)

Retrieves the MNC and MCC of the carrier to which the phone is connected.

Returns
  • LE_OVERFLOW Buffer size is too small.
  • LE_BAD_PARAMETER Invalid parameters.
  • LE_FAULT Failed to retrieve the phone number.
  • LE_OK Phone number retrieved successfully.
Parameters
[in]slotIdSlot ID.
[out]mccPtrMCC string as output.
[in]mccPtrSize
[out]mncPtrMNC string as output.
[in]mncPtrSize

◆ ifgen_taf_sim_GetSelectedCard()

LE_SHARED taf_sim_Id_t ifgen_taf_sim_GetSelectedCard ( le_msg_SessionRef_t  _ifgen_sessionRef)

Gets the slotId of currently selected SIM card.

Returns
slotId of currently selected card.

◆ ifgen_taf_sim_SelectCard()

LE_SHARED le_result_t ifgen_taf_sim_SelectCard ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId 
)

Selects a SIM.

Returns
  • LE_FAULT Failed to select SIM card.
  • LE_OK SIM card selected successfully.
Parameters
[in]slotIdSlot ID.

◆ ifgen_taf_sim_EnterPIN()

LE_SHARED le_result_t ifgen_taf_sim_EnterPIN ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_LockType_t  lockType,
const char *LE_NONNULL  pin 
)

Unlocks the Sim card for an app by entering PIN.

Returns
  • LE_BAD_PARAMETER Invalid SIM slot ID.
  • LE_UNDERFLOW PIN code length is too short (minimum 4 digits).
  • LE_FAULT Failed to send unlock SIM card by PIN request.
  • LE_OK Successfully sent unlock SIM by password request.
Parameters
[in]slotIdSlot ID of SIM.
[in]lockTypeApplicable lock types are PIN1 and PIN2.
[in]pinPIN1/PIN2.

◆ ifgen_taf_sim_ChangePIN()

LE_SHARED le_result_t ifgen_taf_sim_ChangePIN ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_LockType_t  lockType,
const char *LE_NONNULL  oldpin,
const char *LE_NONNULL  newpin 
)

Changes the password used in PIN1/PIN2 lock.

Returns
LE_BAD_PARAMETER Invalid SIM slot ID.
LE_UNDERFLOW PIN code length is too short (minimum 4 digits).
LE_FAULT Failed to send change password for lock SIM card request.
LE_OK Successfully sent change SIM lock password request.
Parameters
[in]slotIdSlot ID of SIM.
[in]lockTypeApplicable lock types are PIN1 and PIN2.
[in]oldpinOld PIN1/PIN2.
[in]newpinNew PIN1/PIN2.

◆ ifgen_taf_sim_GetRemainingPINTries()

LE_SHARED int32_t ifgen_taf_sim_GetRemainingPINTries ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId 
)

Gets the available retry count of PIN tries.

Returns
  • LE_BAD_PARAMETER Invalid SIM slot ID.
  • LE_FAULT Failed to get the number of remaining PIN insertion tries.
  • A positive value Retry count value.
Parameters
[in]slotIdSlot ID.

◆ ifgen_taf_sim_GetRemainingPUKTries()

LE_SHARED le_result_t ifgen_taf_sim_GetRemainingPUKTries ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
uint32_t *  remainingPukTriesPtrPtr 
)

Gets the remaining PUK try count.

Returns
  • LE_BAD_PARAMETER Invalid SIM slot ID.
  • LE_FAULT Failed to get the number of remaining PUK insertion tries.
  • A positive value Retry count value.
Parameters
[in]slotIdSlot ID.
[out]remainingPukTriesPtrPtrNumber of PUK retries remaining.

◆ ifgen_taf_sim_Unlock()

LE_SHARED le_result_t ifgen_taf_sim_Unlock ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_LockType_t  lockType,
const char *LE_NONNULL  pin 
)

Disables PIN1 or FDN lock.

Returns
LE_BAD_PARAMETER Invalid SIM slot ID.
LE_UNDERFLOW PIN code length is too short (minimum 4 digits).
LE_FAULT Failed to send disable lock SIM card request.
LE_OK Successfully sent disable SIM lock request.
Parameters
[in]slotIdSlot ID of SIM.
[in]lockTypeApplicable lock types are PIN1 and FDN.
[in]pinPIN1/PIN2.

◆ ifgen_taf_sim_Lock()

LE_SHARED le_result_t ifgen_taf_sim_Lock ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_LockType_t  lockType,
const char *LE_NONNULL  pin 
)

Enables PIN1 or FDN lock.

Returns
  • LE_BAD_PARAMETER Invalid SIM slot ID.
  • LE_UNDERFLOW PIN code length is too short (minimum 4 digits).
  • LE_FAULT Failed to send enable lock SIM card request.
  • LE_OK Successfully sent the enable SIM lock request.
Parameters
[in]slotIdSlot ID of SIM.
[in]lockTypeApplicable lock types are PIN1 and FDN.
[in]pinPIN1/PIN2.

◆ ifgen_taf_sim_Unblock()

LE_SHARED le_result_t ifgen_taf_sim_Unblock ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_LockType_t  lockType,
const char *LE_NONNULL  puk,
const char *LE_NONNULL  newpin 
)

Unlocks the SIM card for an app by entering PUK and new PIN.

Returns
  • LE_BAD_PARAMETER Invalid SIM slot ID.
  • LE_OUT_OF_RANGE PUK length is not correct (8 digits).
  • LE_UNDERFLOW PIN code length is too short (minimum 4 digits).
  • LE_FAULT Failed to send unlock SIM card request.
  • LE_OK Successfully sent the unlock SIM request.
Parameters
[in]slotIdSlot ID of SIM.
[in]lockTypeApplicable lock types are PUK1 and PUK2.
[in]pukPUK1/PUK2.
[in]newpinNew PIN1/PIN2.

◆ ifgen_taf_sim_GetEID()

LE_SHARED le_result_t ifgen_taf_sim_GetEID ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
char *  eid,
size_t  eidSize 
)

Requests eUICC identifier(EID) for the slot.

Returns
  • LE_OK Succeeded.
  • LE_FAULT Failed.
Parameters
[in]slotIdSlot ID.
[out]eideID
[in]eidSize

◆ ifgen_taf_sim_SetAutomaticSelection()

LE_SHARED le_result_t ifgen_taf_sim_SetAutomaticSelection ( le_msg_SessionRef_t  _ifgen_sessionRef,
bool  enable 
)

Enables or disables the automatic SIM selection.

Returns
  • LE_OK Succeeded.
  • LE_FAULT Failed.
Parameters
[in]enableEnable flag

◆ ifgen_taf_sim_GetAutomaticSelection()

LE_SHARED le_result_t ifgen_taf_sim_GetAutomaticSelection ( le_msg_SessionRef_t  _ifgen_sessionRef,
bool *  enablePtr 
)

Gets the automatic SIM selection.

Returns
  • LE_OK Succeeded.
  • LE_FAULT Failed.
Parameters
[out]enablePtrEnable flag as output.

◆ ifgen_taf_sim_OpenLogicalChannel()

LE_SHARED le_result_t ifgen_taf_sim_OpenLogicalChannel ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
taf_sim_AppType_t  apptype,
uint8_t *  channelPtrPtr 
)

Opens a logical channel to the SIM.

Returns
  • LE_OK Successfully opened logical channel request.
  • LE_BAD_PARAMETER Invalid parameter.
  • LE_FAULT Failed to open logical channel.
Parameters
[in]slotIdSlot ID.
[in]apptypeApp type.
[out]channelPtrPtrChannel as output.

◆ ifgen_taf_sim_CloseLogicalChannel()

LE_SHARED le_result_t ifgen_taf_sim_CloseLogicalChannel ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  slotId,
uint8_t  channel 
)

Closes a previously opened logical channel to the SIM.

Returns
  • LE_OK Successfully closed the logical channel.
  • LE_FAULT Failed to send the request.
Parameters
[in]slotIdSlot ID.
[in]channelThe channel ID to be closed.

◆ ifgen_taf_sim_SendApduOnChannel()

LE_SHARED le_result_t ifgen_taf_sim_SendApduOnChannel ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
uint8_t  channel,
const uint8_t *  commandApduPtr,
size_t  commandApduSize,
uint8_t *  responseApduPtr,
size_t *  responseApduSizePtr 
)

Transmits an APDU to the ICC card over a logical channel.

Returns
  • LE_OK Succeeded.
  • LE_BAD_PARAMETER Invalid parameter.
  • LE_NOT_FOUND Failed to select the SIM card.
  • LE_FAULT Failed to transmit APDU.
Parameters
[in]simIdSlot ID.
[in]channelChannel.
[in]commandApduPtrAPDU.
[in]commandApduSize
[out]responseApduPtrResponse of APDU as output.
[in,out]responseApduSizePtr

◆ ifgen_taf_sim_SendApdu()

LE_SHARED le_result_t ifgen_taf_sim_SendApdu ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
const uint8_t *  commandApduPtr,
size_t  commandApduSize,
uint8_t *  responseApduPtr,
size_t *  responseApduSizePtr 
)

Exchanges APDUs with the SIM on a basic channel.

Returns
  • LE_OK Succeeded.
  • LE_FAULT Failed to transmit APDU.
  • LE_BAD_PARAMETER Invalid parameter.
  • LE_NOT_FOUND Failed to select the SIM card.
Parameters
[in]simIdSlot ID.
[in]commandApduPtrAPDU command.
[in]commandApduSize
[out]responseApduPtrResponse of APDU as output.
[in,out]responseApduSizePtr

◆ ifgen_taf_sim_SendCommand()

LE_SHARED le_result_t ifgen_taf_sim_SendCommand ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
taf_sim_Command_t  command,
const char *LE_NONNULL  fileIdentifier,
uint8_t  p1,
uint8_t  p2,
uint8_t  p3,
const uint8_t *  dataPtr,
size_t  dataSize,
const char *LE_NONNULL  path,
uint8_t *  sw1Ptr,
uint8_t *  sw2Ptr,
uint8_t *  responsePtr,
size_t *  responseSizePtr 
)

Sends a command to the SIM.

Returns
  • LE_OK Succeeded.
  • LE_FAULT Failed.
  • LE_BAD_PARAMETER A parameter is invalid.
  • LE_NOT_FOUND - The function failed to select the SIM card for this operation
    • The requested SIM file is not found
  • LE_OVERFLOW Response buffer is too small to copy the SIM answer.
  • LE_UNSUPPORTED The platform does not support this operation.
Parameters
[in]simIdThe SIM identifier.
[in]commandThe SIM command.
[in]fileIdentifierThe file identifier.
[in]p1Parameter P1 passed to the SIM.
[in]p2Parameter P2 passed to the SIM.
[in]p3Parameter P3 passed to the SIM.
[in]dataPtrThe command data.
[in]dataSize
[in]pathThe path to the elementary file.
[out]sw1PtrStatus word 1 received from the SIM.
[out]sw2PtrStatus word 2 received from the SIM.
[out]responsePtrSIM response.
[in,out]responseSizePtr

◆ ifgen_taf_sim_LocalSwapToEmergencyCallSubscription()

LE_SHARED le_result_t ifgen_taf_sim_LocalSwapToEmergencyCallSubscription ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
taf_sim_Manufacturer_t  manufacturer 
)

Switches the given SIM to the emergency call subscription. The eUICC reboots after switching the profile and the client app must wait for it.

Returns
  • LE_OK – Succeeded.
  • LE_BAD_PARAMETER – Invalid SIM identifier.
  • LE_FAULT – Unexpected error.
Note
The eUICC should be in the Ready state.
Ensure the emergency profile is available on the eUICC or an error will be thrown.
Parameters
[in]simIdThe SIM identifier.
[in]manufacturerThe card manufacturer.

◆ ifgen_taf_sim_LocalSwapToCommercialSubscription()

LE_SHARED le_result_t ifgen_taf_sim_LocalSwapToCommercialSubscription ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
taf_sim_Manufacturer_t  manufacturer 
)

Switches the given SIM to the commercial subscription. The eUICC reboots after switching the profile and the client app must wait for it.

Returns
  • LE_OK – Succeeded.
  • LE_BAD_PARAMETER – Invalid SIM identifier.
  • LE_FAULT – Unexpected error.
Note
The eUICC should be in the Ready state.
Ensure the commercial profile is available on the eUICC or an error will be thrown.
Parameters
[in]simIdThe SIM identifier.
[in]manufacturerThe card manufacturer.

◆ ifgen_taf_sim_SetPower()

LE_SHARED le_result_t ifgen_taf_sim_SetPower ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
le_onoff_t  power 
)

Powers up or down the current SIM.

Returns
  • LE_OK – Succeeded.
  • LE_FAULT – Failed.
  • LE_NOT_FOUND – Failed to select the SIM card.
  • LE_BAD_PARAMETER – Incorrect parameter(s).
Note
For SIM power cycle operation, it must wait until the SIM state is LE_OFF before powering on the SIM, otherwise power up SIM will fail.
Parameters
[in]simIdThe SIM identifier.
[in]powerThe power state.

◆ ifgen_taf_sim_Reset()

LE_SHARED le_result_t ifgen_taf_sim_Reset ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId 
)

Reset the SIM.

Returns
  • LE_FAULT – Failed.
  • LE_OK – Succeeded.
Parameters
[in]simIdThe SIM identifier.

◆ ifgen_taf_sim_IsEmergencyCallSubscriptionSelected()

LE_SHARED le_result_t ifgen_taf_sim_IsEmergencyCallSubscriptionSelected ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
bool *  isEcsPtr 
)

Checks if the emergency profile is activated for the SIM slot.

Returns
  • LE_OK – Succeeded.
  • LE_BAD_PARAMETER – Invalid SIM identifier or null ECS pointer.
  • LE_NOT_FOUND – Cannot determine the current selected subscription.
  • LE_FAULT – Unexpected error.
Parameters
[in]simIdThe SIM identifier.
[out]isEcsPtr- True – Emergency call subscription (ECS) is selected.

◆ ifgen_taf_sim_AddIccidChangeHandler()

LE_SHARED taf_sim_IccidChangeHandlerRef_t ifgen_taf_sim_AddIccidChangeHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_IccidChangeHandlerFunc_t  handlerPtr,
void *  contextPtr 
)

Add handler function for EVENT 'taf_sim_IccidChange'

ICCID information.

Parameters
[in]handlerPtr
[in]contextPtr

◆ ifgen_taf_sim_RemoveIccidChangeHandler()

LE_SHARED void ifgen_taf_sim_RemoveIccidChangeHandler ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_IccidChangeHandlerRef_t  handlerRef 
)

Remove handler function for EVENT 'taf_sim_IccidChange'

Parameters
[in]handlerRef

◆ ifgen_taf_sim_CreateFPLMNList()

LE_SHARED taf_sim_FPLMNListRef_t ifgen_taf_sim_CreateFPLMNList ( le_msg_SessionRef_t  _ifgen_sessionRef)

Creates an empty FPLMN list to insert the FPLMN operators.

Returns
  • Reference to the list object.
  • Null pointer if not able to create list reference.

◆ ifgen_taf_sim_AddFPLMNOperator()

LE_SHARED le_result_t ifgen_taf_sim_AddFPLMNOperator ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_FPLMNListRef_t  fplmnListRef,
const char *LE_NONNULL  mcc,
const char *LE_NONNULL  mnc 
)

Adds the FPLMN network into the newly created FPLMN list. If fplmnListRef, mcc, or mnc is not valid then this function will kill the calling client.

Returns
  • LE_FAULT Function failed.
  • LE_OK Function succeeded.
  • LE_OVERFLOW The FPLMN operator cannot be inserted into the FPLMN list.
Parameters
[in]fplmnListRefFPLMN list reference.
[in]mccMobile Country Code.
[in]mncMobile Network Code.

◆ ifgen_taf_sim_GetFirstFPLMNOperator()

LE_SHARED le_result_t ifgen_taf_sim_GetFirstFPLMNOperator ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_FPLMNListRef_t  fplmnListRef,
char *  mccPtr,
size_t  mccPtrSize,
char *  mncPtr,
size_t  mncPtrSize 
)

Reads the first FPLMN network from the list of FPLMN objects retrieved with taf_sim_ReadFPLMNList(). If fplmnListRef, mccPtr, or mncPtr is not valid then this function will kill the calling client.

Returns
  • LE_FAULT Function failed.
  • LE_OK Function succeeded.
  • LE_OVERFLOW MCC/MNC string size is greater than the string length parameter that has been given to this function.
Parameters
[in]fplmnListRefFPLMN list reference.
[out]mccPtrMobile Country Code.
[in]mccPtrSize
[out]mncPtrMobile Network Code.
[in]mncPtrSize

◆ ifgen_taf_sim_GetNextFPLMNOperator()

LE_SHARED le_result_t ifgen_taf_sim_GetNextFPLMNOperator ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_FPLMNListRef_t  fplmnListRef,
char *  mccPtr,
size_t  mccPtrSize,
char *  mncPtr,
size_t  mncPtrSize 
)

Reads the next FPLMN network from the list of FPLMN objects retrieved with le_sim_ReadFPLMNList(). If fplmnListRef, mccPtr, or mncPtr is not valid then this function will kill the calling client.

Returns
  • LE_FAULT Function failed.
  • LE_OK Function succeeded.
  • LE_OVERFLOW MCC/MNC string size is greater than string length parameter that has been given to this function.
Parameters
[in]fplmnListRefFPLMN list reference.
[out]mccPtrMobile Country Code.
[in]mccPtrSize
[out]mncPtrMobile Network Code.
[in]mncPtrSize

◆ ifgen_taf_sim_ReadFPLMNList()

LE_SHARED taf_sim_FPLMNListRef_t ifgen_taf_sim_ReadFPLMNList ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId 
)

Reads the FPLMN list from the SIM.

Returns
  • Reference to the list object.
  • Null pointer if the FPLMN list is not able to read from the SIM.
Parameters
[in]simIdSIM identifier.

◆ ifgen_taf_sim_DeleteFPLMNList()

LE_SHARED void ifgen_taf_sim_DeleteFPLMNList ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_FPLMNListRef_t  fplmnListRef 
)

Deletes the FPLMN list created by le_sim_ReadFPLMNList() or le_sim_CreateFPLMNList(). If fplmnListRef is not valid then this function will kill the calling client.

Note
On failure, the process exits so that users do not have to worry about checking the returned reference for validity.
Parameters
[in]fplmnListRefFPLMN list reference.

◆ ifgen_taf_sim_WriteFPLMNList()

LE_SHARED le_result_t ifgen_taf_sim_WriteFPLMNList ( le_msg_SessionRef_t  _ifgen_sessionRef,
taf_sim_Id_t  simId,
taf_sim_FPLMNListRef_t  fplmnListRef 
)

Writes the FPLMN list into the SIM. If fplmnListRef is not valid then this function will kill the calling client.

Returns
  • LE_FAULT Function failed.
  • LE_OK Function succeeded.
Parameters
[in]simIdSIM identifier.
[in]fplmnListRefFPLMN list reference.

◆ ifgen_taf_sim_GetSlotCount()

LE_SHARED le_result_t ifgen_taf_sim_GetSlotCount ( le_msg_SessionRef_t  _ifgen_sessionRef,
int32_t *  countPtr 
)

Retrieves the total number of SIM slots in the device.

Returns
LE_FAULT Failed to retrieve the slot count.
LE_OK The slot count was retrieved successfully.
Parameters
[out]countPtrSlot count.