Skip to content

Commit

Permalink
power: set dc_dc1 voltage to 3.3v on boot
Browse files Browse the repository at this point in the history
  • Loading branch information
JamieDriver committed Jan 9, 2024
1 parent 9abc58f commit f7fc4de
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions main/power.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ static esp_err_t _power_set_v_off(void) { return _power_write_command(AXP192_ADD
#endif // CONFIG_BOARD_TYPE_JADE

#ifdef CONFIG_BOARD_TYPE_JADE_V1_1
static esp_err_t _power_set_dc_dc1_voltage(void) { return _power_write_command(AXP192_ADDR, 0x26, 0x68); } // 3.3v
static esp_err_t _power_gpio0_to_ldo(void) { return _power_write_command(AXP192_ADDR, 0x90, 0x02); }
static esp_err_t _power_vbus_hold_limit(void) { return _power_write_command(AXP192_ADDR, 0x30, 0x80); }
static esp_err_t _power_temperature_protection(void) { return _power_write_command(AXP192_ADDR, 0x39, 0xfc); }
Expand Down Expand Up @@ -214,6 +215,9 @@ esp_err_t power_init(void)
_power_open_drain_gpio();

#ifdef CONFIG_BOARD_TYPE_JADE_V1_1
// Set the DC-DC1 voltage appropriately
_power_set_dc_dc1_voltage();

// Set GPIO0 to LDO
_power_gpio0_to_ldo();

Expand Down

0 comments on commit f7fc4de

Please sign in to comment.