Microchip® Advanced Software Framework

nwkRx.c File Reference

Receive routines implementation.

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

#include <stdlib.h>
#include <stdint.h>
#include <stdbool.h>
#include <string.h>
#include "phy.h"
#include "sysConfig.h"
#include "sysTimer.h"
#include "nwk.h"
#include "nwkTx.h"
#include "nwkFrame.h"
#include "nwkGroup.h"
#include "nwkRoute.h"
#include "nwkCommand.h"
#include "nwkSecurity.h"
#include "nwkRouteDiscovery.h"

Data Structures

struct  NwkDuplicateRejectionEntry_t
 

Macros

#define DUPLICATE_REJECTION_TTL
 
#define NWK_RX_DUPLICATE_REJECTION_TIMER_INTERVAL   100 /* ms */
 
#define NWK_SERVICE_ENDPOINT_ID   0
 

Typedefs

typedef struct
NwkDuplicateRejectionEntry_t 
NwkDuplicateRejectionEntry_t
 

Enumerations

enum  {
  NWK_RX_STATE_RECEIVED = 0x20,
  NWK_RX_STATE_DECRYPT = 0x21,
  NWK_RX_STATE_INDICATE = 0x22,
  NWK_RX_STATE_ROUTE = 0x23,
  NWK_RX_STATE_FINISH = 0x24
}
 

Functions

void NWK_SetAckControl (uint8_t control)
 
static void nwkRxDuplicateRejectionTimerHandler (SYS_Timer_t *timer)
 
static void nwkRxHandleIndication (NwkFrame_t *frame)
 
static void nwkRxHandleReceivedFrame (NwkFrame_t *frame)
 
static bool nwkRxIndicateFrame (NwkFrame_t *frame)
 
void nwkRxInit (void)
 Initializes the Rx module. More...
 
static bool nwkRxRejectDuplicate (NwkFrameHeader_t *header)
 
static void nwkRxSendAck (NwkFrame_t *frame)
 
static bool nwkRxSeriveDataInd (NWK_DataInd_t *ind)
 
void nwkRxTaskHandler (void)
 Rx Module task handler. More...
 
void PHY_DataInd (PHY_DataInd_t *ind)
 

Variables

static uint8_t nwkRxAckControl
 
static NwkDuplicateRejectionEntry_t nwkRxDuplicateRejectionTable [NWK_DUPLICATE_REJECTION_TABLE_SIZE]
 
static SYS_Timer_t nwkRxDuplicateRejectionTimer
 

#define DUPLICATE_REJECTION_TTL
Value:
#define NWK_RX_DUPLICATE_REJECTION_TIMER_INTERVAL
Definition: nwkRx.c:59
#define NWK_DUPLICATE_REJECTION_TTL
Definition: PeertoPeer/config.h:60

Referenced by nwkRxRejectDuplicate().

#define NWK_RX_DUPLICATE_REJECTION_TIMER_INTERVAL   100 /* ms */

Referenced by nwkRxInit().

#define NWK_SERVICE_ENDPOINT_ID   0

Referenced by nwkRxInit().

anonymous enum
Enumerator
NWK_RX_STATE_RECEIVED 
NWK_RX_STATE_DECRYPT 
NWK_RX_STATE_INDICATE 
NWK_RX_STATE_ROUTE 
NWK_RX_STATE_FINISH 

void NWK_SetAckControl ( uint8_t  control)

References nwkRxAckControl.

Referenced by appDataInd().

static void nwkRxDuplicateRejectionTimerHandler ( SYS_Timer_t timer)
static

uint8_t nwkRxAckControl
static
SYS_Timer_t nwkRxDuplicateRejectionTimer
static