We have a scenario where we want to be able to manipulate the debug unit in software, namely set watchpoints in software. Traditionally, breakpoints, watchpoints, etc.. can be set within CCS; however, there are cases when this is not enough. For example, we only want a watchpoint active during a certain block of code. Another example is that we want to set a watchpoint on an address that is only known at runtime before a block of code is executed.
I have set watchpoints & breakpoints in software using Cortex M microcontrollers in the past as the debug unit is memory mapped and available to the CPU via the private peripheral bus.
I have looked through available documentation but cannot find any information on a debug register set that could be used in software. Is it possible to do with our chip and can documentation be provided?