Atmel Software Framework

Tester/commands.c File Reference
#include <stdlib.h>
#include <string.h>
#include "config.h"
#include "phy.h"
#include "sys.h"
#include "nwk.h"
#include "tester.h"
#include "filter.h"
#include "events.h"
#include "time.h"
#include "commands.h"

Data Structures

struct  AppRequestBuffer_t
 

Macros

#define APP_NUMBER_OF_ENDPOINTS   16
 
#define APP_RESPONDER_ENDPOINT   15
 

Typedefs

typedef struct AppRequestBuffer_t AppRequestBuffer_t
 

Functions

AppStatus_t appCommandReceived (uint8_t *buf, uint16_t size)
 
void appCommandsInit (void)
 
static void appCommandsSendDataConf (NWK_DataReq_t *req, uint8_t handle, uint32_t time)
 
static void appCommandsSendDataInd (NWK_DataInd_t *ind)
 
static void appCommandsSendRouteEntry (uint16_t index, NWK_RouteTableEntry_t *entry)
 
static void appDataConf (NWK_DataReq_t *req)
 
static bool appDataInd (NWK_DataInd_t *ind)
 
static void appOpenEndpoint (uint8_t index, bool state)
 
static AppStatus_t appProcessDataReq (AppCommandDataReq_t *req)
 
static void appResponderDataConf (NWK_DataReq_t *req)
 
static bool appResponderDataInd (NWK_DataInd_t *ind)
 

Variables

static bool appEndpointAckState [APP_NUMBER_OF_ENDPOINTS]
 
static AppRequestBuffer_t appRequestBuffer [APP_NUMBER_OF_REQUEST_BUFFERS]
 

#define APP_NUMBER_OF_ENDPOINTS   16

Referenced by appCommandsInit().

#define APP_RESPONDER_ENDPOINT   15

Referenced by appCommandsInit().

AppStatus_t appCommandReceived ( uint8_t *  buf,
uint16_t  size 
)

References AppCommandSetAddr_t::addr, AppCommandFilterAdd_t::addr, AppCommandFilterRemove_t::addr, AppCommandFilterAdd_t::allow, APP_COMMAND_DATA_REQ, APP_COMMAND_DUMMY, APP_COMMAND_FILTER_ADD, APP_COMMAND_FILTER_REMOVE, APP_COMMAND_GET_EVENTS, APP_COMMAND_GROUP_ADD, APP_COMMAND_GROUP_REMOVE, APP_COMMAND_OPEN_ENDPOINT, APP_COMMAND_RANDOMIZE, APP_COMMAND_RESET, APP_COMMAND_ROUTE_ADD, APP_COMMAND_ROUTE_FLUSH, APP_COMMAND_ROUTE_REMOVE, APP_COMMAND_ROUTE_TABLE, APP_COMMAND_SET_ACK_STATE, APP_COMMAND_SET_ADDR, APP_COMMAND_SET_CHANNEL, APP_COMMAND_SET_PANID, APP_COMMAND_SET_RX_STATE, APP_COMMAND_SET_SECURITY_KEY, APP_COMMAND_SET_TX_POWER, APP_STATUS_ENTRY_NOT_FOUND, APP_STATUS_SUCESS, APP_STATUS_TABLE_IS_FULL, APP_STATUS_UNKNOWN_COMMAND, appCommandsSendRouteEntry(), appEndpointAckState, appFilterAdd(), appFilterRemove(), appOpenEndpoint(), appProcessDataReq(), AppCommandSetChannel_t::band, AppCommandSetChannel_t::channel, AppReceiveCommand_t::dataReq, AppCommandRouteAdd_t::dstAddr, AppCommandRouteRemove_t::dstAddr, AppReceiveCommand_t::filterAdd, AppReceiveCommand_t::filterRemove, AppCommandRouteAdd_t::fixed, AppCommandGroupAdd_t::group, AppCommandGroupRemove_t::group, AppReceiveCommand_t::groupAdd, AppReceiveCommand_t::groupRemove, AppReceiveCommand_t::header, AppCommandHeader_t::id, AppCommandOpenEndpoint_t::index, AppCommandSetAckState_t::index, AppCommandRouteAdd_t::lqi, AppCommandFilterAdd_t::lqi, AppCommandSetChannel_t::modulation, AppCommandRouteAdd_t::multicast, AppCommandRouteRemove_t::multicast, AppCommandRouteAdd_t::nextHopAddr, NWK_ROUTE_TABLE_SIZE, NWK_ROUTE_UNKNOWN, NWK_SetAddr(), NWK_SetPanId(), AppReceiveCommand_t::openEndpoint, AppCommandSetPanId_t::panId, PHY_SetBand(), PHY_SetChannel(), PHY_SetModulation(), PHY_SetRxState(), PHY_SetTxPower(), AppReceiveCommand_t::randomize, AppCommandRouteRemove_t::removeFixed, AppCommandRouteFlush_t::removeFixed, AppCommandRandomize_t::rnd, AppReceiveCommand_t::routeAdd, AppReceiveCommand_t::routeFlush, AppReceiveCommand_t::routeRemove, AppCommandSetRxState_t::rxState, AppCommandSetSecurityKey_t::securityKey, AppReceiveCommand_t::setAckState, AppReceiveCommand_t::setAddr, AppReceiveCommand_t::setChannel, AppCommandFilterAdd_t::setLqi, AppReceiveCommand_t::setPanId, AppReceiveCommand_t::setRxState, AppReceiveCommand_t::setSecurityKey, AppReceiveCommand_t::setTxPower, AppCommandOpenEndpoint_t::state, AppCommandSetAckState_t::state, and AppCommandSetTxPower_t::txPower.

Referenced by appUartStateMachine().

static bool appDataInd ( NWK_DataInd_t ind)
static
static void appOpenEndpoint ( uint8_t  index,
bool  state 
)
static
static void appResponderDataConf ( NWK_DataReq_t req)
static

bool appEndpointAckState[APP_NUMBER_OF_ENDPOINTS]
static