Analysis of Embedded IPv6 protocol stack

Source: Internet
Author: User

In the previous article, we have made a basic introduction to the IPv6 protocol stack design of wireless sensor networks. Then, based on the above content, let's take a closer look at the design of the Embedded IPv6 protocol stack. First, let's look at the idea of the Embedded IPv6 protocol stack.

Design Concept of Embedded IPv6 protocol stack

Because wireless sensor network nodes are generally embedded devices, the design of the Embedded IPv6 protocol stack should emphasize the idea of "miniaturization. the TCP/TP protocol is first implemented in the Uuix system. Because of the great difference between the embedded system and the PC, the implementation of TCP/IP protocol in the embedded system is very different from that in the operating system towel, so this is the core part of the design. the IPv6 Micro-protocol stack of the embedded system directly faces the hardware and does not have a multi-task operating system platform. The program structure in the MCU is generally a combination of sequential execution and hardware disconnection, unlike the multi-thread concurrent execution in advanced operating systems. because the various resources of the single-chip microcomputer system are limited, such as the CPU processing speed, character length, RAM, ROM memory capacity, and number of interfaces, there is a big gap with general-purpose computers, therefore, how to make the Protocol Stack fine, reliable communication, and relatively complete functions, and give full play to the characteristics of single-chip microcomputer has become a key issue in the design of IPv6 Micro-protocol stack. the idea of "miniaturization" is mainly embodied in the core of the design scheme, which should focus on the protocol stack with a small design size but no impact on the operation. Therefore, we need to conduct in-depth research on protocol stack cropping, remove unnecessary components, traditional complex Scheduling Mechanisms, and additional extension functions, and even remove operating systems.

Based on the above factors, the design requirements for Embedded IPv6 micro-protocol stack applicable to wireless sensor networks are put forward.

① The Protocol Stack runs on a single-chip microcomputer system and has strong compatibility. It can run correctly over Ethernet, and data packets can be transmitted through the wireless data transmission function of 802.15.4 MAC.

② Implement the most basic functions of the IPv6 basic protocol stack core protocol, including IPv6 basic description protocol, ND (Neighbor Discovery) protocol, ICMPv6 (Internet control packet) the automatic configuration protocol of the protocol and IPv6 address.

◆ IPv6 basic Description Protocol: basic functions such as sending, receiving, and processing IPv6 data packets.

◆ ND (Neighbor Discovery) Protocol: The Address Resolution function of neighbor discovery, enabling neighbor requests and neighbor notifications.

◆ ICMPv6 (Internet control packet) Protocol: It mainly implements Message Processing for control packets and responds to requests and responses to the Network diagnosis function.

◆ Automatic IPv6 Address Configuration Protocol: According to the IPv6 address format requirements, the local address of the IPv6 link is configured and the multicast address of the requesting node is configured.

③ Improve the correctness of ICMPv6, TCP and other protocols by calculating and processing the checksum fields.

④ Implement simple application layer protocols (such as TELNET and SNMP protocols), and use remote terminals to log on to the microcontroller system running the Embedded IPv6 protocol stack, and perform simple control and management operations.

Layered and Modular Design of Embedded IPv6 protocol stack

The Embedded IPv6 protocol stack uses a layered structure. The entire protocol stack (including TCP and upper-layer applications) is divided into four layers: event-triggered interface layer, TCP/IP network protocol layer, NIC Network Interface core layer, and network device driver interface layer.

Figure 3 is a layered description of the entire protocol stack. During the operation of the protocol stack, the upper layer calls functions of the adjacent layers to implement the corresponding functions.

The functions of each layer are described as follows:

① Event-triggered interface layer. This layer corresponds to the TCP/IP model's application layer protocol (OSI model's high-level protocol). The main function is to define the network data format and network applications.

② TCP/IP network protocol layer. this layer corresponds to the transport layer protocol and network layer protocol of the TCP/IP model (Layer 3 and Layer 4 of the OSI model). The main function is to define how data is transmitted to the destination. the TCP protocol is used to establish an end-to-end connection between two hosts to ensure reliable transmission. IP protocol is used to select routes and IP address-based addressing.

③ NIC Network Interface core layer. this layer is the key part of the entire network interface. The upper layer is the specific network protocol, and the lower layer is the driver. it provides a unified sending interface for the upper layer to shield a variety of physical media. It is also responsible for sending packets from the lower layer to the appropriate protocol.

④ Network device driver interface layer. this layer is the lowest layer of the layered structure. Its main function is to control the specific physical media, receive and send data from the physical media, and perform various settings such as the maximum data packet on the physical media.

Based on the comprehensive analysis of the design requirements and layered structure of the Embedded IPv6 protocol stack, the design implementation is divided into four modules, as shown in figure 4.

The functions of each module are described as follows:

① Core network interface module. This module provides unified sending interfaces for network protocols to shield various physical media. It is also responsible for distributing packets from lower layers to appropriate protocols.

② Event interface module. the Embedded IPv6 protocol stack uses the event-driven interface instead of the BSD interface. when a specific TCP/IP event occurs, the application is called, and when the application generates output data, it is also sent through this interface.

③ SNMP Network Management Module. This module obtains the MIB of IPv6 wireless sensor network nodes.

④ Configure the display debugging command module. this module is used to provide user configuration and debugging interfaces, including configuring IP addresses, subnet masks, default gateways, and MAC addresses. before the program runs properly, the Super Terminal enters the configuration mode, which is managed by the user.

Conclusion

The wireless sensor network based on IPv6 over 802.15.4 is a new network technology. People are still in its infancy. based on the characteristics of IPv6 over 802.15.4 wireless sensor network, this paper analyzes the key technology of Embedded IPv6 protocol stack. the author believes that although the existing IPv6 protocol stack has great advantages in terms of functions and performance, the code size is large (several MB ~ The storage resources of wireless sensor network nodes are less than kb, so they cannot run in wireless sensor network nodes with limited computing and storage resources. therefore, when designing an Embedded IPv6 protocol stack suitable for sensor nodes, we should fully analyze and study the new requirements of wireless sensor networks for IPv6, and consider finding a compromise between performance and resources, fully utilizes protocol engineering theory and software engineering methods to design a reasonable and efficient embedded IPv6 Micro-protocol stack. this is of great significance for promoting the development of wireless sensor networks and IPv6.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.