31.2.23.7 Key - SFR Unlock Register
Symbol | Description | Symbol | Description | Symbol | Description |
---|---|---|---|---|---|
R | Readable bit | HC | Cleared by Hardware | (Grey cell) | Unimplemented |
W | Writable bit | HS | Set by Hardware | X | Bit is unknown at Reset |
K | Write to clear | S | Software settable bit | — | — |
Name: | KEY |
Offset: | 0x001C |
Reset: | 0x00000000 |
Property: | PAC Write-Protection |
Bit | 31 | 30 | 29 | 28 | 27 | 26 | 25 | 24 | |
KEY[31:24] | |||||||||
Access | R/W | R/W | R/W | R/W | R/W | R/W | R/W | R/W | |
Reset | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Bit | 23 | 22 | 21 | 20 | 19 | 18 | 17 | 16 | |
KEY[23:16] | |||||||||
Access | R/W | R/W | R/W | R/W | R/W | R/W | R/W | R/W | |
Reset | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Bit | 15 | 14 | 13 | 12 | 11 | 10 | 9 | 8 | |
KEY[15:8] | |||||||||
Access | R/W | R/W | R/W | R/W | R/W | R/W | R/W | R/W | |
Reset | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Bit | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | |
KEY[7:0] | |||||||||
Access | R/W | R/W | R/W | R/W | R/W | R/W | R/W | R/W | |
Reset | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Bits 31:0 – KEY[31:0] NVM SFR Key Bits
This register is used to lock and unlock write access to other FCW SFR bits.
The KEY state remains active until it is written to a Valid Lock Code or CTRLA is written.
KEY[31:8] - KEY Code
0x91C32C= Valid Unlock code - Unlocks selected SFR(s)
All Others = Valid Lock Code - Locks all SFR protected by KEY register
KEY[7:0] KEY Value.
0x00= no selection, invalid selection, or invalid Key - Locks all SFR protected by KEY register
0x01= WRKEY Value: Unlock SFR bits associated with Write/Erase
0x02= SWAPKEY Value: Unlock SFR bits associated with Panel Swapping
0x04= CFGKEY Value: Unlock SFR bits associated with general Flash configuration
all other values: Invalid selection - Key Value set to 00 - Locks all SFR protected by KEY register
- KEY can only be written when STATUS.BUSY=0.
- KEY resets to 0 (a valid lock code) on a successful write to CTRLA, SWAP or an unsuccessful write to any register (any write that sets KEYERR).
- KEY allows for multiple writes to configuration registers when using CFGKEY. To lock, write a Valid Lock Code to KEY.