This file implements TAL power management functionality of the transceiver.
Copyright (c) 2013-2018 Microchip Technology Inc. and its subsidiaries.
#include <stdbool.h>
#include <stdint.h>
#include <stddef.h>
#include "pal.h"
#include "return_val.h"
#include "tal.h"
#include "tal_constants.h"
#include "at86rf212b.h"
#include "tal_internal.h"
Functions | |
retval_t | tal_trx_sleep (sleep_mode_t mode) |
Sets the transceiver to sleep. More... | |
retval_t | tal_trx_wakeup (void) |
Wakes up the transceiver from sleep. More... | |
retval_t tal_trx_sleep | ( | sleep_mode_t | mode | ) |
Sets the transceiver to sleep.
This function sets the transceiver to sleep state.
mode | Defines sleep mode of transceiver SLEEP or PHY_TRX_OFF) |
References CMD_SLEEP, CMD_TRX_OFF, MAC_INVALID_PARAMETER, MAC_SUCCESS, pal_timer_source_select(), pal_timer_stop(), set_trx_state(), SLEEP_MODE_1, TAL_BUSY, TAL_IDLE, tal_rx_on_required, tal_state, TAL_TRX_ASLEEP, tal_trx_status, TMR_CLK_SRC_DURING_TRX_SLEEP, TRX_OFF, and TRX_SLEEP.
Referenced by toggle_trx_sleep(), and trx_config().
retval_t tal_trx_wakeup | ( | void | ) |
Wakes up the transceiver from sleep.
This function awakes the transceiver from sleep state.
References Assert, CMD_TRX_OFF, FAILURE, FUNC_PTR, MAC_SUCCESS, pal_timer_source_select(), pal_timer_start(), set_trx_state(), TAL_TRX_AWAKE, tal_trx_status, TIMEOUT_RELATIVE, TMR_CLK_SRC_DURING_TRX_AWAKE, TRX_OFF, and TRX_SLEEP.
Referenced by tal_pib_set(), toggle_trx_sleep(), and trx_config().