From 2940d97c95a997ea54e3b198256b8e71bac31010 Mon Sep 17 00:00:00 2001 From: Nick Pelly Date: Mon, 1 Nov 2010 15:50:33 -0500 Subject: Use new PN544_SET_PWR ioctl Change-Id: I2d8d981d01d1e0f035d3dd3485d62dd26028b8ba Signed-off-by: Nick Pelly --- Linux_x86/phDal4Nfc_i2c.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'Linux_x86') diff --git a/Linux_x86/phDal4Nfc_i2c.c b/Linux_x86/phDal4Nfc_i2c.c index 8cd4a1a..5e0b30b 100644 --- a/Linux_x86/phDal4Nfc_i2c.c +++ b/Linux_x86/phDal4Nfc_i2c.c @@ -22,6 +22,7 @@ * */ +#include #include #include #include @@ -36,8 +37,7 @@ #include #endif -#define PN544_RESET_CMD 0 -#define PN544_DOWNLOAD_CMD 1 +#include typedef struct { @@ -240,9 +240,9 @@ int phDal4Nfc_i2c_reset(long level) { int ret = NFCSTATUS_SUCCESS; - DAL_DEBUG("phDal4Nfc_i2c_reset, VEN level = %d",level); + DAL_DEBUG("phDal4Nfc_i2c_reset, VEN level = %ld",level); - ret = ioctl(gI2cPortContext.nHandle, PN544_RESET_CMD, level); + ret = ioctl(gI2cPortContext.nHandle, PN544_SET_PWR, level); return ret; } @@ -258,9 +258,10 @@ int phDal4Nfc_i2c_download(long level) { int ret = NFCSTATUS_SUCCESS; - DAL_DEBUG("phDal4Nfc_i2c_download, GPIO4 level = %d",level); + DAL_DEBUG("phDal4Nfc_i2c_download, GPIO4 level = %ld",level); - ret = ioctl(gI2cPortContext.nHandle, PN544_DOWNLOAD_CMD, level); + /* TODO: implement firmware download */ abort(); + /* ret = ioctl(gI2cPortContext.nHandle, PN544_DOWNLOAD_CMD, level); */ return ret; } -- cgit v1.1