RFID Filament - deusrex2k/Creality-K2Plus-Extracted-Firmwares GitHub Wiki

RFID Filament

Tag info

Creality uses Mifare Classic 1k tags. There are reports that Mifare Mini tags also work. Mifare Classic 1k tags are broken up into 16 Sectors of 4 Blocks. Each block is 16 bytes. The 4th block is for security, so only 3 blocks are usable in each sector. The security section has the keys used to encrypt the data.

Data structure

Creality tags are encrypted, however, Creality also supports tags using the default key of 0xFFFFFFFFFFF. Creality only uses Sector 1 (blocks 4, 5, 6). The data is stored as an ASCII string, which gets converted to HEX when written to the tag. Here is an example ASCII string:

56D241200A2100001#0000FF016500000100000000000000

Here is the ASCII string converted to HEX and split into the 3 blocks:

35364432343132303041323130303030 31233030303046463031363530303030 30313030303030303030303030303030

The ASCII string has the following data in it:

56D - Batch number (Hex number?) 24120 - Date (YYMDD. Only 1 character for Month, I don't know how Oct-Dec are represented) 0A2 - Supplier (Hex number?) 100001 - Material. Must match a value in material_database.json on the Printer #0000FF - RGB HEX Color code, this one is blue. 0165 - Length in meters. 0330 for 1kg, 0165 for 500g spools 000001 - Serial number 00000000000000 - Reserve for future use.

To generate the data needed for a tag, all you have to do is create the ASCII string defined above (and make sure to keep the length of each field constant), convert it to HEX, break it up into 12 byte blocks, and then write to Sector 1 of the tag using the default key of 0xFFFFFFFFFFF.

Apps to generate tags

⚠️ **GitHub.com Fallback** ⚠️