40 #define SIXLOWPAN_ND_OPT_6CTX_LEN_MIN           (2U) 
   41 #define SIXLOWPAN_ND_OPT_6CTX_LEN_MAX           (3U) 
   42 #define SIXLOWPAN_ND_OPT_AR_LEN                 (2U) 
   43 #define SIXLOWPAN_ND_OPT_ABR_LEN                (3U) 
   57 #define SIXLOWPAN_ND_OPT_ABR_LTIME_DEFAULT      (10000U) 
   66 #define SIXLOWPAN_ND_STATUS_SUCCESS             (0)  
   67 #define SIXLOWPAN_ND_STATUS_DUP                 (1)  
   68 #define SIXLOWPAN_ND_STATUS_NC_FULL             (2)  
   77 #define SIXLOWPAN_ND_OPT_6CTX_FLAGS_MASK        (0x1f) 
   78 #define SIXLOWPAN_ND_OPT_6CTX_FLAGS_C           (0x10)   
   79 #define SIXLOWPAN_ND_OPT_6CTX_FLAGS_CID_MASK    (0x0f)   
   89 #define SIXLOWPAN_ND_MIN_CTX_CHANGE_SEC_DELAY   (300U)   
   97 #define SIXLOWPAN_ND_MAX_RA_NUMOF               (3U)         
   98 #define SIXLOWPAN_ND_MIN_MS_DELAY_BETWEEN_RAS   (10000U)     
   99 #define SIXLOWPAN_ND_MAX_RA_MS_DELAY            (2000U)      
  100 #define SIXLOWPAN_ND_TENTATIVE_NCE_SEC_LTIME    (20U)        
  108 #define SIXLOWPAN_ND_MULTIHOP_HL                (64U)        
  123 #define SIXLOWPAN_ND_REG_TRANSMIT_NUMOF         (3U) 
  127 #define SIXLOWPAN_ND_RS_MSEC_INTERVAL           (10000U) 
  128 #define SIXLOWPAN_ND_MAX_RS_NUMOF               (3U)         
  132 #define SIXLOWPAN_ND_MAX_RS_SEC_INTERVAL        (60U) 
  141 typedef struct __attribute__((packed)) {
 
  158 typedef struct __attribute__((packed)) {
 
  174 typedef struct __attribute__((packed)) {
 
  189 typedef struct __attribute__((packed)) {
 
Functions to work with different byte orders.
 
static network_uint16_t byteorder_htons(uint16_t v)
Convert from host byte order to network byte order, 16 bit.
 
static uint16_t byteorder_ntohs(network_uint16_t v)
Convert from network byte order to host byte order, 16 bit.
 
EUI-64 data type definition.
 
static uint8_t sixlowpan_nd_opt_6ctx_get_cid(const sixlowpan_nd_opt_6ctx_t *ctx_opt)
Gets a CID (context identifier) from a 6LoWPAN context option.
 
#define SIXLOWPAN_ND_OPT_ABR_LTIME_DEFAULT
Valid lifetime (in minutes) assumed if sixlowpan_nd_opt_abr_t::ltime is 0.
 
#define SIXLOWPAN_ND_OPT_6CTX_FLAGS_C
valid for compression
 
static uint16_t gnrc_sixlowpan_nd_opt_get_ltime(const sixlowpan_nd_opt_abr_t *abr_opt)
Get the lifetime of an Authoritative Border Router from an ABR option.
 
#define SIXLOWPAN_ND_OPT_6CTX_FLAGS_CID_MASK
mask for CID
 
static bool sixlowpan_nd_opt_6ctx_is_comp(const sixlowpan_nd_opt_6ctx_t *ctx_opt)
Checks if a 6LoWPAN context in an 6LoWPAN context option is valid for compression.
 
static void sixlowpan_nd_opt_6ctx_set_cid(sixlowpan_nd_opt_6ctx_t *ctx_opt, uint8_t cid)
Sets a CID (context identifier) for a 6LoWPAN context option.
 
static uint32_t sixlowpan_nd_opt_abr_get_version(const sixlowpan_nd_opt_abr_t *abr_opt)
Gets the version in correct order from an Authoritative Border Router option.
 
static void sixlowpan_nd_opt_abr_set_version(sixlowpan_nd_opt_abr_t *abr_opt, uint32_t version)
Sets the version of an Authoritative Border Router option.
 
Definitions for IPv6 addresses.
 
Duplicate address request and confirmation message format.
 
uint8_t status
indicates registration status in DAC; must be 0 in DAR.
 
uint8_t resv
reserved field
 
network_uint16_t ltime
registration lifetime
 
ipv6_addr_t addr
registered address
 
network_uint16_t csum
checksum
 
6LoWPAN context option format
 
uint8_t ctx_len
context length
 
network_uint16_t ltime
valid lifetime
 
uint8_t len
length in units of 8 octets
 
network_uint16_t resv
reserved field
 
uint8_t resv_c_cid
3-bit reserved, 1-bit c flag, 4 bit CID
 
Authoritative border router option format.
 
network_uint16_t vhigh
version high
 
ipv6_addr_t braddr
6LoWPAN border router address
 
network_uint16_t vlow
version low
 
network_uint16_t ltime
valid lifetime
 
uint8_t len
length in units of 8 octets
 
Address registration option format.
 
uint8_t len
length in units of 8 octets
 
uint8_t status
indicates registration status in NA response; must be 0 in NS messages
 
network_uint16_t ltime
registration lifetime
 
A 16 bit integer in big endian aka network byte order.
 
Data type to represent an EUI-64.
 
Data type to represent an IPv6 address.