2 * Copyright (C) 2010 NXP Semiconductors
\r
4 * Licensed under the Apache License, Version 2.0 (the "License");
\r
5 * you may not use this file except in compliance with the License.
\r
6 * You may obtain a copy of the License at
\r
8 * http://www.apache.org/licenses/LICENSE-2.0
\r
10 * Unless required by applicable law or agreed to in writing, software
\r
11 * distributed under the License is distributed on an "AS IS" BASIS,
\r
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
\r
13 * See the License for the specific language governing permissions and
\r
14 * limitations under the License.
\r
18 * \file phLibNfc_SE.h
\r
20 * Project: NFC-FRI 1.1
\r
22 * $Workfile:: phLibNfc_1.1.h $
\r
24 * $Author: ing07299 $
\r
28 #ifndef PHLIBNFC_SE_H
\r
29 #define PHLIBNFC_SE_H
\r
31 #define LIBNFC_SE_INVALID_HANDLE 0
\r
32 #define LIBNFC_SE_SUPPORTED 2
\r
33 #define LIBNFC_SE_BASE_HANDLE 0xABCDEF
\r
35 #define LIBNFC_SE_SMARTMX_INDEX 0
\r
36 #define LIBNFC_SE_UICC_INDEX 1
\r
38 #define PAUSE_PHASE 0x0824 /*Indicates the Pause phase duration*/
\r
39 #define EMULATION_PHASE 0x5161 /*Indicates the Emulation phase duration*/
\r
41 typedef struct phLibNfc_SeCallbackInfo
\r
43 /* SE set mode callback and its context */
\r
44 pphLibNfc_SE_SetModeRspCb_t pSEsetModeCb;
\r
45 void *pSEsetModeCtxt;
\r
46 /* Store SE discovery notification callback and its context */
\r
47 pphLibNfc_SE_NotificationCb_t pSeListenerNtfCb;
\r
48 void *pSeListenerCtxt;
\r
50 }phLibNfc_SECallbackInfo_t;
\r
54 phLibNfc_eSeInvalid = 0x00,
\r
57 phLibNfc_eSeVirtual,
\r
59 }phLibNfc_SeState_t;
\r
62 /* Context for secured element */
\r
63 typedef struct phLibNfc_SeCtxt
\r
66 /* UICC Status in Virtual Mode */
\r
67 uint8_t uUiccActivate;
\r
69 /* SMX Status in Virtual Mode */
\r
70 uint8_t uSmxActivate;
\r
72 /* Count of the Secure Elements Present */
\r
75 /* Se Temp handle */
\r
76 phLibNfc_Handle hSetemp;
\r
78 /*Current SE state*/
\r
79 phLibNfc_SeState_t eSE_State;
\r
81 /*Current SE Mode */
\r
83 phLibNfc_eSE_ActivationMode eActivatedMode;
\r
85 /* SE callback information */
\r
86 phLibNfc_SECallbackInfo_t sSeCallabackInfo;
\r
90 extern phLibNfc_SE_List_t sSecuredElementInfo[PHLIBNFC_MAXNO_OF_SE];
\r