mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
feat(vbat): Add vbat support on esp32h2
This commit is contained in:
@@ -179,6 +179,10 @@ config SOC_BOD_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_VBAT_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
config SOC_APM_SUPPORTED
|
||||
bool
|
||||
default y
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD
|
||||
* SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
@@ -19,12 +19,12 @@
|
||||
#define I2C_BOD I2C_PMU
|
||||
#define I2C_BOD_HOSTID I2C_PMU_HOSTID
|
||||
|
||||
#define I2C_PMU_OR_DREFL_VBAT 17
|
||||
#define I2C_PMU_OR_DREFL_VBAT_MSB 4
|
||||
#define I2C_PMU_OR_DREFL_VBAT_LSB 2
|
||||
#define I2C_PMU_OR_DREFH_VBAT 17
|
||||
#define I2C_PMU_OR_DREFH_VBAT_MSB 7
|
||||
#define I2C_PMU_OR_DREFH_VBAT_LSB 5
|
||||
#define I2C_PMU_OR_DREF_VBAT_L 17
|
||||
#define I2C_PMU_OR_DREF_VBAT_L_MSB 4
|
||||
#define I2C_PMU_OR_DREF_VBAT_L_LSB 2
|
||||
#define I2C_PMU_OR_DREF_VBAT_H 17
|
||||
#define I2C_PMU_OR_DREF_VBAT_H_MSB 7
|
||||
#define I2C_PMU_OR_DREF_VBAT_H_LSB 5
|
||||
|
||||
#define I2C_PMU_OR_XPD_DIGDET 18
|
||||
#define I2C_PMU_OR_XPD_DIGDET_MSB 0
|
||||
@@ -44,6 +44,22 @@
|
||||
#define I2C_PMU_OR_DREFH_VDDA_MSB 7
|
||||
#define I2C_PMU_OR_DREFH_VDDA_LSB 5
|
||||
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_L 20
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_L_MSB 4
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_L_LSB 2
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_H 20
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_H_MSB 7
|
||||
#define I2C_BIAS_OR_DREF_VBAT_CHARGER_H_LSB 5
|
||||
|
||||
#define I2C_BIAS_OR_FORCE_PU_VBAT_CHARGER 20
|
||||
#define I2C_BIAS_OR_FORCE_PU_VBAT_CHARGER_MSB 0
|
||||
#define I2C_BIAS_OR_FORCE_PU_VBAT_CHARGER_LSB 0
|
||||
|
||||
/** Change the charging current by adjusting the value of the series resistor. 1kΩ + N * 0.5kΩ */
|
||||
#define I2C_BIAS_OR_DRES_CHARGER 15
|
||||
#define I2C_BIAS_OR_DRES_CHARGER_MSB 7
|
||||
#define I2C_BIAS_OR_DRES_CHARGER_LSB 4
|
||||
|
||||
#define I2C_BOD_THRESHOLD_L I2C_PMU_OR_DREFL_VDDA
|
||||
#define I2C_BOD_THRESHOLD_L_MSB I2C_PMU_OR_DREFL_VDDA_MSB
|
||||
#define I2C_BOD_THRESHOLD_L_LSB I2C_PMU_OR_DREFL_VDDA_LSB
|
||||
|
||||
@@ -77,6 +77,7 @@
|
||||
#define SOC_FLASH_ENC_SUPPORTED 1
|
||||
#define SOC_SECURE_BOOT_SUPPORTED 1
|
||||
#define SOC_BOD_SUPPORTED 1
|
||||
#define SOC_VBAT_SUPPORTED 1
|
||||
#define SOC_APM_SUPPORTED 1 /*!< Support for APM peripheral */
|
||||
#define SOC_PMU_SUPPORTED 1
|
||||
#define SOC_LP_TIMER_SUPPORTED 1
|
||||
|
||||
Reference in New Issue
Block a user