m***@gmail.com
2018-12-04 15:58:00 UTC
m_switchToOffEvent is a private member variable of the WifiRadioEnergyModel
class, which has the task of maintaining the state-to-off event.
Each state change in the physical layer is notified to the
WifiRadioEnergyModel class through the WifiRadioEnergyModelPhyListener
class, and then the WifiRadioEnergyModel class calculates the maximum time
that it can continuously continue to operate in that state based on the
remaining energy, and then a change-to-off event in That time is scheduled.
Clearly, for each state change, the previous event maintained in the
m_switchToOffEvent should be canceled and a new event calculated based on
the new state should be scheduled and stored in m_switchToOffEvent.
The main bug is that despite canceling previous events when storing a new
event in the m_switchToOffEvent, the previous events are not canceled and
invoke at their specified time.
The invoking of those events, which should actually be canceled, has
significant consequences, such as inaccurate calculation of total energy
consumption and remaining energy, because, regardless of the network
conditions, the very first change of state, which is a change from IDLE to
TX, leads to early OFF. It's like every device stays in the TX state after
its first change until it turns off.
There are other consequences that not need to be mentioned.
These problems are clear by tracing and testing the wifi-sleep simple
example.
This is not a new bug, and it has been reported both personally and by
others (https://www.nsnam.org/bugzilla/show_bug.cgi?id=2987), but the
developer has not responded. I personally tried to fix this, but
unfortunately, I have not yet come up with the result and I decided to
share with you details so that if someone is trying to help fix this bug.
best regards
class, which has the task of maintaining the state-to-off event.
Each state change in the physical layer is notified to the
WifiRadioEnergyModel class through the WifiRadioEnergyModelPhyListener
class, and then the WifiRadioEnergyModel class calculates the maximum time
that it can continuously continue to operate in that state based on the
remaining energy, and then a change-to-off event in That time is scheduled.
Clearly, for each state change, the previous event maintained in the
m_switchToOffEvent should be canceled and a new event calculated based on
the new state should be scheduled and stored in m_switchToOffEvent.
The main bug is that despite canceling previous events when storing a new
event in the m_switchToOffEvent, the previous events are not canceled and
invoke at their specified time.
The invoking of those events, which should actually be canceled, has
significant consequences, such as inaccurate calculation of total energy
consumption and remaining energy, because, regardless of the network
conditions, the very first change of state, which is a change from IDLE to
TX, leads to early OFF. It's like every device stays in the TX state after
its first change until it turns off.
There are other consequences that not need to be mentioned.
These problems are clear by tracing and testing the wifi-sleep simple
example.
This is not a new bug, and it has been reported both personally and by
others (https://www.nsnam.org/bugzilla/show_bug.cgi?id=2987), but the
developer has not responded. I personally tried to fix this, but
unfortunately, I have not yet come up with the result and I decided to
share with you details so that if someone is trying to help fix this bug.
best regards
--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+***@googlegroups.com.
To post to this group, send email to ns-3-***@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+***@googlegroups.com.
To post to this group, send email to ns-3-***@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.