Question
Internal flash memory locking (FLASH_CR->LOCK) and write protection (nWRP) - Why does the latter exist?
I am working with the STM32F446 Nucleo-144 development board. I understand that there are 2 ways to prevent the flash from being unintentionally erased/overwritten:
1. LOCK-bit in register FLASH_CR
2. nWRP-bits in the option bytes
Why has the second method been introduced, why isn't locking enough? Could someone please give some examples of when #2 should be used?
