esp-idf/components/soc/include/hal
houwenxiang aac935ec81 bugfix(i2c): fix I2C driver breaking change issue.
1. Fixed I2C driver breaking change issue.
    2. Add I2C UT test case.
2019-12-04 15:51:36 +08:00
..
adc_hal.h refactor the adc driver 2019-11-22 15:42:16 +08:00
adc_types.h refactor the adc driver 2019-11-22 15:42:16 +08:00
dac_hal.h dac: refactor driver add hal 2019-11-22 11:44:46 +08:00
dac_types.h dac: refactor driver add hal 2019-11-22 11:44:46 +08:00
esp_flash_err.h Fix error code collision and CI check 2019-08-29 08:14:08 +00:00
gpio_hal.h bugfix(gpio):fix esp32 s2 rtc io issue 2019-11-27 17:18:20 +08:00
gpio_types.h bugfix(gpio):fix esp32 s2 rtc io issue 2019-11-27 17:18:20 +08:00
hal_defs.h mcpwm: add HAL layer support 2019-11-25 00:36:30 +08:00
i2c_hal.h bugfix(i2c): fix I2C driver breaking change issue. 2019-12-04 15:51:36 +08:00
i2c_types.h feature(I2C): Add i2c hal support. 2019-11-21 20:34:07 +08:00
i2s_hal.h i2s: fix regression in retrieval of chip revision causing apll test to fail 2019-11-22 11:46:38 +05:30
i2s_types.h refactor(i2s): add hal i2s driver 2019-11-19 22:19:19 +08:00
ledc_hal.h feat(ledc): refactor ledc driver 2019-11-21 16:25:22 +08:00
ledc_types.h feat(ledc): refactor ledc driver 2019-11-21 16:25:22 +08:00
mcpwm_hal.h mcpwm: add HAL layer support 2019-11-25 00:36:30 +08:00
mcpwm_types.h mcpwm: add HAL layer support 2019-11-25 00:36:30 +08:00
pcnt_hal.h refactor(pcnt): add hal pcnt driver 2019-11-18 14:35:46 +08:00
pcnt_types.h refactor(pcnt): add hal pcnt driver 2019-11-18 14:35:46 +08:00
readme.md spi_slave: add HAL support 2019-05-20 07:34:34 +00:00
rmt_hal.h rmt: add HAL layer 2019-11-20 10:54:21 +08:00
rmt_types.h rmt: add HAL layer 2019-11-20 10:54:21 +08:00
rtc_io_hal.h rtcio: add hal for driver 2019-11-21 10:40:49 +08:00
rtc_io_types.h rtcio: add hal for driver 2019-11-21 10:40:49 +08:00
sigmadelta_hal.h refactor(sigmadelta): add hal sigmadelta driver 2019-11-21 11:53:07 +08:00
sigmadelta_types.h refactor(sigmadelta): add hal sigmadelta driver 2019-11-21 11:53:07 +08:00
spi_flash_hal.h ble_mesh_wifi_coexist example: Disable Wi-Fi RX IRAM optimisation 2019-11-28 09:20:00 +08:00
spi_flash_types.h ble_mesh_wifi_coexist example: Disable Wi-Fi RX IRAM optimisation 2019-11-28 09:20:00 +08:00
spi_hal.h spi: multichip support 2019-06-22 19:08:47 +08:00
spi_slave_hal.h spi: multichip support 2019-06-20 10:38:52 +08:00
spi_types.h Merge branch 'master' into feature/esp32s2beta_update 2019-08-08 13:44:24 +10:00
timer_hal.h bugfix(timer): add a macro to control making the XTAL related functions 2019-11-26 12:39:46 +00:00
timer_types.h bugfix(timer): add a macro to control making the XTAL related functions 2019-11-26 12:39:46 +00:00
touch_sensor_hal.h Refactor the touch sensor driver 2019-11-27 20:08:44 +08:00
touch_sensor_types.h Refactor the touch sensor driver 2019-11-27 20:08:44 +08:00
uart_hal.h feature: Add uart hal support. 2019-11-26 20:01:50 +08:00
uart_types.h feature: Add uart hal support. 2019-11-26 20:01:50 +08:00

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.