• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /******************************************************************************
2  *
3  *  Copyright (C) 2010-2014 Broadcom Corporation
4  *
5  *  Licensed under the Apache License, Version 2.0 (the "License");
6  *  you may not use this file except in compliance with the License.
7  *  You may obtain a copy of the License at:
8  *
9  *  http://www.apache.org/licenses/LICENSE-2.0
10  *
11  *  Unless required by applicable law or agreed to in writing, software
12  *  distributed under the License is distributed on an "AS IS" BASIS,
13  *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  *  See the License for the specific language governing permissions and
15  *  limitations under the License.
16  *
17  ******************************************************************************/
18 
19 /******************************************************************************
20  *
21  *  NFA interface to NFCEE
22  *
23  ******************************************************************************/
24 #ifndef NFA_EE_API_H
25 #define NFA_EE_API_H
26 
27 #include "nfa_api.h"
28 #include "nfc_api.h"
29 #include "nfc_target.h"
30 
31 /*****************************************************************************
32 **  Constants and data types
33 *****************************************************************************/
34 /* 16 per ISO 7816 specification    */
35 #define NFA_MAX_AID_LEN NFC_MAX_AID_LEN
36 
37 /* NFA EE callback events */
38 enum {
39   NFA_EE_DISCOVER_EVT,   /* The status for NFA_EeDiscover () */
40   NFA_EE_REGISTER_EVT,   /* The status for NFA_EeRegister () */
41   NFA_EE_DEREGISTER_EVT, /* The status for NFA_EeDeregister () */
42   NFA_EE_MODE_SET_EVT, /* The status for activating or deactivating an NFCEE */
43   NFA_EE_ADD_AID_EVT,  /* The status for adding an AID to a routing table entry
44                         */
45   NFA_EE_REMOVE_AID_EVT,  /* The status for removing an AID from a routing table
46                            */
47   NFA_EE_ADD_SYSCODE_EVT, /* The status for adding an System Code to a routing
48                              table entry */
49   NFA_EE_REMOVE_SYSCODE_EVT, /* The status for removing an System Code from
50                               routing table */
51   NFA_EE_REMAINING_SIZE_EVT, /* The remaining size of the Listen Mode Routing
52                                 Table   */
53   NFA_EE_SET_TECH_CFG_EVT,   /* The status for setting the routing based on RF
54                                 tech.  */
55   NFA_EE_CLEAR_TECH_CFG_EVT, /* The status for clearing the routing based on RF
56                               tech.  */
57 
58   NFA_EE_SET_PROTO_CFG_EVT,   /* The status for setting the routing based on
59                                  protocols */
60   NFA_EE_CLEAR_PROTO_CFG_EVT, /* The status for clearing the routing based on
61                                protocols */
62 
63   NFA_EE_UPDATED_EVT, /* The status for NFA_EeUpdateNow */
64   NFA_EE_CONNECT_EVT, /* Result of NFA_EeConnect */
65   NFA_EE_DATA_EVT, /* Received data from NFCEE.                             */
66   NFA_EE_DISCONNECT_EVT, /* NFCEE connection closed. */
67   NFA_EE_NEW_EE_EVT, /* A new NFCEE is discovered                             */
68   NFA_EE_ACTION_EVT, /* An action happened in NFCEE                           */
69   NFA_EE_DISCOVER_REQ_EVT, /* NFCEE Discover Request Notification */
70   NFA_EE_NO_MEM_ERR_EVT,   /* Error - out of GKI buffers */
71   NFA_EE_NO_CB_ERR_EVT /* Error - Can not find control block or wrong state */
72 };
73 typedef uint8_t tNFA_EE_EVT;
74 
75 /* tNFA_NFCEE_INTERFACE values */
76 /* HCI Access Interface*/
77 #define NFA_EE_INTERFACE_HCI_ACCESS NFC_NFCEE_INTERFACE_HCI_ACCESS
78 typedef uint8_t tNFA_EE_INTERFACE;
79 
80 typedef uint8_t tNFA_EE_TAG;
81 
82 /* for NFA_EeModeSet () */
83 #define NFA_EE_MD_ACTIVATE NFC_MODE_ACTIVATE
84 #define NFA_EE_MD_DEACTIVATE NFC_MODE_DEACTIVATE
85 typedef uint8_t tNFA_EE_MD;
86 
87 /* The device is on                 */
88 #define NFA_EE_PWR_STATE_ON 0x01
89 /* The device is switched off       */
90 #define NFA_EE_PWR_STATE_SWITCH_OFF 0x02
91 /* The device's battery is removed  */
92 #define NFA_EE_PWR_STATE_BATT_OFF 0x04
93 typedef uint8_t tNFA_EE_PWR_STATE;
94 
95 /* NFCEE connected and inactive */
96 #define NFA_EE_STATUS_INACTIVE NFC_NFCEE_STATUS_INACTIVE
97 /* NFCEE connected and active   */
98 #define NFA_EE_STATUS_ACTIVE NFC_NFCEE_STATUS_ACTIVE
99 /* NFCEE removed                */
100 #define NFA_EE_STATUS_REMOVED NFC_NFCEE_STATUS_REMOVED
101 /* waiting for response from NFCC */
102 #define NFA_EE_STATUS_PENDING 0x10
103 typedef uint8_t tNFA_EE_STATUS;
104 
105 /* additional NFCEE Info */
106 typedef struct {
107   tNFA_EE_TAG tag;
108   uint8_t len;
109   uint8_t info[NFC_MAX_EE_INFO];
110 } tNFA_EE_TLV;
111 
112 typedef struct {
113   tNFA_HANDLE ee_handle;    /* handle for NFCEE oe DH   */
114   tNFA_EE_STATUS ee_status; /* The NFCEE status         */
115   uint8_t num_interface;    /* number of NFCEE interface*/
116   tNFA_EE_INTERFACE
117       ee_interface[NFC_MAX_EE_INTERFACE]; /* NFCEE supported interface */
118   uint8_t num_tlvs;                       /* number of TLVs           */
119   tNFA_EE_TLV ee_tlv[NFC_MAX_EE_TLVS];    /* the TLV                  */
120   uint8_t ee_power_supply_status;         /* The NFCEE Power supply */
121 } tNFA_EE_INFO;
122 
123 typedef struct {
124   tNFA_STATUS status; /* NFA_STATUS_OK is successful      */
125   uint8_t num_ee;     /* number of NFCEEs found           */
126   tNFA_EE_INFO ee_info[NFA_EE_MAX_EE_SUPPORTED]; /*NFCEE information */
127 } tNFA_EE_DISCOVER;
128 
129 typedef struct {
130   tNFA_HANDLE ee_handle; /* Handle of NFCEE                                  */
131   tNFA_STATUS status;    /* NFA_STATUS_OK is successful                      */
132   tNFA_EE_INTERFACE
133       ee_interface; /* NFCEE interface associated with this connection  */
134 } tNFA_EE_CONNECT;
135 
136 typedef tNFC_EE_TRIGGER tNFA_EE_TRIGGER;
137 
138 /* Union of NFCEE action parameter depending on the associated trigger */
139 typedef union {
140   tNFA_NFC_PROTOCOL protocol; /* NFA_EE_TRGR_RF_PROTOCOL: the protocol that
141                                  triggers this event */
142   tNFC_RF_TECH technology;    /* NFA_EE_TRGR_RF_TECHNOLOGY:the technology that
143                                  triggers this event */
144   tNFC_AID aid; /* NFA_EE_TRGR_SELECT      : the AID in the received SELECT AID
145                    command */
146   tNFC_APP_INIT app_init; /* NFA_EE_TRGR_APP_INIT:     The information for the
147                              application initiated trigger */
148 } tNFA_EE_ACTION_PARAM;
149 
150 typedef struct {
151   tNFA_HANDLE ee_handle;   /* Handle of NFCEE                  */
152   tNFA_EE_TRIGGER trigger; /* the trigger of this event        */
153   tNFA_EE_ACTION_PARAM param;
154 } tNFA_EE_ACTION;
155 
156 typedef struct {
157   tNFA_HANDLE ee_handle;    /* Handle of NFCEE              */
158   tNFA_STATUS status;       /* NFA_STATUS_OK is successful  */
159   tNFA_EE_STATUS ee_status; /* The NFCEE status             */
160 } tNFA_EE_MODE_SET;
161 
162 typedef struct {
163   tNFA_HANDLE ee_handle;          /* Handle of MFCEE      */
164   tNFA_NFC_PROTOCOL la_protocol;  /* Listen A protocol    */
165   tNFA_NFC_PROTOCOL lb_protocol;  /* Listen B protocol    */
166   tNFA_NFC_PROTOCOL lf_protocol;  /* Listen F protocol    */
167   tNFA_NFC_PROTOCOL lbp_protocol; /* Listen B' protocol   */
168 } tNFA_EE_DISCOVER_INFO;
169 
170 /* Data for NFA_EE_DISCOVER_REQ_EVT */
171 typedef struct {
172   uint8_t status; /* NFA_STATUS_OK if successful   */
173   uint8_t num_ee; /* number of MFCEE information   */
174   tNFA_EE_DISCOVER_INFO ee_disc_info[NFA_EE_MAX_EE_SUPPORTED -
175                                      1]; /* NFCEE DISCOVER Request info   */
176 } tNFA_EE_DISCOVER_REQ;
177 
178 /* Data for NFA_EE_DATA_EVT */
179 typedef struct {
180   tNFA_HANDLE handle; /* Connection handle */
181   uint16_t len;       /* Length of data    */
182   uint8_t* p_buf;     /* Data buffer       */
183 } tNFA_EE_DATA;
184 
185 /* Union of all EE callback structures */
186 typedef union {
187   tNFA_STATUS
188       status; /* NFA_STATUS_OK is successful; otherwise NFA_STATUS_FAILED */
189   tNFA_EE_DATA data;
190   tNFA_HANDLE handle;
191   tNFA_EE_DISCOVER ee_discover;
192   tNFA_STATUS ee_register;
193   tNFA_STATUS deregister;
194   tNFA_STATUS add_aid;
195   tNFA_STATUS remove_aid;
196   tNFA_STATUS add_sc;
197   tNFA_STATUS remove_sc;
198   tNFA_STATUS set_tech;
199   tNFA_STATUS clear_tech;
200   tNFA_STATUS set_proto;
201   tNFA_STATUS clear_proto;
202   uint16_t size;
203   tNFA_EE_CONNECT connect;
204   tNFA_EE_ACTION action;
205   tNFA_EE_MODE_SET mode_set;
206   tNFA_EE_INFO new_ee;
207   tNFA_EE_DISCOVER_REQ discover_req;
208 } tNFA_EE_CBACK_DATA;
209 
210 /* EE callback */
211 typedef void(tNFA_EE_CBACK)(tNFA_EE_EVT event, tNFA_EE_CBACK_DATA* p_data);
212 
213 /*****************************************************************************
214 **  External Function Declarations
215 *****************************************************************************/
216 
217 /*******************************************************************************
218 **
219 ** Function         NFA_EeDiscover
220 **
221 ** Description      This function retrieves the NFCEE information from NFCC.
222 **                  The NFCEE information is reported in NFA_EE_DISCOVER_EVT.
223 **
224 **                  This function may be called when a system supports removable
225 **                  NFCEEs,
226 **
227 ** Returns          NFA_STATUS_OK if information is retrieved successfully
228 **                  NFA_STATUS_FAILED If wrong state (retry later)
229 **                  NFA_STATUS_INVALID_PARAM If bad parameter
230 **
231 *******************************************************************************/
232 extern tNFA_STATUS NFA_EeDiscover(tNFA_EE_CBACK* p_cback);
233 
234 /*******************************************************************************
235 **
236 ** Function         NFA_EeGetInfo
237 **
238 ** Description      This function retrieves the NFCEE information from NFA.
239 **                  The actual number of NFCEE is returned in p_num_nfcee
240 **                  and NFCEE information is returned in p_info
241 **
242 ** Returns          NFA_STATUS_OK if information is retrieved successfully
243 **                  NFA_STATUS_FAILED If wrong state (retry later)
244 **                  NFA_STATUS_INVALID_PARAM If bad parameter
245 **
246 *******************************************************************************/
247 extern tNFA_STATUS NFA_EeGetInfo(uint8_t* p_num_nfcee, tNFA_EE_INFO* p_info);
248 
249 /*******************************************************************************
250 **
251 ** Function         NFA_EeRegister
252 **
253 ** Description      This function registers a callback function to receive the
254 **                  events from NFA-EE module.
255 **
256 ** Returns          NFA_STATUS_OK if successfully initiated
257 **                  NFA_STATUS_FAILED otherwise
258 **                  NFA_STATUS_INVALID_PARAM If bad parameter
259 **
260 *******************************************************************************/
261 extern tNFA_STATUS NFA_EeRegister(tNFA_EE_CBACK* p_cback);
262 
263 /*******************************************************************************
264 **
265 ** Function         NFA_EeDeregister
266 **
267 ** Description      This function de-registers the callback function
268 **
269 ** Returns          NFA_STATUS_OK if successfully initiated
270 **                  NFA_STATUS_FAILED otherwise
271 **                  NFA_STATUS_INVALID_PARAM If bad parameter
272 **
273 *******************************************************************************/
274 extern tNFA_STATUS NFA_EeDeregister(tNFA_EE_CBACK* p_cback);
275 
276 /*******************************************************************************
277 **
278 ** Function         NFA_EeModeSet
279 **
280 ** Description      This function is called to activate
281 **                  (mode = NFA_EE_MD_ACTIVATE) or deactivate
282 **                  (mode = NFA_EE_MD_DEACTIVATE) the NFCEE identified by the
283 **                  given ee_handle. The result of this operation is reported
284 **                  with the NFA_EE_MODE_SET_EVT.
285 **
286 ** Returns          NFA_STATUS_OK if successfully initiated
287 **                  NFA_STATUS_FAILED otherwise
288 **                  NFA_STATUS_INVALID_PARAM If bad parameter
289 **
290 *******************************************************************************/
291 extern tNFA_STATUS NFA_EeModeSet(tNFA_HANDLE ee_handle, tNFA_EE_MD mode);
292 
293 /*******************************************************************************
294 **
295 ** Function         NFA_EeSetDefaultTechRouting
296 **
297 ** Description      This function is called to add, change or remove the
298 **                  default routing based on RF technology in the listen mode
299 **                  routing table for the given ee_handle. The status of this
300 **                  operation is reported as the NFA_EE_SET_TECH_CFG_EVT.
301 **
302 ** Note:            If RF discovery is started,
303 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
304 **                  happen before calling this function
305 **
306 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
307 **                  function to change the listen mode routing is called.
308 **
309 ** Returns          NFA_STATUS_OK if successfully initiated
310 **                  NFA_STATUS_FAILED otherwise
311 **                  NFA_STATUS_INVALID_PARAM If bad parameter
312 **
313 *******************************************************************************/
314 extern tNFA_STATUS NFA_EeSetDefaultTechRouting(
315     tNFA_HANDLE ee_handle, tNFA_TECHNOLOGY_MASK technologies_switch_on,
316     tNFA_TECHNOLOGY_MASK technologies_switch_off,
317     tNFA_TECHNOLOGY_MASK technologies_battery_off,
318     tNFA_TECHNOLOGY_MASK technologies_screen_lock,
319     tNFA_TECHNOLOGY_MASK technologies_screen_off,
320     tNFA_TECHNOLOGY_MASK technologies_screen_off_lock);
321 
322 /*******************************************************************************
323 **
324 ** Function         NFA_EeClearDefaultTechRouting
325 **
326 ** Description      This function is called to remove the
327 **                  default routing based on RF technology in the listen mode
328 **                  routing table for the given ee_handle. The status of this
329 **                  operation is reported as the NFA_EE_CLEAR_TECH_CFG_EVT.
330 **
331 ** Note:            If RF discovery is started,
332 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
333 **                  happen before calling this function
334 **
335 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
336 **                  function to change the listen mode routing is called.
337 **
338 ** Returns          NFA_STATUS_OK if successfully initiated
339 **                  NFA_STATUS_FAILED otherwise
340 **                  NFA_STATUS_INVALID_PARAM If bad parameter
341 **
342 *******************************************************************************/
343 extern tNFA_STATUS NFA_EeClearDefaultTechRouting(
344     tNFA_HANDLE ee_handle, tNFA_TECHNOLOGY_MASK clear_technology);
345 
346 /*******************************************************************************
347 **
348 ** Function         NFA_EeSetDefaultProtoRouting
349 **
350 ** Description      This function is called to add, change or remove the
351 **                  default routing based on Protocol in the listen mode routing
352 **                  table for the given ee_handle. The status of this
353 **                  operation is reported as the NFA_EE_SET_PROTO_CFG_EVT.
354 **
355 ** Note:            If RF discovery is started,
356 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
357 **                  happen before calling this function
358 **
359 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
360 **                  function to change the listen mode routing is called.
361 **
362 ** Returns          NFA_STATUS_OK if successfully initiated
363 **                  NFA_STATUS_FAILED otherwise
364 **                  NFA_STATUS_INVALID_PARAM If bad parameter
365 **
366 *******************************************************************************/
367 extern tNFA_STATUS NFA_EeSetDefaultProtoRouting(
368     tNFA_HANDLE ee_handle, tNFA_PROTOCOL_MASK protocols_switch_on,
369     tNFA_PROTOCOL_MASK protocols_switch_off,
370     tNFA_PROTOCOL_MASK protocols_battery_off,
371     tNFA_PROTOCOL_MASK technologies_screen_lock,
372     tNFA_PROTOCOL_MASK technologies_screen_off,
373     tNFA_PROTOCOL_MASK technologies_screen_off_lock);
374 
375 /*******************************************************************************
376 **
377 ** Function         NFA_EeClearDefaultProtoRouting
378 **
379 ** Description      This function is called remove the
380 **                  default routing based on Protocol in the listen mode routing
381 **                  table for the given ee_handle. The status of this
382 **                  operation is reported as the NFA_EE_CLEAR_PROTO_CFG_EVT.
383 **
384 ** Note:            If RF discovery is started,
385 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
386 **                  happen before calling this function
387 **
388 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
389 **                  function to change the listen mode routing is called.
390 **
391 ** Returns          NFA_STATUS_OK if successfully initiated
392 **                  NFA_STATUS_FAILED otherwise
393 **                  NFA_STATUS_INVALID_PARAM If bad parameter
394 **
395 *******************************************************************************/
396 extern tNFA_STATUS NFA_EeClearDefaultProtoRouting(
397     tNFA_HANDLE ee_handle, tNFA_PROTOCOL_MASK clear_protocol);
398 
399 /*******************************************************************************
400 **
401 ** Function         NFA_EeAddAidRouting
402 **
403 ** Description      This function is called to add an AID entry in the
404 **                  listen mode routing table in NFCC. The status of this
405 **                  operation is reported as the NFA_EE_ADD_AID_EVT.
406 **
407 ** Note:            If RF discovery is started,
408 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
409 **                  happen before calling this function
410 **
411 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
412 **                  function to change the listen mode routing is called.
413 **
414 ** Returns          NFA_STATUS_OK if successfully initiated
415 **                  NFA_STATUS_FAILED otherwise
416 **                  NFA_STATUS_INVALID_PARAM If bad parameter
417 **
418 *******************************************************************************/
419 extern tNFA_STATUS NFA_EeAddAidRouting(tNFA_HANDLE ee_handle, uint8_t aid_len,
420                                        uint8_t* p_aid,
421                                        tNFA_EE_PWR_STATE power_state,
422                                        uint8_t aidInfo);
423 
424 /*******************************************************************************
425 **
426 ** Function         NFA_EeRemoveAidRouting
427 **
428 ** Description      This function is called to remove the given AID entry from
429 **                  the listen mode routing table. If the entry configures VS,
430 **                  it is also removed. The status of this operation is reported
431 **                  as the NFA_EE_REMOVE_AID_EVT.
432 **
433 ** Note:            If RF discovery is started,
434 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
435 **                  happen before calling this function
436 **
437 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
438 **                  function to change the listen mode routing is called.
439 **
440 ** Returns          NFA_STATUS_OK if successfully initiated
441 **                  NFA_STATUS_FAILED otherwise
442 **                  NFA_STATUS_INVALID_PARAM If bad parameter
443 **
444 *******************************************************************************/
445 extern tNFA_STATUS NFA_EeRemoveAidRouting(uint8_t aid_len, uint8_t* p_aid);
446 
447 /*******************************************************************************
448  **
449  ** Function         NFA_EeAddSystemCodeRouting
450  **
451  ** Description      This function is called to add an system code entry in the
452  **                  listen mode routing table in NFCC. The status of this
453  **                  operation is reported as the NFA_EE_ADD_SYSCODE_EVT.
454  **
455  ** Note:            If RF discovery is started,
456  **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
457  **                  happen before calling this function
458  **
459  ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
460  **                  function to change the listen mode routing is called.
461  **
462  ** Returns          NFA_STATUS_OK if successfully initiated
463  **                  NFA_STATUS_FAILED otherwise
464  **                  NFA_STATUS_INVALID_PARAM If bad parameter
465  **
466  *******************************************************************************/
467 extern tNFA_STATUS NFA_EeAddSystemCodeRouting(uint16_t systemcode,
468                                               tNFA_HANDLE ee_handle,
469                                               tNFA_EE_PWR_STATE power_state);
470 
471 /*******************************************************************************
472 **
473 ** Function         NFA_EeRemoveSystemCodeRouting
474 **
475 ** Description      This function is called to remove the given System Code
476 *based entry from
477 **                  the listen mode routing table. The status of this operation
478 *is reported
479 **                  as the NFA_EE_REMOVE_SYSCODE_EVT.
480 **
481 ** Note:            If RF discovery is started,
482 **                  NFA_StopRfDiscovery()/NFA_RF_DISCOVERY_STOPPED_EVT should
483 **                  happen before calling this function
484 **
485 ** Note:            NFA_EeUpdateNow() should be called after last NFA-EE
486 **                  function to change the listen mode routing is called.
487 **
488 ** Returns          NFA_STATUS_OK if successfully initiated
489 **                  NFA_STATUS_FAILED otherwise
490 **                  NFA_STATUS_INVALID_PARAM If bad parameter
491 **
492 *******************************************************************************/
493 extern tNFA_STATUS NFA_EeRemoveSystemCodeRouting(uint16_t systemcode);
494 
495 /*******************************************************************************
496 **
497 ** Function         NFA_GetAidTableSize
498 **
499 ** Description      This function is called to get the AID routing table size.
500 **
501 ** Returns          Maximum AID routing table size.
502 **
503 *******************************************************************************/
504 extern uint16_t NFA_GetAidTableSize();
505 
506 /*******************************************************************************
507 **
508 ** Function         NFA_EeGetLmrtRemainingSize
509 **
510 ** Description      This function is called to get remaining size of the
511 **                  Listen Mode Routing Table.
512 **                  The remaining size is reported in NFA_EE_REMAINING_SIZE_EVT
513 **
514 ** Returns          NFA_STATUS_OK if successfully initiated
515 **                  NFA_STATUS_FAILED otherwise
516 **
517 *******************************************************************************/
518 extern tNFA_STATUS NFA_EeGetLmrtRemainingSize(void);
519 
520 /*******************************************************************************
521 **
522 ** Function         NFA_EeUpdateNow
523 **
524 ** Description      This function is called to send the current listen mode
525 **                  routing table and VS configuration to the NFCC (without
526 **                  waiting for NFA_EE_ROUT_TIMEOUT_VAL).
527 **
528 **                  The status of this operation is
529 **                  reported with the NFA_EE_UPDATED_EVT.
530 **
531 ** Returns          NFA_STATUS_OK if successfully initiated
532 **                  NFA_STATUS_SEMANTIC_ERROR is update is currently in progress
533 **                  NFA_STATUS_FAILED otherwise
534 **
535 *******************************************************************************/
536 extern tNFA_STATUS NFA_EeUpdateNow(void);
537 
538 /*******************************************************************************
539 **
540 ** Function         NFA_EeConnect
541 **
542 ** Description      Open connection to an NFCEE attached to the NFCC
543 **
544 **                  The status of this operation is
545 **                  reported with the NFA_EE_CONNECT_EVT.
546 **
547 ** Returns          NFA_STATUS_OK if successfully initiated
548 **                  NFA_STATUS_FAILED otherwise
549 **                  NFA_STATUS_INVALID_PARAM If bad parameter
550 **
551 *******************************************************************************/
552 extern tNFA_STATUS NFA_EeConnect(tNFA_HANDLE ee_handle, uint8_t ee_interface,
553                                  tNFA_EE_CBACK* p_cback);
554 
555 /*******************************************************************************
556 **
557 ** Function         NFA_EeSendData
558 **
559 ** Description      Send data to the given NFCEE.
560 **                  This function shall be called after NFA_EE_CONNECT_EVT is
561 **                  reported and before NFA_EeDisconnect is called on the given
562 **                  ee_handle.
563 **
564 ** Returns          NFA_STATUS_OK if successfully initiated
565 **                  NFA_STATUS_FAILED otherwise
566 **                  NFA_STATUS_INVALID_PARAM If bad parameter
567 **
568 *******************************************************************************/
569 extern tNFA_STATUS NFA_EeSendData(tNFA_HANDLE ee_handle, uint16_t data_len,
570                                   uint8_t* p_data);
571 
572 /*******************************************************************************
573 **
574 ** Function         NFA_EeDisconnect
575 **
576 ** Description      Disconnect (if a connection is currently open) from an
577 **                  NFCEE interface. The result of this operation is reported
578 **                  with the NFA_EE_DISCONNECT_EVT.
579 **
580 ** Returns          NFA_STATUS_OK if successfully initiated
581 **                  NFA_STATUS_FAILED otherwise
582 **                  NFA_STATUS_INVALID_PARAM If bad parameter
583 **
584 *******************************************************************************/
585 extern tNFA_STATUS NFA_EeDisconnect(tNFA_HANDLE ee_handle);
586 
587 #endif /* NFA_EE_API_H */
588