HAL PWR Overview

Introducing PWR

group PWR_Introduction

  • This introduction is under development.

Module and files

The following diagram illustrates the PWR module and its associated files.

Module and files diagram

Component diagram

The following diagram illustrates the software components involved in the PWR module. It shows the interactions between the user application, HAL drivers, low-level drivers, and the hardware components.

@startuml

<style>

componentDiagram {

   arrow {

      FontSize 8

   }

}

</style>



title PWR Software Component Diagram



package "HAL" {

    [HAL_PWR]

}



package "Low Layer" {

    component "LL" {

      [LL_PWR]

      [LL_SYSTEM]

    }

    [CMSIS]

    [DFP]

    [PWR Interrupt routine service]

}



package "HW" {

   component "STM32_HW" {

    [ARM_HW]

  }

}



' ==================================================================================================

' =                                             GENERIC                                            =

' ==================================================================================================



' -------------------- Layout --------------------

[Appli] -[hidden]-> [HAL_PWR]

[HAL_PWR] -[hidden]-> [LL_PWR]

[LL] -[hidden]-> [CMSIS]

[LL] -[hidden]-> [DFP]

[DFP] -[hidden]-> [STM32_HW]



' -------------------- Diagram --------------------

[Appli] --> [HAL_PWR] : HAL PWR API

[Appli] <-- [HAL_PWR] : PWR callback



[HAL_PWR] -> [LL_PWR] : LL PWR API

[HAL_PWR] --d--> [ARM_HW] : ARM registers R/W



[LL] -> [CMSIS] : ARM register def

[LL] -> [DFP] : PWR register def



[LL_PWR] --> [STM32_HW] : PWR registers R/W





' ==================================================================================================

' =                                            SPECIFIC                                            =

' ==================================================================================================



' -------------------- Layout --------------------

[HAL_PWR] -[hidden]-> [PWR Interrupt routine service]

[HAL_PWR] -[hidden]-> [LL_SYSTEM]



' -------------------- Diagram --------------------

[HAL_PWR] -> [LL_SYSTEM] : LL SYSTEM API

[LL_SYSTEM] -> [STM32_HW] : SYSTEM registers R/W

[STM32_HW] -> [PWR Interrupt routine service]: PWR Irq



[PWR Interrupt routine service] -> [HAL_PWR]: PWR IRQ Handler

@enduml

Configuration table

The following table lists the configuration defines for the HAL PWR module, specifying their locations, default values, and descriptions:

group PWR_Configuration_Table

Configuration inside the PWR driver

Config defines

Description

Default value

Note

USE_HAL_PWR_MODULE

from hal_conf.h

1U

When set, HAL PWR module is enabled.

USE_ASSERT_DBG_PARAM

from IDE

None

When defined, enable the params assert.

USE_HAL_CHECK_PARAM

from hal_conf.h

0U

When set, parameters are checked in runtime.