Design Ideas for energy efficient IOT wireless nodes

Design Ideas for energy efficient IOT wireless nodes

Introduction?

IOT nodes are ubiquitous and many of them are running on battery. Be it a sensor node, a portable light, or a wearable device, it is important to have longer battery life while keeping the device small and portable.?

A typical IOT system has 3 major components – end nodes, controllers, and cloud. The Controllers are mobile Apps, web portals. Cloud is to host cloud applications, services, ensure always and from anywhere connectivity, security, and analytics to name few of the services. End nodes are the foot soldiers of the IOT systems and tasked with the ‘dirty’ work of collecting data and actuating the commands sent from the controller devices or the cloud. The end nodes are part of various kinds of devices (many a times battery operated), typically have low power and computational capacity.?

Other than the end nodes, few controllers such as remotes and sensors could also be battery based and utilizing wireless communication technologies such as plain RF, Bluetooth, Zigbee or Wi-Fi etc.?

These MCUs and wireless SOCs come with various sleep modes like light sleep, deep sleep etc. In most cases a reference documentation is available. Therefore, here we’ll talk more about some additional ways to design low power wireless nodes and increase the battery life of the end products. The article gives a detailed list of available options but not limited to any one wireless technology. These techniques could be adopted to develop any custom protocols as well. The article refers to any existing IEEE standards such as IEEE 802.11 (Wi-Fi), BLE etc. to explain specific available features. Though, it talks more from the end node’s perspective but not limiting its applicability to other kinds of applications.??

Major factors causing the energy consumption

Main causes of the power consumption in the devices are 1. radio communication, 2. processing power. Wireless SOCs and standards are generic which are built by keeping several applications in mind. But several of these features are configurable to suit respective applications.?

Radio communication could be reduced by available techniques and suitable configuration of the protocol layers in a manner that reduces need of the communication itself. We will see if we can reduce the power consumption per transaction with some trade off.?

On the processing side, power consumption is proportional to the CPU frequency. Therefore, we will see if we can tweak the CPU frequency for certain applications to have a low power solution with trade-off for latency. For some simple applications, it can certainly be possible. There are wake locks used by processors which block CPU from going to power saving modes. A developer can disable these wake locks to get some mileage on this front as well.?

On the radio environment side, interference, and flooding of the network due to other transmitting devices is a cause of radio retransmissions and hence cause of excessive power consumption. DFS (Dynamic frequency selection) is a mechanism to select the less congested frequency channel of communication. A node can utilize this to reduce radio retransmissions and save power. Typically, in Wi-Fi networks, operating frequency channel is defined by access points. In Zigbee, PAN coordinator selects the channel while Bluetooth implements frequency hopping, so this may not apply to Bluetooth technology. Consider this for any battery based wireless hotspots, repeater nodes or ad-hoc networks.?

Communication Protocol Optimization?

Reduce TX packets - Optimize ACK.?

  • Block ACK: Most of the wireless communication protocols are acknowledgement driven for each packet. This is because wireless communication is inherently unreliable. Combining multiple acknowledgements into one block reduces the number of packets transmitted in the network. This technique makes less sense for short bursts of data transmissions but more suitable to continuous streams of data transactions as required in the multimedia applications such as IP cameras etc.??
  • Piggybacking acknowledgement with the response is another way to reduce the number of transmissions (hence, collision possibility) for each transaction. This is what is utilized during TCP connection making, also known as 3-way handshake. The client sends SYN, server sends its own SYN and ACK of received SYN by clubbing both as one segment. And the client sends final ACK to signal establishing of connection. Similar, procedure could be built for any custom application or network layer protocol. Important thing to remember here is to keep ACK timeout at the sender side to be big enough so that delayed ACK is not considered as a lost packet.?
  • Avoid redundant ACKs: Reduce redundancy due to different protocol layer’s ACK. For example, using TCP for local link communication will have ACK at transport layer as well as at layer 2.?So, UDP could be a favorable option for local link communication.

Optimize Software?

  • Optimize the software algos to keep CPU less busy and transact with outer world (TX/RX) less frequently using simple data aggregation at the node itself and allow the SOC (System on Chips) to sleep for longer periods. In general, CPU processing is cheaper than radio communication.?
  • Choose security options wisely. Symmetric cryptographic (AES etc.) operations are simpler than asymmetric ones (RSA, DSA etc.) so prefer methods like AES for larger data crypto operations. Symmetric algorithms like AES etc. consume less power but considered less secure.??

Avoid Segmentation and Reassembly?

  • Avoiding segmentation and reassembly (SAR) is an important way to reduce CPU processing at both ends. SAR happens when the application-level packets are larger than the MTU specified by the data link layer. The MTU defines the maximum size of the packet that could be sent at the link level and larger packets would be discarded. Segmentation of large packets is done at the sender end and reassembly is done at receiver end. Thus, increasing the processing requirement at both ends. Developers should mindfully keep the maximum application packet size to be within the link level limits of maximum transfer unit size.?This is how TCP MSS (maximum segment size) is calculated considering the IP layer's MTU which is futher dependent on the link layer.

Use connectionless communication?

  • Consider avoiding connection-oriented protocols like TCP where keep-alive messages are mandatory to keep the connection live. The connection less communication does not require radio level keep-alive messages. The keep-alive messages’ interval should also be configured wisely if et all it is mandatory.??
  • For portable devices, this makes more sense as with device movement, frequent disconnect/reconnects increase processing and network transmissions due to protocol exchanges.?
  • Beacons are used for navigation now a days but generically these are just periodically transmitted messages from a source which could be an end device broadcasting its location or a Wi-Fi access point updating its clients about network parameters. Increase the interval of beacon transmissions as much as affordable.

Reduce channel width?

  • Reduce channel width if the protocol permits. This reduces data transfer speed but improves power consumption performance. In the IOT systems data rate requirement is typically low so this could be done in most cases. For example, 20MHz channel width in the Wi-Fi networks will provide better power savings than 40MHz or more.?

Optimize scan mechanism and interval?

  • Optimize it by using passive scanning instead of active scanning. The IEEE 802.11 (Wi-Fi) standard defines both active and passive scanning. Passive scanning is also considered to be more secure as it does not broadcast the name of any historically saved AP along with its Probe request packet and just listens to AP beacons in the surrounding. It is slower compared to active scanning but brings power savings to the clients.?
  • Increasing active scan interval can reduce power consumption at the cost of increased latency of connection.?

Advertisement interval, connection interval and slave latency??

Let’s take an example of Bluetooth Low Energy to explain these parameters. Advertisement interval, connection interval and slave latency are 3 critical parameters that could be tuned to optimize the power consumption with some trade off in Bluetooth low energy (BLE) devices. Here is a brief description of each,?

  • Advertisement interval: Devices advertise their availability to other devices for connction and information sharing. We can increase the advertisement interval (range 100ms to 1s to save up to >90% power) or beacon intervals to save more power. In case of connectible advertisements, the trade-off is the latency of connection which will increase with the increase in the advertisement interval.
  • Connection interval (trade off – throughput in both direction): Connection interval is the time between 2 link level radio transmission opportunities. Bluetooth low energy devices sleep between 2 connection events and increasing this will increase the latency of the data communication but could be utilized optimally for the trade off with power savings. It can range between 7.5ms to 4 seconds.?
  • Slave latency (trade off – throughput from central to peripheral): It is defined as the number of connection events, a slave device can skip if it is in the idle state. Thus, the effective connection interval is dependent on slave latency linearly. This technique is utilized in BLE. The DTIM (delivery traffic indication map) is a similar technique utilized in Wi-Fi client nodes where clients save power with the help of access point as defined by IEEE 802.11 standard.??

For example, consider the scenario of a TV and the remote. Connection interval could be smaller so TV can wake up every connection event to maintain the connection but remote could sleep longer by skipping connection events using slave latency feature. But since the connection interval is small, remote can send command instantly on the button press. TV anyway is not going to initiate communication so a remote can afford to be sleeping for longer duration (several connection events) utilizing the higher slave latency.?

Adaptive TX Power Control (TPC)?

Transmitting at lower power reduces the collision in the network (due to reduced range) as well as the power consumption at the source of transmitting packets. We can define a simple algorithm based on 802.11h that defines using transmit power control to minimize the interference. IEEE 802.11h defines controlling the transmission power statically, however we can define a simple feedback-based algorithm like how some of the systems such as Cisco CCX based clients & servers use. Here is a simple implementation of such an algorithm –??

Example of a TX power negotiation algorithm for Star Network scenario?

  1. Identify total number of clients connected to a central device of the star network, this could be done in two ways -??

  • Send this protocol packet with full power to all nodes from the center device, and expect an ACK back, count number of devices responding to know total number of devices for further reference. Report this information to a controller node such as mobile application and ask user to verify and confirm the maximum nodes physically.?
  • or manually feed the total number of devices in the range to the source or star of the network using a mobile application i.e., the one whose power is being reduced.?

2. Reduce power by 1db, repeat step 1.

3. Further reduce, continue to repeat step 1-2 until all ACKs (from each device) are not received.

4. Confirm (lets’ say 3 times) by repeating step 3 with increased power and ensure all ACKs are received (total number of ACKs to be same as noted in step 1).?

5. Set this as the final power.?

6. If during the negotiation, a node loses power then observation may be abnormal, therefore go back to step 1.??

Consider the example of a sensor node in a Bluetooth mesh network. The sensor node can follow above algorithm to know the required TX power needed to communicate with all its interested clients or group members.?

DFS?

Dynamic frequency selection (DFS) is another method to reduce power consumption by selecting less congestion channel of operation. This technique is defined by the standard IEEE 802.11h. This reduces retransmissions in the wireless communication and hence reduces power consumption for same amount of data transaction. But this is applicable only to access point (AP) devices in case of Wi-Fi where AP is in charge to set the channel of operation. However, the technique could be adopted in other ad-hoc wireless networks as well.

CPU Processing?

DVFS (Dynamic Voltage and Frequency Scaling)?and DVS (Dynamic voltage scaling)

For less CPU intensive operations such as sensors or simple data collection devices, the SoC (System on Chips) can be configured to operate at a lower CPU frequency. An important thing to note here is that the transition across frequency levels also is time consuming, therefore it should be considered that device is meant to sleep for longer duration and tasks are not CPU intensive. If the tasks are CPU bound (intensive processing) such as multimedia streaming etc, then it does not provide desired results as with lower frequency, execution time for the same amount of computation will also increase. Voltage and frequency scaling are used mostly together.

The standalone DVS (Dynamic Voltage Scaling) is used in some of the peripherals that allow low voltage operations in power savings mode. For example, some low power mmc or SD cards can run at 1.8V as well as 3.3 volts.?Main processor hosted driver can automatically detect the availability of these modes in the peripherals and activate lower voltage as required.

Power modes like sleep, deep sleep etc., that are available with various SOCs (System on Chips) utilize this by controlling clock frequency and turning off some of the hardware power domain blocks on the SOC. An application driven approach could be taken to control these modes and make the device to be in sleep (highest possible savings mode) for longer duration and hence save more power.

Wake locks

To allow some applications or peripherals such as SPI, I2C buses etc., there is a provision of wake locks which could be utilized by these operations to restrict the scaling down of voltage and frequency for their efficient operations. Once the application releases these wake locks, this restriction is lifted. Software should efficiently utilize the usage of wake locks.?

Other ideas based on efficient software design could be adopted to reduce frequent peripheral writes (e.g., data logging etc.) such as non-volatile memory writes for persistent storage of data to reduce processing requirements of the application. Typically, peripherals are custom designed and more efficient than the main CPU or the controller, therefore an optimum software design should off load maximum processing responsibilities to peripherals wherever possible. The use of hardware accelerators for crypto operations or TCP checksum calculation of incoming packets by the Wi-Fi chipsets are few such scenarios where it is utilized in most devices.

Conclusion

The proposed technique in the article gives a comprehensive list of ideas that could be applied to implementation. The article mainly focused on reducing power consumption due to CPU processing and radio communication. Techniques like DVFS, DVS, DFS, TPC (802.11h) etc. are discussed. Some ideas are applicable for only point to point topology; some are useful for star network topologies while some are node specific. Since one size cannot fit all so it may not be possible to apply all of these in one go on a particular device. Idea here is to discuss the options available and then based on the applicability and affordability with respect to the trade off, same should be adopted in the respective application. The existing IEEE standards are cited wherever applicable and same could be referred for further reference.

Stanley Russel

??? Engineer & Manufacturer ?? | Internet Bonding routers to Video Servers | Network equipment production | ISP Independent IP address provider | Customized Packet level Encryption & Security ?? | On-premises Cloud ?

1 年

That's a great post! You mentioned a lot of important technologies that make up #IoT. #BLE, #WiFi, and #Bluetooth are each useful, but they all come with their own power and range restrictions. Have you considered using multiple technologies in a mesh network to get the best of all worlds? You talked about wireless technology in your post - if you need to cover a large area with many devices, how would you technically use these technologies for a reliable connection?

回复
Dhananjay Dubey

Senior Staff Engineer | Senior Technical Leader | Android Health Solutions | Digital Health @ Samsung Research Institute, Noida

2 年

Good Share Rahul Yadav ..Informative article.

回复
Shreya Misra

R&D Engineer at Havells India Ltd

2 年

Informative, nicely explained.

Atul Vaish

Architect | Mentor | Trainer ( Embedded & AI Systems)

2 年

Great Rahul..

Prashant Sharma

5G/Cloud Kubernetes-Docker/C/Golang

2 年

Excellent article

要查看或添加评论,请登录

Rahul Yadav的更多文章

社区洞察

其他会员也浏览了