The PMIC driver provides API to control I2C/SPI based PMIC present in the board. It supports configuration of various features/modules in the PMIC. I2C/MCSPI controller is used to read/write to the PMIC registers. Refer to the corresponding PMIC datasheet for more details.
Features Supported
- Support enable/disable watchdog
- Watchdog in Trigger and Q&A mode with interrupt/reset support upon failure
- GPIO configuration
- Thermal monitoring
- Voltage monitoring
- IRQ
- ESM
SysConfig Features
- Note
- It is strongly recommend to use SysConfig where it is available instead of using direct SW API calls. This will help simplify the SW application and also catch common mistakes early in the development cycle.
- Option to select the PMIC
- Supported PMIC's
- TPS65386xx (Blackbird)
- TPS65036xx (Derby)
Features NOT Supported
Important Usage Guidelines
- Power cycle the board to restore the PMIC register configurations.
Example Usage
Include the below file to access the APIs
Instance Open Blackbird PMIC Example
PMIC_Params gPmicParams[CONFIG_PMIC_NUM_INSTANCES] =
{
{
.deviceType = PMIC_DEV_BB_TPS65386X,
.commMode = PMIC_INTF_SPI,
.instType = PMIC_MAIN_INST,
.instance = CONFIG_MCSPI0,
},
};
Instance Open Derby PMIC Example
PMIC_Params gPmicParams[CONFIG_PMIC_NUM_INSTANCES] =
{
{
.i2cAddr = 0x60,
.instance = CONFIG_MCSPI0,
},
};
Instance Close Example
API
APIs for I2C/MCSPI based PMIC driver