user2866385
user2866385

Reputation: 21

NFC tag goes blank if tag write fails in android

I am trying to write data to my NFC tag which i have already written some data in my previous write operation. If i don't keep the tag properly to write then tag write fails, but my previous data get erased. Can someone please help how to avoid this scenario or what would be the root cause of it.

I don't have any problem in reading and writing the data. but only facing problem if write tag fails!!!

Upvotes: 1

Views: 1038

Answers (2)

NFC guy
NFC guy

Reputation: 10228

This behaviour is exactly as it is supposed to work. To ensure that the tag is always in a defined state, overwriting a tag starts by setting the current message length to 0. Then the new message content is written. When that is finished, the proper length is written. In this way, when the writing is interrupted, there will not be some corrupt/unfinished message data on the tag, but a message of length 0 (containing nothing).

Upvotes: 1

Jeremy Zahner
Jeremy Zahner

Reputation: 501

Did you try to first, properly erase all data on it, and then write to it. I guess, thats the proper way of doing it!? Did you try another writer (app)? Maybe your Writer app doesn't work the way it should (i had some non correct working writer apps on my lumia920).

Upvotes: 0

Related Questions