ChibiOS/HAL  7.1.5
HAL Driver

Hardware Abstraction Layer. More...

Collaboration diagram for HAL Driver:

Detailed Description

Hardware Abstraction Layer.

The HAL (Hardware Abstraction Layer) driver performs the system initialization and includes the platform support code shared by the other drivers. This driver does contain any API function except for a general initialization function halInit() that must be invoked before any HAL service can be used, usually the HAL initialization should be performed immediately before the kernel initialization.
Some HAL driver implementations also offer a custom early clock setup function that can be invoked before the C runtime initialization in order to accelerate the startup time.

Macros

#define _CHIBIOS_HAL_
 ChibiOS/HAL identification macro. More...
 
#define CH_HAL_STABLE   1
 Stable release flag. More...
 

ChibiOS/HAL version identification

#define HAL_VERSION   "7.1.5"
 HAL version string. More...
 
#define CH_HAL_MAJOR   7
 HAL version major number. More...
 
#define CH_HAL_MINOR   1
 HAL version minor number. More...
 
#define CH_HAL_PATCH   5
 HAL version patch number. More...
 

Return codes

#define HAL_SUCCESS   false
 HAL operation success. More...
 
#define HAL_FAILED   true
 HAL operation failed. More...
 

Platform identification macros

#define PLATFORM_NAME   "templates"
 

Functions

void halInit (void)
 HAL initialization. More...
 
void hal_lld_init (void)
 Low level HAL driver initialization. More...
 

Macro Definition Documentation

◆ _CHIBIOS_HAL_

#define _CHIBIOS_HAL_

ChibiOS/HAL identification macro.

Definition at line 188 of file hal.h.

◆ CH_HAL_STABLE

#define CH_HAL_STABLE   1

Stable release flag.

Definition at line 193 of file hal.h.

◆ HAL_VERSION

#define HAL_VERSION   "7.1.5"

HAL version string.

Definition at line 202 of file hal.h.

◆ CH_HAL_MAJOR

#define CH_HAL_MAJOR   7

HAL version major number.

Definition at line 207 of file hal.h.

◆ CH_HAL_MINOR

#define CH_HAL_MINOR   1

HAL version minor number.

Definition at line 212 of file hal.h.

◆ CH_HAL_PATCH

#define CH_HAL_PATCH   5

HAL version patch number.

Definition at line 217 of file hal.h.

◆ HAL_SUCCESS

#define HAL_SUCCESS   false

HAL operation success.

Definition at line 227 of file hal.h.

◆ HAL_FAILED

#define HAL_FAILED   true

HAL operation failed.

Definition at line 231 of file hal.h.

Function Documentation

◆ halInit()

void halInit ( void  )

HAL initialization.

This function invokes the low level initialization code then initializes all the drivers enabled in the HAL. Finally the board-specific initialization is performed by invoking boardInit() (usually defined in board.c).

Function Class:
Initializer, this function just initializes an object and can be invoked before the kernel is initialized.

Definition at line 56 of file hal.c.

References adcInit(), canInit(), cryInit(), dacInit(), eflInit(), gptInit(), hal_lld_init(), i2cInit(), i2sInit(), icuInit(), macInit(), mmcInit(), osalInit(), palInit, pwmInit(), rtcInit(), sdcInit(), sdInit(), sduInit(), spiInit(), stInit(), trngInit(), uartInit(), usbInit(), wdgInit(), and wspiInit().

Here is the call graph for this function:

◆ hal_lld_init()

void hal_lld_init ( void  )

Low level HAL driver initialization.

Function Class:
Not an API, this function is for internal use only.

Definition at line 56 of file hal_lld.c.

Referenced by halInit().