PN7462 - Mifare - NfcCcid sample

cancel
Showing results for 
Search instead for 
Did you mean: 

PN7462 - Mifare - NfcCcid sample

721 Views
benten
Contributor II

Hello,

I am looking for another way to detect that mifare card isn't in rf field. 

At NfcCcid sample somebody implements phExNFCCcid_Check_Presence_L3A_Card which "restart" card. So every loop (Clif task) mifare card is restarted.

In my opinion this is wrong solution.  I have problems commands in separates CCID APDU commands like "Restore" / "Transfer". Every CCID command - NFC reader restarts card. Additionally I see that somebody handle this problem in Read/Write block by write extra Auth command every Read/Write command. 

Kamil

0 Kudos
6 Replies

466 Views
jayyehtw
Contributor III

Hi Kamil,

I also face the same problem.

Could you kindly share the workaround you have?

 

Thanks,

Jay

0 Kudos

573 Views
benten
Contributor II

Hi Kan,

I understand how to workaround my problem. However my last question is - is any other way to detect that mifare card is not in field?

Kamil

0 Kudos

573 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Hello Kamil,

You may set up a timer from host controller side, and if no response till timer expired, the card should be removed in that case.

Hope that helps,

Have a great day,
Kan


-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

573 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Hello Kamil,

The CCID example provides templates for reading and writing block, if you want to implement commands like "Decrement", "Increment" and "Restore" , you may just copy the process from the reading and writing block commands, and append the Transfer command, I just don't understand why you have to separate CCID APDU commands like "Restore" / "Transfer", would you please specify your use case? Thanks for your patience!

Have a great day,
Kan


-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

572 Views
benten
Contributor II

Hello Kan,

I understand that sample doesn't implement restore/transfer etc. 

For a moment, forget about the Transfer / Restore functions. Let's return to the common Read operation.
Mainly, I mean that the card is reset every time the CCID command is execute. A brief picture of what happens to the card:

  1. Cart is near the reader
    1. Card activated / reset
  2. CCID command -> Authorize block
    1. Cart activated / reset (again by phExNFCCcid_Check_Presence_L3A_Card )
    2. Block authenticated success
  3. CCID command -> Read block
    1. Cart activated / reset (again by phExNFCCcid_Check_Presence_L3A_Card )
    2. Read block will not success because card "forget" about authorization. 
     

Somebody workaround problem by execute authentication before every read. So this CCID command take longer etc.

Returning to Transfer / Restore command is not possible to implement, because after oe CCID command cart forget state (because card is reset by phExNFCCcid_Check_Presence_L3A_Card )

Now Is more clear to you about my issue?

Thanks,

Kamil

0 Kudos

572 Views
Kan_Li
NXP TechSupport
NXP TechSupport

Hi Kamil,

I understand your concern, but I think it is just an implementing issue, you know , the read operation provided from that example is just for reference, you may implement it by yourself for some specific use case. For example, for the Restore command, you may just copy the Read command process, by execute authentication before every restore operation, and append the Transfer command , so in that case the host SW just has to send Restore command, PN7462 helps to issue Transfer command after that.

Hope that makes sense,

Have a great day,
Kan


-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos