esp-idf/components/hal/include/hal
Jiang Jiang Jian f3922f1b7f Merge branch 'feature/flash_mmap_refactor' into 'master'
flash mmap: abstract R/W of MMU table instead of reg access

See merge request espressif/esp-idf!16882
2022-05-29 13:56:37 +08:00
..
adc_hal.h adc: create common adc hal layer 2022-05-07 19:20:44 +08:00
adc_hal_common.h adc: create common adc hal layer 2022-05-07 19:20:44 +08:00
adc_types.h docs: fix all doxygen warnings 2022-05-12 14:50:03 +08:00
adc_types_private.h adc: create common adc hal layer 2022-05-07 19:20:44 +08:00
aes_hal.h
aes_types.h
brownout_hal.h
cache_hal.h cache/mmu: implememnt cache and mmu hal APIs in bootloader 2022-03-11 22:43:11 +08:00
cache_types.h cache/mmu: implememnt cache and mmu hal APIs in bootloader 2022-03-11 22:43:11 +08:00
cpu_hal.h
cpu_types.h
dac_hal.h
dac_types.h
dma_types.h
ds_hal.h
ecc_hal.h esp32c2/hal: Added ECC HAL layer 2022-03-08 14:05:23 +00:00
ecc_types.h esp32c2/hal: Added ECC HAL layer 2022-03-08 14:05:23 +00:00
efuse_hal.h soc: Adds efuse hal 2022-02-24 22:20:09 +08:00
emac_hal.h esp_netif: remove dependency of L2 TAP Interface from netif_lwip 2022-04-08 16:40:29 +02:00
esp_flash_err.h
eth_types.h
gdma_hal.h
gpio_hal.h esp32h2: support GPIO peripheral, IO_MUX, GPIO matrix. 2022-03-04 11:25:05 +08:00
gpio_types.h esp32h2: support GPIO peripheral, IO_MUX, GPIO matrix. 2022-03-04 11:25:05 +08:00
i2c_hal.h
i2c_types.h driver: remove deprecated code 2022-05-19 11:31:53 +08:00
i2s_hal.h i2s: extract std/pdm/tdm modes 2022-03-22 10:14:45 +08:00
i2s_pdm.h i2s: extract std/pdm/tdm modes 2022-03-22 10:14:45 +08:00
i2s_std.h i2s: fix only right case 2022-04-23 07:38:45 +00:00
i2s_tdm.h i2s: extract std/pdm/tdm modes 2022-03-22 10:14:45 +08:00
i2s_types.h i2s: fix bug of switching mono/stereo mode by 'i2s_set_clk' on c3/s3 2022-03-02 03:34:25 +00:00
i2s_types_priv.h i2s: fix only right case 2022-04-23 07:38:45 +00:00
interrupt_controller_hal.h
interrupt_controller_types.h
lcd_hal.h
lcd_types.h clk_tree: prework of introducing clk subsystem control 2022-04-11 12:09:06 +08:00
ledc_hal.h ledc: Provide support for esp32c2 and esp32h2 2022-04-14 08:15:14 +00:00
ledc_types.h ledc: Provide support for esp32c2 and esp32h2 2022-04-14 08:15:14 +00:00
mcpwm_hal.h
mcpwm_types.h
memprot_types.h
mmu_hal.h cache/mmu: implememnt cache and mmu hal APIs in bootloader 2022-03-11 22:43:11 +08:00
mmu_types.h flash mmap: abstract R/W MMU table instead of reg access 2022-05-20 16:46:27 +08:00
mpu_hal.h
mpu_types.h
pcnt_hal.h pulse_cnt: new driver for PCNT peripheral 2022-03-03 22:38:32 +08:00
pcnt_types.h pulse_cnt: new driver for PCNT peripheral 2022-03-03 22:38:32 +08:00
readme.md
rmt_hal.h driver_ng: implement new rmt driver 2022-05-07 10:34:50 +00:00
rmt_types.h driver_ng: implement new rmt driver 2022-05-07 10:34:50 +00:00
rtc_hal.h esp_hw_‎support/sleep: ‎fix cannot lightsleep again after a wakeup from ULP 2022-05-12 17:57:08 +08:00
rtc_io_hal.h
rtc_io_types.h
sdio_slave_hal.h
sdio_slave_ll.h
sdio_slave_types.h
sha_hal.h
sha_types.h
sigmadelta_hal.h
sigmadelta_types.h
soc_hal.h
spi_flash_encrypt_hal.h
spi_flash_hal.h spi_flash: refactor the spi_flash clock configuration, and add support for esp32c2 2022-04-26 15:22:37 +08:00
spi_flash_types.h spi_flash: refactor the spi_flash clock configuration, and add support for esp32c2 2022-04-26 15:22:37 +08:00
spi_hal.h
spi_slave_hal.h
spi_slave_hd_hal.h
spi_types.h
systimer_hal.h
systimer_types.h hal: Fix systimer counter value bit field 2022-05-26 12:56:25 +00:00
temperature_sensor_types.h clk_tree: prework of introducing clk subsystem control 2022-04-11 12:09:06 +08:00
timer_hal.h
timer_types.h clk_tree: added default clock source for peripheral 2022-04-14 15:44:56 +08:00
touch_sensor_hal.h rtc_clk: Clean up some clock related enum and macro in soc/rtc.h, replace with new ones in 2022-05-24 22:59:41 +08:00
touch_sensor_types.h
twai_hal.h twai: Fix twai_ll_parse_frame_buffer() typo 2022-04-22 15:25:39 +08:00
twai_types.h
uart_hal.h uart: Provide support for esp32c2 and esp32h2 2022-03-02 11:29:13 +08:00
uart_types.h driver: remove deprecated code 2022-05-19 11:31:53 +08:00
uhci_types.h
usb_hal.h
usb_phy_hal.h
usb_phy_types.h
usb_types_private.h
usbh_hal.h
usbh_ll.h
wdt_hal.h
wdt_types.h
xt_wdt_hal.h

readme.md

HAL Layer Readme

The HAL layer is designed to be used by the drivers. We don't guarantee the stability and back-compatibility among versions. The HAL layer may update very frequently with the driver. Please don't use them in the applications or treat them as stable APIs.

The HAL layer consists of two layers: HAL (upper) and Lowlevel(bottom). The HAL layer defines the steps and data required by the peripheral. The lowlevel is a translation layer converting general conceptions to register configurations.

Lowlevel

This layer should be all static inline. The first argument of LL functions is usually a pointer to the beginning address of the peripheral register. Each chip should have its own LL layer. The functions in this layer should be atomic and independent from each other so that the upper layer can change/perform one of the options/operation without touching the others.

HAL

This layer should depend on the operating system as little as possible. It's a wrapping of LL functions, so that the upper layer can combine basic steps into different working ways (polling, non-polling, interrupt, etc.). Without using queues/locks/delay/loop/etc., this layer can be easily port to other os or simulation systems.

To get better performance and better porting ability, contexts are used to hold sustainable data and pass the parameters.

To develop your own driver, it is suggested to copy the HAL layer to your own code and keep them until manual update.