In the ever-expanding world of the Internet of Things (IoT), businesses are constantly looking for ways to optimise the management and performance of their connected devices.
Since its specification in 2017, the Lightweight Machine to Machine (LwM2M) protocol has emerged as a solution of choice to meet these needs. It offers a simplified data structure and uses proven security protocols, all in a lightweight footprint ideal for the limited resources typical of IoT devices.
Technically, the LwM2M stack is primarily based on UDP/DTLS, despite being compatible with other transport protocols and suitable for IP and non-IP cellular communications, including satellite and SMS. This guarantees the flexibility and security of data transmission.
The LwM2M communication protocol, designed to meet IoT requirements, stands out for its ability to enable efficient remote management of IoT devices. Centralised management is essential in smart building applications, where sensors are scattered across various sites. The LwM2M protocol provides a robust mechanism for remote discovery, configuration, control, and an update of these devices from a central server.
This greatly simplifies the maintenance and management of the entire system, reducing operational costs and saving valuable time. For example, it is possible to interrogate a sensor remotely to find out its current configuration and to adjust its application configuration parameters in real-time, such as scanning interval or alarm thresholds, from an LwM2M server, with a single click. This flexibility maximises operational efficiency and optimises sensor lifetime.
In addition, the integration of LwM2M protocol means that users can benefit from the latest firmware upgrades, even after deploying several sensors in the field, thanks to the remote update function (FOTA). FOTA is an operation standardised by the LwM2M protocol and, depending on the type of network used, it takes just 5 to 15 minutes to download the updated file to the product.
Another major advantage of LwM2M is its scalability and interoperability. Unlike other communication protocols, the LwM2M protocol does not require codecs or connectors to process the data sent by devices. LwM2M offers a standardised data model, enabling devices from different manufacturers to communicate seamlessly with each other. This interoperability simplifies systems integration, data collection and analysis, and centralised management for Adeunis customers.
To ensure this interoperability, Adeunis sensors expose standard profiles for business data, such as temperature, humidity, CO2 level, and impulse, as well as network and product parameters.
The LwM2M protocol also enables sensor manufacturers to combine standardised objects with proprietary ones to provide data related to specific functions of their products or to offer complementary modes of operation. Adeunis has exploited this flexibility by developing a proprietary object for each product. This CUSTOM object can be used to manage alarms with hysteresis.
Another crucial point for IoT sensors, most of which are battery-powered, is energy consumption. Energy consumption must be kept to a minimum both when the device is in standby mode and when data is being transmitted to guarantee that it will operate for several years without requiring on-site maintenance. The LwM2M protocol is an ideal solution, offering optimised energy consumption compared to the MQTT protocol, for instance.
To illustrate the impact of the LwM2M protocol on the energy consumption of our cellular sensors, we present two concrete examples taken from our comparative analysis.
In this scenario, our cellular sensor is configured to collect and transmit temperature and humidity data every 10 minutes. Our tests have shown that the autonomy of our product is 5 times better with the LwM2M protocol, compared with the MQTT protocol.
In this second use case, where a pulse counter sensor reads the index value of a meter once an hour, we also observe a significant advantage in terms of energy efficiency thanks to the use of the LwM2M protocol.
Estimated autonomy:
Estimated autonomy:
Two main factors explain these differences in energy consumption between the LwM2M protocol and the MQTT protocol.
Firstly, when data transmissions to a remote LwM2M server are at least 5 minutes apart, the ID connection maintains the security context (DTLS). Each time it is sent, the IoT device transmits only its business data and no security elements. Since less data is transmitted with each exchange with the LwM2M server, the modem sessions are shorter and the sensor’s power consumption is optimised.
In MQTT, on the other hand, for each transmission to a broker, an IoT sensor will send 90% security-related data and 10% business data, because a complete security session must be created each time data is sent.
The transport protocol also plays a crucial role in energy consumption. LwM2M is based on the UDP transport protocol, while MQTT is built on the TCP transport protocol.
This difference influences the sensitivity of exchanges to latency, with a tendency for more packet losses and retransmissions with TCP, particularly in the event of a poor network or the use of an NB-IoT network, resulting in higher energy consumption.
24-hour consumption of an IoT sensor pulse counter:
MQTT
24-hour consumption, with 1 transmission per hour
LWM2M
24-hour consumption, with 1 transmission per hour
A sensor incorporating the LwM2M protocol transmits only business data for each transmission, which not only has a positive impact on its energy efficiency but also on the cost of subscribing to an operator.
1 temperature and humidity reading every 10 minutes and 1 transmission per hour (6 temperature values + 6 humidity values)
Product/Server communication mode | Monthly data consumption |
---|---|
LwM2M | 430 ko |
MQTT | 5250 ko |
In concrete terms, for a use case where an IoT sensor collects temperature and ambient humidity data every 10 minutes and transmits it once an hour, monthly data consumption is 10 times higher if communications are based on the MQTT protocol versus the LwM2M protocol.
In conclusion, the LwM2M protocol represents a versatile and effective solution for Adeunis cellular sensors, offering increased remote management, interoperability, scalability, and energy efficiency. By adopting this technology, companies can improve operational efficiency, reduce costs, and deliver a better end-user experience.
26/03/2024
expertise to support you, from the diagnosis to the implementation of your solution
Take advantage of our introductory offer for all NB-IoT / LTE-M Field Test Device pre-orders before 31 January 2025.