cancel
Showing results for 
Search instead for 
Did you mean: 

Can I read ST25R3916 MAC address ?

toshko
Associate II

I have two devices (which are with STM32F429 & ST25R 3916) from which I read NFC Wifi pairing and Bluetooth pairing tags. What can I change to make these two identical devices in terms of functionality (which are still physically different) indistinguishable from NFC-enabled Android phones? For example, could I read the MAC address of ST25P3916? Without an additional program, can I use any data from the already read tag. My idea is as an access point to have mobility when moving in space, and when a new access point is needed.

Best Regards,

Toshko

1 ACCEPTED SOLUTION

Accepted Solutions
Brian TIDAL
ST Employee

Hi Toshko,

regarding Q1: tags have UIDs that are used during collision resolution process. When different tags are in the reader operating volume, the reader is able to discover the various tags and the application is able to select a given tag based on the tag UID and then to communicate with this tag. A Card Emulation also has a UID. In our implementation, this is a 4 bytes non-unique UID for NFCA protocol (see ceNFCA_NFCID[]   = {0x5F, 'S', 'T', 'M'};). So by default, all instances of the ST25R3916 Card Emulation demo use this UID and are therefore indistinguishable by the reader. If you want that the reader is able to distinguish between different instances, you can use different UID: for example {0x5F, 'T', 'o', '1'} for the first instance and {0x5F, 'T', 'o', '2'} for the second instance. Note that if the NDEF content is identical in each Card Emulation, your application will not distinguish the various Card Emulations. If you want to have a different content in each Card Emulation, you can for example add a Device Information record inside the NDEF and put the STM32 unique identifier inside the Device Information record..

Regarding Q2: STM32F429 has a unique 96 bits device ID (stored in 3 registers located at UID_BASE address). This can be retrieved through HAL_GetUIDw0(), HAL_GetUIDw1() and HAL_GetUIDw2() API. This unique identifier can be used in a Device Information record appended to your existing Wifi/Bluetooth paring records.

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

3 REPLIES 3
Ulysses HERNIOSUS
ST Employee

Hi Toshko,

I am not fully understanding what you are trying to achieve... The ST25R3916, is it reading NDEF tags or is it emulating NDEF tags? And where would you put the MAC/UID?

In any case ST25R3916 does not have a MAC address and not even a unique identifier. What could be an option for you is to read and use the UID from STM32 (symbol UID_BASE from STM32 HAL).

BR, Ulysses

toshko
Associate II

Hi Ulysses,

In my case STR3916 emulate NDEF tags; so I already developed several NFC projects and now I can read successfully Bluetooth pairing and WiFi pairing tags in Card Emulation mode with NFC enabled phone, and the phone is able to establish connections to given Computer pairing its Bluetooth or WiFi .

Instead I rush to details explanations, because some guys move to patent documents (the base project is pretty bigger and too much complex) and I'm really not enough involved, meaning reasonable I didn't ask them about details, back to my sub task let me ask you:

Q1: Suppose I have two identical devices (which are with STM32F429 & ST25R 3916) and one NFC enabled phone read Bluetooth(or WiFi) pairing tags from them. The question is: Are these two tags fully identical as NDEF tags(meaning the devices are indistinguishable for the phone)?

If not I'd like to know is it possible using only UID from STM32 to make them indistinguishable for the phone.

Q2: What about UID_BASE? I'll be able to find needed read/write functions soon; perhaps HAL_GetUIDw012() you mean , but I don't know for now how as parameter in the NDEF tag will be present UID_BASE. For my NDEF WiFi pairing tag I use only SSID and password as parameters; And for NDEF Bluetooth only the Bluetooth name (in my case: localName[] = {'D','E','S','K','T','O','P','-','R','J','1','A','6','L','1'};)

Thank you for the answer.

Toshko

Brian TIDAL
ST Employee

Hi Toshko,

regarding Q1: tags have UIDs that are used during collision resolution process. When different tags are in the reader operating volume, the reader is able to discover the various tags and the application is able to select a given tag based on the tag UID and then to communicate with this tag. A Card Emulation also has a UID. In our implementation, this is a 4 bytes non-unique UID for NFCA protocol (see ceNFCA_NFCID[]   = {0x5F, 'S', 'T', 'M'};). So by default, all instances of the ST25R3916 Card Emulation demo use this UID and are therefore indistinguishable by the reader. If you want that the reader is able to distinguish between different instances, you can use different UID: for example {0x5F, 'T', 'o', '1'} for the first instance and {0x5F, 'T', 'o', '2'} for the second instance. Note that if the NDEF content is identical in each Card Emulation, your application will not distinguish the various Card Emulations. If you want to have a different content in each Card Emulation, you can for example add a Device Information record inside the NDEF and put the STM32 unique identifier inside the Device Information record..

Regarding Q2: STM32F429 has a unique 96 bits device ID (stored in 3 registers located at UID_BASE address). This can be retrieved through HAL_GetUIDw0(), HAL_GetUIDw1() and HAL_GetUIDw2() API. This unique identifier can be used in a Device Information record appended to your existing Wifi/Bluetooth paring records.

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.