Multiple Writes with MIFARE Classics 1K RFID

Hi Everyone,

I have a question on how to perform multiple writes on MIFARE Classics 1K PICC. I am now able to write one set of data to a data block once without any issue. However, I don't know how to do multiple writes (or "update") to the same data block. My intention is to make my RFID card function as one of those used when one tags on or off a train or bus to pay for the fare. I seems to me that I can only ever write to that data block once without resetting my Arduino board (or re-upload the whole program).

What is the difference between a data block and a value block? Should I configure the access bits to make the data block a value one?

Please advise me on how to resolve this issue :slight_smile:

Thank you very much

Kenny

There is no difference between writing a block and updating a block. I you must always write the entire block so for an update, you would read, modify what you want, and then write the whole block back.

https://www.nxp.com/docs/en/application-note/AN1304.pdf

I seems to me that I can only ever write to that data block once without resetting my Arduino board (or re-upload the whole program).

Then your code is wrong.