Atmel Software Framework

stb.h File Reference

Declarations for security tool box.

Copyright (c) 2013-2015 Atmel Corporation. All rights reserved.

#include "sal.h"
#include "stb_generic.h"
#include "stb_internal.h"

Macros

#define AUX_HDR_LEN   (MSDU_POS_KEY_SEQ_NO)
 Maximum length of ZigBee Auxiliary Frame Header. More...
 
#define FRM_COUNTER_LEN   (4)
 Length of ZigBee Frame Counter in octets. More...
 
#define KEY_ID_DATA_KEY   (0x00)
 Key Identifier Sub-field of Security Control Field indicates Data key. More...
 
#define KEY_ID_KEY_LOAD_KEY   (0x03)
 Key Identifier Sub-field of Security Control Field indicates Key-load key. More...
 
#define KEY_ID_KEY_TRANSPORT_KEY   (0x02)
 Key Identifier Sub-field of Security Control Field indicates Key-transport key. More...
 
#define KEY_ID_NWK_KEY   (0x01)
 Key Identifier Sub-field of Security Control Field indicates Network key. More...
 
#define MSDU_POS_FRM_CNTR   (2)
 Position of Frame Counter octet in Auxiliary Security Header. More...
 
#define MSDU_POS_KEY_SEQ_NO   (14)
 Position of Key Sequence Number octet in Auxiliary Security Header. More...
 
#define MSDU_POS_SEC_CTRL   (1)
 Position of Security Control octet in Auxiliary Security Header. More...
 
#define MSDU_POS_SRC_ADDR   (6)
 Position of first Source Addess octet in Auxiliary Security Header. More...
 
#define NONCE_POS_SEC_CTRL   (13)
 Position of Security Control octet in Nonce. More...
 
#define SEC_CTRL_POS_EXT_NONCE   (5)
 Position ofExtended Nonce enabled bit in Security Control Field. More...
 
#define SEC_CTRL_POS_KEY_ID   (3)
 Position of Key identifier bits in Security Control Field. More...
 
#define SEC_CTRL_POS_SEC_LEVEL   (0)
 Position of Security Level bits in Security Control Field. More...
 
#define TRX_SLEEP()
 

Functions

void stb_restart (void)
 STB Restart. More...
 

#define AUX_HDR_LEN   (MSDU_POS_KEY_SEQ_NO)

Maximum length of ZigBee Auxiliary Frame Header.

#define FRM_COUNTER_LEN   (4)

Length of ZigBee Frame Counter in octets.

#define KEY_ID_DATA_KEY   (0x00)

Key Identifier Sub-field of Security Control Field indicates Data key.

#define KEY_ID_KEY_LOAD_KEY   (0x03)

Key Identifier Sub-field of Security Control Field indicates Key-load key.

#define KEY_ID_KEY_TRANSPORT_KEY   (0x02)

Key Identifier Sub-field of Security Control Field indicates Key-transport key.

#define KEY_ID_NWK_KEY   (0x01)

Key Identifier Sub-field of Security Control Field indicates Network key.

#define MSDU_POS_FRM_CNTR   (2)

Position of Frame Counter octet in Auxiliary Security Header.

#define MSDU_POS_KEY_SEQ_NO   (14)

Position of Key Sequence Number octet in Auxiliary Security Header.

#define MSDU_POS_SEC_CTRL   (1)

Position of Security Control octet in Auxiliary Security Header.

#define MSDU_POS_SRC_ADDR   (6)

Position of first Source Addess octet in Auxiliary Security Header.

#define NONCE_POS_SEC_CTRL   (13)

Position of Security Control octet in Nonce.

#define SEC_CTRL_POS_EXT_NONCE   (5)

Position ofExtended Nonce enabled bit in Security Control Field.

#define SEC_CTRL_POS_KEY_ID   (3)

Position of Key identifier bits in Security Control Field.

#define SEC_CTRL_POS_SEC_LEVEL   (0)

Position of Security Level bits in Security Control Field.

#define TRX_SLEEP ( )
Value:
{ \
if (prev_trx_status == TRX_SLEEP) { \
} \
} \
/* === Types
*============================================================== */
#define TRX_SLEEP()
Definition: stb.h:194
retval_t tal_trx_sleep(sleep_mode_t mode)
Sets the transceiver to sleep.
Definition: at86rf231/src/tal_pwr_mgmt.c:90
if((SERIAL_RX_BUF_SIZE_NCP-1)==serial_rx_buf_tail)
Definition: sio2ncp.c:259
Definition: tal.h:691

Referenced by handle_incoming_msg(), mac_ready_to_sleep(), perform_cca_twice(), set_transceiver_state(), set_trx_state(), stb_ccm_secure(), tal_pib_set(), tal_trx_sleep(), tal_trx_wakeup(), and tfa_get_batmon_voltage().

void stb_restart ( void  )

STB Restart.

This function re-starts the STB after power down.

References stb_restart_required.

Referenced by tal_trx_sleep(), and trx_reset().