Microchip® Advanced Software Framework

mac_beacon.c File Reference

Implements the building of beacon frames and initiates transmission via CSMA-CA after reception of a beacon request frame in a nonbeacon-enabled PAN.

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 ADVNC_BCN_PREP_TIME   (50)
 
#define BEACON_MAX_PEND_ADDR_CNT   (7)
 
#define BEACON_PAYLOAD_LEN   (4)
 
#define MAC_MIN_WAKEUP_US   (200)
 

Functions

static uint8_t add_pending_extended_address_cb (void *buf_ptr, void *handle)
 
static uint8_t add_pending_short_address_cb (void *buf_ptr, void *handle)
 
static uint8_t mac_buffer_add_pending (uint8_t *buf_ptr)
 
void mac_build_and_tx_beacon (bool beacon_enabled, buffer_t *beacon_buffer_header)
 Builds and transmits the beacon frame. More...
 
void mac_process_beacon_request (buffer_t *msg)
 Processes a beacon request. More...
 

Variables

static uint8_t * beacon_ptr
 
static uint8_t pending_address_count
 

#define ADVNC_BCN_PREP_TIME   (50)
#define BEACON_MAX_PEND_ADDR_CNT   (7)
#define BEACON_PAYLOAD_LEN   (4)

Referenced by mac_build_and_tx_beacon().

#define MAC_MIN_WAKEUP_US   (200)

static uint8_t add_pending_extended_address_cb ( void *  buf_ptr,
void *  handle 
)
static
static uint8_t add_pending_short_address_cb ( void *  buf_ptr,
void *  handle 
)
static

uint8_t pending_address_count
static