9.4.8 Secure Debug and Code Protection

Secure debug can be used either with or without code protection. When secure debug is enabled without code protection, once authorization is given, debug and test access are allowed with full access to the user program and user data Flash (subject to protection region restrictions).

When both secure debug and code-protect are enabled, both IRT authorization and a chip erase are required for external access to user program Flash. This allows user program memory to be changed without revealing its original contents and only with IRT authorization. The permanent regions (IRT and OTP) are not erased on a chip erase.

When secure debug is enabled, there is no way to disable or bypass secure debug access controls.