Power Optimization of WiFi Networks based on RSSI-awareness

This research analyzed the impact of Wi-Fi received signal strength indication (RSSI) on power consumption of smart phones under different network environments. It was found that bad signal may lead to decrease in network link speed but increase in power consumption; whereas good signal contributed to rapid transmission and low power consumption. To reduce the power consumption and prolong the battery life, through combination with the original IEEE 802.11 PS mechanism, an optimization mechanism based on RSSI-awareness was proposed which aggregated network packets and delayed transmission. In essence, the proposed mechanism functioned through decreasing the number of mode switches of Wi-Fi component and extending the time of Wi-Fi stay in the Power-Save (PS) mode. Specifically, the signal strength was divided into three levels, including "good", "weak" or "bad". The decision tree was used to choose the best transmission method (Normal / Lineral / Exporational Transmission) according to previous and current signal strength. Algorithms were introduced to select the best split of decision tree for partitioning specific records into smaller subsets. Finally, the proposed mechanism was performed on the TI pandaboard platform. The results indicated that the proposed mechanism was practical and able to reduce the power consumption of smartphones in an effective manner. Received on 08 March 2019; accepted on 05 April 2019; published on 19 June 2019


Introduction
Smartphones have experienced tremendous and continuous growth in recent years, accelerating the development both in software and hardware.However, they encounter some limitations in power supply, which becomes a major factor interfering with the user experience.There are quite a few factors impacting on power consumption, among which signal strength is an important one.As an example, when opening the browser on a high-speed rail, or sending a message at a place far away from Access Point (AP), we often feel the phone gradually gets hotter.This can be explained by the bad signal resulting in slow link speed.More specifically, transmission for the same amount of network packets Bo Chen, Xi Li and Xuehai Zhou • We analyzed the impact of Wi-Fi RSSI on energy consumption of smartphones under different network environments.In brief, weak or bad Wi-Fi signal was found to cause more power consumption; while good Wi-Fi signal may lead to low power consumption.
• To reduce the power consumption of smartphones in different network environments, by combining the original IEEE 802.11PS mechanism, we proposed the optimization method that could recognize the dynamic network environment and dynamically adjust the Wi-Fi transmission method based on the decision tree.Essentially, the proposed mechanism took full advantage of the PS mechanism to improve battery utilization.
• We implemented the proposed mechanism on OMAP4 pandaboard ES.Many related experiments were also carried out.The experimental data showed that the optimization mechanism could not only prolong the battery life for common application under different network environments, but also improve the user experience to some extent.

Background and related work
IEEE 802.11 gives two operation modes for power management [3] [4]: Continuous Active (CA) mode and Power Save (PS) Mode.Some details on these two modes are given in this section.

Continuous Active (CA) and Power Save (PS) mode
For the wireless network, CA mode (left in Fig. 1) is intended for devices when power is not an issue.This mode provides the best connectivity from the user perspective.In other words, it keeps the radio powered up continuously to ensure minimal lag in response time.Specifically, Wi-Fi Network Interface Control (WNIC) provides users with more high-quality network communications services.The weakness of this mode is high power consumption.For instance, it may consume 1000mW for sending network packets by WNIC, 750mW for receiving packets, and even 650mW in idle state.In this way, WNIC quickly drains out battery [5].This CA mode consumes the most power but offers the highest throughput.In comparison, PS mode allows the network to switch to low-power state after a period of time, thereby saving energy.The AP periodically sends a frame to notify smartphones whether or not data arrive in AP, and periodically awakens the smartphones to receive the AP-sent frame and detect whether there are data to be received.

Dynamic Power Save mode and Static Power Save mode
There also have two implementations of Power Save Mode (right in Figure 1), static PSM and Dynamic PSM, respectively.Static PSM was first standardized.
With Static PSM, it allows the client to sleep as much as possible by indicating the client to fall asleep immediately if the AP does not have any packet for it.Station (STA) enters PS mode by sending a Null frame to the AP with the Power Management bit set.From then on, the AP stores all packets destined to the STA in a queue and set the TIM field in the beacon frame, indicating that packets destined for the STA have been queued at the AP.And STA is woken up by every Listen interval to receive the beacon frame.When detecting that the TIM field for it has been set, it sends a PS-Poll frame to the AP.In response, AP sends the first queued frame to the STA.After receiving the queued data frame, STA sends another PS-Poll frame to the AP if the More Data field in this frame.STA continues to send PS-Poll frames to receive all the queued frames; when none is left, it goes back to sleep until the next Listen Interval.However, this process leads to long network latency and low network efficiency as a separate PS-Poll message is required for every packet.Another feature of IEEE 802.11 is dynamic Power Save.It allows the wireless device to dynamically go into power save mode if the device is associated.No network traffic is going through the card for a certain period of time, with a default value set to 100 ms.To enable dynamic power save, the wireless driver must support power save mode of operation.The dynamic power save timeout (the time for no traffic through the card before going to PS mode) is affected by the PM-QOS network latency setting.To enable power save, a wireless device sleeps at most the duration of the Delivery Traffic Indication Map (DTIM) interval.It will wake up during that period to listen for beacons from the AP, so as to find out whether the AP has buffered frames for it.Refer to The Power Savings Guide for more details as to how this works.In sum, Static PSM allows Wi-Fi to switch sleep mode immediately after packets are received.Also, Wi-Fi components will stay in sleep mode for higher energy optimization, or in active mode longer by Dynamic PSM for better performance.

Related Works
In the last few years, there has been a growing interest in studying energy consumption in mobile devices and green computation.These works mainly include: Power consumption on WI-FI/4G/bluetooth/screen components [6][7] [8], power consumption profiling based on android application execution process [9][10], network protocol power optimization [11], etc. Niranjan [12] Power Optimization of WiFi Networks based on RSSI-awareness

Continuous Active (CA) and Power Save (PS) mode
For the wireless network, CA mode (left in Fig. 1) is intended for devices when power is not an issue.This mode provides the best connectivity from the user perspective.In other words, it keeps the radio powered up continuously to ensure minimal lag in response time.Specifically, Wi-Fi Network Interface Control (WNIC) provides users with more high-quality network communications services.The weakness of this mode is high power consumption.For instance, it may consume 1000mW for sending network packets by WNIC, 750mW for receiving packets, and even 650mW in idle state.In this way, WNIC quickly drains out battery [5].This CA mode consumes the most power but offers the highest throughput.In comparison, PS mode allows the network to switch to low-power state after a period of time, thereby saving energy.The AP periodically sends a frame to notify smartphones whether or not data arrive in AP, and periodically awakens the smartphones to receive the AP-sent frame and detect whether there are data to be received.

Dynamic Power Save mode and Static Power Save mode
There also have two implementations of Power Save Mode (right in Figure 1), static PSM and Dynamic PSM, respectively.
Static PSM was first standardized.With Static PSM, it allows the client to sleep as much as possible by indicating the client to fall asleep immediately if the AP does not have any packet for it.Station (STA) enters PS mode by sending a Null frame to the AP with the Power Management bit set.From then on, the AP stores all packets destined to the STA in a queue and set the TIM field in the beacon frame, indicating that packets destined for the STA have been queued at the AP.And STA is woken up by every Listen interval to receive the beacon frame.When detecting that the TIM field for it has been set, it sends a PS-Poll frame to the AP.In response, AP sends the first queued frame to the STA.After receiving the queued data frame, STA sends another PS-Poll frame to the AP if the More Data field in this frame.STA continues to send PS-Poll frames to receive all the queued frames; when none is left, it goes back to sleep until the next Listen Interval.However, this process leads to long network latency and low network efficiency as a separate PS-Poll message is required for every packet.
Another feature of IEEE 802.11 is dynamic Power Save.It allows the wireless device to dynamically go into power save mode if the device is associated.No network traffic is going through the card for a certain period of time, with a default value set to 100 ms.To enable dynamic power save, the wireless driver must support power save mode of operation.The dynamic power save timeout (the time for no traffic through the card before going to PS mode) is affected by the PM-QOS network latency setting.To enable power save, a wireless device sleeps at most the duration of the Delivery Traffic Indication Map (DTIM) interval.It will wake up during that period to listen for beacons from the AP, so as to find out whether the AP has buffered frames for it.Refer to The Power Savings Guide for more details as to how this works.
In sum, Static PSM allows Wi-Fi to switch sleep mode immediately after packets are received.Also, Wi-Fi components will stay in sleep mode for higher energy optimization, or in active mode longer by Dynamic PSM for better performance.

Related Works
In the last few years, there has been a growing interest in studying energy consumption in mobile devices and green computation.
These works mainly include: Power consumption on WI-FI/4G/bluetooth/screen components [6][7] [8], power consumption profiling based on android application execution process [9][10], network protocol power optimization [11], etc. Niranjan [12] conducted measurement study on the energy consumption characteristics of three widespread mobile networking technologies: 3G, 4G and Wi-Fi.He found that 3G and GSM incurred a high tail energy overhead because of lingering in high power states after completing a transfer.Hid work presented a protocol of TailEnder to reduce energy consumption.Andrew [13] proposed a novel Power Save Mode that labelled each application with a priority.High priority application would switch to CAM or Active mode, while low priority traffic was optimized for energy efficiency.Zhao [14] put forward a method focusing on web browsing.It firstly recognized the computation sequence of the web browser, and then predicted users' reading time through a practical data mining methods.It switched to low power states when the reading time was longer than a threads.Chulhong [15] developed a system which provided users with power use of sensing apps at pre-installation time.Chen [16] proposed an energy saving method for large file downloading on smartphones.In the industrial sectors, Apple MAC OS provided a service, named APP Nap.It reduced power consumption by completely suspending your app's execution when certain criteria were met.The system conducted measurement study on the energy consumption characteristics of three widespread mobile networking technologies: 3G, 4G and Wi-Fi.He found that 3G and GSM incurred a high tail energy overhead because of lingering in high power states after completing a transfer.Hid work presented a protocol of TailEnder to reduce energy consumption.Andrew [13] proposed a novel Power Save Mode that labelled each application with a priority.High priority application would switch to CAM or Active mode, while low priority traffic was optimized for energy efficiency.Zhao [14] put forward a method focusing on web browsing.It firstly recognized the computation sequence of the web browser, and then predicted usersąŕ reading time through a practical data mining methods.It switched to low power states when the reading time was longer than a threads.Chulhong [15] developed a system which provided users with power use of sensing apps at preinstallation time.Chen [16] proposed an energy saving method for large file downloading on smartphones.In the industrial sectors, Apple MAC OS provided a service, named APP Nap.It reduced power consumption by completely suspending your appąŕs execution when certain criteria were met.The system knew a certain app that was in the background and completely hidden by other appsąŕ windows.When that app had no task, OS X would slow the app down, keeping it from using up CPU cycles, thereby saving battery power.All those works provide good references for our research.

Impact of RSSI on Energy Consumption
This section analyzes the impact of Wi-Fi RSSI on power consumption of smartphones.First, the communication behaviors of different apps were described.It was found that small amounts of network packets would lead to frequent switch of Wi-Fi network from PS mode to CA mode, even if a small packet was transmitted.Second, the impact of Wi-Fi RSSI on power consumption was explored, so as to make full use of this feature for transmission optimization.An experiment was performed on a TI Pandaboard ES platform [17] that carried on the network communication through WL1271 chips [18].To change the network environment, we chose different positions from AP to smartphone.This would help to simulate the real network environment and measure the various value of RSSI.For our purpose, the experiment was designed to evaluate two factors: (i) The network transmission behavior of different apps.
(ii) The transmission behavior of Wi-Fi component under different network environments.
This section analyzes the impact of Wi-Fi RSSI on power consumption of smartphones.First, the communication behaviors of different apps were described.It was found that small amounts of network packets would lead to frequent switch of Wi-Fi network from PS mode to CA mode, even if a small packet was transmitted.Second, the impact of Wi-Fi RSSI on power consumption was explored, so as to make full use of this feature for transmission optimization.
An experiment was performed on a TI Pandaboard ES platform [17] that carried on the network communication through WL1271 chips [18].To change the network environment, we chose different positions from AP to smartphone.This would help to simulate the real network environment and measure the various value of RSSI.For our purpose, the experiment was designed to evaluate two factors: (1) The network transmission behavior of different apps; (2) The transmission behavior of Wi-Fi component under different network environments.
For the first, as seen from Fig. 2(a), network packets of Wechat and Tencent QQ apps are small; while those of Youku and Chrome apps are relatively big.That is to say, social apps always send small packets periodicity or sporadically, resulting in frequent switches of Wi-Fi components from CA mode to PS mode (figure 2(b)).Accordingly, this will increase the power consumption of smartphones to some extent.For the first, as seen from Fig. 2, network packets of Wechat and Tencent QQ apps are small; while those of Youku and Chrome apps are relatively big.That is to say, social apps always send small packets periodicity or sporadically, resulting in frequent switches of Wi-Fi components from CA mode to PS mode (Fig. 3).Accordingly, this will increase the power consumption of smartphones to some extent.
For the second, to measure the impact of different network environments on signal strength, we ran some applications to present a conventional network transmission behavior.Games, browsers, videos and other typical applications were selected for user experience respectively.For the second, to measure the impact of different network environments on signal strength, we ran some applications to present a conventional network transmission behavior.Games, browsers, videos and other typical applications were selected for user experience respectively.

Fig. 3. (b) The jitter of Wi-Fi signal when the smartphone was far away from AP
As shown in Fig. 3(a), when the signal was good (RSSI between -60dBm and -40dBm) and Wi-Fi was establishing connection to AP, a relatively large jitter was produced.After successful connection, RSSI signal strength got stabilized.When the smartphone was far away from the AP, as presented in Figure 3(b), the signal was bad (RSSI below -80dBm); while the network communication condition became worse.
The average power consumption over different RSSIs was obtained as in Fig. 4.  As shown in Fig. 4(top), when the signal was good (RSSI between -60dBm and -40dBm) and Wi-Fi was establishing connection to AP, a relatively large jitter was produced.After connection, RSSI signal strength got stabilized.When the smartphone was far away from the AP, as presented in Fig. 4(down), the signal was bad (RSSI below -80dBm), while the network communication condition became worse.
The average power consumption over different RSSIs was obtained as in Fig. 5.For the second, to measure the impact of different network environments on signal strength, we ran some applications to present a conventional network transmission behavior.Games, browsers, videos and other typical applications were selected for user experience respectively.As shown in Fig. 3(a), when the signal was good (RSSI between -60dBm and -40dBm) and Wi-Fi was establishing connection to AP, a relatively large jitter was produced.After successful connection, RSSI signal strength got stabilized.When the smartphone was far away from the AP, as presented in Figure 3(b), the signal was bad (RSSI below -80dBm); while the network communication condition became worse.
The average power consumption over different RSSIs was obtained as in Fig. 4.  For the second, to measure the impact of different network environments on signal strength, we ran some applications to present a conventional network transmission behavior.Games, browsers, videos and other typical applications were selected for user experience respectively.As shown in Fig. 3(a), when the signal was good (RSSI between -60dBm and -40dBm) and Wi-Fi was establishing connection to AP, a relatively large jitter was produced.After successful connection, RSSI signal strength got stabilized.When the smartphone was far away from the AP, as presented in Figure 3(b), the signal was bad (RSSI below -80dBm); while the network communication condition became worse.
The average power consumption over different RSSIs was obtained as in Fig. 4. It was concluded that: 1) at RSSI above -60dBm, the energy consumption was subject to a certain limit and independent to RSSI; 2) at RSSI between -60dBm and -80dBm, the power consumption insignificantly increased with decline in RSSI; 3) at RSSI below -80dBm, the power consumption underwent a dramatic growth.Thus, the signal strength was divided as "good", "weak" and "bad", respectively, to represent different RSSI ranges.
It was concluded that: 1) at RSSI above -60dBm, the energy consumption was subject to a certain limit and independent to RSSI; 2) at RSSI between -60dBm and -80dBm, the power consumption insignificantly increased with decline in RSSI; 3) at RSSI below -80dBm, the power consumption underwent a dramatic growth.Thus, the signal strength was divided as "good", "weak" and "bad", respectively, to represent different RSSI ranges.In previous sections, we analyzed the impacts of Wi-Fi RSSI on power consumption under different network environments.To reduce power consumption, methods were proposed based on RSSI to buffer packets for different intervals.The architecture is illustrated in Fig. 5.
The framework mainly consisted of three parts: Main_Filter, UE state control and NF Queue.The Main_Filter thread invoked the callback function in Netfilter framework [19] to buffer network packets, and executed the fork() function to create other threads.Buffered packets were controlled by NF Queue thread using Wait_Queue(), which was an internal mechanism of Linux OS used to wait for timer-based event occurrences.The UE state thread continued to track and detect the RSSI of the UE, and transferred the value of RSSI to other threads [6].
As the optimized design methods, decision tree algorithms were employed to select the best way of transmission.

Architecture Design
In previous sections, we analyzed the impacts of Wi-Fi RSSI on power consumption under different network environments.To reduce power consumption, methods were proposed based on RSSI to buffer packets for different intervals.The architecture is illustrated in Fig. 6.
It was concluded that: 1) at RSSI above -60dBm, the energy consumption was subject to a certain limit and independent to RSSI; 2) at RSSI between -60dBm and -80dBm, the power consumption insignificantly increased with decline in RSSI; 3) at RSSI below -80dBm, the power consumption underwent a dramatic growth.Thus, the signal strength was divided as "good", "weak" and "bad", respectively, to represent different RSSI ranges.In previous sections, we analyzed the impacts of Wi-Fi RSSI on power consumption under different network environments.To reduce power consumption, methods were proposed based on RSSI to buffer packets for different intervals.The architecture is illustrated in Fig. 5.
The framework mainly consisted of three parts: Main_Filter, UE state control and NF Queue.The Main_Filter thread invoked the callback function in Netfilter framework [19] to buffer network packets, and executed the fork() function to create other threads.Buffered packets were controlled by NF Queue thread using Wait_Queue(), which was an internal mechanism of Linux OS used to wait for timer-based event occurrences.The UE state thread continued to track and detect the RSSI of the UE, and transferred the value of RSSI to other threads [6].
As the optimized design methods, decision tree algorithms were employed to select the best way of transmission.

Basic op
The princip in the followin the transmissio and be norm current transm Wi-Fi network status was we next status wa 'good-weak(2) jitter of Wi-Fi next status wa 'good-weak(2) 'normal->line to the situation the router. of Linux OS used to wait for timer-based event occurrences.The UE state thread continued to track and detect the RSSI of the UE, and transferred the value of RSSI to other threads [6].
As the optimized design methods, decision tree algorithms were employed to select the best way of transmission.

Decision Tree building
Specifically, the signal strength was divided as "good", "weak" and "bad".Through the decision tree, the best way to transmission (Normal/Lineral/ Exporational Transmission) was selected on basis of previous and current signal strengths.The basic strategies for optimization were presented first.Then, impurity function was applied to construction of the decision tree.
Basic optimization operation Using Decision Tree.The principle of the optimization framework is described in the followings(Fig.7).When the signal is weak or bad, the transmission will be delayed under weak or bad signal, and be normal under good signal.For instance, when current transmission was normal, then previous status of Wi-Fi network was good (path-1 or path-4); and if current status was weak, then current path would be path-2.If the next status was good, then the total sequence of status was 'good-weak(2)-good(4)'.This situation was similar to the jitter of Wi-Fi in a place without being moved.When the next status was bad and the total sequence of status was 'good-weak(2)bad(6)', the Wi-Fi would be transmitted by 'normal->liner delay->exponential delay'.This was similar to the situation when someone gradually got far away from the router.e -60dBm, the rtain limit and -60dBm andantly increased Bm, the power hus, the signal " and "bad", es.
rent RSSIs pacts of Wi-Fi ferent network , methods were ts for different .5. three parts: Queue.The k function in k packets, and other threads.ue thread using anism of Linux rences.The UE he RSSI of the r threads [6].decision tree best way of sm

Decision Tree building
Specifically, the signal strength was divided as "good", "weak" and "bad".Through the decision tree, the best way to transmission (Normal/Lineral/ Exporational Transmission) was selected on basis of previous and current signal strengths.The basic strategies for optimization were presented first.Then, impurity function was applied to construction of the decision tree.

Basic optimization operation Using Decision Tree
The principle of the optimization framework is described in the followings(Fig.6).When the signal is weak or bad, the transmission will be delayed under weak or bad signal, and be normal under good signal.For instance, when current transmission was normal, then previous status of Wi-Fi network was good (path-1 or path-4); and if current status was weak, then current path would be path-2.If the next status was good, then the total sequence of status was 'good-weak(2)-good(4)'.This situation was similar to the jitter of Wi-Fi in a place without being moved.When the next status was bad and the total sequence of status was 'good-weak(2)-bad(6)', the Wi-Fi would be transmitted by 'normal->liner delay->exponential delay'.This was similar to the situation when someone gradually got far away from the router.

Implementation of Decision Tree Classification
To build the decision tree, we evaluated the different attributes using information gain theory.The greater the information gain value, the greater the purity of information obtained by partitioning with such attributes.Specifically, mainly the entropy schemes were considered in this research.
The Entropy(D) was defined as:: Where n represents the number of the data set; Pk represents the proportion of k classes in the data set.
The information gain of Gain(D,a) was defined as:

Implementation of Decision Tree Classification.
To build the decision tree, we evaluated the different attributes using information gain theory.The greater the information gain value, the greater the purity of information obtained by partitioning with such attributes.Specifically, mainly the entropy schemes were considered in this research.
The Entropy(D) was defined as: Where n represents the number of the data set; Pk represents the proportion of k classes in the data set.
The information gain of Gain(D,a) was defined as: The Gini(D) was defined as: The information gain of Gini_index(D, a) was defined as: The information gain of Gini_index(D, a) was defined as: Gain(D, "OLD_T RAN ") = Entropy(D)− The experimental data from Table 2 were utilized to illustrate the process of building the decision tree.For explanation, OLD_TRAN was adopted to describe the transmission mode of the last transmission.NOW_STATUS represents the current Wi-Fiąŕs RSSI status; NOW_TRAN stands for the current transmission mode.
For example, the attribute "OLD_TRAN" had three values of NT, LT, ET when used to divide the decision node.At first, its three branch nodes were obtained: • D 1 (OLD_TRAN=NT), it includes 30 samples (13 for NT, 10 for LT, 7 for ET) ; • D 2 (OLD_TRAN=LT), it includes 30 samples(10 for NT, 6 for LT, 14 for ET) ; • D 3 (OLD_TRAN=ET), it includes 30 samples(0 for NT, 15 for LT, 15 for ET) ; Then, the information entropy was calculated respectively:  The information gains of attribute 'OLD_TRAN' and 'NOW_STATUS' were computed as: The attribute 'NOW_STATUS' partition was found better than the partition of 'OLD_TRAN'.Finally, the decision tree was obtained as shown in Fig. 8.The information gains of attribute 'OLD_TRAN' and 'NOW_STATUS' were computed as: The attribute 'NOW_STATUS' partition was found better than the partition of 'OLD_TRAN'.Finally, the decision tree was obtained as shown in Fig. 7.

Implementation of delay-transmission mechanism
Signal strength imposes impacts on the power consumption of Wi-Fi components in many ways.The experimental results demonstrated that power consumption varied when the same application was running under different network environments.The power consumption by good signal strength was found 20% lower than weak signal strength and 50% lower than bad signal strength (Fig. 4).Most importantly, under the bad network environment, the smartphone led to delay in data reception and prolongation of the duration of awake mode.Thus, an energy optimization mechanism based on RSSI-awareness was put forward for Wi-Fi network.This mechanism was able to determine whether the current Wi-Fi RSSI was good, weak Signal strength imposes impacts on the power consumption of Wi-Fi components in many ways.The experimental results demonstrated that power consumption varied when the same application was running under different network environments.The power consumption by good signal strength was found 20% lower than weak signal strength and 50% lower than bad signal strength (Fig. 5).Most importantly, under the bad network environment, the smartphone led to delay in data reception and prolongation of the duration of awake mode.Thus, an energy optimization mechanism based on RSSI-awareness was put forward for Wi-Fi network.This mechanism was able to determine whether the current Wi-Fi RSSI was good, weak or bad, and to identify delayed-transmit packets for different intervals.
For the underlying implementation, based on the decision tree and combination with the original IEEE 802.11Power Save mechanism, mainly three parameters (Listen Interval, Timeout, TX delay) of Wi-Fi components were adjusted to achieve delayed transmission.

• Listen Interval
The listen interval parameter specifies a number of beacon intervals.These intervals can pass from a time that a beacon frame is listened by the wireless client device from the access point before a next beacon frame is listened (shown in Fig. 9).The value of listen interval defined in WL1271 chipset ranges from 0 to 255 and can be configured through the Wi-Fi driver interface.With the good signal strength, in order to improve the response capability of the application, the listen Interval was set to a small value.With the weak signal strength, the listen interval was properly increased linearly.Similarly, listen interval was adjusted in more aggressive growth for bad signal strength exponentially.client device listens for a beacon frame from the access point before the wireless client device listens for a next beacon frame from the access point(shown in Figure 6).The value of listen interval defined in WL1271 chipset ranges from 0 to 255and can be configured through the WiFi driver interface.With the good signal strength, in order to improve the response capability of the application,we can set the listen Interval to a smaller value.With the weak signal strength,we can properly increase the listen interval and set it to linearly grow up.Similarly, we can adjust Listen Interval in more aggressive growth for bad signal strength.Therefore, we set the value of listen interval is in exponential growth when signal strength is bad.

Fig. 6. The implementation of delay transmission using Listen Interval
Pseudocode: The corresponding communication flow of mobile network communication is that,first the smartphone sends  The corresponding communication flow of mobile network communication is described as follows.First the smartphone sends a request to AP, which forwards the request packets to the server.After processing the request, the server immediately returns the response data to the smartphone.Many experiments were carried out to measure the Round Trip Time (RTT) under different network environments.As shown by Experimental Cumulative Distribution Function (CDF) in Fig. 10, the response returned to the smartphone within 100 ms.

ig. 9 The experimental CDF of RTT
In the IEEE 802.11PS mode, the parameter timeout efers to a passed time without traffic before the CA mode witches to the PS mode.As described in section 2, when a equest is sent, the response data usually arrive within 00ms.Therefore timeout was set as 100ms.In this case, all he response data could be received without the need to turn o the PS mode.The periodic wake-up time increased or ecreased as appropriate after 100ms to some extent.The imeout was then set 100ms for the three RSSI conditions, o that after a request, it could quickly receive response data nd avoid "tail power".

seudocode:
When data transmission is completed 18.
queue_delayed_work_filter(rx_streaming_disabled,100ms); // shut down in 100ms In the IEEE 802.11PS mode, the parameter timeout refers to a passed time without traffic before the CA mode switches to the PS mode.As described in section 2, when a request is sent, the response data usually arrive within 100ms.Therefore timeout was set as 100ms.In this case, all the response data could be received without the need to turn to the PS mode.The periodic wake-up time increased or decreased as appropriate after 100ms to some extent.The Timeout was then set 100ms for the three RSSI conditions, so that after a request, it could quickly receive response data and avoid ąřtail powerąś.

Evaluation
To verify the power consumption improvement of the proposed mechanism, we performed the mechanism on OMAP4 Pandaboard ES platform.A number of experiments and tests were also conducted in different environments.Results showed that the improved mechanism contributed to effective reduction in power consumption under weak or bad signal strength, as well as better user experience under good signal strength.

experimental methods
During verification, different RSSI ranges were obtained through adjustment of the distance from mobile client to AP.To download large and small files in the case of RSSI being constantly changing, the proposed mechanism slowed down or accelerated network transmission speed to save energy consumption and improve user experience.Furthermore, an App was designed for statistical analysis on the energy consumption of different hardware components (CPU/Wi-Fi/Bluetooth/...) in smartphones.The power consumption of Wi-Fi was calculated with a power model.All statistical data were displayed in the interface.The power consumption in wireless network interface card (NIC) was calculated via the power consumption model proposed by Ning Ding of Purdue University [5]: E total = P tx × T tx + P rx × T rx + P active × T active + P tail × T tail Where P tx is unit power consumption on packets transmission; T tx is the time used in transmission; P active is the power spent on active mode when there is no data transfer; P tail is the tail power, put simply, equal P active .P rx and T rx , as mentioned above, describe the power consumption of the receiving process.The power consumption was calculated under four states.The time and basic power consumption of the model at each state were analyzed, and the power consumption of each state was obtained by the product of the two data.The power consumption of the unit through the corresponding hardware datasheet was obtained as show in table 3.

experimental results
Lots of performance evaluation experiments were carried out for comparison of the proposed and original mechanisms.Different types of applications (news/video/ games /..., etc.) representing various behaviors of network communication were tested.
To verify the power consumption improvement of the proposed mechanism, we performed the mechanism on OMAP4 Pandaboard ES platform.A number of experiments and tests were also conducted in different environments.Results showed that the improved mechanism contributed to effective reduction in power consumption under weak or bad signal strength, as well as better user experience under good signal strength.

experimental methods
During verification, different RSSI ranges were obtained through adjustment of the distance from mobile client to AP.To download large and small files in the case of RSSI being constantly changing, the proposed mechanism slowed down or accelerated network transmission speed to save energy consumption and improve user experience.Furthermore, an App was designed for statistical analysis on the energy consumption of different hardware components (CPU/Wi-Fi/Bluetooth/...) in smartphones.The power consumption of Wi-Fi was calculated with a power model.All statistical data were displayed in the interface.The power consumption in wireless network interface card (NIC) was calculated via the power consumption model proposed by Ning Ding of Purdue University [5]: Where tx P is unit power consumption on packets transmission; tx T is the time used in transmission; active P is the power spent on active mode when there is no data transfer; tail P is the tail power, put simply, equal to active P .
rx P and rx T , as mentioned above, describe the power consumption of the receiving process.The power consumption was calculated under four states.The time and basic power consumption of the model at each state were analyzed, and the power consumption of each state was obtained by the product of the two data.The power consumption of the unit through the corresponding hardware datasheet was obtained as show in table 3.

experimental results
Lots of performance evaluation experiments were carried out for comparison of the proposed and original mechanisms.Different types of applications (news/video/ games /..., etc.) representing various behaviors of network consumption was compared.The proposed mechanism was found to save 6.42% of the power consumption after the video playback finished.As seen in Fig. 10, power optimization mechanism achieved better performance for Wechat and Google chrome, because of a great deal of background data in such application.Specifically, the proposed mechanism reduced 13.64% energy consumption for the Wechat.In sum, our optimization mechanism performed better on background application than on foreground application.

Fig. 10. The comparison of Power Consumption for different Apps
In addition, the delayed transmission effect on latencies for packets was tested.The experiment was carried out by running App under different network environments.As shown in Fig. 11, the proposed mechanism consumed 4.64% of total time more than original mechanism for Youku.Specifically, it took 1.392 seconds more time compared with the original mechanism when playing the Angry Bird.More accurately, the proposed mechanism imposed greater influence on background packets (Chrome/ Wechat, etc.) than foreground packets (Skype/ Youku, etc.).This paper analyzed the impacts of Wi-Fi RSSI on power consumption.The environment of wireless network has an impact on power consumption.The signal strength was classified as good, weak and bad.Under different signal strength conditions, the proposed mechanism aggregated packets and delayed transmission through prolonging the duration of smartphones stay in PS mode.Although the power consumption could be optimized by RSSI-awareness, there is no further distinction in task importance.For example, in the background, there are still some urgent tasks that need to be dealt with immediately (playing music /downloading file etc.).This could be optimized through the distinction between task behaviors more finely.For one experiment, an online video was played through the platform of Youku, and power consumption was compared.The proposed was found to save 6.42% of the power consumption after the video playback finished.As seen in Fig. 11, power optimization mechanism achieved better performance for Wechat and Google chrome, because of a great deal of background data in such application.Specifically, the proposed mechanism reduced 13.64% energy consumption for the Wechat.In sum, our optimization mechanism performed better on background application than on foreground application.

Evaluation
To verify the power consumption improvement of the proposed mechanism, we performed the mechanism on OMAP4 Pandaboard ES platform.A number of experiments and tests were also conducted in different environments.Results showed that the improved mechanism contributed to effective reduction in power consumption under weak or bad signal strength, as well as better user experience under good signal strength.

experimental methods
During verification, different RSSI ranges were obtained through adjustment of the distance from mobile client to AP.To download large and small files in the case of RSSI being constantly changing, the proposed mechanism slowed down or accelerated network transmission speed to save energy consumption and improve user experience.Furthermore, an App was designed for statistical analysis on the energy consumption of different hardware components (CPU/Wi-Fi/Bluetooth/...) in smartphones.The power consumption of Wi-Fi was calculated with a power model.All statistical data were displayed in the interface.The power consumption in wireless network interface card (NIC) was calculated via the power consumption model proposed by Ning Ding of Purdue University [5]: Where tx P is unit power consumption on packets transmission; tx T is the time used in transmission; active P is the power spent on active mode when there is no data transfer; tail P is the tail power, put simply, equal to active P .
rx P and rx T , as mentioned above, describe the power consumption of the receiving process.The power consumption was calculated under four states.The time and basic power consumption of the model at each state were analyzed, and the power consumption of each state was obtained by the product of the two data.The power consumption of the unit through the corresponding hardware datasheet was obtained as show in table 3.

experimental results
Lots of performance evaluation experiments were carried out for comparison of the proposed and original mechanisms.Different types of applications (news/video/ games /..., etc.) representing various behaviors of network communication were tested.For one experiment, an online video was played through the platform of Youku, and power consumption was compared.The proposed mechanism was found to save 6.42% of the power consumption after the video playback finished.As seen in Fig. 10, power optimization mechanism achieved better performance for Wechat and Google chrome, because of a great deal of background data in such application.Specifically, the proposed mechanism reduced 13.64% energy consumption for the Wechat.In sum, our optimization mechanism performed better on background application than on foreground application.In addition, the delayed transmission effect on latencies for packets was tested.The experiment was carried out by running App under different network environments.As shown in Fig. 11, the proposed mechanism consumed 4.64% of total time more than original mechanism for Youku.Specifically, it took 1.392 seconds more time compared with the original mechanism when playing the Angry Bird.More accurately, the proposed mechanism imposed greater influence on background packets (Chrome/ Wechat, etc.) than foreground packets (Skype/ Youku, etc.).This paper analyzed the impacts of Wi-Fi RSSI on power consumption.The environment of wireless network has an impact on power consumption.The signal strength was classified as good, weak and bad.Under different signal strength conditions, the proposed mechanism aggregated packets and delayed transmission through prolonging the duration of smartphones stay in PS mode.Although the power consumption could be optimized by RSSI-awareness, there is no further distinction in task importance.For example, in the background, there are still some urgent tasks that need to be dealt with immediately (playing music /downloading file etc.).This could be optimized through the distinction between task behaviors more finely.In addition, the delayed transmission effect on latencies for packets was tested.The experiment was carried out by running App under different network environments.As shown in Fig. 12, the proposed mechanism consumed 4.64% of total time more than original mechanism for Youku.Specifically, it took 1.392 seconds more time compared with the original mechanism when playing the Angry Bird.More accurately, the proposed mechanism imposed greater influence on background packets (Chrome/ Wechat, etc.) than foreground packets (Skype/ Youku, etc.).

Conclusion
This paper analyzed the impacts of Wi-Fi RSSI on power consumption.The environment of wireless network has an impact on power consumption.The signal strength was classified as good, weak and bad.Under different signal strength conditions, the proposed mechanism aggregated packets and delayed transmission through prolonging the duration of smartphones stay in PS mode.Although the power consumption could be optimized by RSSI-awareness, there is no further distinction in task importance.For example, in the background, there are still some urgent tasks that need to be dealt with immediately (playing music /downloading file etc.).This could be optimized through the distinction between task behaviors more finely.

Figure 3 .
Figure 3. Network transmission behavior impact on suspend/resume mode switch

Fig. 3 .
Fig. 3. (a) The jitter of Wi-Fi signal when the smartphone was near to the AP

Fig. 3 .
Fig. 3. (b) The jitter of Wi-Fi signal when the smartphone was far away from AP

Fig. 3 .
Fig. 3. (a) The jitter of Wi-Fi signal when the smartphone was near to the AP

Fig. 3 .
Fig. 3. (b) The jitter of Wi-Fi signal when the smartphone was far away from AP

Figure 4 .
Figure 4. (Top) The jitter of Wi-Fi signal when the smartphone was near to the AP; (Down)The jitter of Wi-Fi signal when the smartphone was far away from AP

Fig. 5 .
Fig. 5.The framework of the optimization mechanism

Fig. 5 .
Fig. 5.The framework of the optimization mechanism

Fig. 6 Figure 6 .
Fig. 6.The Deci4.1.2ImplemeTo build th attributes usin information ga obtained by p mainly the ent The Entropy Entropy

Fig. 6 .
Fig. 6.The Decision Tree of the framework

Figure 7 .
Figure 7.The Decision Tree of the framework , "N OW _ST AT U S") = Entropy(D)−

5 Power
Optimization of WiFi Networks based on RSSI-awareness EAI Endorsed Transactions on Mobile Communications and Applications les(13 for NT, les(10 for NT, les(0 for NT, Then, the information entropy was calculated respectively:

Fig. 7 .
Fig. 7.The decision tree obtained from the experiment

Figure 8 .
Figure 8.The decision tree obtained from the experiment

Figure 9 .
Figure 9.The implementation of delay transmission using Listen Interval

Figure 10 .
Figure 10.The experimental CDF of RTT

Algorithm 2 7 Power
when data transmission is completed queue_work_filter(rx_streaming_enabled); queue_delayed_work_filter(rx_streaming_disabled, 100ms); queue_work_filter(wl1271_sleep); In the IEEE 802.11PS mode, TX_Delay represents the delay time before data is sent.In other words, it is the expression of the gathered packets to send.Buffer for sending packets in the Wi-Fi network prolongs the time of the PS mode.The prolonged time in PS mode leads to significant reduction in power consumption.Based on different RSSIs, the proposed mechanism was optimized by setting TX_Delay to various empirical values (0s/3s/5s), thereby simulating the real network environment.Algorithm 3 when data transfer is completed define BG_CACHED_TIME(3*HZ) define SLEEP_CACHED_TIME(5*HZ) if activity_stat < 60 then queue_delay_work(tx_work, 0); next_send_time = 0; else if activity_stat > 60 and activity_stat < 80 then queue_delayed_workOptimization of WiFi Networks based on RSSI-awareness EAI Endorsed Transactions on Mobile Communications and Applications 01 2019 | Volume 5 | Issue 16 | e1

Fig. 11 .
Fig. 11.The comparison of transmission delay before and after use of optimization mechanism

Figure 11 .
Figure 11.The comparison of Power Consumption for different Apps

Fig. 10 .
Fig. 10.The comparison of Power Consumption for different Apps

Fig. 11 .
Fig. 11.The comparison of transmission delay before and after use of optimization mechanism

Figure 12 .
Figure 12.The comparison of transmission delay before and after use of optimization mechanism

Table 1 Static
under different network environments RSSI quality Signal Good Above -60 dBm weak Between -60 and -80dBm Bad Below -80 dBm

Table 1 .
Statistics for different network environments