This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NFC and the CR95HF

Hello DevZone,

SDK 15.0.0. SD132 PCA10040

SPI settings : Mode 0, MSB first, 125kbps, orc = 0

I am trying to get NFC communication between two dev kits, one using the X-NUCLEO-NFC03A1 adapter and the other dev kit with the flex antenna.

I'm using the NDEF message example on the dev kit with the flex antenna. (nfc_writable_ndef_msg_pca10040) If I'm not mistaken this is configured to use the TYPE4-A tag configuration.

I did get a message whilst compiling the ndef_msg app that it was missing isodepmsg.c and nfc_t4t_lib.c. I don't know why these messages came but I was successful in building none the less.

I'm using the examples listed in the datasheet of the CR95HF to configure, read and write the tag but so far this is unsuccessful.

https://www.st.com/resource/en/datasheet/cr95hf.pdf page 67

I am able to configure the chip to use the right protocol and setup anti collision. When I perform a REQ-A command the datasheet lists that it should return : 80 05 0400 280000, but my tag returns 80 05 4400 280000. Now I do not know what this answer is as it is not properly listed in the datasheet and could possible be some information in the TYPE4-A tag.

I assume that the UID listed in the datasheet is obviously different from what the dev kit returns but I do not know for sure. Expected is 80 08 08192D A29E 280000, got 80 08 885FAF 91E9 280000

Until this point I semi get back what I expect from the chip while reading the datasheet, but the following commands result in timeout/unsupported tag.

ISO14443A_4 RATS/ATS (bit rate capability/FDT/CID usage)

ISO14443A_4 PPS (Protocol parameter data rate)

I tried skipping these commands and go straight for reading out the NDEF message but this also results in the error of timeout/unsupported tag.

I even tried to run the example of the TYPE2 tag but this also resulted in a lot of errors of timeouts/unsupported tag.

Now I have seen some other folks have a go with using a nrf dev kit in combination with this chip, but they didn't have the same problems as what I have at the moment.

Any help on what I'm doing wrong or mistakes that I'm making would help a lot 

Thanks

Parents
  • Hi,

    Responding briefly to your questions/concerns:

    • 80 05 4400 280000 is correct, value '4400' is a SENS_RES frame which the tag transmits as a response to SENS_REQ (REQ-A). The value '4' instead of the "expected" '0' means the tag uses a double-size UID (7 bytes). Refer to the NFC Forum "Digital Protocol Specification" section 6.6.3.
    • 80 08 885FAF 91E9 280000 is also correct - like you suggested, the tag has a different UID than what is shown in the example from the datasheet. BTW, byte '5F' is a manufacturer ID
    • RATS command - yes it is required to activate the Type 4 Tag, and the tag normally should respond to this command - if it is transmitted correctly from the reader.
    • PPS command is not supported by the SDK Type 4 Tag library, and is not required by the NFC Forum specs - you should be able to read and write the tag without using this command

    I would suggest that you go to the nRF Connect SDK, even just for reference (you don't have to migrate there with you project). There you can find a reference NFC reader implementation which uses a chip from the ST25 family (as Nordic doesn't provide the NFC Reader/Writer HW solution), see: http://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/include/st25r3911b_nfc.html. You can find the source code at: https://github.com/NordicPlayground/fw-nrfconnect-nrf/tree/master/lib/st25r3911b

    Here you can find implementations of the required protocols (for supporting T4T) also for the Reader/Writer side: github.com/NordicPlayground/fw-nrfconnect-nrf/blob/master/subsys/nfc/t4t/

    Best regards,

    Michał

  • You... You... You are awesome. If it wasn't for Covid-19 I'd give you a hug.

    I've got it working and now I can read out my tag properly. Thank you for ending my week of struggling to get the damn chip operational.

    The double size UID was the case I had indeed.

    I continued using the datasheets reference on reading out the type 4 tag but instead of having a single size UID I implemented the double size UID. This method is select1 anticol1 and select2 anticol2.

    After this the chip accepted the RATS command and reading out the rest was accepted.

    Here is an image of me reading out my nRF tag.

    One question tho, all this information you'd posted. Is this something you knew or did you read it somewhere because I am unable to find any information on what these numbers actually mean.

    I can continue being busy with deciphering the rest of the data around it. 

    Kind regards and, 

    Dziękuję Ci Michał

Reply
  • You... You... You are awesome. If it wasn't for Covid-19 I'd give you a hug.

    I've got it working and now I can read out my tag properly. Thank you for ending my week of struggling to get the damn chip operational.

    The double size UID was the case I had indeed.

    I continued using the datasheets reference on reading out the type 4 tag but instead of having a single size UID I implemented the double size UID. This method is select1 anticol1 and select2 anticol2.

    After this the chip accepted the RATS command and reading out the rest was accepted.

    Here is an image of me reading out my nRF tag.

    One question tho, all this information you'd posted. Is this something you knew or did you read it somewhere because I am unable to find any information on what these numbers actually mean.

    I can continue being busy with deciphering the rest of the data around it. 

    Kind regards and, 

    Dziękuję Ci Michał

Children
Related