Prusa MINI Firmware overview
APB1 Peripheral Low Power Enable Disable

Enable or disable the APB1 peripheral clock during Low Power (Sleep) mode. More...

Collaboration diagram for APB1 Peripheral Low Power Enable Disable:

Macros

#define __HAL_RCC_TIM5_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_TIM5LPEN))
 
#define __HAL_RCC_WWDG_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_WWDGLPEN))
 
#define __HAL_RCC_SPI2_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_SPI2LPEN))
 
#define __HAL_RCC_USART2_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_USART2LPEN))
 
#define __HAL_RCC_I2C1_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_I2C1LPEN))
 
#define __HAL_RCC_I2C2_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_I2C2LPEN))
 
#define __HAL_RCC_PWR_CLK_SLEEP_ENABLE()   (RCC->APB1LPENR |= (RCC_APB1LPENR_PWRLPEN))
 
#define __HAL_RCC_TIM5_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_TIM5LPEN))
 
#define __HAL_RCC_WWDG_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_WWDGLPEN))
 
#define __HAL_RCC_SPI2_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_SPI2LPEN))
 
#define __HAL_RCC_USART2_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_USART2LPEN))
 
#define __HAL_RCC_I2C1_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_I2C1LPEN))
 
#define __HAL_RCC_I2C2_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_I2C2LPEN))
 
#define __HAL_RCC_PWR_CLK_SLEEP_DISABLE()   (RCC->APB1LPENR &= ~(RCC_APB1LPENR_PWRLPEN))
 

Detailed Description

Enable or disable the APB1 peripheral clock during Low Power (Sleep) mode.

Note
Peripheral clock gating in SLEEP mode can be used to further reduce power consumption.
After wake-up from SLEEP mode, the peripheral clock is enabled again.
By default, all peripheral clocks are enabled during SLEEP mode.

Macro Definition Documentation

◆ __HAL_RCC_TIM5_CLK_SLEEP_ENABLE

#define __HAL_RCC_TIM5_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_TIM5LPEN))

◆ __HAL_RCC_WWDG_CLK_SLEEP_ENABLE

#define __HAL_RCC_WWDG_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_WWDGLPEN))

◆ __HAL_RCC_SPI2_CLK_SLEEP_ENABLE

#define __HAL_RCC_SPI2_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_SPI2LPEN))

◆ __HAL_RCC_USART2_CLK_SLEEP_ENABLE

#define __HAL_RCC_USART2_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_USART2LPEN))

◆ __HAL_RCC_I2C1_CLK_SLEEP_ENABLE

#define __HAL_RCC_I2C1_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_I2C1LPEN))

◆ __HAL_RCC_I2C2_CLK_SLEEP_ENABLE

#define __HAL_RCC_I2C2_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_I2C2LPEN))

◆ __HAL_RCC_PWR_CLK_SLEEP_ENABLE

#define __HAL_RCC_PWR_CLK_SLEEP_ENABLE ( )    (RCC->APB1LPENR |= (RCC_APB1LPENR_PWRLPEN))

◆ __HAL_RCC_TIM5_CLK_SLEEP_DISABLE

#define __HAL_RCC_TIM5_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_TIM5LPEN))

◆ __HAL_RCC_WWDG_CLK_SLEEP_DISABLE

#define __HAL_RCC_WWDG_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_WWDGLPEN))

◆ __HAL_RCC_SPI2_CLK_SLEEP_DISABLE

#define __HAL_RCC_SPI2_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_SPI2LPEN))

◆ __HAL_RCC_USART2_CLK_SLEEP_DISABLE

#define __HAL_RCC_USART2_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_USART2LPEN))

◆ __HAL_RCC_I2C1_CLK_SLEEP_DISABLE

#define __HAL_RCC_I2C1_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_I2C1LPEN))

◆ __HAL_RCC_I2C2_CLK_SLEEP_DISABLE

#define __HAL_RCC_I2C2_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_I2C2LPEN))

◆ __HAL_RCC_PWR_CLK_SLEEP_DISABLE

#define __HAL_RCC_PWR_CLK_SLEEP_DISABLE ( )    (RCC->APB1LPENR &= ~(RCC_APB1LPENR_PWRLPEN))