semf
semf::Stm32Power Class Reference

app::Power implementation for STM32. More...

#include <stm32power.h>

Inheritance diagram for semf::Stm32Power:
Inheritance graph
Collaboration diagram for semf::Stm32Power:
Collaboration graph

Public Member Functions

 Stm32Power ()=default
 
 Stm32Power (const Stm32Power &other)=delete
 
virtual ~Stm32Power ()=default
 
void reset () override
 
void standby () override
 Switches microcontroller directly into standby mode. More...
 
void sleep () override
 Switches microcontroller directly into sleep mode. More...
 
void stop () override
 Switches microcontroller directly into stop mode. More...
 
- Public Member Functions inherited from semf::app::Power
virtual ~Power ()=default
 
virtual void reset ()=0
 
virtual void standby ()=0
 Switches microcontroller directly into standby mode. More...
 
virtual void sleep ()=0
 Switches microcontroller directly into sleep mode. More...
 
virtual void stop ()=0
 Switches microcontroller directly into stop mode. More...
 

Detailed Description

app::Power implementation for STM32.

Definition at line 22 of file stm32power.h.

Constructor & Destructor Documentation

◆ Stm32Power() [1/2]

semf::Stm32Power::Stm32Power ( )
default

◆ Stm32Power() [2/2]

semf::Stm32Power::Stm32Power ( const Stm32Power other)
explicitdelete

◆ ~Stm32Power()

virtual semf::Stm32Power::~Stm32Power ( )
virtualdefault

Member Function Documentation

◆ reset()

void semf::Stm32Power::reset ( )
overridevirtual

Executes a software reset on the microcontroller.

Implements semf::app::Power.

Definition at line 16 of file stm32power.cpp.

◆ sleep()

void semf::Stm32Power::sleep ( )
overridevirtual

Switches microcontroller directly into sleep mode.

Note
Sleep is called lightsleep for some microcontrollers and does need more power than standby.

Implements semf::app::Power.

Definition at line 28 of file stm32power.cpp.

◆ standby()

void semf::Stm32Power::standby ( )
overridevirtual

Switches microcontroller directly into standby mode.

Note
Stanby is called deepsleep for some microcontrollers and does need less power than sleep.

Implements semf::app::Power.

Definition at line 22 of file stm32power.cpp.

◆ stop()

void semf::Stm32Power::stop ( )
overridevirtual

Switches microcontroller directly into stop mode.

Note
Stops the program code, while the microcontroller is still running. Normally stop mode is exited by an interrupt.

Implements semf::app::Power.

Definition at line 34 of file stm32power.cpp.