Skip to content

Commit

Permalink
Expose max_current through MQTT
Browse files Browse the repository at this point in the history
  • Loading branch information
mathieucarbou committed May 6, 2023
1 parent 8af3b17 commit 55e9667
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/input.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ class InputTask : public MicroTasks::Task
event["vehicle"] = evse.isVehicleConnected() ? 1 : 0;
event["colour"] = evse.getStateColour();
event["pilot"] = evse.getChargeCurrent();
event["max_current"] = evse.getMaxCurrent();
event["manual_override"] = manual.isActive() ? 1 : 0; //TODO: remove this
event["status"] = evse.getState().toString();
event["elapsed"] = evse.getSessionElapsed();
Expand Down Expand Up @@ -104,6 +105,7 @@ void create_rapi_json(JsonDocument &doc)
doc["voltage"] = evse.getVoltage() * VOLTS_SCALE_FACTOR;
doc["power"] = evse.getPower() * POWER_SCALE_FACTOR;
doc["pilot"] = evse.getChargeCurrent();
doc["max_current"] = evse.getMaxCurrent();
if(evse.isTemperatureValid(EVSE_MONITOR_TEMP_MONITOR)) {
doc["temp"] = evse.getTemperature(EVSE_MONITOR_TEMP_MONITOR) * TEMP_SCALE_FACTOR;
} else {
Expand Down

0 comments on commit 55e9667

Please sign in to comment.