COSA
An Object-Oriented Platform for Arduino Programming
Power Class Reference

#include <Power.hh>

Collaboration diagram for Power:
Collaboration graph

Static Public Member Functions

static uint8_t set (uint8_t mode)
 
static void sleep (uint8_t mode=POWER_SLEEP_MODE)
 
static void adc_enable ()
 
static void adc_disable ()
 
static void timer0_enable ()
 
static void timer0_disable ()
 
static void timer1_enable ()
 
static void timer1_disable ()
 
static void all_enable ()
 
static void all_disable ()
 

Detailed Description

Power Management and Sleep modes.

Definition at line 31 of file Power.hh.

Member Function Documentation

static void Power::adc_disable ( )
inlinestatic

Definition at line 62 of file Power.hh.

static void Power::adc_enable ( )
inlinestatic

Definition at line 55 of file Power.hh.

static void Power::all_disable ( )
inlinestatic

Definition at line 268 of file Power.hh.

static void Power::all_enable ( )
inlinestatic

Definition at line 261 of file Power.hh.

static uint8_t Power::set ( uint8_t  mode)
inlinestatic

Set the default sleep mode: SLEEP_MODE_IDLE, SLEEP_MODE_ADC, SLEEP_MODE_PWR_DOWN, SLEEP_MODE_PWR_SAVE, SLEEP_MODE_STANDBY, and SLEEP_MODE_EXT_STANDBY.

Parameters
[in]modesleep mode, see <avr/sleep.h>
Returns
previous mode.

Definition at line 40 of file Power.hh.

void Power::sleep ( uint8_t  mode = POWER_SLEEP_MODE)
static

Put the processor in the given sleep mode and wait for an interrupt to wake up.

Parameters
[in]modesleep mode, see <avr/sleep.h>

Definition at line 30 of file Power.cpp.

static void Power::timer0_disable ( )
inlinestatic

Definition at line 75 of file Power.hh.

static void Power::timer0_enable ( )
inlinestatic

Definition at line 69 of file Power.hh.

static void Power::timer1_disable ( )
inlinestatic

Definition at line 87 of file Power.hh.

static void Power::timer1_enable ( )
inlinestatic

Definition at line 81 of file Power.hh.


The documentation for this class was generated from the following files: