nRF5 IoT SDK  v0.9.0
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Layers and protocols

A stack of several layers is required to route IPv6 packets to and from IoT devices. Figure 1 gives an overview of the required layers and the protocols that are used on these layers. The figure maps each of the components onto the OSI model.

IPv6onNRF51.png
Figure 1: IPv6 on nRF5x

The SoftDevice, in connection with the Internet Protocol Support Profile (IPSP), serves the role of Physical and Link Layer. This layer is responsible for establishing physical links and enabling logical channels for the IPv6 data exchange.

Bluetooth low energy IPv6 over Low-Power Wireless Personal Area Networks (BLE 6LoWPAN) is used on the Adaptation Layer. It enables compression of IPv6 traffic and optimizations in procedures (for example, neighbor discovery) on Bluetooth low energy. BLE 6LoWPAN could be considered a part of the Network Layer because it also provides stateless address autoconfiguration (SLAAC), which means that it provides link-local addresses derived from the Bluetooth device address to the network interface. However, recent efforts of defining techniques to make IPv6 more suitable on low-power lossy networks justify listing it as a separate layer.

Internet Protocol version 6 (IPv6), Internet Control Message Protocol version 6 (ICMPv6), and Routing Protocol for Low-Power and Lossy Networks (RPL) form the Network Layer. This layer is responsible for establishing neighbors, ensuring that other devices can be reached, and routing.

User Datagram Protocol (UDP) and Transmission Control Protocol (TCP) are well-known transport protocols for IPv6. They form the Transport Layer and work with various physical transports, for example Bluetooth low energy.

Note
For constrained applications, UDP is preferred over TCP.

Constrained Application Protocol (CoAP) and Message Queuing Telemetry Transport (MQTT) on the Application Layer are application protocols based on UDP and TCP, respectively. They are defined for machine-to-machine communication between devices with constrained resources and constrained bandwidth.