There are times when resetting the CLA is needed.
For example, during code debug the CLA can enter an infinite loop due to a code bug.
The CLA has two types of resets: hard and soft. Both of these resets can be
performed by the debugger or by the main CPU.
- Hard Reset Writing a 1 to the
MCTL[HARDRESET] bit performs a hard reset of the CLA. The behavior of a hard
reset is the same as a system reset (using XRS or the
debugger). In this case, all CLA configuration and execution registers can be
set to the default state and CLA execution halts.
- Soft Reset Writing a 1 to the
MCTL[SOFTRESET] bit performs a soft reset of the CLA. If a task is executing,
the task halts and the associated MIRUN bit is cleared. All bits within the
interrupt enable (MIER) register are also cleared, so that no new tasks
start. In addition, the background task start bit (MCTLBGRN.BGSTART) and trigger
enable bit (MCTLBGRND.TRIGEN) are reset. The MVECTBGRNACTIVE is set to the
value of MVECTBGRND, and the status register (MSTSBGRND) is also
reset.