Merge PR #382: Simulation: EV Charger update interface

master
Jenkins nymea 2021-02-26 10:27:59 +01:00
commit 72f97880ce
2 changed files with 7 additions and 7 deletions

View File

@ -248,7 +248,7 @@ void IntegrationPluginSimulation::executeAction(ThingActionInfo *info)
} else if(action.actionTypeId() == evChargerMaxChargingCurrentActionTypeId){
// get the param value
Param maxChargeParam = action.param(evChargerMaxChargingCurrentActionMaxChargingCurrentParamTypeId);
uint maxCharge = maxChargeParam.value().toInt();
double maxCharge = maxChargeParam.value().toDouble();
qCDebug(dcSimulation()) << "Set maximum charging current to" << maxCharge << "for EV Charger device" << thing->name();
thing->setStateValue(evChargerMaxChargingCurrentStateTypeId, maxCharge);
return info->finish(Thing::ThingErrorNoError);

View File

@ -204,7 +204,7 @@
"name": "evCharger",
"displayName": "EV Charging Station",
"createMethods": ["user"],
"interfaces": ["extendedevcharger"],
"interfaces": ["evcharger"],
"paramTypes": [ ],
"stateTypes": [
{
@ -223,11 +223,11 @@
"displayName": "Maximum charging current",
"displayNameEvent": "MAximum charging current changed",
"displayNameAction": "Set maximum charging current",
"type": "uint",
"unit": "MilliAmpere",
"defaultValue": 0,
"minValue": 6000,
"maxValue": 80000,
"type": "double",
"unit": "Ampere",
"defaultValue": 6,
"minValue": 6,
"maxValue": 80,
"writable": true
}
]