Skip to content

Commit

Permalink
NetworkIOMeter: remove code for auto-updating "total"
Browse files Browse the repository at this point in the history
  • Loading branch information
Explorer09 committed May 17, 2024
1 parent 455a80e commit 954080b
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions NetworkIOMeter.c
Original file line number Diff line number Diff line change
Expand Up @@ -111,9 +111,6 @@ static void NetworkIOMeter_updateValues(Meter* this) {

this->values[0] = cached_rxb_diff;
this->values[1] = cached_txb_diff;
if (cached_rxb_diff + cached_txb_diff > this->total) {
this->total = cached_rxb_diff + cached_txb_diff;
}

if (status == RATESTATUS_NODATA) {
xSnprintf(this->txtBuffer, sizeof(this->txtBuffer), "no data");
Expand Down Expand Up @@ -172,7 +169,7 @@ const MeterClass NetworkIOMeter_class = {
.supportedModes = METERMODE_DEFAULT_SUPPORTED,
.maxItems = 2,
.isPercentChart = false,
.total = 100.0,
.total = 1.0,
.attributes = NetworkIOMeter_attributes,
.name = "NetworkIO",
.uiName = "Network IO",
Expand Down

0 comments on commit 954080b

Please sign in to comment.