Contiki 3.x
Macros
sicslowpan.c File Reference

    6lowpan implementation (RFC4944 and draft-ietf-6lowpan-hc-06)
More...

#include <string.h>
#include "contiki.h"
#include "dev/watchdog.h"
#include "net/ip/tcpip.h"
#include "net/ip/uip.h"
#include "net/ipv6/uip-ds6.h"
#include "net/rime/rime.h"
#include "net/ipv6/sicslowpan.h"
#include "net/netstack.h"
#include <stdio.h>
#include "net/ip/uip-debug.h"

Go to the source code of this file.

Macros

#define DEBUG   DEBUG_NONE
 FOR HC-06 COMPLIANCE TODO: -Add compression options to UDP, currently only supports both ports compressed or both ports elided. More...
 
#define MAC_MAX_PAYLOAD   (127 - 2)
 Maximum available size for frame headers, link layer security-related overhead, as well as 6LoWPAN payload. More...
 
#define COMPRESSION_THRESHOLD   0
 Some MAC layers need a minimum payload, which is configurable through the SICSLOWPAN_CONF_MIN_MAC_PAYLOAD option. More...
 
#define sicslowpan_buf   uip_buf
 The buffer used for the 6lowpan processing is uip_buf. More...
 
Pointers in the packetbuf buffer
#define PACKETBUF_FRAG_PTR   (packetbuf_ptr)
 
#define PACKETBUF_FRAG_DISPATCH_SIZE   0 /* 16 bit */
 
#define PACKETBUF_FRAG_TAG   2 /* 16 bit */
 
#define PACKETBUF_FRAG_OFFSET   4 /* 8 bit */
 
#define PACKETBUF_IPHC_BUF   ((uint8_t *)(packetbuf_ptr + packetbuf_hdr_len))
 
#define PACKETBUF_HC1_PTR   (packetbuf_ptr + packetbuf_hdr_len)
 
#define PACKETBUF_HC1_DISPATCH   0 /* 8 bit */
 
#define PACKETBUF_HC1_ENCODING   1 /* 8 bit */
 
#define PACKETBUF_HC1_TTL   2 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_PTR   (packetbuf_ptr + packetbuf_hdr_len)
 
#define PACKETBUF_HC1_HC_UDP_DISPATCH   0 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_HC1_ENCODING   1 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_UDP_ENCODING   2 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_TTL   3 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_PORTS   4 /* 8 bit */
 
#define PACKETBUF_HC1_HC_UDP_CHKSUM   5 /* 16 bit */
 
Pointers in the sicslowpan and uip buffer
#define SICSLOWPAN_IP_BUF   ((struct uip_ip_hdr *)&sicslowpan_buf[UIP_LLH_LEN])
 
#define SICSLOWPAN_UDP_BUF   ((struct uip_udp_hdr *)&sicslowpan_buf[UIP_LLIPH_LEN])
 
#define UIP_IP_BUF   ((struct uip_ip_hdr *)&uip_buf[UIP_LLH_LEN])
 
#define UIP_UDP_BUF   ((struct uip_udp_hdr *)&uip_buf[UIP_LLIPH_LEN])
 
#define UIP_TCP_BUF   ((struct uip_tcp_hdr *)&uip_buf[UIP_LLIPH_LEN])
 
#define UIP_ICMP_BUF   ((struct uip_icmp_hdr *)&uip_buf[UIP_LLIPH_LEN])
 

Variables

General variables
HC06 specific variables
const uint8_t unc_llconf [] = {0x0f,0x28,0x22,0x20}
 
const uint8_t unc_ctxconf [] = {0x00,0x88,0x82,0x80}
 
const uint8_t unc_mxconf [] = {0x0f, 0x25, 0x23, 0x21}
 
const uint8_t llprefix [] = {0xfe, 0x80}
 

Detailed Description

    6lowpan implementation (RFC4944 and draft-ietf-6lowpan-hc-06)
Author
Adam Dunkels adam@.nosp@m.sics.nosp@m..se
Nicolas Tsiftes nvt@s.nosp@m.ics..nosp@m.se
Niclas Finne nfi@s.nosp@m.ics..nosp@m.se
Mathilde Durvy mdurv.nosp@m.y@ci.nosp@m.sco.c.nosp@m.om
Julien Abeille jabei.nosp@m.lle@.nosp@m.cisco.nosp@m..com
Joakim Eriksson joaki.nosp@m.me@s.nosp@m.ics.s.nosp@m.e
Joel Hoglund joel@.nosp@m.sics.nosp@m..se

Definition in file sicslowpan.c.