pcsc-tools | Some tools to be used with smart cards and PC/SC | Video Game library
kandi X-RAY | pcsc-tools Summary
kandi X-RAY | pcsc-tools Summary
Some tools to be used with smart cards and PC/SC
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of pcsc-tools
pcsc-tools Key Features
pcsc-tools Examples and Code Snippets
Community Discussions
Trending Discussions on pcsc-tools
QUESTION
I am building a Windows/Java program (using javax.smartcardio
) to communicate with Jewel/Topaz512 tags (from Innovision/Broadcom) using an ACR122U device (with a PN532 NFC Controller chip inside).
I implemented the Topaz512 protocol (from this data sheet) but only half of my commands are working.
- Some commands that work:
RID, RALL, READ, WRITE-NE, RSEG
- Some commands that don't work:
WRITE-E, READ8, WRITE-E8, WRITE-NE8
For instance, here is what I get when I send a WRITE-NO-ERASE command:
Command: FF:00:00:00:0C:D4:40:01:1A:7F:42:38:01:9A:00:17:E8
Where:
D4:40:01
is the InDataExchange command,1A:7F:42
is the WRITE-NO-ERASE command (value: 0x42, block 0x0F, byte 7),38:01:9A:00
is the 4-bytes tag UID,17:E8
is the CRC.
Response: D5:41:00:42:90:00
Here the response is correct: 0x42
. The status byte (0x00
) informs that everything went well.
And here is what I get when I send a WRITE-WITH-ERASE command:
Command: FF:00:00:00:0C:D4:40:01:53:7F:42:38:01:9A:00:28:6E
Where:
D4:40:01
is the InDataExchange command,53:7F:42
is the WRITE-WITH-ERASE command (value: 0x42, block 0x0F, byte 7),38:01:9A:00
is the 4-bytes tag UID,28:6E
is the CRC.
Response: D5:41:01:90:00
Here, the status byte (0x01
) informs of a timeout detected by the PN532. (From the PN532 documentation (p67): "Time Out, the target has not answered - 0x01")
Also when I remove the PN532 timeouts (with FF:00:00:00:06:D4:32:02:00:00:00
) non-working commands do not respond D5:41:01:90:00
, but wait longer, then I get no response.
I just tried to execute the commands using gscriptor (from the pcsc-tools suite) and I got the same behavior. Here are my results:
The script:
...ANSWER
Answered 2020-Apr-22 at 15:33Some time ago I looked into this in detail and concluded that the PN532 NFC controller chip from NXP has an issue with its firmware that prevents it from successfully transceiving some commands with NFC Forum Type 1 tags (Topaz/Jewel brands). The ACR122U is based on this chip as noted.
When I tried to write 8 byte blocks at a time using the WRITE-E8 (0x54)
command, the response received is 0x01
, a timeout waiting for the tag to respond.
Things I tried that don't work:
Including the UID echo in the InDataExchange
, I even played with the endianness of the UID echo and still the same result.
Using the inCommunicateThru
command rather than InDataExchange
and calculating the CRC1 and CRC2 values at the application level (same results)
The final conclusion I reached is:
The PN532 cannot write to pages 0x10
and greater on a Type 1 tag which makes it impossible to write to the full range of memory on popular models such as the Topaz 512.
Recommendation:
This issue was relevant in 2012 when the Topaz 512 was a great low cost yet high memory NFC tag. Now that there's the NAG215 and NTAG216 models, I recommend using those models that have high memory and universal compatibility with NFC readers.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install pcsc-tools
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page