HAL FDCAN Overview

Introducing FDCAN

group FDCAN_Introduction

  • This introduction is under development.

Module and files

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

Module and files diagram

Component diagram

The following diagram illustrates the software components involved in the FDCAN 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 FDCAN Software Component Diagram



package "HAL" {

    [HAL_SERVICE]

    [HAL_FDCAN]

}



package "Low Layer" {

    [CMSIS]

    [FDCAN Interrupt routine service]

}



package "HW" {

    [STM32_HW]

}



[Appli] --> [HAL_FDCAN] : HAL FDCAN API

[Appli] <-- [HAL_FDCAN] : FDCAN callback

[HAL_FDCAN] -l-> [HAL_SERVICE] : HAL_GetTick

[HAL_FDCAN] <-- [FDCAN Interrupt routine service]

[HAL_FDCAN] --> [CMSIS]:FDCAN register def

[STM32_HW] -u--> [FDCAN Interrupt routine service]: FDCANx Irq

[STM32_HW] <--u--- [HAL_FDCAN] : FDCAN registers R/W

@enduml

Configuration table

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

group FDCAN_Configuration_Table

10.Configuration inside the FDCAN driver

Config defines

Description

Default value

Note

USE_HAL_FDCAN_CLK_ENABLE_MODEL

from hal_conf.h

HAL_CLK_ENABLE_NO

Enable the gating of the peripheral clock

USE_HAL_FDCAN_MODULE

from hal_conf.h

1

When set, HAL FDCAN module is enabled

USE_HAL_FDCAN_GET_LAST_ERRORS

from hal_conf.h

0

Enable the get last process error

USE_HAL_FDCAN_USER_DATA

from hal_conf.h

0

Enable the set/get user data

USE_HAL_FDCAN_REGISTER_CALLBACKS

from hal_conf.h

0

Enable the register callbacks assert

USE_HAL_CHECK_PARAM

from hal_conf.h

0

Parameters (pointers or sizes) are checked in runtime

USE_HAL_CHECK_PROCESS_STATE

from hal_conf.h

0

Allows to check the HAL FDCAN state transition in run time

USE_HAL_MUTEX

from hal_conf.h

0

Enable the acquire/release bus services

USE_ASSERT_DBG_PARAM

from PreProcessor env

NA

Enable the params assert

USE_ASSERT_DBG_STATE

from PreProcessor env

NA

Enable the state assert