frag.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015 Martine Lenders <mlenders@inf.fu-berlin.de>
3  * Copyright (C) 2015 Hamburg University of Applied Sciences
4  *
5  * This file is subject to the terms and conditions of the GNU Lesser
6  * General Public License v2.1. See the file LICENSE in the top level
7  * directory for more details.
8  */
9 
25 #ifndef NET_GNRC_SIXLOWPAN_FRAG_H
26 #define NET_GNRC_SIXLOWPAN_FRAG_H
27 
28 #include <inttypes.h>
29 #include <stdbool.h>
30 
31 #include "byteorder.h"
32 #include "kernel_types.h"
33 #include "net/gnrc/pkt.h"
34 #include "net/ieee802154.h"
35 #include "net/sixlowpan.h"
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40 
44 #define GNRC_SIXLOWPAN_MSG_FRAG_SND (0x0225)
45 
60 typedef struct {
67  uint8_t src_len;
68  uint8_t dst_len;
69  uint16_t tag;
71 
75 typedef struct {
77  size_t datagram_size;
78  uint16_t offset;
82 
90 
97 
98 #ifdef __cplusplus
99 }
100 #endif
101 
102 #endif /* NET_GNRC_SIXLOWPAN_FRAG_H */
103 
Types used by the kernel.
uint16_t tag
the datagram&#39;s tag
Definition: frag.h:69
int16_t kernel_pid_t
Unique process identifier.
Definition: kernel_types.h:83
General definitions for network packets and their helper functions.
gnrc_pktsnip_t * pkt
Pointer to the IPv6 packet to be fragmented.
Definition: frag.h:76
6LoWPAN dispatch type and helper function definitons.
IEEE 802.15.4 header definitions.
uint16_t offset
Offset of the Nth fragment from the beginning of the payload datagram.
Definition: frag.h:78
Definition of 6LoWPAN fragmentation type.
Definition: frag.h:75
An entry in the 6LoWPAN reassembly buffer.
Definition: frag.h:60
kernel_pid_t pid
PID of the interface.
Definition: frag.h:80
uint8_t dst_len
length of gnrc_sixlowpan_rbuf_t::dst
Definition: frag.h:68
Functions to work with different byte orders.
Adds include for missing inttype definitions.
void gnrc_sixlowpan_frag_send(gnrc_sixlowpan_msg_frag_t *fragment_msg)
Sends a packet fragmented.
void gnrc_sixlowpan_frag_handle_pkt(gnrc_pktsnip_t *pkt)
Handles a packet containing a fragment header.
gnrc_pktsnip_t * pkt
The reassembled packet in the packet buffer.
Definition: frag.h:64
Type to represent parts (either headers or payload) of a packet, called snips.
size_t datagram_size
Length of just the IPv6 packet to be fragmented.
Definition: frag.h:77
#define IEEE802154_LONG_ADDRESS_LEN
long address (EUI-64)
uint8_t src_len
length of gnrc_sixlowpan_rbuf_t::src
Definition: frag.h:67