From: Nathael Pajani Date: Thu, 3 Jan 2019 16:56:06 +0000 (+0100) Subject: This is DEEP power down bit, not "power down". X-Git-Url: http://git.techno-innov.fr/?a=commitdiff_plain;h=361f3d6f4cee77610e5a3dbc080cde0206eac58c;p=soft%2Flpc122x%2Fcore This is DEEP power down bit, not "power down". --- diff --git a/core/system.c b/core/system.c index 103c87e..c3e8f9c 100644 --- a/core/system.c +++ b/core/system.c @@ -155,7 +155,7 @@ void enter_deep_power_down(void) while (!(sys_config->main_clk_upd_en & 0x01)); /* Enter deep power-down on next wfi() call */ - pmu->power_ctrl |= LPC_PD_EN; + pmu->power_ctrl |= LPC_DPD_EN; scb->scr |= SCB_SCR_SLEEPDEEP; /* Power down everything but the IRC and Flash */ diff --git a/include/core/system.h b/include/core/system.h index e51bd23..b7be0bd 100644 --- a/include/core/system.h +++ b/include/core/system.h @@ -284,7 +284,7 @@ struct lpc_pm_unit #define LPC_PMU ((struct lpc_pm_unit *) LPC_PMU_BASE) /* Power control register */ -#define LPC_PD_EN (0x01 << 1) +#define LPC_DPD_EN (0x01 << 1) #define LPC_SLEEP_FLAG (0x01 << 8) #define LPC_DPD_FLAG (0x01 << 11) /* System config register */