By Debugger; Figure 71. Dbgmcu_Cr Hal Library Functions - STMicroelectronics STM32 Application Note

Microcontroller debug toolbox
Hide thumbs Also See for STM32:
Table of Contents

Advertisement

Managing DBGMCU registers
For M0 Cortex based families (L0/F0) DBGMCU module need to be clocked by setting bit 22
of register RCC_APB2ENR (refer to the corresponding reference manual) prior to be
written.
RCC->APB2ENR |= RCC_APB2ENR_DBGMCUEN;
Some HAL macros are also available to Enable/Disable this clock.
__HAL_RCC_DBGMCU_CLK_ENABLE();
HAL_DBGMCU_EnableDBGStopMode();
HAL_DBGMCU_EnableDBGStandbyMode();
HAL_DBGMCU_EnableDBGSleepMode();
__HAL_RCC_DBGMCU_CLK_DISABLE();
A.2

By debugger

In order to avoid debugging specific lines in the source code, there are several possibilities
to set DBGMCU registers through debugger interfaces or scripts.
96/118

Figure 71. DBGMCU_CR HAL Library Functions

AN4989 Rev 3
AN4989

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32 and is the answer not in the manual?

Table of Contents

Save PDF