Skip to content

Commit e075ff3

Browse files
vanticarlescufi
authored andcommitted
soc: cc13x2_cc26x2: add support for deep sleep mode #1
Implement deep sleep mode #1 using the shutdown state on the CC13x2/CC26x2. Signed-off-by: Vincent Wan <[email protected]>
1 parent c098971 commit e075ff3

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

soc/arm/ti_simplelink/cc13x2_cc26x2/Kconfig.series

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ config SOC_SERIES_CC13X2_CC26X2
1414
select HAS_TI_CCFG
1515
select HAS_SYS_POWER_STATE_SLEEP_1
1616
select HAS_SYS_POWER_STATE_SLEEP_2
17+
select HAS_SYS_POWER_STATE_DEEP_SLEEP_1
1718
select SYS_PM_STATE_LOCK if SYS_POWER_MANAGEMENT
1819
help
1920
Enable support for TI SimpleLink CC13x2 / CC26x2 SoCs

soc/arm/ti_simplelink/cc13x2_cc26x2/power.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ extern PowerCC26X2_ModuleState PowerCC26X2_module;
3838
* Power state mapping:
3939
* SYS_POWER_STATE_SLEEP_1: Idle
4040
* SYS_POWER_STATE_SLEEP_2: Standby
41+
* SYS_POWER_STATE_DEEP_SLEEP_1: Shutdown
4142
*/
4243

4344
/* Invoke Low Power/System Off specific Tasks */
@@ -97,6 +98,12 @@ void sys_set_power_state(enum power_states state)
9798
&PowerCC26X2_module.clockObj));
9899
break;
99100
#endif
101+
102+
#ifdef CONFIG_SYS_POWER_DEEP_SLEEP_STATES
103+
case SYS_POWER_STATE_DEEP_SLEEP_1:
104+
Power_shutdown(0, 0);
105+
break;
106+
#endif
100107
default:
101108
LOG_DBG("Unsupported power state %u", state);
102109
break;

0 commit comments

Comments
 (0)