diff options
author | Jan Brands <jan.r.brands@nxp.com> | 2010-12-08 00:30:37 +0100 |
---|---|---|
committer | Nick Pelly <npelly@google.com> | 2010-12-07 23:12:38 -0800 |
commit | 74216af142920e0bce72ec3d9609ec86db211c69 (patch) | |
tree | 7de9c148be30bc650c8d251a089b932a22efced1 /src/phLibNfc.h | |
parent | b2c5ac1e2d4dda413c4b3a66dc8a186e1dc5f6c4 (diff) | |
download | external_libnfc-nxp-74216af142920e0bce72ec3d9609ec86db211c69.zip external_libnfc-nxp-74216af142920e0bce72ec3d9609ec86db211c69.tar.gz external_libnfc-nxp-74216af142920e0bce72ec3d9609ec86db211c69.tar.bz2 |
NDEF tag R/W-R/O status functionality from Bangalore
Provides all the states as defined by the NFC-Forum.
Change-Id: I369138404e679b49613a391a9487766160afd8e2
Diffstat (limited to 'src/phLibNfc.h')
-rw-r--r-- | src/phLibNfc.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/phLibNfc.h b/src/phLibNfc.h index 0f16aee..60ccff2 100644 --- a/src/phLibNfc.h +++ b/src/phLibNfc.h @@ -327,6 +327,22 @@ typedef struct phLibNfc_Ndef_Info } phLibNfc_Ndef_Info_t; +/* As per NFC forum specification, the card can be in either of the below mentioned states + INVALID - means card is NOT NFC forum specified tag. NDEF FORMAT can only be performed for + the factory cards, other cards may or may not be formatted for NDEF FORMAT function. + INITIALISED - means card is NFC forum specified tag. But, in this state + the user has to first call NDEF WRITE, because in INITIALISED state, there + wont be any data i.e.,ACTUAL NDEF FILE SIZE is 0. After the first + NDEF WRITE, NDEF READ and WRITE functions can be called any number of times. + READ WRITE - means card is NFC forum specified tag. User can use both + NDEF READ and WRITE functions + READ ONLY - means card is NFC forum specified tag. User can only use + NDEF READ. NDEF WRITE function will not work. + */ +#define PHLIBNFC_NDEF_CARD_INVALID 0x00U +#define PHLIBNFC_NDEF_CARD_INITIALISED 0x01U +#define PHLIBNFC_NDEF_CARD_READ_WRITE 0x02U +#define PHLIBNFC_NDEF_CARD_READ_ONLY 0x03U /** * \ingroup grp_lib_nfc @@ -335,6 +351,7 @@ typedef struct phLibNfc_Ndef_Info */ typedef struct phLibNfc_ChkNdef_Info { + uint8_t NdefCardState; /**< Card state information */ uint32_t ActualNdefMsgLength; /**< Indicates Actual length of NDEF Message in Tag */ uint32_t MaxNdefMsgLength; /**< Indicates Maximum Ndef Message length that Tag can hold*/ } phLibNfc_ChkNdef_Info_t; |