2020-09-22 07:23 AM
If I perform like a stupid User (write Tag and before the message is published i remove it from the Tag), I am able to get an error message from the NFC-Tag. It's something like "Tag I/O-Error" or "Tag I/O-Error, Tag is not ndef". So if this happens many times in a row, i am not able to write,read,format or clear the Tag via NFC again. Not with my Phone-App or with "NFC-Tools". I am only able to reset it via I2C on the Microcontroller. If I want to get Information from the Chip, it says "Capacity 0/0Bytes" so it's not accepting any order. My Question now is, why does this happen and is there a way to Reset the tag via NFC? Did anybody else have this problem before?
Solved! Go to Solution.
2020-09-25 01:58 AM
Hi,
just for your information, here are the steps used by readers when writing an NDEF message into a tag:
If you remove the tag, this is likely to happen in step #2 or before step #3 completion. Therefore, it is likely the NDEF file inside the tag has a Len=0 (byte 0 and 1 at offset 0 are set to 0) after a tag removal during NDEF write
In M24SR64-Y product, the ReadBinary command does not allow to read more NDEF bytes than the actual length indicated in the NDEF File, i.e. if the lenght is 0, then the ReadBinary can only read the length field. This is explained in §3.1.3 and §5.6.7 of the M24SR64-Y datasheet . The Response of the ReadBinary command is successful when the data to be read is within the selected file; in other words, when the sum of P1-P2 and Le fields is equal to or lower than the selected file length.
Apps have to first read the NDEF length (ReadBinary of 2 bytes at offset 0 of the NDEF file). Then if the Length is different from 0, Apps have to read only the message content.
Rgds
BT
2020-09-22 08:10 AM
Hi,
can you try to read the tag with the ST25 NFC Tap App?
Can you elaborate on:
Thanks
Rgds
BT
2020-09-23 04:07 AM
Hey, thank you for the answer!
-The St25 NFC Tap App says: "Command Failed"
Tag Info: M24SR64-Y
NFC type4A-ISO/IEC 14443A
Manufacturer: STMicroelectonics
UID: 02840036669979
Memory size(Bytes): 8192 bytes
Tech list:
android.nfc.tech.IsoDep
android.nfc.tech.NfcA
android.nfc.tech.Ndef
I can also Read Momory, Write Memory etc. After i did this, I've send an Ndef Message to it and it worked!! Now i can write with my App again… weird..
So what happend to the M24SR that i couldn't write on it from my App/ or another one (from the Playstore) on it? Is there a function to clear it first? Should I clear the Tag everytime, before I write a new NdefMessage on it? Do you Need a Picture of the Memory?
best regards,
Jon
2020-09-23 04:26 AM
Ok i tried it on another Tag I got into this state, I don't Need to do anything more than Write a NdefMessage (text) from the St25 App...
I looked in the Memory and there was only my 2 Records I've send to the Tag. But when I tried to Write a Message from another App to the "Buggy" Tag, it said Message size to big. Message was: "Hello". After I used your App to write a Message, I was able to use my old App again.
What am I doing wrong?
btw. I tried to get the Tag into this state again, it's not possible anymore. So if you don't know what I did to the Tag and how I can fix it - maybe I fixed it already myself and I don't even know ^^
2020-09-23 04:35 AM
2020-09-23 05:13 AM
Hi,
can you reproduce this issue with other Type 4 tags such as ST25TA?
Rgds
BT
2020-09-23 05:21 AM
Hi,
if i get you right, you are asking if I have any other Tags. No I don't. I only hve your M24SR Discovery, M24SR Nucleo Expansion and some ant7-t-m24sr. The Bug was possible with all of them.
Greetings,
Jon
2020-09-25 01:58 AM
Hi,
just for your information, here are the steps used by readers when writing an NDEF message into a tag:
If you remove the tag, this is likely to happen in step #2 or before step #3 completion. Therefore, it is likely the NDEF file inside the tag has a Len=0 (byte 0 and 1 at offset 0 are set to 0) after a tag removal during NDEF write
In M24SR64-Y product, the ReadBinary command does not allow to read more NDEF bytes than the actual length indicated in the NDEF File, i.e. if the lenght is 0, then the ReadBinary can only read the length field. This is explained in §3.1.3 and §5.6.7 of the M24SR64-Y datasheet . The Response of the ReadBinary command is successful when the data to be read is within the selected file; in other words, when the sum of P1-P2 and Le fields is equal to or lower than the selected file length.
Apps have to first read the NDEF length (ReadBinary of 2 bytes at offset 0 of the NDEF file). Then if the Length is different from 0, Apps have to read only the message content.
Rgds
BT