examples: rename nfc-sam to pn53x-sam, it need to made some direct calls to pn53x_* functions.
This commit is contained in:
parent
ec3f854a68
commit
5fdb7ab254
3 changed files with 12 additions and 14 deletions
|
@ -8,10 +8,10 @@ bin_PROGRAMS = \
|
||||||
nfc-mfultralight \
|
nfc-mfultralight \
|
||||||
nfc-poll \
|
nfc-poll \
|
||||||
nfc-relay \
|
nfc-relay \
|
||||||
nfc-sam \
|
|
||||||
nfcip-initiator \
|
nfcip-initiator \
|
||||||
nfcip-target \
|
nfcip-target \
|
||||||
pn53x-diagnose \
|
pn53x-diagnose \
|
||||||
|
pn53x-sam \
|
||||||
pn53x-tamashell
|
pn53x-tamashell
|
||||||
|
|
||||||
# set the include path found by configure
|
# set the include path found by configure
|
||||||
|
@ -58,10 +58,6 @@ nfc_emulate_tag_SOURCES = nfc-emulate-tag.c
|
||||||
nfc_emulate_tag_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
nfc_emulate_tag_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
||||||
libnfcutils.la
|
libnfcutils.la
|
||||||
|
|
||||||
nfc_sam_SOURCES = nfc-sam.c
|
|
||||||
nfc_sam_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
|
||||||
libnfcutils.la
|
|
||||||
|
|
||||||
nfcip_target_SOURCES = nfcip-target.c
|
nfcip_target_SOURCES = nfcip-target.c
|
||||||
nfcip_target_LDADD = $(top_builddir)/libnfc/libnfc.la
|
nfcip_target_LDADD = $(top_builddir)/libnfc/libnfc.la
|
||||||
|
|
||||||
|
@ -72,11 +68,15 @@ pn53x_diagnose_SOURCES = pn53x-diagnose.c
|
||||||
pn53x_diagnose_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
pn53x_diagnose_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
||||||
libnfcutils.la
|
libnfcutils.la
|
||||||
|
|
||||||
|
pn53x_sam_SOURCES = pn53x-sam.c
|
||||||
|
pn53x_sam_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
||||||
|
libnfcutils.la
|
||||||
|
|
||||||
pn53x_tamashell_SOURCES = pn53x-tamashell.c
|
pn53x_tamashell_SOURCES = pn53x-tamashell.c
|
||||||
pn53x_tamashell_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
pn53x_tamashell_LDADD = $(top_builddir)/libnfc/libnfc.la \
|
||||||
libnfcutils.la
|
libnfcutils.la
|
||||||
pn53x_tamashell_LDFLAGS = @READLINE_LIBS@
|
pn53x_tamashell_LDFLAGS = @READLINE_LIBS@
|
||||||
|
|
||||||
dist_man_MANS = nfc-anticol.1 nfc-emulate.1 nfc-list.1 nfc-mfclassic.1 nfc-mfultralight.1 nfc-relay.1 nfc-sam.1
|
dist_man_MANS = nfc-anticol.1 nfc-emulate.1 nfc-list.1 nfc-mfclassic.1 nfc-mfultralight.1 nfc-relay.1 pn53x-sam.1
|
||||||
|
|
||||||
EXTRA_DIST = CMakeLists.txt
|
EXTRA_DIST = CMakeLists.txt
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
.TH NFC-SAM 1 "June 15, 2010"
|
.TH PN53X-SAM 1 "June 15, 2010"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
nfc-sam \- NFC SAM comunication command line tool based on libnfc
|
pn53x-sam \- PN53x SAM comunication demonstration tool
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
.B nfc-sam
|
.B pn53x-sam
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
.B nfc-sam
|
.B pn53x-sam
|
||||||
utility attempts to test a simple connection with a SAM (Secure Access Module) in several modes.
|
utility attempts to test a simple connection with a SAM (Secure Access Module) in several modes.
|
||||||
|
|
||||||
To run this utility you must have a SAM (like the NXP's P5CN072 chip) successfully connected to your NFC chip.
|
To run this utility you must have a SAM (like the NXP's P5CN072 chip) successfully connected to your PN53x chip.
|
||||||
|
|
||||||
.SH BUGS
|
.SH BUGS
|
||||||
Please report any bugs on the
|
Please report any bugs on the
|
|
@ -18,7 +18,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @file nfc-sam.c
|
* @file pn53x-sam.c
|
||||||
* @brief Configure the NFC device to comunicate with a SAM (Secure Access Module).
|
* @brief Configure the NFC device to comunicate with a SAM (Secure Access Module).
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
@ -46,7 +46,6 @@
|
||||||
#include <nfc/nfc-messages.h>
|
#include <nfc/nfc-messages.h>
|
||||||
#include "nfc-utils.h"
|
#include "nfc-utils.h"
|
||||||
|
|
||||||
// FIXME Avoid usage of pn53x specific function or change the name from nfc-sam to pn53x-sam
|
|
||||||
#include "chips/pn53x.h"
|
#include "chips/pn53x.h"
|
||||||
|
|
||||||
#define MAX_FRAME_LEN 264
|
#define MAX_FRAME_LEN 264
|
||||||
|
@ -83,7 +82,6 @@ sam_connection (nfc_device_t * pnd, int mode)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FIXME Avoid direct call to pn53x functions
|
|
||||||
if (!pn53x_transceive (pnd, pncmd_sam_config, szCmd, abtRx, &szRxLen)) {
|
if (!pn53x_transceive (pnd, pncmd_sam_config, szCmd, abtRx, &szRxLen)) {
|
||||||
nfc_perror(pnd, "pn53x_transceive");
|
nfc_perror(pnd, "pn53x_transceive");
|
||||||
ERR ("%s %d", "Unable to execute SAMConfiguration command with mode byte:", mode);
|
ERR ("%s %d", "Unable to execute SAMConfiguration command with mode byte:", mode);
|
Loading…
Add table
Reference in a new issue