Plain English

Applies a Gen2 access-policy lock to `<bank>` using the 32-bit access password (TSPL2 PG §RFID LOCK p116). `<password>` is 8 hex characters. `<policy>` is the Gen2 lock-action enum (0–3). Policy 3 is irreversible (use `RFID PERMALOCK` as the convenience wrapper). Note: the RESERVED bank exposes two named partitions on some firmware — `"KILL"` for the kill-password area and `"ACCESS"` for the access-password area.

When to use

After encoding the EPC (or other bank), to prevent unauthorised re-writes. Pair with `RFID WRITE`.

Syntax

RFID LOCK "<bank>", "<password>", <policy>

Parameters

ParameterDescription
bank
Quoted Gen2 memory bank or RESERVED partition.
  • "EPC" - Electronic Product Code bank
  • "USER" - User memory bank
  • "TID" - Tag Identifier bank (read-only on most tags)
  • "RESERVED" - Whole reserved bank
  • "KILL" - Kill-password partition of RESERVED
  • "ACCESS" - Access-password partition of RESERVED
password
Quoted 8-hex-character access password (32 bits).
policy
Gen2 lock-action enum.
  • 0 - Unlocked — writable without password
  • 1 - Locked — writable only with access password
  • 2 - Permanently unlocked — cannot be locked again
  • 3 - Permanently locked — cannot be unlocked (use RFID PERMALOCK as convenience wrapper)

Example

RFID LOCK "EPC", "12345678", 1

Lock the EPC bank so subsequent writes require the access password "12345678"

Try it in the playground View all TSPL commands