MAX77985/MAX77986 charger setup for EVAL-POWRMS project.
More...
MAX77985/MAX77986 charger setup for EVAL-POWRMS project.
- Author
- Robert Budai (rober.nosp@m.t.bu.nosp@m.dai@a.nosp@m.nalo.nosp@m.g.com)
Copyright 2025(c) Analog Devices, Inc.
SPDX-License-Identifier: BSD-3-Clause
◆ MAX77986_CHG_CNFG_00_VAL
| #define MAX77986_CHG_CNFG_00_VAL 0x14 |
◆ MAX77986_CHG_CNFG_04_VAL
| #define MAX77986_CHG_CNFG_04_VAL 0xE4 |
◆ MAX77986_CHG_CNFG_06_UNLOCK
| #define MAX77986_CHG_CNFG_06_UNLOCK 0x0C |
◆ MAX77986_CHG_CNFG_07_VAL
| #define MAX77986_CHG_CNFG_07_VAL 0x20 |
◆ MAX77986_CHG_CNFG_08_VAL
| #define MAX77986_CHG_CNFG_08_VAL 0x50 |
◆ MAX77986_CHG_CNFG_09_VAL
| #define MAX77986_CHG_CNFG_09_VAL 0x6D |
◆ MAX77986_I2C_ADDR
| #define MAX77986_I2C_ADDR 0x6B |
◆ MAX77986_REG_CHG_CNFG_00
| #define MAX77986_REG_CHG_CNFG_00 0x16 |
◆ MAX77986_REG_CHG_CNFG_04
| #define MAX77986_REG_CHG_CNFG_04 0x1A |
◆ MAX77986_REG_CHG_CNFG_06
| #define MAX77986_REG_CHG_CNFG_06 0x1C |
◆ MAX77986_REG_CHG_CNFG_07
| #define MAX77986_REG_CHG_CNFG_07 0x1D |
◆ MAX77986_REG_CHG_CNFG_08
| #define MAX77986_REG_CHG_CNFG_08 0x1E |
◆ MAX77986_REG_CHG_CNFG_09
| #define MAX77986_REG_CHG_CNFG_09 0x1F |
◆ max77986_init()
Initialize the MAX77986 over I2C in MODE 6 with maximum current.
Brings up the adapter->SYS synchronous buck (no battery) regulated to a fixed 5.0 V with the adapter input current limit set to its maximum (5.5 A). The charger config registers are unlocked first, the voltage and current limits configured, the BATT-to-SYS FET forced off, and MODE = 0x6 enabled last.
- Parameters
-
| desc | - Will be set to the allocated I2C descriptor on success. The caller owns it and must release it with max77986_remove(). |
| param | - I2C bus initialization parameters (slave address 0x6B). |
- Returns
- 0 on success, negative error code on failure.
◆ max77986_remove()
Free the resources allocated by max77986_init().
- Parameters
-
- Returns
- 0 on success, negative error code on failure.