Skip to content

Fix error in voltages field#96

Merged
vchrisb merged 3 commits into
fsantini:masterfrom
eikowagenknecht:dcbvoltages
Oct 17, 2023
Merged

Fix error in voltages field#96
vchrisb merged 3 commits into
fsantini:masterfrom
eikowagenknecht:dcbvoltages

Conversation

@eikowagenknecht

Copy link
Copy Markdown
Contributor

Unfortunately in #86 there was a small problem that led to the "voltages" field containing an error message instead of being empty. This renames the problematic variables so it's clearer what the code does and the voltages object stays empty.

Old:

    "dcbs": {
      "0": {
        "current": null,
        "currentAvg30s": -0.4657486081123352,
        "cycleCount": null,
        "designCapacity": null,
        "designVoltage": null,
        "deviceName": null,
        "endOfDischarge": null,
        "error": null,
        "fullChargeCapacity": null,
        "fwVersion": null,
        "manufactureDate": null,
        "manufactureName": null,
        "maxChargeCurrent": null,
        "maxChargeTemperature": null,
        "maxChargeVoltage": null,
        "maxDischargeCurrent": null,
        "minChargeTemperature": null,
        "parallelCellCount": null,
        "sensorCount": 0,
        "seriesCellCount": 0,
        "pcbVersion": null,
        "protocolVersion": null,
        "remainingCapacity": null,
        "serialCode": null,
        "serialNo": null,
        "soc": null,
        "soh": null,
        "status": null,
        "temperatures": [],
        "voltage": null,
        "voltageAvg30s": 392.5743408203125,
        "voltages": [
          "BAT_DCB_ALL_CELL_VOLTAGES",
          "Error",
          "RSCP_ERR_OUT_OF_BOUNDS"
        ],
        "warning": null
      }
    },

New:

  "dcbs": {
    "0": {
      "current": null,
      "currentAvg30s": -0.5459553003311157,
      "cycleCount": null,
      "designCapacity": null,
      "designVoltage": null,
      "deviceName": null,
      "endOfDischarge": null,
      "error": null,
      "fullChargeCapacity": null,
      "fwVersion": null,
      "manufactureDate": null,
      "manufactureName": null,
      "maxChargeCurrent": null,
      "maxChargeTemperature": null,
      "maxChargeVoltage": null,
      "maxDischargeCurrent": null,
      "minChargeTemperature": null,
      "parallelCellCount": null,
      "sensorCount": 0,
      "seriesCellCount": 0,
      "pcbVersion": null,
      "protocolVersion": null,
      "remainingCapacity": null,
      "serialCode": null,
      "serialNo": null,
      "soc": null,
      "soh": null,
      "status": null,
      "temperatures": [],
      "voltage": null,
      "voltageAvg30s": 392.34014892578125,
      "voltages": [],
      "warning": null
    }
  },

Signed-off-by: Eiko Wagenknecht <git@eiko-wagenknecht.de>
@vchrisb

vchrisb commented Oct 16, 2023

Copy link
Copy Markdown
Collaborator

PR needs to be updated.

@eikowagenknecht

Copy link
Copy Markdown
Contributor Author

@vchrisb done

@vchrisb vchrisb merged commit d03b026 into fsantini:master Oct 17, 2023
@eikowagenknecht eikowagenknecht deleted the dcbvoltages branch October 24, 2023 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants