diff options
author | Martijn Coenen <martijn.coenen@nxp.com> | 2011-02-03 17:07:12 +0100 |
---|---|---|
committer | Nick Pelly <npelly@google.com> | 2011-02-18 01:50:36 -0800 |
commit | a61bf7e2cb6cf80f1deea680613423a477ac4fb8 (patch) | |
tree | c1e8a7bff48acc4957fdbf20f074a8d2fd038c3b /Linux_x86 | |
parent | 18516f4e58aad80815fb6efea22d217d39b90c10 (diff) | |
download | external_libnfc-nxp-a61bf7e2cb6cf80f1deea680613423a477ac4fb8.zip external_libnfc-nxp-a61bf7e2cb6cf80f1deea680613423a477ac4fb8.tar.gz external_libnfc-nxp-a61bf7e2cb6cf80f1deea680613423a477ac4fb8.tar.bz2 |
Narrow down NFCSTATUS_TARGET_LOST responses from libNFC.
During extensive testing we found that some ISO15693 tags do not react
to some commands. However, they do send an error code to the PN544 indicating
they do not support the command. The PN544 in turn sends one specific error code
over the HCI interface. However, libNFC maps that error code always
to NFCSTATUS_TARGET_LOST, which in the end maps to the application API reporting
a TargetLostException.
This fix maps only the timeout return values from the PN544 to NFCSTATUS_TARGET_LOST;
all other values are mapped to NFCSTATUS_FAILED, which in turn maps to an
IOException at API level.
In effect, a timeout is still not the same as a target lost; libNFC does not do any
additional internal presence check to make sure the tag is really gone, although
it usually is. I'll submit a separate fix on packages/apps/Nfc to take care of this.
Change-Id: If64857658d683aff29134f74b42efd99b695e634
Diffstat (limited to 'Linux_x86')
0 files changed, 0 insertions, 0 deletions