2018-05-14 07:40 AM
Hello,
I am a beginner with M24LR04E.
I use X-NUCLEO-NFC02a1 with NUCLEO-L053R8.
I use STM32CubeExpansion_NFC2_V1.3.0 with True Studio.
I do some examples with ST library which work good (SMS, email, URI, website, text, contact)
I do an example with lib_ndef_aar and it not works.
I wrote this code :
strcpy(App_Android.PakageName,'com.gombosdev.ampere');
NDEF_AddAAR(&App_Android);I use an application 'NFC Tools'to write data in M24LR04E and it work good.
I don't understand.
Do you have an example which work with the library NDEF-AAR ?
best regards,
Mickaël Bucher
Solved! Go to Solution.
2018-05-17 01:28 AM
Hi Mickael,
Writing an AAR with the NDEF library is as simple as you already did.
From your description, the only issue that could occur is that the memory of your tag is full.
The NDEF_AddAAR actually adds an AAR record to an existing NDEF message in the tag, so you need to make sure the remaining available memory is sufficient.
If you prefer to have an NDEF message containing only a single AAR record, your should clear the NDEF message prior to call NDEF_AddAAR:
memset(NDEF_Buffer,0,2);
NDEF_WriteNDEF(NDEF_Buffer);
NDEF_AddAAR(&App_Android);
Let us know if this helps with your issue.
And if not, please provide more details on your failure:
1. Does NDEF_AddAAR return an error code? Which one?
2. How do you read the tag on RF side. Do you use an Android phone?
Regards,
Remi B.
2018-05-17 01:28 AM
Hi Mickael,
Writing an AAR with the NDEF library is as simple as you already did.
From your description, the only issue that could occur is that the memory of your tag is full.
The NDEF_AddAAR actually adds an AAR record to an existing NDEF message in the tag, so you need to make sure the remaining available memory is sufficient.
If you prefer to have an NDEF message containing only a single AAR record, your should clear the NDEF message prior to call NDEF_AddAAR:
memset(NDEF_Buffer,0,2);
NDEF_WriteNDEF(NDEF_Buffer);
NDEF_AddAAR(&App_Android);
Let us know if this helps with your issue.
And if not, please provide more details on your failure:
1. Does NDEF_AddAAR return an error code? Which one?
2. How do you read the tag on RF side. Do you use an Android phone?
Regards,
Remi B.