Microchip® Advanced Software Framework

mac_process_beacon_frame.c File Reference

Implements the processing of a received beacon frame.

This happens either after scan, where the PAN Descriptor list is filled, or while the device is tracking beacon frames. In the latter case the device checks whether the coordinator does have pending data and initiates the transmission of a data request frame if required.

Copyright (c) 2013-2018 Microchip Technology Inc. and its subsidiaries.

#include <compiler.h>
#include <string.h>
#include <stdint.h>
#include <stdbool.h>
#include "return_val.h"
#include "pal.h"
#include "bmm.h"
#include "qmm.h"
#include "tal.h"
#include "ieee_const.h"
#include "mac_msg_const.h"
#include "mac_api.h"
#include "mac_msg_types.h"
#include "mac_data_structures.h"
#include "stack_config.h"
#include "mac_internal.h"
#include "mac.h"
#include "mac_build_config.h"

Macros

#define GET_BEACON_ORDER(spec)   ((spec) & 0x000F)
 
#define GET_FINAL_CAP(spec)   (((spec) & 0x0F00) >> 8)
 
#define GET_GTS_PERMIT(spec)   (((spec) & 0x80) >> 7)
 
#define GET_SUPERFRAME_ORDER(spec)   (((spec) & 0x00F0) >> 4)
 

Functions

void mac_process_beacon_frame (buffer_t *beacon)
 Processes received beacon frame. More...
 
static void mac_t_wait_for_bc_time_cb (void *callback_parameter)
 Handle T_Poll_Wait_Time timer in case we expected a broadcast frame from our coordinator, but did not receive one. More...
 

#define GET_BEACON_ORDER (   spec)    ((spec) & 0x000F)
#define GET_FINAL_CAP (   spec)    (((spec) & 0x0F00) >> 8)
#define GET_GTS_PERMIT (   spec)    (((spec) & 0x80) >> 7)
#define GET_SUPERFRAME_ORDER (   spec)    (((spec) & 0x00F0) >> 4)

static void mac_t_wait_for_bc_time_cb ( void *  callback_parameter)
static

Handle T_Poll_Wait_Time timer in case we expected a broadcast frame from our coordinator, but did not receive one.

Parameters
callback_parameterCallback parameter.

References mac_bc_data_indicated, MAC_POLL_IDLE, mac_poll_state, MAC_SCAN_IDLE, mac_scan_state, and mac_sleep_trans().

Referenced by mac_process_beacon_frame().