cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any example file of Card Emulation Mode?

BAkeryy
Associate II

Hello

I have a custom board with the st25r3920B. I want to operate this board in CE mode.

So I set RFAL_FEATURE_LISTEN_MODE to true. 

But there is a difficulty because there is no sequence or example code for how to operate in CE mode.

Where should NDEF data be set and how do I set AID?

Is there any working example, or documentation to implement card emulation?

 

This discussion has been locked for participation. If you have a question, please start a new topic in order to ask your question
1 ACCEPTED SOLUTION

Accepted Solutions
Brian TIDAL
ST Employee

Hi,

X-CUBE-NFC6 provides a polling example that supports T3T and T4T CE mode and emulates a tag having an NDEF message. The STSW-ST25R016 (ST25 embedded NFC library) also provides a dedicated CE example (its emulate a pairing record).

See demoCE function inside demo_polling.c. In this demo, you can also set the DEMO_CARD_EMULATION_ONLY flag to have only CE mode and disable reader activities (otherwise the device will alternate between reader mode and card emulation mode during polling)

Rgds

BT

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

5 REPLIES 5
Brian TIDAL
ST Employee

Hi,

X-CUBE-NFC6 provides a polling example that supports T3T and T4T CE mode and emulates a tag having an NDEF message. The STSW-ST25R016 (ST25 embedded NFC library) also provides a dedicated CE example (its emulate a pairing record).

See demoCE function inside demo_polling.c. In this demo, you can also set the DEMO_CARD_EMULATION_ONLY flag to have only CE mode and disable reader activities (otherwise the device will alternate between reader mode and card emulation mode during polling)

Rgds

BT

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Hi, 

Thanks to your support. I checked the example code and NDEF stack library well.

I have one more question, do I need RF matching even when running in CE mode?

 

When the device operating as a reader in the NFC reads data from the tag(CE mode tag),

I think there was nothing to control on the tag side, because the device supplies power to the tag.

But I think the sensitivity is not good when operation in CE mode.

The reader device responds very occasionally.. Is this not my problem, but the reader's problem?

How do I get my CE mode to react well with the reader device?

Hi eagles64,

the existing demos we are providing (X-NUCLEO-NFC06/8) should show good performance in Reader and tag mode. 

Even for tag mode you need to match to adapt the resonance frequency. For a pure tag application one could imagine moving to completely different matching topologies (removing EMC filter, maybe disconnecting RFO pins and solely modulate using EXT_LM, ...) but we cannot give you guidance on these topics. Your easiest way forward is to stick with matchings as described in AN5276.

Best Regards, Ulysses

Hi Ulysses,

Thank you for your answer. Now my device operates well in CE mode.

And I have more question about NDEF record,

Can I put multiple function in one NDEF file?

For example, I just want to connect uri link with one NDEF file and also wifi connection at the same time.

Is it possible?

 

Several sites have confirmed that Android only recognizes one record, but I can't find anything like an official specification, so I leave a question.
If you know any related official documents, please guide us.

 

Best Regards,

Hi eagles64,

 

my memory tells Android is able to read NDEF messages with multiple records whereas iPhones only read one NDEF record.

So best if you create a new topic here on the community and then some of my colleagues with more knowledge on this topic may answer.

Ulysses