summaryrefslogtreecommitdiffstats
path: root/inc
diff options
context:
space:
mode:
authorMartijn Coenen <maco@google.com>2011-11-02 15:58:37 -0700
committerMartijn Coenen <maco@google.com>2011-11-03 17:56:36 -0700
commitb99be65c277b0cc65a00a33e784ed49461531737 (patch)
treefa283e7ed283b12e692729a860fb51315d130d78 /inc
parent366238178f7a6d26ce051150f4fb65e533c2fae4 (diff)
downloadexternal_libnfc-nxp-b99be65c277b0cc65a00a33e784ed49461531737.zip
external_libnfc-nxp-b99be65c277b0cc65a00a33e784ed49461531737.tar.gz
external_libnfc-nxp-b99be65c277b0cc65a00a33e784ed49461531737.tar.bz2
Use NFC HAL for some libnfc settings.
The NFC HAL in libhardware allows us to store and retrieve product-specific settings. This patch moves two product-specific settings to the HAL: the device port, and the usage of the i2c workaround we had for crespo. This means configuring the port no longer needs to be done from JNI land. Change-Id: I2e19b6f188f808bc2f2a1f1abc28f2a6c47e6a4c
Diffstat (limited to 'inc')
-rw-r--r--inc/phNfcTypes.h26
1 files changed, 2 insertions, 24 deletions
diff --git a/inc/phNfcTypes.h b/inc/phNfcTypes.h
index 989cfe8..1f0fe1c 100644
--- a/inc/phNfcTypes.h
+++ b/inc/phNfcTypes.h
@@ -222,28 +222,6 @@ typedef struct phNfc_sData_t
uint32_t length;
} phNfc_sData_t;
-
-/**
- *\brief Possible Hardware Configuration exposed to upper layer.
- * Typically this should be port name (Ex:"COM1","COM2") to which PN544 is connected.
- */
-typedef enum
-{
- ENUM_LINK_TYPE_COM1,
- ENUM_LINK_TYPE_COM2,
- ENUM_LINK_TYPE_COM3,
- ENUM_LINK_TYPE_COM4,
- ENUM_LINK_TYPE_COM5,
- ENUM_LINK_TYPE_COM6,
- ENUM_LINK_TYPE_COM7,
- ENUM_LINK_TYPE_COM8,
- ENUM_LINK_TYPE_I2C,
- ENUM_LINK_TYPE_USB,
- ENUM_LINK_TYPE_TCP,
-
- ENUM_LINK_TYPE_NB,
-} phLibNfc_eConfigLinkType;
-
/**
* \brief Possible Hardware Configuration exposed to upper layer.
* Typically this should be at least the communication link (Ex:"COM1","COM2")
@@ -251,8 +229,8 @@ typedef enum
*/
typedef struct phLibNfc_sConfig_t
{
- /** Hardware communication link to the controller */
- phLibNfc_eConfigLinkType nLinkType;
+ /** Device node of the controller */
+ const char* deviceNode;
/** The client ID (thread ID or message queue ID) */
unsigned int nClientId;
} phLibNfc_sConfig_t, *pphLibNfc_sConfig_t;