SAM Power Driver Quick Start.
Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.
#include <asf.h>
#include "conf_test.h"
Functions | |
static void | config_clock_output_and_extwake_pin (void) |
[switch_pl] More... | |
static void | configure_extint_channel (void) |
[pin_mux] More... | |
static void | led_toggle_indication (uint32_t count) |
[config_extint] More... | |
int | main (void) |
[setup] More... | |
static void | performance_level_switch_test (void) |
[setup] More... | |
|
static |
[switch_pl]
[pin_mux] Config GCLK0/GCLK1 output pin and extwakeup pin.
References system_pinmux_config::direction, system_pinmux_config::input_pull, system_pinmux_config::mux_position, system_pinmux_get_config_defaults(), SYSTEM_PINMUX_PIN_DIR_INPUT, SYSTEM_PINMUX_PIN_DIR_OUTPUT, SYSTEM_PINMUX_PIN_PULL_UP, and system_pinmux_pin_set_config().
Referenced by main().
|
static |
[pin_mux]
[config_extint] Config external interrupt.
References extint_chan_conf::detection_criteria, EXTINT_CALLBACK_TYPE_DETECT, extint_chan_clear_detected(), extint_chan_enable_callback(), extint_chan_get_config_defaults(), extint_chan_is_detected(), extint_chan_set_config(), EXTINT_DETECT_BOTH, EXTINT_PULL_UP, extint_chan_conf::gpio_pin, extint_chan_conf::gpio_pin_mux, extint_chan_conf::gpio_pin_pull, and system_interrupt_enable_global().
|
static |
[config_extint]
Turn LED ON and OFF as an indication.
References count, delay_ms, i, and port_pin_set_output_level().
Referenced by main().
int main | ( | void | ) |
[setup]
[setup_init]
[ext_wakeup]
[ext_wakeup]
[backup_stanby_mode]
[backup_stanby_mode]
[setup_init]
References config_clock_output_and_extwake_pin(), configure_extint_channel(), delay_init(), delay_s, EXTINT_CALLBACK_TYPE_DETECT, extint_chan_clear_detected(), extint_chan_disable_callback(), led_toggle_indication(), performance_level_switch_test(), port_pin_set_output_level(), system_get_backup_exit_source(), system_get_reset_cause(), system_init(), system_io_retension_disable(), SYSTEM_RESET_CAUSE_BACKUP, system_set_sleepmode(), system_sleep(), SYSTEM_SLEEPMODE_BACKUP, and SYSTEM_SLEEPMODE_STANDBY.
|
static |
[setup]
[switch_pl] Switch performance level to PL2 and GCLK0 is running at 48MHz.
References system_gclk_gen_config::division_factor, GCLK_GENERATOR_0, system_gclk_gen_config::output_enable, system_gclk_gen_config::run_in_standby, system_gclk_gen_config::source_clock, SYSTEM_CLOCK_SOURCE_DFLL, system_flash_set_waitstates(), system_gclk_gen_get_config_defaults(), system_gclk_gen_set_config(), SYSTEM_PERFORMANCE_LEVEL_2, and system_switch_performance_level().
Referenced by main().