To validate the effectiveness and superiority of the proposed efficient IoT communication model based on NFC and LoRa, comprehensive experiments and evaluations were conducted. This section details the experimental setup, evaluation methodology, simulated experimental data analysis, and comparative analysis with the existing literature to quantify the improvements achieved by our model.
4.1. Experimental Design and Implementation
4.1.1. Objectives
The main objectives of the experimental evaluation are threefold. The first is to perform feasibility validation to demonstrate the practical feasibility of the proposed communication model and algorithms in a real-world scenario. Secondly, performance evaluation is conducted to assess the performance of the model in terms of data transmission efficiency, energy consumption, and reliability. Finally, the performance of the model is evaluated by comparative analysis; we compare the performance of our model with existing solutions and quantify the improvements.
4.1.2. Experimental Setup
Our system comprises sensor nodes equipped with ESP32 microcontrollers, which serve as the core controllers for managing data collection and communication. These nodes incorporate temperature and humidity sensors like DHT22 for collecting environmental data and NFC modules such as PN532 to facilitate NFC tag writing and reading. For long-range data transmission, they utilize LoRa modules like SX1276. An INA226 power monitoring chip is integrated to monitor power consumption, and NFC readers are incorporated with ESP32 for enhanced data collection. The collected data are transmitted to gateway devices, including a LoRa gateway that receives data from the sensor nodes and forwards it to a Raspberry Pi acting as a server for data processing and storage. Power supply units are employed throughout the system to provide stable power to all devices. As shown in
Figure 5, the prototype setup includes the IoT node based on ESP32 with SX1276 and the LoRa gateway using the SX1302 chip.
Our software environment encompasses firmware development for ESP32, implemented in C++ and incorporating algorithms A, B, and C. On the server side, we utilize Raspbian as the operating system on a Raspberry Pi, with Python 3.10.9 employed for data processing. Data storage is managed using databases like MySQL or MongoDB, and data visualization is facilitated through tools such as Matplotlib 3.7.1 and Grafana 9.4.7. For communication, we adhere to standard NFC Forum protocols for NFC interactions, use the LoRaWAN protocol for LoRa communication, and implement network protocols like TCP/IP and MQTT for data transmission. Our experimental environment includes both indoor settings for controlled initial testing and outdoor settings to evaluate long-range communication and assess interference in real-world conditions.
To facilitate comparison with common LoRaWAN unoptimized scenarios, we define a baseline without adaptive frequency control (Algorithm A), without differential compression (Algorithm B), and without packet retransmission detection (Algorithm C). Its main parameter settings refer to the conventional LoRa node configurations in the literature [
21], i.e., a fixed sampling frequency (every 5 min), a fixed transmission power (14 dBm), and a minimal CRC checksum enabled only at the hardware level.
The proposed model, on the other hand, introduces Algorithm A/B/C on top of the above baseline to optimize the sampling and compression process under the same hardware platform. This design allows us to directly compare the differences in important metrics under the same hardware conditions “with and without optimization” and also aligns with the fixed-frequency model used in common LoRa studies, such as those in the literature [
21], thus ensuring the comparability and representativeness of the baseline.
4.1.3. Experimental Procedures
The system assembly involved integrating the ESP32 microcontroller with temperature and humidity sensors, an NFC module, a LoRa module, and the INA226 power monitoring chip to create the sensor nodes. Simultaneously, the LoRa gateway and the Raspberry Pi server were configured to handle data reception and processing.
For algorithm implementation, Algorithm A (Adaptive Frequency Control) was deployed on ESP32 to adjust the data acquisition frequency based on variations in sensor data. Algorithm B (Data Compression and Aggregation) was implemented to compress and aggregate data before transmission, enhancing efficiency. To ensure reliable data transmission, Algorithm C (Packet Loss Detection and Retransmission) was incorporated to detect lost packets and initiate retransmission when necessary. Parameter configuration was carefully set to optimize performance. The data variation threshold () was established at 0.5 °C for temperature changes. The maximum frequency () was set to one acquisition per minute, while the minimum frequency () was configured for one acquisition every five minutes. The aggregation window size (NN) was set to 10 data points to balance data granularity and transmission efficiency. During data collection and transmission, the sensor nodes initiated data acquisition. ESP32 processed the collected data and wrote it to the NFC tag. An NFC reader then retrieved the processed data from the NFC tag. The compressed and aggregated data packets were transmitted via the LoRa module to the gateway, ensuring efficient long-range communication.
Upon data reception and processing, the LoRa gateway forwarded the received data to the Raspberry Pi server. Server side applications validated and decompressed the data before storing it in the database. Throughout this process, power consumption data were recorded using the INA226 chip, providing insights into the system’s energy efficiency.
Performance metrics—including data transmission times, packet loss rates, energy consumption, and data acquisition frequencies—were meticulously recorded. These metrics were essential for assessing the system’s performance and identifying areas for improvement. The experiments were repeated under varying environmental conditions, such as different distances, obstacles, and interference levels. By adjusting algorithm parameters, we observed changes in performance, which aided in fine-tuning the system for optimal operation in both controlled and real-world scenarios.
4.1.4. Experimental Environment Details
This section provides comprehensive details regarding the experimental setup, including specific hardware models, chip specifications, sensor accuracy, and software configurations used in the experiments.
The experimental system’s main hardware includes an ESP32-WROOM-32 microcontroller unit (MCU) with a dual-core Xtensa LX6 processor running at 240 MHz and built-in Wi-Fi and Bluetooth support; an NXP PN532 NFC module running at 13.56 MHz with SPI and I2C interfaces, allowing a read/write range of up to 5 cm; a Semtech SX1276 LoRa communication module that works with frequencies from 137 MHz to 1020 MHz and has a programmable RF transmit power range of −4 dBm to +20 dBm and a receiver sensitivity of down to −148 dBm; and a Semtech SX1302 LoRa gateway that can receive multiple channels and multiple data rates at the same time, improving network capacity and handling packet collisions. A Raspberry Pi 4 Model B with a Broadcom BCM2711 quad-core Cortex-A72 CPU running at 1.5 GHz and 4 GB of RAM was also used as the main computer for processing, storing, and analyzing data. The system uses a Texas Instruments INA226 chip for accurate power tracking. This chip can measure voltage and current with a high level of accuracy (±0.1%) and can handle sampling rates of up to 500 samples per second.
Tests were conducted within a laboratory space (approximately 100 m2), characterized by typical office furniture and walls made of standard gypsum board. The LoRa module and gateway were positioned at distances ranging from 5 m to 30 m to evaluate short-range communication efficiency and signal attenuation due to indoor obstacles. Tests were executed in open outdoor areas and semi-obstructed scenarios (including buildings and vegetation) with distances ranging from 100 m up to 1 km to assess the long-range capabilities and reliability of the LoRa communication under realistic environmental conditions.
Key LoRa configuration parameters during the testing process were fixed to ensure consistent performance evaluation. The frequency channel is set to a fixed frequency channel of 868 MHz (Europe). Bandwidth is fixed at 125 kHz to achieve the best trade-off between the range and data rate. The configuration of diffusion coefficients SF7 to SF12 was tested, with SF10 primarily used for balancing range and reliability.
4.3. Simulated Experimental Data Analysis
4.3.1. Data Transmission Efficiency
We achieved an average compression ratio of 70%, significantly reducing the data size transmitted. This efficiency is attributed to Algorithm B, which effectively compresses and aggregates data before transmission, enhancing overall transmission efficiency. The average transmission latency was reduced to 2.5 s from the 3.5 s observed in baseline models. The reduction in latency is due to the smaller data packets and optimized transmission frequency, which allow for faster data delivery. Algorithm B played a crucial role in enhancing transmission efficiency. By significantly reducing data size, it minimized the bandwidth required for transmission and contributed to lower latency. The combination of transmitting smaller data packets and optimizing transmission frequency led to a noticeable decrease in latency. This improvement enhances the system’s responsiveness and data delivery speed. As shown in
Figure 6,
Figure 6a illustrates the average compression ratio for both the proposed model and the baseline model, while
Figure 6b presents the corresponding average transmission delay for each model.
4.3.2. Energy Consumption
In the baseline model, the average power consumption of a sensor node was 100 mW. Our proposed model reduced this to 70 mW, resulting in a 30% energy saving. This significant reduction is primarily due to the implementation of adaptive frequency control (Algorithm A), which minimizes unnecessary data acquisition and transmission. The power consumption of the LoRa module was reduced by 25% because of fewer transmissions. By sending data only when necessary, the system conserves energy without compromising performance. We achieved an overall energy saving of 28% compared to the baseline. The use of the INA226 power monitoring chip allowed for dynamic adjustments to optimize energy usage, further enhancing the system’s energy efficiency. As shown in
Figure 7, we compare the sensor node power consumption for both the proposed optimized model and the baseline model across multiple iterations. It can be observed that the optimized model maintains a consistently lower power consumption level.
4.3.3. Reliability
The packet loss rate was reduced from 5% in the baseline model to 2% in our proposed model. This improvement highlights the system’s enhanced reliability in data transmission. We achieved a 98% success rate in packet retransmissions. This high success rate is due to Algorithm C, which effectively detects and retransmits lost packets, ensuring data integrity. The use of the INA226 chip for power monitoring allowed for dynamic energy optimization. Additionally, Algorithm C improved the system’s robustness by maintaining low packet loss even under adverse conditions, such as interference or obstacles. As shown in
Figure 8,
Figure 8a presents a comparison of the packet loss rate between the proposed model and the baseline model, while
Figure 8b illustrates the corresponding retransmission success rate.
4.3.4. Adaptability
The system demonstrated an average frequency adjustment response time of 5 s. This quick response ensures that the system adapts promptly to changing environmental conditions. During sudden temperature changes, the system increased the data acquisition frequency from once every 5 min to once per minute within 1 min. This dynamic scaling allows for more timely data collection when significant environmental variations occur. The model quickly adapted to environmental changes, ensuring timely and relevant data collection. This responsiveness demonstrates the system’s enhanced flexibility and its ability to meet varying application demands effectively. As shown in
Figure 9, we compare the adaptability of the proposed optimized model against the baseline model by examining their response times across multiple iterations. It can be observed that the optimized model consistently achieves lower response times, indicating superior adaptability.
4.3.5. Comparison with Outdoor Environment
The baseline model is characterized by fixed data acquisition and transmission frequencies, lacking data compression or aggregation, and without any packet loss detection or retransmission mechanisms. In contrast, our proposed model demonstrates significant efficiency gains by outperforming the baseline in all key metrics. The adaptive algorithms contribute to substantial energy savings, enhancing energy efficiency. Additionally, the implementation of packet loss detection and retransmission improves data integrity, resulting in enhanced reliability.
In
Table 1, we present a comparative analysis of the unoptimized and optimized approaches across four key metrics (data transmission efficiency, energy consumption, communication reliability, and adaptability) in both outdoor and indoor environments. The results demonstrate clear advantages of the optimized model, including marked increases in data transmission efficiency (up to 59.9% outdoors and 38.9% indoors), significant reductions in energy consumption (up to 22.2% outdoors and 26.4% indoors), notable improvements in communication reliability (up to 10.8% outdoors and 6.2% indoors), and substantial decreases in response times (up to 63.4% outdoors and 72.4% indoors). Overall, these findings highlight the robustness and effectiveness of the optimized approach under various operational conditions.
In
Figure 10a, we observe that the optimized approach achieves higher data transmission efficiency in both short-range indoor (<10 m) and long-range outdoor (>1 km) scenarios when compared to the unoptimized approach. In
Figure 10b, the optimized method consistently exhibits lower energy consumption under similar indoor and outdoor conditions.
Figure 10c illustrates that communication reliability improves with the optimized solution across different ranges, while
Figure 10d highlights the optimized model’s shorter response times, indicating superior adaptability in both indoor and outdoor environments. These comparisons collectively confirm that the optimized approach outperforms the unoptimized one in multiple key metrics. As shown in
Figure 10, subfigures (a), (b), (c), and (d), respectively, compare the data transmission efficiency, energy consumption, communication reliability, and adaptability for the unoptimized and optimized methods under both indoor and outdoor conditions.
4.3.6. Performance Distribution Under Different Distances and Node Counts (CDF Analysis)
In the previous experiments and analysis, we mainly measured the transmission efficiency and energy consumption of the system in indoor and outdoor environments in terms of average and maximum/minimum values. In order to have a more comprehensive understanding of the performance distribution characteristics of the system at different distances or node scale expansion, this section draws CDF (Cumulative Distribution Function) curves for key metrics (e.g., transmission delay, throughput, or energy consumption) and analyzes their overall distribution in various scenarios.
As shown in
Figure 11, we choose two sets of typical scenarios: (a) is the delay distribution under different transmission distances (e.g., 100 m, 200 m, 500 m, 800 m, 1 km); and (b) is the delay distribution under different numbers of nodes (5, 10, 25, 50, 100). The horizontal coordinate of the graph is the value of the performance metric (e.g., delay in seconds), and the vertical coordinate is the cumulative probability when the value of the corresponding metric does not exceed this horizontal coordinate.
By comparing the shapes and positions of the different curves, it can be seen that when the distance increases from 100 m to 1 km, the entire CDF curve shifts to the right. This indicates a higher probability of large delays in longer-distance scenarios, along with a more pronounced long-tail effect (extreme values). As the number of nodes increases from 10 to 100, the CDF curves also shift to the right or extend in their tails, suggesting that large-scale access leads to a higher likelihood of greater delays or packet loss. About 10–15% of the transmission delays may rise significantly, primarily due to increased competition for gateway or channel resources and more frequent retransmission triggers.
From
Figure 9, one can observe that when both the distance and the node count are relatively large, the tail of the CDF curve becomes significantly extended, indicating that, in extreme cases, delays can exceed 5 s or even more. However, in over 80% of the scenarios, the system still maintains relatively low latency (for example, completing transmission within 3 s), demonstrating that the proposed Algorithm C retransmission mechanism and Algorithm B compression measures can maintain reliability and transmission efficiency in most instances.
4.3.7. Algorithm Sensitivity and Parameter Tuning Results (Heatmap)
In order to further investigate the impact of the three aforementioned algorithms (A, Adaptive Frequency Control; B, Data Compression and Aggregation; and C, Packet Loss Detection and Retransmission) on the system’s key performance, we conducted several sets of experiments on the core hyperparameters (e.g., the threshold value of Algorithm A, the size of the aggregation window of B, the upper limit of the number of retransmissions of C, etc.) and plotted the parameters against the system’s performance indexes (e.g., energy consumption, average latency, and packet loss) in a heatmap (see below). These parameters are plotted against system performance metrics (e.g., energy consumption, average delay, packet loss rate) in a heatmap. The heatmap is able to indicate the magnitude of the performance metrics in two-dimensional coordinates with color shades, which makes our sensitivity analysis under different combinations of parameters more intuitive.
As shown in
Figure 12, the horizontal axis represents the temperature or data change threshold (Threshold) in the adaptive frequency algorithm (A), which ranges from a lower threshold (0.1 °C) to a higher threshold (1.0 °C), and the vertical axis represents the size of the aggregation window (N) in the data compression aggregation algorithm (B), which ranges from 5 to 20 points. The color indicates the average energy consumption level of the system, with darker colors representing higher energy consumption and vice versa.
When the threshold is set too low (<0.3 °C), the system collects and transmits data too frequently, resulting in darker regions in the figure that indicate higher energy consumption. On the other hand, if the threshold is set too high (>0.8 °C), although energy consumption is significantly reduced, real-time performance and monitoring accuracy are compromised. From the vertical axis, it can be observed that a larger aggregation window (N > 15) makes it possible to compress and send multiple data samples together, reducing energy usage per transmission. However, under extreme environmental changes, this also prolongs the waiting period before sending the data and increases the risk of losing multiple packets at once.
The heatmap reveals a relatively lighter area of energy consumption (for example, around a threshold of 0.5 °C and a window size of about 12). In this parameter combination, the system achieves the lowest energy consumption, and our measurements of packet loss and latency indicate that overall performance remains well balanced. This suggests that by moderately increasing the threshold to reduce unnecessary data transmissions and choosing a suitably sized aggregation window, it is possible to balance energy consumption and reliability.
4.4. Comparative Analysis with Existing Literature
In comparing the existing literature, this paper analyzes the key metrics such as compression rate, energy consumption, communication reliability, adaptability, and latency in conjunction. For indicators such as energy consumption, communication reliability, adaptability, and delay, direct comparison through bar charts is less effective due to their detailed and multidimensional nature, and indicators such as energy consumption are affected by multiple parameters such as transmission frequency, hardware, and environment, and simple bar charts may lead to misinterpretation. Communication reliability and adaptability often show a non-linear trend, and line graphs are difficult to accurately present changes. Indicators such as adaptability not only contain numerical values but also need to be combined with descriptive analysis, which cannot be adequately reflected in bar charts. Compression ratio, as a single numerical indicator, can show the performance trend and advantages of different models through histograms. As shown in
Figure 13, the models are compared in terms of key metrics such as compression rate, energy consumption, reliability, and latency.
The proposed model achieves a compression rate exceeding 70%, significantly outperforming other models and demonstrating high compression efficiency. In comparison, the compression rates of Hanumanthaiah, A. et al. [
13] and Al-Kadhim, H.M. et al. [
14] are approximately 50%, indicating moderate compression performance. Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24] achieve compression rates below 40%, reflecting lower efficiency.
The compression rate of Guberovic, E. et al. [
37] is also around 50%, slightly surpassing that of Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24], yet comparable to the rates achieved by Hanumanthaiah, A. et al. [
13] and Al-Kadhim, H.M. et al. [
14].
In terms of energy consumption, our adaptive frequency control and differential coding enable the overall energy consumption to be reduced by about 30% in typical scenarios, which significantly outperforms the schemes relying on a fixed transmit frequency or uncompressed processing in Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24].
In terms of reliability and latency, the model in this paper improves the retransmission success rate to 98% while controlling the end-to-end latency to around 2.5 s, which is more than 1 s less than the conventional LoRaWAN scheme.
The proposed methodology significantly reduces energy consumption by efficiently compressing data, thereby minimizing both the frequency and size of data transmissions. A higher compression ratio also helps mitigate packet loss and improves communication reliability compared to alternative approaches. Additionally, the proposed approach exhibits high adaptability across various IoT applications, including low-power devices and bandwidth-limited networks.
By generating smaller packets, the proposed technology reduces latency, making it highly suitable for real-time IoT applications such as environmental monitoring and healthcare.
Table 2 presents a comparative analysis of key performance metrics after applying the proposed technique.
Regarding communication reliability, the proposed model achieves the highest reliability. Hanumanthaiah, A. et al. [
13] and Al-Kadhim, H.M. et al. [
14] demonstrated moderate reliability, while Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24] exhibited lower reliability. Guberovic, E. et al. [
37] also achieved a moderate reliability rating. For adaptability, the proposed model performs most effectively, while Hanumanthaiah, A. et al. [
13], Al-Kadhim, H.M. et al. [
14], and Guberovic, E. et al. [
37] are rated as moderate. In contrast, Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24] showed lower adaptability. In terms of latency, the proposed model achieves the lowest latency (<10 ms), while Hanumanthaiah, A. et al. [
13], Al-Kadhim, H.M. et al. [
14], and Guberovic, E. et al. [
37] exhibited moderate latency (<20 ms). Chowdhury, M.R. et al. [
17] and Has, M. et al. [
24] demonstrated higher latency (>30 ms). Overall, the proposed model demonstrates substantial advantages across key performance metrics, including energy efficiency, communication reliability, adaptability, and latency, making it a highly effective solution for IoT applications.
In the subsequent evaluations, we concentrate on end-to-end performance metrics (e.g., second-level latency, total energy consumption, and overall network reliability), differentiating them from the previously referenced millisecond-level test data (which generally encompasses only local processing latency or local communication latency). We quantified the total transmission duration (in seconds) from the moment the sensor node finalizes data acquisition, executes compression or encoding, and transmits the data via the LoRaWAN gateway until it is received and processed by the back-end server to offer a more thorough assessment of the system’s performance in a practical deployment context. Furthermore, we meticulously assess the node duty cycle, duty range, sleep cycle, transmit power, and back-end server processing flow to quantitatively evaluate the total energy consumption of the nodes and the network; analyze communication reliability utilizing metrics such as packet loss rate and retransmission success rate; and gauge adaptability by monitoring the system’s responsiveness to modifications in collection frequency and power level across varying environments and loads. These measures offer system-level evaluation criteria that enhance prior millisecond test results, which concentrated solely on localized delay or processing, hence establishing a more accurate benchmark against other literature and real-world deployment standards.
The proposed model demonstrates substantial improvements in data transmission efficiency by employing advanced compression and encoding strategies. This method significantly reduces the bandwidth required and consequently lowers the overall transmission latency to approximately 2.5 s. In comparison, conventional LoRaWAN models, as reported in [
19], typically exhibit average latencies around 3.5 s when compression is not employed. Furthermore, while other compression-based energy-saving algorithms in the literature (e.g., [
8]) achieve only about a 50% compression ratio, the proposed model outperforms these techniques, thus ensuring both higher throughput and reduced communication overhead in multi-node Internet of Things (IoT) environments.
Energy efficiency is critical for resource-constrained IoT nodes. The proposed model integrates adaptive power control mechanisms, intelligent duty cycling, and context-aware scheduling to reduce overall energy consumption at the node level by 30%. Additionally, the LoRa transceiver module’s energy draw is reduced by 25%. In contrast, machine learning (ML)-enhanced adaptive algorithms discussed in [
10] achieve a 20% reduction in energy usage, while similar adaptive data rate (ADR) mechanisms explored in [
9] report comparable improvements. This model’s capacity to achieve an extra ~10% energy savings beyond state-of-the-art adaptive approaches significantly prolongs node battery life and decreases maintenance and replacement costs in practical IoT deployments.
Ensuring reliable data transmission is paramount in diverse IoT scenarios. The proposed model reduces packet loss rates to an impressively low 2% and attains a 98% retransmission success rate by utilizing proactive loss detection and intelligent retransmission strategies. By contrast, existing solutions (e.g., [
19])—even when employing optimized spreading factors—exhibit packet loss rates between 3% and 5%, and earlier retransmission techniques ([
15]) report success rates of 90–92%. Thus, the proposed model not only enhances link reliability but also guarantees superior data integrity, ensuring robust operation in large-scale, interference-prone environments.
Adaptability is essential in dynamic, heterogeneous IoT environments. The proposed system can adjust its response time within 4–6 s in indoor conditions and 5–7 s outdoors. The literature examples, such as the adaptive systems noted in Petajajarvi, J. et al. [
20], often have response times on the order of 10–15 s, and studies like Noprianto, N. et al. [
21] indicate that environmental variability frequently degrades responsiveness. The proposed model’s ability to shorten adaptation times by about 50–60% ensures swift operational adjustments, enhancing the system’s scalability and responsiveness across different environmental conditions.
As shown in
Table 3, our proposed model is compared against existing methods in the literature, illustrating improvements in data transmission efficiency, energy savings, communication reliability, and overall adaptability under various deployment conditions.