IoT and Sensor Network Course Review Notes
1 Introduction
1.1 Definition of IoT
- Technical Understanding The Internet of Things refers to a smart network where the information of objects reaches a designated information processing center through intelligent sensing devices and transmission networks, ultimately achieving automated information exchange and processing between objects and between people and objects.
- Application Understanding The Internet of Things refers to connecting all objects in the world into a network, forming the IoT, which then integrates with the existing “Internet” to achieve the integration of human society and physical systems, enabling more refined and dynamic management of production and life.
- Common Understanding Combining RFID radio frequency identification and WSN wireless sensor networks to provide users with services in monitoring, command and dispatch, remote data collection and measurement, and remote diagnosis in production and life.
1.2 Characteristics of IoT
- Comprehensive Perception Use RFID, sensors, QR codes, etc., to obtain information about objects anytime and anywhere.
- Reliable Transmission Through the integration of networks and the Internet, transmit the information of objects to users in real-time and accurately.
- Intelligent Processing Use computing, data mining, and fuzzy recognition and other artificial intelligence technologies to analyze and process massive data and information, implementing intelligent control of objects.
1.3 Conceptual Model of IoT
Perception (Perception Layer), Transmission (Network Layer), Computing (Application Layer)
- Perception Layer: The perception layer identifies objects, collects and captures information through methods such as RFID cameras, forming the basis of comprehensive perception in IoT; requires more comprehensive and sensitive perception capabilities, low power consumption, and solutions to miniaturization and low-cost issues.
- Network Layer: Connects the perception layer and the application layer, achieving ubiquitous connection, and is currently the most mature part; includes access networks, core networks, and business platforms; requires scalable management and operation capabilities and simplified structure to achieve upper and lower layer integration.
- Application Layer: A collection of solutions for extensive intelligent applications; application directions include smart homes, electricity, transportation, etc.; requires deep integration of information technology and industries, social sharing of information, and security assurance, based on cloud computing application assurance.
1.4 Main Characteristics of Sensor Data
- Massiveness: Assuming each sensor only returns data once per minute, 1000 nodes would generate about 1.4GB of data per day.
- Polymorphism: Ecological monitoring systems (temperature, humidity, light); multimedia sensor networks (audio, video); fire navigation systems (structured communication data).
- Correlation: Data describing the same entity has temporal correlation (temperature at the same node changes over time); data describing different entities has spatial correlation (temperature and humidity measured by different nodes in the same area are similar); different dimensions of the entity also have correlation (temperature and humidity measured at the same node at the same time are related).
- Semantic Nature: Data is given meaning by humans for ease of use.
1.5 Wireless Sensing Methods
- Traditional Sensing: Various sensors
- Intelligent Wireless Sensing/Sensor-free Sensing: WiFi, Bluetooth, ZeegBee, OWB, RFID
- Crowd Sensing: Crowdsourcing, Baidu Maps
2 Wireless Local Area Network
2.1 Composition Structure of Wireless LAN
- Station/Wireless Access Point (AP): AP is the core device of the wireless LAN, providing wired and wireless interfaces for connecting workstations and network servers.
- Wireless Medium
- Distributed System (DS): DS connects different BSS devices, allowing workstations to move between BSS, achieving roaming functionality.
- Terminal
In the IEEE 802.11 b/g North American standard, there are 11 channels, with channels 1, 6, and 11 being non-overlapping transmission channels.
2.2 Classic Problems of Wireless LAN
Characteristics of Wireless Information Transmission:
- Electromagnetic waves emitted by a wireless user spread in all directions.
- All wireless users within a certain range share the transmission channel.
- Wireless communication has a coverage range.
Classic Problems of Wireless Networks
Hidden Terminal Problem: Three entities, AC both think B is idle and send to B, resulting in a collision, solved by RTS and CTS (including source address, destination address, communication time). Exposed Terminal Problem: Four entities, A sends data to B, not affecting C sending data to D, but C hesitates.
The RTC/CTS mechanism can solve the hidden terminal problem but cannot solve the exposed terminal problem:
- Before data transmission, achieve data transmission recognition with the receiving node through RTS/CTS handshake, while notifying the neighboring nodes of the sending and receiving nodes of the upcoming transmission.
- Neighboring nodes suppress their transmission after receiving RTS/CTS, avoiding collision with the upcoming data transmission.
- This problem-solving method is at the cost of adding additional control messages.
RTS/CTS cannot solve the exposed terminal problem because RTS frames do not have high priority, and the existence of data packets will conflict with RTS/CTS frames, as shown in the following figure.
2.3 CSMA/CD Protocol
CSMA/CD Protocol Carrier Sense Multiple Access/Collision Detection Protocol content can be summarized as: listen before sending, listen while sending, stop on collision, delay retransmission. CSMACD protocol is not suitable for wireless LAN.
Reasons why CSMACD is not suitable for wireless LAN:
- Wireless LAN devices cannot achieve the CSMACD protocol requirement of a station continuously detecting the channel while sending its own data (half-duplex).
- Even if we can achieve collision detection, and when we detect the channel is idle while sending data, collisions may still occur at the receiving end (hidden terminal).
- A collision at the local node does not mean a collision at the receiving end (exposed terminal).
2.4 CSMA/CA
Carrier Sense Medium Busy, then wait until the current transmission is completely over. Listening methods include physical carrier sensing (signal strength judgment) and virtual carrier sensing protocol (source station notifies the time of channel occupation).
The CSMA/CA flowchart needs to be mastered.
There are two ways to avoid conflicts:
2.4.1 Priority Acknowledgment Protocol
Inter Frame Space (Inter Frame Space): All stations must wait a short time after completing a transmission (continue listening) before sending the next frame.
Priority: The length of the inter-frame space depends on the type of frame the station wants to send. High-priority frames need to wait for a shorter time, thus gaining priority to send.
Type | Time | Frame Types Included | Description |
---|---|---|---|
SIFS Short IFS | Shortest | ACK frames, CTS frames, data frames after being fragmented by long MAC frames, and all frames responding to AP inquiries | Shortest, highest priority |
PIFS Point Coordination Function IFS | + slot | Coordinated by AP | |
DIFS Distributed Coordination Function IFS | + 2 slot | Used to send data frames and management frames,RTS frames in DCF mode | Longest, distributed coordination |
2.4.2 Random Backoff Algorithm
Contention may also occur at the same priority. When the channel changes from busy to idle, any station that wants to send a data frame must not only wait for a DIFS interval but also enter a contention window and calculate a random backoff time to attempt to access the channel again.
When the network load is high, the smaller the contention window, the closer the random values selected by the nodes, resulting in too many conflicts; when the network load is light, the larger the contention window, the longer the nodes wait, resulting in unnecessary contention. The system should adapt to the current number of nodes wanting to send. Exponential backoff algorithm: Initialize the contention window to the minimum value, and increase the window when a conflict occurs until it reaches the maximum value.
2.5 Functions of the MAC Layer
The MAC layer must implement DCF distributed coordination (each node determines the access time itself) and select PCF point coordination function (coordinated by AP, such as round-robin). Both DCF and PCF can provide parallel competitive and non-competitive access in the same BSS (Basic Service Set, including one AP and several stations, multiple BSS can be connected through a routing system to form an extended BSS).
Main Functions of the MAC Layer:
- Media Access Control
- Network Connection Joining
- Data Verification and Confidentiality
Conversion between Decibels and Power
$$ dB=10log_{10}{P} $$
National standards stipulate that the maximum power of a router should not exceed 100mw, approximately 20 decibels.
2.6 Zigzag
Transmit twice, each time with a random Δ time difference. Two packets are transmitted in two time slots, which can be sequentially restored to two data packets, equivalent to no collision of data packets. Based on two characteristics:
- There will inevitably be retransmissions when a collision occurs.
- The position of each collision is different.
To avoid errors in the parsing process leading to a domino effect, the second data packet can be parsed from back to front, and if the two data packets are the same, they are adopted; if different, it indicates an error, and the AP selects the PHY with high confidence.
Advantages of Zigzag:
- Can use 802.11 standard decoders without modifying its protocol.
- Zigzag can be used for multiple collision packets and does not introduce additional overhead when there is no collision.
- Zigzag requires changing the AP point, not the client.
3 Wireless Sensor Network
3.1 Wireless Sensor Network WSN
Wireless sensor network systems usually include sensor nodes, sink nodes, and management nodes. It is a large-scale, self-organizing, dynamic, reliable, and application-related network.
3.1.1 Structural Composition
The sensor node structure is composed as follows, with operating systems including TinyOS (flexible, modifiable, high difficulty to get started) and TI based on the Zigbee protocol stack (opposite);
- Sensor Module
- Processor Module
- Wireless Communication Module
- Energy Supply Module
Differences between sensor networks and wireless networks: The primary goal of sensor networks is energy-saving; wireless network devices can move, while sensor network nodes are mostly stationary (but prone to failure).
3.1.2 Characteristics of Nodes
Limitations:
- Limited power energy (communication module consumes the most energy, with communication states including sending, receiving, idle listening, and sleep).
- Limited computing and storage capabilities.
- Limited communication capabilities.
Characteristics:
- Neighboring nodes have similar data (can be used for optimization).
- Sensor nodes do not have a global ID.
3.1.3 Antenna Length
When using wireless communication, a basic condition must be met, which is usually considered that the antenna size should be greater than one-tenth of the wavelength for the signal to be effectively transmitted. In practical use, low-frequency waves should be modulated to high-frequency.
Three types of signals emitted by antennas: ground wave, sky wave (ionospheric reflection), direct line (above 30MHz).
Communication Distance of Antenna:
$$ d= 3.57\sqrt{Kh} $$
Where $K=\frac{4}{3}$ is the refraction constant.
The maximum distance between two antennas is:
$$ d= 3.57(\sqrt{Kh_1}+\sqrt{Kh_2}) $$
3.2 Architecture of Sensor Networks
Implosion and Overlap Phenomenon
Implosion Nodes forward data packets to neighboring nodes, regardless of whether they have received the same ones, i.e., information implosion refers to the phenomenon of nodes in the network receiving multiple copies of the same data.
Overlap The sensing areas of sensing nodes overlap, leading to data redundancy, i.e., due to the dense deployment of wireless sensor network nodes, in the same local area, several nodes respond similarly to the same event in the area, and the information sensed is similar in data nature and identical in value, so the data copies received by the neighboring nodes of these nodes also have a high correlation.
3.2.1 Classification of Sensor Networks
Proactive Network-Continuously Operating Model
- Nodes periodically turn on sensors and transmitters, sense the environment, and send out interesting data.
- Suitable for applications requiring periodic monitoring of data.
Reactive Network-Query-Response Model
- Nodes respond immediately according to user queries.
- Nodes respond immediately to changes in certain attributes of the network.
3.2.2 Classification of Sensor Network Architecture
September 22
3.2.2.1 Hierarchical System
Disadvantage: Nodes near the base station consume energy quickly, forming an energy hole.
3.2.2.2 Clustered System
LEACH Protocol: Low Energy Adaptive Clustering Hierarchy, clusters form spontaneously, cluster heads are elected autonomously.
PEGASIS: In LEACH, each node can only communicate with the head, but if there is a node in the cluster far from the head, it will incur a high cost. PEGASIS optimizes this point, allowing nodes to communicate with the nearest neighbor through a chain PPT29/37.
Advantages: Any message is at most two hops, head distributed election achieves balanced energy consumption.
3.2.2.3 Direct Transmission
All nodes directly transmit data to the base station, high energy consumption, base station needs to handle conflicts.
3.2.3 Data Dissemination and Data Collection
The above architectures are all for data collection, with the goal of minimizing energy consumption and minimizing delay in data transmission, using energy*delay as a measure of algorithm performance.
Data dissemination is the process of routing query packets and data packets in sensor networks. The most direct method is flooding, where each non-target node broadcasts packets with non-zero TTL, which is simple, requiring no complex topology maintenance or routing discovery algorithms, but will have problems such as internal explosion, data overlap, and blind resource use.
3.3 Positioning Technology
Classification of WSN Positioning
3.3.1 Range-based Positioning
- Signal Strength RSS
- Time-based TOA/TDOA/RTOF
- Angle-based AOA
Time Of Arrival requires synchronization between sender and receiver (time); Time Difference Of Arrival adds an ultrasonic module, eliminating the need for synchronization; Round Travel Of Flight is a compromise between the first two, requiring neither synchronization nor hardware, but with lower accuracy than TDOA.
Range-based measures physical quantities, high cost, high accuracy. Examination form: Given a scenario, data, and problem, write a solution, calculate distance and coordinates.
3.3.2 Range-free Positioning Technology
Also called distance-independent, does not require measuring physical quantities.
Anchor: Known position.
Hop distance: Average distance per hop.
3.3.2.1 Centroid Algorithm
Beacon nodes periodically broadcast beacon packets to neighboring nodes, with beacon packets containing the beacon node’s ID and location information; when an unknown node receives beacon packets from different beacon nodes exceeding a certain threshold k or after receiving for a certain time, it determines its position as the centroid of the polygon formed by these beacon nodes.
$$ X,Y=\frac{1}{n}\sum_{i=1}^kX_i,\frac{1}{n}\sum_{i=1}^kY_i $$
3.3.2.2 DV-HOP Algorithm
October 11
Unknown location nodes rely on known location nodes to calculate their own positions.
The algorithm requires determining the minimum hop count and average distance per hop.
Why the minimum hop count? Because it reduces cumulative error and the distance is closest to a straight line.
How to determine the average distance? Estimated by known location nodes. PPT19/73 Three methods: only use the nearest node (first received, unreasonable), average, weighted.
How to determine the minimum hop count? PPT16/73
Suitable for networks with many anchors and uniform distribution.
Examination of average hop distance calculation.
3.3.2.3 APIT
October 13
Nodes communicate with neighbors, simulate the movement process, and then approximately determine whether they are inside or outside the triangle according to the PIT criterion PPT8-9. Repeat this process multiple times to determine the overlapping area of multiple triangles, and take the centroid as the position PPT12.
Disadvantages: There may be judgment errors; unable to locate when the number of nodes is too small (≤3); requires node coverage and distribution; based on signal measurement, only suitable for open fields; distance and signal strength are not completely corresponding.
3.3.3 Other Technologies Related to Positioning
3.3.3.1 Sequence Positioning
Nodes sort the received signal sequences from anchor points and determine the common area through multiple perpendicular bisectors.
Another method is to determine the neighbor sequence, sort, calculate similarity (feature distance), and finally correct the feature distance between two nodes. If the similarity between two nodes is high, the position is close (logical distance, feature distance).
In this method, the number of neighbors for each node is different, how to calculate similarity (under conditions of different dimensions)? Use the order of node pairs as a measure, calculate similarity, which can have explicit, implicit, and possible different situations.
$$ SD=F_e +F_i + \frac{F_p}{2} $$
$$ RSD=SD* \frac{\sqrt{K}}{K*(K-1)/2} ,K=|S_i ∪ S_j| $$
Example of Feature Distance Calculation
Advantages of RSD Method:
- Improved accuracy.
- Can achieve per-hop accuracy.
- Efficient: no flooding, two nodes exchange sequences.
- Low computational complexity.
- Can be centralized or distributed.
The shortcoming of RSD is that signal strength and distance are still not completely corresponding.
3.4 Time Synchronization Mechanisms in Sensor Networks
October 20, 2023
The role of time synchronization: positioning, data fusion, sleep wake-up (energy-saving! environmental protection!)
Factors affecting time synchronization transmission delay: PPT5/117 sending, access (most uncertain PPT23/117), transmission, propagation, reception, acceptance.
- Sending Time: Time for the sender to assemble and deliver the message to the MAC layer.
- Access Time: Time from when the sender’s MAC layer receives the message to obtaining the wireless channel transmission right. Most uncertain factor, depending on network load.
- Transmission Time: Time for the sender to transmit the message.
- Propagation Time: Time for the message to travel from the sender to the receiver.
- Reception Time: Time for the receiver to receive the message.
- Acceptance Time: Time for the receiver to process the received message.
3.4.1 NTP
Here, synchronization only requires calculating the time difference, solving the equation to get
$$ offset = \frac{(T_2-T_1)-(T_4-T_3)}{2} $$
From this formula, it can be seen that the time difference is independent of the processing time of the server or client.
The protocol used in computer networks is not suitable for sensor networks for the following reasons:
- Sensor network links are more likely to be interrupted due to environmental influences.
- The network structure (topology) of sensor networks is unstable.
- NTP servers cannot be implemented through the network itself.
- NTP information exchange is frequent, resulting in high energy consumption.
3.4.2 RBS Class
Reference Broadcast Synchronization, multiple nodes receive the same synchronization signal, and then synchronize among the nodes that received the synchronization signal (multiple times, using the least squares method to reduce errors). This algorithm eliminates the time uncertainty of the synchronization signal sender.
Principle: Reference messages do not need to carry the local time of the sending node, RBS protocol broadcasts time synchronization messages, calculates the average time difference of message arrivals between each other, thereby minimizing the impact of non-simultaneous recordings.
Advantages: Time synchronization is separated from the MAC layer protocol, no longer limited, good interoperability.
Disadvantages: Protocol overhead is large.
The sender does not need to write the time.
To reduce the error in time propagation, statistical techniques can be used, broadcasting multiple time synchronization messages at the same time, and calculating the average time difference of message arrivals between each other.
3.4.3 TPSN
Adopts a hierarchical structure, with all nodes logically graded according to the hierarchical structure, and each node synchronizes with a node at the upper level (NTP).
Principle/Idea:
- Synchronization is achieved using a hierarchical structure.
- Nodes are logically graded according to the hierarchical structure, indicating the distance to the root node.
- Based on the sender-receiver node pair method, each node synchronizes with the upper-level node.
Root Node: Communicates with the outside world and obtains time, serving as the clock source for the entire network system.
Process:
- Generate Hierarchy: Root node is level 0, level i nodes can communicate with at least one level i-1 node.
- Time Synchronization: Level 1 nodes synchronize to the root node, level i nodes synchronize to level i-1 nodes.
Problems: Accumulation of synchronization errors; long synchronization time for the entire network; potential collision when synchronizing between adjacent nodes of two layers.
Problems: Error accumulation, competition problem (solved by random waiting), very long synchronization time for the entire network.
Optimization: Add a timestamp to the message when it starts being sent at the MAC layer to eliminate access errors.
4 Industrial Internet
What is the Industrial Internet?
What is the Digital Twin, Five-Dimensional Model?
4.1 Industrial Internet and Traditional Consumer Internet
PPT 36/117 The Industrial Internet is an evolution and upgrade of the physical economy based on the Internet.
4.2 Relationship between Industrial Internet and Industry 4.0
Industry 4.0 originated in Germany, focusing more on the intelligence and digitization of production and manufacturing processes.
The Industrial Internet originated in the United States, focusing more on improving production equipment and product services through Internet technology.
4.3 Five-Dimensional Model of Digital Twin
- Physical Entity: Various subsystems and sensors.
- Virtual Entity: Mapping of physical devices.
- Service: Optimizing physical devices, correcting virtual devices.
- Network Connection: Keeping physical devices, virtual devices, and services interacting during operation.
- Twin Data: Driving the operation of physical devices, virtual devices, and services.
4.4 Specific Content of Made in China 2025
In terms of significance, Made in China 2025 has clearer goals, more precise connotations, and clearer routes compared to Industry 4.0 and the Industrial Internet.
Theme: Promote innovative development of the manufacturing industry.
Center: Improve quality and efficiency.
Main Line: Accelerate the deep integration of new generation information technology and manufacturing.
Main Direction: Promote intelligent manufacturing.
Goal: Meet the needs of economic and social development and national defense construction for major technical equipment.
4.5 Ultimate Question
What is the relationship between IoT, Big Data, Cloud Computing, and Artificial Intelligence?
- IoT devices generate a large amount of data, serving as part of the source of big data.
- Cloud computing provides large-scale computing and storage resources for big data processing and analysis.
- Big data and cloud computing provide sufficient training samples and computing resources for artificial intelligence learning.
- IoT provides a broader application scenario for artificial intelligence, such as smart homes, smart transportation, etc.
- In summary, IoT, big data, cloud computing, and artificial intelligence support each other.
5 True Questions for Level 20 (Partial)
5.1 Short Answer Questions
Randomly select a few from the review outline.
5.2 Analysis Questions
- Why is the CSMA/CD protocol not suitable for wireless LAN?
- Two main categories of positioning technology and list some algorithms for each.
- Analyze and compare TPSN and RBS.
5.3 Comprehensive Questions
- Given a network topology diagram with eight nodes, the first question requires writing the neighbor node sequences of five of them; the second question requires calculating the RSD of two of the nodes.
- Fill in the blanks in a red box similar to the one below, requiring writing the English abbreviation and explanation.


