Read and write Mifare Classic 1K RFID on Nexus-S

I would like to write and read lines from RFID Mifare 1K. I successfully read and wrote the tag that I am using the NXP TagWriter application. Then I tried the code here , but was able to extract something meaningful from it. It didn’t even authenticate until I changed

auth = mfc.authenticateSectorWithKeyA(0, MifareClassic.KEY_DEFAULT); 

TO

 auth = mfc.authenticateSectorWithKeyA(0, MifareClassic.KEY_MIFARE_APPLICATION_DIRECTORY); 

But he only got this as a result:

 BLOCK 0: 298091JFIS8903JF0SDF093 BLOCK 1: 298091JFIS8903JF0SDF093 

Not sure what to do with it, and what the process of reading and writing to the card will be. Any examples or directions would be very helpful!

+8
android nfc rfid mifare
source share
1 answer

Have you tried the code above on the empty Mifare 1K Classic tag?

Just delete one variable. Perhaps the NXP TagWriter application changed the authentication key on first recording, preventing other programs from writing to it.

+2
source share

All Articles