added extendedsmartmeter interface

master
bernhard.trinnes 2020-07-21 10:05:43 +02:00
parent a0fb2000de
commit 4d3633e3eb
4 changed files with 9 additions and 9 deletions

View File

@ -125,7 +125,7 @@ void IntegrationPluginSolarLog::getData(Thing *thing)
QVariantMap map = data.toVariant().toMap().value("801").toMap().value("170").toMap();
thing->setStateValue(solarlogLastupdateStateTypeId, map.value(QString::number(JsonObjectNumbers::LastUpdateTime)));
thing->setStateValue(solarlogPacStateTypeId, (map.value(QString::number(JsonObjectNumbers::Pac)).toDouble()/1000.00));
thing->setStateValue(solarlogTotalPowerEventTypeId, (map.value(QString::number(JsonObjectNumbers::Pac)).toDouble()/1000.00));
thing->setStateValue(solarlogPdcStateTypeId, (map.value(QString::number(JsonObjectNumbers::Pdc)).toDouble()/1000.00));
thing->setStateValue(solarlogUacStateTypeId, map.value(QString::number(JsonObjectNumbers::Uac)));
thing->setStateValue(solarlogDcVoltageStateTypeId, map.value(QString::number(JsonObjectNumbers::DCVoltage)));
@ -133,7 +133,7 @@ void IntegrationPluginSolarLog::getData(Thing *thing)
thing->setStateValue(solarlogYieldYesterdayStateTypeId, (map.value(QString::number(JsonObjectNumbers::YieldYesterday)).toDouble()/1000.00));
thing->setStateValue(solarlogYieldMonthStateTypeId, (map.value(QString::number(JsonObjectNumbers::YieldMonth)).toDouble()/1000.00));
thing->setStateValue(solarlogYieldYearStateTypeId, (map.value(QString::number(JsonObjectNumbers::YieldYear)).toDouble()/1000.00));
thing->setStateValue(solarlogYieldTotalStateTypeId, (map.value(QString::number(JsonObjectNumbers::YieldTotal)).toDouble()/1000.00));
thing->setStateValue(solarlogTotalEnergyProducedStateTypeId, (map.value(QString::number(JsonObjectNumbers::YieldTotal)).toDouble()/1000.00));
thing->setStateValue(solarlogCurrentTotalConsumptionStateTypeId, map.value(QString::number(JsonObjectNumbers::ConsPac)));
thing->setStateValue(solarlogConsYieldDayStateTypeId, map.value(QString::number(JsonObjectNumbers::ConsYieldDay)));
thing->setStateValue(solarlogConsYieldYesterdayStateTypeId, map.value(QString::number(JsonObjectNumbers::ConsYieldYesterday)));

View File

@ -13,7 +13,7 @@
"name": "solarlog",
"displayName": "Solar-Log",
"createMethods": [ "user", "discovery" ],
"interfaces": [ "connectable" ],
"interfaces": ["extendedsmartmeterproducer", "connectable" ],
"paramTypes": [
{
"id": "84bd8a41-2411-4bb0-87a9-ab7e01044b10",
@ -44,7 +44,7 @@
},
{
"id": "0bf515d8-0f48-4eba-9255-f774d68c80fe",
"name": "pac",
"name": "currentPower",
"displayName": "Power AC",
"displayNameEvent": "Power AC changed",
"type": "double",
@ -116,7 +116,7 @@
},
{
"id": "3afb6ea1-fef8-4c17-8307-c7547a7a6f3c",
"name": "yieldTotal",
"name": "totalEnergyProduced",
"displayName": "Yield total",
"displayNameEvent": "Yield total changed",
"type": "double",

View File

@ -188,7 +188,7 @@ The name of the StateType ({5d6d5ba5-ebc3-42ce-9d08-802da694b4da}) of ThingClass
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="171"/>
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="174"/>
<source>Power AC</source>
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: pac, ID: {0bf515d8-0f48-4eba-9255-f774d68c80fe})
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: currentPower, ID: {0bf515d8-0f48-4eba-9255-f774d68c80fe})
----------
The name of the StateType ({0bf515d8-0f48-4eba-9255-f774d68c80fe}) of ThingClass solarlog</extracomment>
<translation>Leistung AC</translation>
@ -263,7 +263,7 @@ The name of the StateType ({9a77662a-2034-4031-8e7a-1e6347089d97}) of ThingClass
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="225"/>
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="228"/>
<source>Yield total</source>
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: yieldTotal, ID: {3afb6ea1-fef8-4c17-8307-c7547a7a6f3c})
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: totalEnergyProduced, ID: {3afb6ea1-fef8-4c17-8307-c7547a7a6f3c})
----------
The name of the StateType ({3afb6ea1-fef8-4c17-8307-c7547a7a6f3c}) of ThingClass solarlog</extracomment>
<translation>Totalertrag</translation>

View File

@ -188,7 +188,7 @@ The name of the StateType ({5d6d5ba5-ebc3-42ce-9d08-802da694b4da}) of ThingClass
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="171"/>
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="174"/>
<source>Power AC</source>
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: pac, ID: {0bf515d8-0f48-4eba-9255-f774d68c80fe})
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: currentPower, ID: {0bf515d8-0f48-4eba-9255-f774d68c80fe})
----------
The name of the StateType ({0bf515d8-0f48-4eba-9255-f774d68c80fe}) of ThingClass solarlog</extracomment>
<translation type="unfinished"></translation>
@ -263,7 +263,7 @@ The name of the StateType ({9a77662a-2034-4031-8e7a-1e6347089d97}) of ThingClass
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="225"/>
<location filename="../../../build-nymea-plugins-Desktop-Debug/solarlog/plugininfo.h" line="228"/>
<source>Yield total</source>
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: yieldTotal, ID: {3afb6ea1-fef8-4c17-8307-c7547a7a6f3c})
<extracomment>The name of the ParamType (ThingClass: solarlog, EventType: totalEnergyProduced, ID: {3afb6ea1-fef8-4c17-8307-c7547a7a6f3c})
----------
The name of the StateType ({3afb6ea1-fef8-4c17-8307-c7547a7a6f3c}) of ThingClass solarlog</extracomment>
<translation type="unfinished"></translation>