iobroker.amtronwallbox 0.2.4 → 0.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/io-package.json +14 -1
- package/main.js +334 -162
- package/package.json +7 -7
package/README.md
CHANGED
package/io-package.json
CHANGED
|
@@ -1,8 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "amtronwallbox",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.5",
|
|
5
5
|
"news": {
|
|
6
|
+
"0.2.5": {
|
|
7
|
+
"en": "smaller bug fixes",
|
|
8
|
+
"de": "kleinere Fehlerbehebungen",
|
|
9
|
+
"ru": "мелкие исправления ошибок",
|
|
10
|
+
"pt": "correções de bugs menores",
|
|
11
|
+
"nl": "kleinere bugfixes",
|
|
12
|
+
"fr": "petites corrections de bugs",
|
|
13
|
+
"it": "correzioni di bug minori",
|
|
14
|
+
"es": "correcciones de errores más pequeñas",
|
|
15
|
+
"pl": "mniejsze poprawki błędów",
|
|
16
|
+
"uk": "менші виправлення помилок",
|
|
17
|
+
"zh-cn": "较小的错误修复"
|
|
18
|
+
},
|
|
6
19
|
"0.2.4": {
|
|
7
20
|
"en": "dependencies updated",
|
|
8
21
|
"de": "Abhängigkeiten aktualisiert",
|
package/main.js
CHANGED
|
@@ -184,11 +184,13 @@ async function read_MHCP_DevInfo(system) {
|
|
|
184
184
|
let buffer = await axios.get(sURL, header);
|
|
185
185
|
|
|
186
186
|
adapter.log.debug("got status data: " + typeof buffer.data + " " + JSON.stringify(buffer.data));
|
|
187
|
-
|
|
187
|
+
|
|
188
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
189
|
+
|
|
188
190
|
if (buffer != null && buffer.status == 200 && buffer.data != null) {
|
|
189
191
|
|
|
190
192
|
for (let entry in buffer.data) {
|
|
191
|
-
await adapter.setStateAsync(
|
|
193
|
+
await adapter.setStateAsync(SystemName + ".info." + entry, { ack: true, val: buffer.data[entry] });
|
|
192
194
|
}
|
|
193
195
|
}
|
|
194
196
|
}
|
|
@@ -218,10 +220,12 @@ async function read_MHCP_ChargeData(system) {
|
|
|
218
220
|
|
|
219
221
|
adapter.log.debug("got charge data: " + typeof buffer.data + " " + JSON.stringify(buffer.data));
|
|
220
222
|
|
|
223
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
224
|
+
|
|
221
225
|
if (buffer != null && buffer.status == 200 && buffer.data != null) {
|
|
222
226
|
|
|
223
227
|
for (let entry in buffer.data) {
|
|
224
|
-
await adapter.setStateAsync(
|
|
228
|
+
await adapter.setStateAsync(SystemName + ".charge." + entry, { ack: true, val: buffer.data[entry] });
|
|
225
229
|
}
|
|
226
230
|
}
|
|
227
231
|
}
|
|
@@ -257,10 +261,12 @@ async function read_MHCP_StatisticData(system, period) {
|
|
|
257
261
|
|
|
258
262
|
adapter.log.debug("got statistic data: " + period + " " + typeof buffer.data + " " + JSON.stringify(buffer.data));
|
|
259
263
|
|
|
264
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
265
|
+
|
|
260
266
|
if (buffer != null && buffer.status == 200 && buffer.data != null) {
|
|
261
267
|
|
|
262
268
|
if (period == "Annual") {
|
|
263
|
-
await adapter.setStateAsync(
|
|
269
|
+
await adapter.setStateAsync(SystemName + ".Statistics." + period + ".Years", { ack: true, val: JSON.stringify(buffer.data) });
|
|
264
270
|
}
|
|
265
271
|
else {
|
|
266
272
|
for (let entry in buffer.data) {
|
|
@@ -280,7 +286,7 @@ async function read_MHCP_StatisticData(system, period) {
|
|
|
280
286
|
//do nothing
|
|
281
287
|
}
|
|
282
288
|
else {
|
|
283
|
-
await adapter.setStateAsync(
|
|
289
|
+
await adapter.setStateAsync(SystemName + ".Statistics." + period + "." + entry, { ack: true, val: buffer.data[entry] });
|
|
284
290
|
}
|
|
285
291
|
}
|
|
286
292
|
}
|
|
@@ -355,6 +361,8 @@ async function read_rest(system) {
|
|
|
355
361
|
got data status string "conn_state:no_vehicle_connected\nauth_state:not_authorized_for_charging\nauth_uid:\ntime_since_charging_start:0\nmeter_wh:16701\npower_w:0\ntransaction_wh:0\ncp_id:+49*839*00000000001\nocpp_state:available\ntype2_state:a\ntype2_proximity:cable_attached\nsig_current:0\nschuko_state:idle\nbackend_conn_state:pending\nfree_charging:off\nslave_state:\nocpp_meter_cfg:modbus_meter_nzr\nocpp_meter_serial:00202035\ncurrent_a:0.00,0.00,0.00\nenergy_man_current:0\nambient_temp:+15.00\nfirmware_ver:5.22.1-13295\ncc_serial_n:2202532503/b94060010me2\ncon_cycles_schuko:0\ncon_cycles_type2:5\nmax_current:16\nrcmb_state:okay\nrcmb_max_values: 0.0, 0.0\nrcmb_current_values: 0.0, 0.0\ncable_attached:on\nschuko_cfg:disable\nrcd_state:disable\nmcb_type2_state:disable\nmcb_schuko_state:disable\ncp_vendor:MENNEKES\nerrors:no_errors\ncp_model:CC612_2S0R_CC\ndisplay_text:"
|
|
356
362
|
*/
|
|
357
363
|
|
|
364
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
365
|
+
|
|
358
366
|
if (buffer != null && buffer.status == 200 && buffer.data != null && typeof buffer.data === "string") {
|
|
359
367
|
|
|
360
368
|
let data = buffer.data.split(/\r?\n/);
|
|
@@ -362,44 +370,44 @@ async function read_rest(system) {
|
|
|
362
370
|
adapter.log.debug("data " + JSON.stringify(data));
|
|
363
371
|
|
|
364
372
|
|
|
365
|
-
await adapter.setStateAsync(
|
|
366
|
-
await adapter.setStateAsync(
|
|
367
|
-
await adapter.setStateAsync(
|
|
368
|
-
await adapter.setStateAsync(
|
|
369
|
-
await adapter.setStateAsync(
|
|
370
|
-
await adapter.setStateAsync(
|
|
371
|
-
await adapter.setStateAsync(
|
|
372
|
-
await adapter.setStateAsync(
|
|
373
|
-
await adapter.setStateAsync(
|
|
374
|
-
await adapter.setStateAsync(
|
|
375
|
-
await adapter.setStateAsync(
|
|
376
|
-
await adapter.setStateAsync(
|
|
377
|
-
await adapter.setStateAsync(
|
|
378
|
-
await adapter.setStateAsync(
|
|
379
|
-
await adapter.setStateAsync(
|
|
380
|
-
await adapter.setStateAsync(
|
|
381
|
-
await adapter.setStateAsync(
|
|
382
|
-
await adapter.setStateAsync(
|
|
383
|
-
await adapter.setStateAsync(
|
|
384
|
-
await adapter.setStateAsync(
|
|
385
|
-
await adapter.setStateAsync(
|
|
386
|
-
await adapter.setStateAsync(
|
|
387
|
-
await adapter.setStateAsync(
|
|
388
|
-
await adapter.setStateAsync(
|
|
389
|
-
await adapter.setStateAsync(
|
|
390
|
-
await adapter.setStateAsync(
|
|
391
|
-
await adapter.setStateAsync(
|
|
392
|
-
await adapter.setStateAsync(
|
|
393
|
-
await adapter.setStateAsync(
|
|
394
|
-
await adapter.setStateAsync(
|
|
395
|
-
await adapter.setStateAsync(
|
|
396
|
-
await adapter.setStateAsync(
|
|
397
|
-
await adapter.setStateAsync(
|
|
398
|
-
await adapter.setStateAsync(
|
|
399
|
-
await adapter.setStateAsync(
|
|
400
|
-
await adapter.setStateAsync(
|
|
401
|
-
await adapter.setStateAsync(
|
|
402
|
-
await adapter.setStateAsync(
|
|
373
|
+
await adapter.setStateAsync(SystemName + ".Connection.State", { ack: true, val: data[0].split(":")[1] });
|
|
374
|
+
await adapter.setStateAsync(SystemName + ".Authorisation.State", { ack: true, val: data[1].split(":")[1] });
|
|
375
|
+
await adapter.setStateAsync(SystemName + ".Authorisation.UID", { ack: true, val: data[2].split(":")[1] });
|
|
376
|
+
await adapter.setStateAsync(SystemName + ".TimeSinceChargingStart", { ack: true, val: Number(data[3].split(":")[1]) });
|
|
377
|
+
await adapter.setStateAsync(SystemName + ".Meter", { ack: true, val: Number(data[4].split(":")[1]) });
|
|
378
|
+
await adapter.setStateAsync(SystemName + ".Power", { ack: true, val: Number(data[5].split(":")[1]) });
|
|
379
|
+
await adapter.setStateAsync(SystemName + ".Transaction", { ack: true, val: Number(data[6].split(":")[1]) });
|
|
380
|
+
await adapter.setStateAsync(SystemName + ".CP_ID", { ack: true, val: data[7].split(":")[1] });
|
|
381
|
+
await adapter.setStateAsync(SystemName + ".OCPP.State", { ack: true, val: data[8].split(":")[1] });
|
|
382
|
+
await adapter.setStateAsync(SystemName + ".Type2.State", { ack: true, val: data[9].split(":")[1] });
|
|
383
|
+
await adapter.setStateAsync(SystemName + ".Type2.Proximity", { ack: true, val: data[10].split(":")[1] });
|
|
384
|
+
await adapter.setStateAsync(SystemName + ".SigCurrent", { ack: true, val: Number(data[11].split(":")[1]) });
|
|
385
|
+
await adapter.setStateAsync(SystemName + ".Schuko.State", { ack: true, val: data[12].split(":")[1] });
|
|
386
|
+
await adapter.setStateAsync(SystemName + ".Backend.ConnectionState", { ack: true, val: data[13].split(":")[1] });
|
|
387
|
+
await adapter.setStateAsync(SystemName + ".FreeCharging", { ack: true, val: Boolean( data[14].split(":")[1]) });
|
|
388
|
+
await adapter.setStateAsync(SystemName + ".SlaveState", { ack: true, val: data[15].split(":")[1] });
|
|
389
|
+
await adapter.setStateAsync(SystemName + ".OCPP.MeterConfig", { ack: true, val: data[16].split(":")[1] });
|
|
390
|
+
await adapter.setStateAsync(SystemName + ".OCPP.MeterSerial", { ack: true, val: data[17].split(":")[1] });
|
|
391
|
+
await adapter.setStateAsync(SystemName + ".Current", { ack: true, val: Number(data[18].split(":")[1]) });
|
|
392
|
+
await adapter.setStateAsync(SystemName + ".EnergyManagerCurrent", { ack: true, val: Number(data[19].split(":")[1]) });
|
|
393
|
+
await adapter.setStateAsync(SystemName + ".AmbientTemperature", { ack: true, val: data[20].split(":")[1] });
|
|
394
|
+
await adapter.setStateAsync(SystemName + ".FirmwareVersion", { ack: true, val: data[21].split(":")[1] });
|
|
395
|
+
await adapter.setStateAsync(SystemName + ".SerialNumber", { ack: true, val: data[22].split(":")[1] });
|
|
396
|
+
await adapter.setStateAsync(SystemName + ".ContactCyclesSchuko", { ack: true, val: Number(data[23].split(":")[1]) });
|
|
397
|
+
await adapter.setStateAsync(SystemName + ".ContactcyclesType2", { ack: true, val: Number(data[24].split(":")[1]) });
|
|
398
|
+
await adapter.setStateAsync(SystemName + ".MaxCurrent", { ack: true, val: Number(data[25].split(":")[1]) });
|
|
399
|
+
await adapter.setStateAsync(SystemName + ".RCMB.State", { ack: true, val: data[26].split(":")[1] });
|
|
400
|
+
await adapter.setStateAsync(SystemName + ".RCMB.MaxValues", { ack: true, val: data[27].split(":")[1] });
|
|
401
|
+
await adapter.setStateAsync(SystemName + ".RCMB.CurrentValues", { ack: true, val: data[28].split(":")[1] });
|
|
402
|
+
await adapter.setStateAsync(SystemName + ".CableAttached", { ack: true, val: Boolean(data[29].split(":")[1]) });
|
|
403
|
+
await adapter.setStateAsync(SystemName + ".Schuko.Config", { ack: true, val: data[30].split(":")[1] });
|
|
404
|
+
await adapter.setStateAsync(SystemName + ".RCD.State", { ack: true, val: data[31].split(":")[1] });
|
|
405
|
+
await adapter.setStateAsync(SystemName + ".MCB.Type2State", { ack: true, val: data[32].split(":")[1] });
|
|
406
|
+
await adapter.setStateAsync(SystemName + ".MCB.SchukoState", { ack: true, val: data[33].split(":")[1] });
|
|
407
|
+
await adapter.setStateAsync(SystemName + ".CP_Vendor", { ack: true, val: data[34].split(":")[1] });
|
|
408
|
+
await adapter.setStateAsync(SystemName + ".Errors", { ack: true, val: data[35].split(":")[1] });
|
|
409
|
+
await adapter.setStateAsync(SystemName + ".CP_Model", { ack: true, val: data[36].split(":")[1] });
|
|
410
|
+
await adapter.setStateAsync(SystemName + ".DisplayText", { ack: true, val: data[37].split(":")[1] });
|
|
403
411
|
|
|
404
412
|
/*
|
|
405
413
|
amtronwallbox.0 2022-05-20 12:20:53.613 info State value to set for "amtronwallbox.0.Wallbox.CableAttached" has to be type "boolean" but received type "string"
|
|
@@ -470,9 +478,11 @@ async function updateInfo(id,state) {
|
|
|
470
478
|
|
|
471
479
|
let systemName = id.split(".")[2];
|
|
472
480
|
|
|
481
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
482
|
+
|
|
473
483
|
for (const system of adapter.config.WallboxSystems) {
|
|
474
484
|
|
|
475
|
-
if (
|
|
485
|
+
if (SystemName == systemName && system.IsActive) {
|
|
476
486
|
if (system.Type === "ChargeControl") {
|
|
477
487
|
|
|
478
488
|
}
|
|
@@ -495,9 +505,11 @@ async function updateCharge(id, state) {
|
|
|
495
505
|
|
|
496
506
|
let systemName = id.split(".")[2];
|
|
497
507
|
|
|
508
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
509
|
+
|
|
498
510
|
for (const system of adapter.config.WallboxSystems) {
|
|
499
511
|
|
|
500
|
-
if (
|
|
512
|
+
if (SystemName == systemName && system.IsActive) {
|
|
501
513
|
if (system.Type === "ChargeControl") {
|
|
502
514
|
|
|
503
515
|
}
|
|
@@ -603,24 +615,26 @@ function subscribeVars() {
|
|
|
603
615
|
}
|
|
604
616
|
else if (system.Type === "Xtra") {
|
|
605
617
|
|
|
618
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
619
|
+
|
|
606
620
|
//All parameters can be set to null if no change is intended.
|
|
607
621
|
//https://github.com/lephisto/amtron/blob/master/docs/api/DevInfo/post.md
|
|
608
|
-
adapter.subscribeStates(
|
|
609
|
-
adapter.subscribeStates(
|
|
610
|
-
adapter.subscribeStates(
|
|
611
|
-
adapter.subscribeStates(
|
|
612
|
-
adapter.subscribeStates(
|
|
613
|
-
adapter.subscribeStates(
|
|
614
|
-
adapter.subscribeStates(
|
|
615
|
-
adapter.subscribeStates(
|
|
622
|
+
adapter.subscribeStates(SystemName + ".info.DevName");
|
|
623
|
+
adapter.subscribeStates(SystemName + ".info.LocTime");
|
|
624
|
+
adapter.subscribeStates(SystemName + ".info.Summer");
|
|
625
|
+
adapter.subscribeStates(SystemName + ".info.Tz");
|
|
626
|
+
adapter.subscribeStates(SystemName + ".info.FixedVehCosts");
|
|
627
|
+
adapter.subscribeStates(SystemName + ".info.OldVehCosts");
|
|
628
|
+
adapter.subscribeStates(SystemName + ".info.Battery");
|
|
629
|
+
adapter.subscribeStates(SystemName + ".info.DevMode");
|
|
616
630
|
|
|
617
631
|
//All parameters except "Permanent" can be set to null if no change is intended.
|
|
618
632
|
//https://github.com/lephisto/amtron/blob/master/docs/api/ChargeData/post.md
|
|
619
|
-
//adapter.subscribeStates(
|
|
620
|
-
adapter.subscribeStates(
|
|
621
|
-
//adapter.subscribeStates(
|
|
622
|
-
adapter.subscribeStates(
|
|
623
|
-
adapter.subscribeStates(
|
|
633
|
+
//adapter.subscribeStates(SystemName + ".charge.Permanent");
|
|
634
|
+
adapter.subscribeStates(SystemName + ".charge.RemoteCurr");
|
|
635
|
+
//adapter.subscribeStates(SystemName + ".charge.AutoChg"); //gibt es den DP?
|
|
636
|
+
adapter.subscribeStates(SystemName + ".charge.ChgState");
|
|
637
|
+
adapter.subscribeStates(SystemName + ".charge.Uid");
|
|
624
638
|
|
|
625
639
|
//Solar price can be set to null when no changes have to be made.
|
|
626
640
|
//https://github.com/lephisto/amtron/blob/master/docs/api/HomeManager/post.md
|
|
@@ -674,9 +688,111 @@ async function checkVariables_rest(system) {
|
|
|
674
688
|
let key;
|
|
675
689
|
let obj;
|
|
676
690
|
|
|
677
|
-
|
|
691
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
678
692
|
|
|
679
|
-
key =
|
|
693
|
+
key = SystemName;
|
|
694
|
+
obj = {
|
|
695
|
+
type: "channel",
|
|
696
|
+
common: {
|
|
697
|
+
name: "Wallbox " + SystemName,
|
|
698
|
+
role: "value",
|
|
699
|
+
}
|
|
700
|
+
}
|
|
701
|
+
await CreateObject(key, obj);
|
|
702
|
+
|
|
703
|
+
|
|
704
|
+
key = SystemName + ".Connection";
|
|
705
|
+
obj = {
|
|
706
|
+
type: "channel",
|
|
707
|
+
common: {
|
|
708
|
+
name: "Connection ",
|
|
709
|
+
role: "value",
|
|
710
|
+
}
|
|
711
|
+
}
|
|
712
|
+
await CreateObject(key, obj);
|
|
713
|
+
|
|
714
|
+
key = SystemName + ".Authorisation";
|
|
715
|
+
obj = {
|
|
716
|
+
type: "channel",
|
|
717
|
+
common: {
|
|
718
|
+
name: "Authorisation ",
|
|
719
|
+
role: "value",
|
|
720
|
+
}
|
|
721
|
+
}
|
|
722
|
+
await CreateObject(key, obj);
|
|
723
|
+
|
|
724
|
+
key = SystemName + ".Backend";
|
|
725
|
+
obj = {
|
|
726
|
+
type: "channel",
|
|
727
|
+
common: {
|
|
728
|
+
name: "Backend ",
|
|
729
|
+
role: "value",
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
await CreateObject(key, obj);
|
|
733
|
+
|
|
734
|
+
key = SystemName + ".MCB";
|
|
735
|
+
obj = {
|
|
736
|
+
type: "channel",
|
|
737
|
+
common: {
|
|
738
|
+
name: "MCB",
|
|
739
|
+
role: "value",
|
|
740
|
+
}
|
|
741
|
+
}
|
|
742
|
+
await CreateObject(key, obj);
|
|
743
|
+
|
|
744
|
+
key = SystemName + ".OCPP";
|
|
745
|
+
obj = {
|
|
746
|
+
type: "channel",
|
|
747
|
+
common: {
|
|
748
|
+
name: "OCPP",
|
|
749
|
+
role: "value",
|
|
750
|
+
}
|
|
751
|
+
}
|
|
752
|
+
await CreateObject(key, obj);
|
|
753
|
+
|
|
754
|
+
key = SystemName + ".RCD";
|
|
755
|
+
obj = {
|
|
756
|
+
type: "channel",
|
|
757
|
+
common: {
|
|
758
|
+
name: "RCD",
|
|
759
|
+
role: "value",
|
|
760
|
+
}
|
|
761
|
+
}
|
|
762
|
+
await CreateObject(key, obj);
|
|
763
|
+
|
|
764
|
+
key = SystemName + ".RCMB";
|
|
765
|
+
obj = {
|
|
766
|
+
type: "channel",
|
|
767
|
+
common: {
|
|
768
|
+
name: "RCMB",
|
|
769
|
+
role: "value",
|
|
770
|
+
}
|
|
771
|
+
}
|
|
772
|
+
await CreateObject(key, obj);
|
|
773
|
+
|
|
774
|
+
key = SystemName + ".Schuko";
|
|
775
|
+
obj = {
|
|
776
|
+
type: "channel",
|
|
777
|
+
common: {
|
|
778
|
+
name: "Schuko",
|
|
779
|
+
role: "value",
|
|
780
|
+
}
|
|
781
|
+
}
|
|
782
|
+
await CreateObject(key, obj);
|
|
783
|
+
|
|
784
|
+
key = SystemName + ".Type2";
|
|
785
|
+
obj = {
|
|
786
|
+
type: "channel",
|
|
787
|
+
common: {
|
|
788
|
+
name: "Type2",
|
|
789
|
+
role: "value",
|
|
790
|
+
}
|
|
791
|
+
}
|
|
792
|
+
await CreateObject(key, obj);
|
|
793
|
+
|
|
794
|
+
|
|
795
|
+
key = SystemName + ".Connection.State";
|
|
680
796
|
obj = {
|
|
681
797
|
type: "state",
|
|
682
798
|
common: {
|
|
@@ -689,7 +805,7 @@ async function checkVariables_rest(system) {
|
|
|
689
805
|
}
|
|
690
806
|
await CreateObject(key, obj);
|
|
691
807
|
|
|
692
|
-
key =
|
|
808
|
+
key = SystemName + ".Authorisation.State";
|
|
693
809
|
obj = {
|
|
694
810
|
type: "state",
|
|
695
811
|
common: {
|
|
@@ -703,7 +819,7 @@ async function checkVariables_rest(system) {
|
|
|
703
819
|
}
|
|
704
820
|
await CreateObject(key, obj);
|
|
705
821
|
|
|
706
|
-
key =
|
|
822
|
+
key = SystemName + ".Authorisation.UID";
|
|
707
823
|
obj = {
|
|
708
824
|
type: "state",
|
|
709
825
|
common: {
|
|
@@ -717,7 +833,7 @@ async function checkVariables_rest(system) {
|
|
|
717
833
|
}
|
|
718
834
|
await CreateObject(key, obj);
|
|
719
835
|
|
|
720
|
-
key =
|
|
836
|
+
key = SystemName + ".TimeSinceChargingStart";
|
|
721
837
|
obj = {
|
|
722
838
|
type: "state",
|
|
723
839
|
common: {
|
|
@@ -732,7 +848,7 @@ async function checkVariables_rest(system) {
|
|
|
732
848
|
await CreateObject(key, obj);
|
|
733
849
|
|
|
734
850
|
|
|
735
|
-
key =
|
|
851
|
+
key = SystemName + ".Meter";
|
|
736
852
|
obj = {
|
|
737
853
|
type: "state",
|
|
738
854
|
common: {
|
|
@@ -746,7 +862,7 @@ async function checkVariables_rest(system) {
|
|
|
746
862
|
}
|
|
747
863
|
await CreateObject(key, obj);
|
|
748
864
|
|
|
749
|
-
key =
|
|
865
|
+
key = SystemName + ".Power";
|
|
750
866
|
obj = {
|
|
751
867
|
type: "state",
|
|
752
868
|
common: {
|
|
@@ -760,7 +876,7 @@ async function checkVariables_rest(system) {
|
|
|
760
876
|
}
|
|
761
877
|
await CreateObject(key, obj);
|
|
762
878
|
|
|
763
|
-
key =
|
|
879
|
+
key = SystemName + ".Transaction";
|
|
764
880
|
obj = {
|
|
765
881
|
type: "state",
|
|
766
882
|
common: {
|
|
@@ -774,7 +890,7 @@ async function checkVariables_rest(system) {
|
|
|
774
890
|
}
|
|
775
891
|
await CreateObject(key, obj);
|
|
776
892
|
|
|
777
|
-
key =
|
|
893
|
+
key = SystemName + ".CP_ID";
|
|
778
894
|
obj = {
|
|
779
895
|
type: "state",
|
|
780
896
|
common: {
|
|
@@ -788,7 +904,7 @@ async function checkVariables_rest(system) {
|
|
|
788
904
|
}
|
|
789
905
|
await CreateObject(key, obj);
|
|
790
906
|
|
|
791
|
-
key =
|
|
907
|
+
key = SystemName + ".OCPP.State";
|
|
792
908
|
obj = {
|
|
793
909
|
type: "state",
|
|
794
910
|
common: {
|
|
@@ -802,7 +918,7 @@ async function checkVariables_rest(system) {
|
|
|
802
918
|
}
|
|
803
919
|
await CreateObject(key, obj);
|
|
804
920
|
|
|
805
|
-
key =
|
|
921
|
+
key = SystemName + ".Type2.State";
|
|
806
922
|
obj = {
|
|
807
923
|
type: "state",
|
|
808
924
|
common: {
|
|
@@ -816,7 +932,7 @@ async function checkVariables_rest(system) {
|
|
|
816
932
|
}
|
|
817
933
|
await CreateObject(key, obj);
|
|
818
934
|
|
|
819
|
-
key =
|
|
935
|
+
key = SystemName + ".Type2.Proximity";
|
|
820
936
|
obj = {
|
|
821
937
|
type: "state",
|
|
822
938
|
common: {
|
|
@@ -830,7 +946,7 @@ async function checkVariables_rest(system) {
|
|
|
830
946
|
}
|
|
831
947
|
await CreateObject(key, obj);
|
|
832
948
|
|
|
833
|
-
key =
|
|
949
|
+
key = SystemName + ".SigCurrent";
|
|
834
950
|
obj = {
|
|
835
951
|
type: "state",
|
|
836
952
|
common: {
|
|
@@ -844,7 +960,7 @@ async function checkVariables_rest(system) {
|
|
|
844
960
|
}
|
|
845
961
|
await CreateObject(key, obj);
|
|
846
962
|
|
|
847
|
-
key =
|
|
963
|
+
key = SystemName + ".Schuko.State";
|
|
848
964
|
obj = {
|
|
849
965
|
type: "state",
|
|
850
966
|
common: {
|
|
@@ -859,7 +975,7 @@ async function checkVariables_rest(system) {
|
|
|
859
975
|
await CreateObject(key, obj);
|
|
860
976
|
|
|
861
977
|
|
|
862
|
-
key =
|
|
978
|
+
key = SystemName + ".Backend.ConnectionState";
|
|
863
979
|
obj = {
|
|
864
980
|
type: "state",
|
|
865
981
|
common: {
|
|
@@ -874,7 +990,7 @@ async function checkVariables_rest(system) {
|
|
|
874
990
|
await CreateObject(key, obj);
|
|
875
991
|
|
|
876
992
|
|
|
877
|
-
key =
|
|
993
|
+
key = SystemName + ".FreeCharging";
|
|
878
994
|
obj = {
|
|
879
995
|
type: "state",
|
|
880
996
|
common: {
|
|
@@ -889,7 +1005,7 @@ async function checkVariables_rest(system) {
|
|
|
889
1005
|
await CreateObject(key, obj);
|
|
890
1006
|
|
|
891
1007
|
|
|
892
|
-
key =
|
|
1008
|
+
key = SystemName + ".SlaveState";
|
|
893
1009
|
obj = {
|
|
894
1010
|
type: "state",
|
|
895
1011
|
common: {
|
|
@@ -904,7 +1020,7 @@ async function checkVariables_rest(system) {
|
|
|
904
1020
|
await CreateObject(key, obj);
|
|
905
1021
|
|
|
906
1022
|
|
|
907
|
-
key =
|
|
1023
|
+
key = SystemName + ".OCPP.MeterConfig";
|
|
908
1024
|
obj = {
|
|
909
1025
|
type: "state",
|
|
910
1026
|
common: {
|
|
@@ -918,7 +1034,7 @@ async function checkVariables_rest(system) {
|
|
|
918
1034
|
}
|
|
919
1035
|
await CreateObject(key, obj);
|
|
920
1036
|
|
|
921
|
-
key =
|
|
1037
|
+
key = SystemName + ".OCPP.MeterSerial";
|
|
922
1038
|
obj = {
|
|
923
1039
|
type: "state",
|
|
924
1040
|
common: {
|
|
@@ -932,7 +1048,7 @@ async function checkVariables_rest(system) {
|
|
|
932
1048
|
}
|
|
933
1049
|
await CreateObject(key, obj);
|
|
934
1050
|
|
|
935
|
-
key =
|
|
1051
|
+
key = SystemName + ".Current";
|
|
936
1052
|
obj = {
|
|
937
1053
|
type: "state",
|
|
938
1054
|
common: {
|
|
@@ -946,7 +1062,7 @@ async function checkVariables_rest(system) {
|
|
|
946
1062
|
}
|
|
947
1063
|
await CreateObject(key, obj);
|
|
948
1064
|
|
|
949
|
-
key =
|
|
1065
|
+
key = SystemName + ".EnergyManagerCurrent";
|
|
950
1066
|
obj = {
|
|
951
1067
|
type: "state",
|
|
952
1068
|
common: {
|
|
@@ -960,7 +1076,7 @@ async function checkVariables_rest(system) {
|
|
|
960
1076
|
}
|
|
961
1077
|
await CreateObject(key, obj);
|
|
962
1078
|
|
|
963
|
-
key =
|
|
1079
|
+
key = SystemName + ".AmbientTemperature";
|
|
964
1080
|
obj = {
|
|
965
1081
|
type: "state",
|
|
966
1082
|
common: {
|
|
@@ -974,7 +1090,7 @@ async function checkVariables_rest(system) {
|
|
|
974
1090
|
}
|
|
975
1091
|
await CreateObject(key, obj);
|
|
976
1092
|
|
|
977
|
-
key =
|
|
1093
|
+
key = SystemName + ".FirmwareVersion";
|
|
978
1094
|
obj = {
|
|
979
1095
|
type: "state",
|
|
980
1096
|
common: {
|
|
@@ -988,7 +1104,7 @@ async function checkVariables_rest(system) {
|
|
|
988
1104
|
}
|
|
989
1105
|
await CreateObject(key, obj);
|
|
990
1106
|
|
|
991
|
-
key =
|
|
1107
|
+
key = SystemName + ".SerialNumber";
|
|
992
1108
|
obj = {
|
|
993
1109
|
type: "state",
|
|
994
1110
|
common: {
|
|
@@ -1002,7 +1118,7 @@ async function checkVariables_rest(system) {
|
|
|
1002
1118
|
}
|
|
1003
1119
|
await CreateObject(key, obj);
|
|
1004
1120
|
|
|
1005
|
-
key =
|
|
1121
|
+
key = SystemName + ".ContactCyclesSchuko";
|
|
1006
1122
|
obj = {
|
|
1007
1123
|
type: "state",
|
|
1008
1124
|
common: {
|
|
@@ -1016,7 +1132,7 @@ async function checkVariables_rest(system) {
|
|
|
1016
1132
|
}
|
|
1017
1133
|
await CreateObject(key, obj);
|
|
1018
1134
|
|
|
1019
|
-
key =
|
|
1135
|
+
key = SystemName + ".ContactcyclesType2";
|
|
1020
1136
|
obj = {
|
|
1021
1137
|
type: "state",
|
|
1022
1138
|
common: {
|
|
@@ -1030,7 +1146,7 @@ async function checkVariables_rest(system) {
|
|
|
1030
1146
|
}
|
|
1031
1147
|
await CreateObject(key, obj);
|
|
1032
1148
|
|
|
1033
|
-
key =
|
|
1149
|
+
key = SystemName + ".MaxCurrent";
|
|
1034
1150
|
obj = {
|
|
1035
1151
|
type: "state",
|
|
1036
1152
|
common: {
|
|
@@ -1044,7 +1160,7 @@ async function checkVariables_rest(system) {
|
|
|
1044
1160
|
}
|
|
1045
1161
|
await CreateObject(key, obj);
|
|
1046
1162
|
|
|
1047
|
-
key =
|
|
1163
|
+
key = SystemName + ".RCMB.State";
|
|
1048
1164
|
obj = {
|
|
1049
1165
|
type: "state",
|
|
1050
1166
|
common: {
|
|
@@ -1058,7 +1174,7 @@ async function checkVariables_rest(system) {
|
|
|
1058
1174
|
}
|
|
1059
1175
|
await CreateObject(key, obj);
|
|
1060
1176
|
|
|
1061
|
-
key =
|
|
1177
|
+
key = SystemName + ".RCMB.MaxValues";
|
|
1062
1178
|
obj = {
|
|
1063
1179
|
type: "state",
|
|
1064
1180
|
common: {
|
|
@@ -1072,7 +1188,7 @@ async function checkVariables_rest(system) {
|
|
|
1072
1188
|
}
|
|
1073
1189
|
await CreateObject(key, obj);
|
|
1074
1190
|
|
|
1075
|
-
key =
|
|
1191
|
+
key = SystemName + ".RCMB.CurrentValues";
|
|
1076
1192
|
obj = {
|
|
1077
1193
|
type: "state",
|
|
1078
1194
|
common: {
|
|
@@ -1086,7 +1202,7 @@ async function checkVariables_rest(system) {
|
|
|
1086
1202
|
}
|
|
1087
1203
|
await CreateObject(key, obj);
|
|
1088
1204
|
|
|
1089
|
-
key =
|
|
1205
|
+
key = SystemName + ".CableAttached";
|
|
1090
1206
|
obj = {
|
|
1091
1207
|
type: "state",
|
|
1092
1208
|
common: {
|
|
@@ -1101,7 +1217,7 @@ async function checkVariables_rest(system) {
|
|
|
1101
1217
|
await CreateObject(key, obj);
|
|
1102
1218
|
|
|
1103
1219
|
|
|
1104
|
-
key =
|
|
1220
|
+
key = SystemNamee + ".Schuko.Config";
|
|
1105
1221
|
obj = {
|
|
1106
1222
|
type: "state",
|
|
1107
1223
|
common: {
|
|
@@ -1115,7 +1231,7 @@ async function checkVariables_rest(system) {
|
|
|
1115
1231
|
}
|
|
1116
1232
|
await CreateObject(key, obj);
|
|
1117
1233
|
|
|
1118
|
-
key =
|
|
1234
|
+
key = SystemName + ".RCD.State";
|
|
1119
1235
|
obj = {
|
|
1120
1236
|
type: "state",
|
|
1121
1237
|
common: {
|
|
@@ -1129,7 +1245,7 @@ async function checkVariables_rest(system) {
|
|
|
1129
1245
|
}
|
|
1130
1246
|
await CreateObject(key, obj);
|
|
1131
1247
|
|
|
1132
|
-
key =
|
|
1248
|
+
key = SystemName + ".MCB.Type2State";
|
|
1133
1249
|
obj = {
|
|
1134
1250
|
type: "state",
|
|
1135
1251
|
common: {
|
|
@@ -1143,7 +1259,7 @@ async function checkVariables_rest(system) {
|
|
|
1143
1259
|
}
|
|
1144
1260
|
await CreateObject(key, obj);
|
|
1145
1261
|
|
|
1146
|
-
key =
|
|
1262
|
+
key = SystemName + ".MCB.SchukoState";
|
|
1147
1263
|
obj = {
|
|
1148
1264
|
type: "state",
|
|
1149
1265
|
common: {
|
|
@@ -1157,7 +1273,7 @@ async function checkVariables_rest(system) {
|
|
|
1157
1273
|
}
|
|
1158
1274
|
await CreateObject(key, obj);
|
|
1159
1275
|
|
|
1160
|
-
key =
|
|
1276
|
+
key = SystemName + ".CP_Vendor";
|
|
1161
1277
|
obj = {
|
|
1162
1278
|
type: "state",
|
|
1163
1279
|
common: {
|
|
@@ -1171,7 +1287,7 @@ async function checkVariables_rest(system) {
|
|
|
1171
1287
|
}
|
|
1172
1288
|
await CreateObject(key, obj);
|
|
1173
1289
|
|
|
1174
|
-
key =
|
|
1290
|
+
key = SystemName + ".Errors";
|
|
1175
1291
|
obj = {
|
|
1176
1292
|
type: "state",
|
|
1177
1293
|
common: {
|
|
@@ -1185,7 +1301,7 @@ async function checkVariables_rest(system) {
|
|
|
1185
1301
|
}
|
|
1186
1302
|
await CreateObject(key, obj);
|
|
1187
1303
|
|
|
1188
|
-
key =
|
|
1304
|
+
key = SystemName + ".CP_Model";
|
|
1189
1305
|
obj = {
|
|
1190
1306
|
type: "state",
|
|
1191
1307
|
common: {
|
|
@@ -1200,7 +1316,7 @@ async function checkVariables_rest(system) {
|
|
|
1200
1316
|
await CreateObject(key, obj);
|
|
1201
1317
|
|
|
1202
1318
|
|
|
1203
|
-
key =
|
|
1319
|
+
key = SystemName + ".DisplayText";
|
|
1204
1320
|
obj = {
|
|
1205
1321
|
type: "state",
|
|
1206
1322
|
common: {
|
|
@@ -1223,7 +1339,30 @@ async function checkVariables_MHCP(system) {
|
|
|
1223
1339
|
|
|
1224
1340
|
//dev info data
|
|
1225
1341
|
|
|
1226
|
-
|
|
1342
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
1343
|
+
|
|
1344
|
+
key = SystemName ;
|
|
1345
|
+
obj = {
|
|
1346
|
+
type: "channel",
|
|
1347
|
+
common: {
|
|
1348
|
+
name: "Wallbox " + SystemName,
|
|
1349
|
+
role: "value",
|
|
1350
|
+
}
|
|
1351
|
+
}
|
|
1352
|
+
await CreateObject(key, obj);
|
|
1353
|
+
|
|
1354
|
+
|
|
1355
|
+
key = SystemName + ".info"
|
|
1356
|
+
obj = {
|
|
1357
|
+
type: "channel",
|
|
1358
|
+
common: {
|
|
1359
|
+
name: "info",
|
|
1360
|
+
role: "value",
|
|
1361
|
+
}
|
|
1362
|
+
}
|
|
1363
|
+
await CreateObject(key, obj);
|
|
1364
|
+
|
|
1365
|
+
key = SystemName + ".info.DevName";
|
|
1227
1366
|
obj = {
|
|
1228
1367
|
type: "state",
|
|
1229
1368
|
common: {
|
|
@@ -1236,7 +1375,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1236
1375
|
}
|
|
1237
1376
|
await CreateObject(key, obj);
|
|
1238
1377
|
|
|
1239
|
-
key =
|
|
1378
|
+
key = SystemName + ".info.LocTime";
|
|
1240
1379
|
obj = {
|
|
1241
1380
|
type: "state",
|
|
1242
1381
|
common: {
|
|
@@ -1249,7 +1388,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1249
1388
|
}
|
|
1250
1389
|
await CreateObject(key, obj);
|
|
1251
1390
|
|
|
1252
|
-
key =
|
|
1391
|
+
key = SystemName + ".info.Summer";
|
|
1253
1392
|
obj = {
|
|
1254
1393
|
type: "state",
|
|
1255
1394
|
common: {
|
|
@@ -1262,7 +1401,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1262
1401
|
}
|
|
1263
1402
|
await CreateObject(key, obj);
|
|
1264
1403
|
|
|
1265
|
-
key =
|
|
1404
|
+
key = SystemName + ".info.Tz";
|
|
1266
1405
|
obj = {
|
|
1267
1406
|
type: "state",
|
|
1268
1407
|
common: {
|
|
@@ -1275,7 +1414,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1275
1414
|
}
|
|
1276
1415
|
await CreateObject(key, obj);
|
|
1277
1416
|
|
|
1278
|
-
key =
|
|
1417
|
+
key = SystemName + ".info.ItemNo";
|
|
1279
1418
|
obj = {
|
|
1280
1419
|
type: "state",
|
|
1281
1420
|
common: {
|
|
@@ -1288,7 +1427,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1288
1427
|
}
|
|
1289
1428
|
await CreateObject(key, obj);
|
|
1290
1429
|
|
|
1291
|
-
key =
|
|
1430
|
+
key = SystemName + ".info.Sn";
|
|
1292
1431
|
obj = {
|
|
1293
1432
|
type: "state",
|
|
1294
1433
|
common: {
|
|
@@ -1301,7 +1440,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1301
1440
|
}
|
|
1302
1441
|
await CreateObject(key, obj);
|
|
1303
1442
|
|
|
1304
|
-
key =
|
|
1443
|
+
key = SystemName + ".info.Hcc3";
|
|
1305
1444
|
obj = {
|
|
1306
1445
|
type: "state",
|
|
1307
1446
|
common: {
|
|
@@ -1314,7 +1453,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1314
1453
|
}
|
|
1315
1454
|
await CreateObject(key, obj);
|
|
1316
1455
|
|
|
1317
|
-
key =
|
|
1456
|
+
key = SystemName + ".info.Hmi";
|
|
1318
1457
|
obj = {
|
|
1319
1458
|
type: "state",
|
|
1320
1459
|
common: {
|
|
@@ -1327,7 +1466,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1327
1466
|
}
|
|
1328
1467
|
await CreateObject(key, obj);
|
|
1329
1468
|
|
|
1330
|
-
key =
|
|
1469
|
+
key = SystemName + ".info.Rfid";
|
|
1331
1470
|
obj = {
|
|
1332
1471
|
type: "state",
|
|
1333
1472
|
common: {
|
|
@@ -1340,7 +1479,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1340
1479
|
}
|
|
1341
1480
|
await CreateObject(key, obj);
|
|
1342
1481
|
|
|
1343
|
-
key =
|
|
1482
|
+
key = SystemName + ".info.Wifi";
|
|
1344
1483
|
obj = {
|
|
1345
1484
|
type: "state",
|
|
1346
1485
|
common: {
|
|
@@ -1353,7 +1492,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1353
1492
|
}
|
|
1354
1493
|
await CreateObject(key, obj);
|
|
1355
1494
|
|
|
1356
|
-
key =
|
|
1495
|
+
key = SystemName + ".info.FixedVehCosts";
|
|
1357
1496
|
obj = {
|
|
1358
1497
|
type: "state",
|
|
1359
1498
|
common: {
|
|
@@ -1366,7 +1505,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1366
1505
|
}
|
|
1367
1506
|
await CreateObject(key, obj);
|
|
1368
1507
|
|
|
1369
|
-
key =
|
|
1508
|
+
key = SystemName + ".info.OldVehCosts";
|
|
1370
1509
|
obj = {
|
|
1371
1510
|
type: "state",
|
|
1372
1511
|
common: {
|
|
@@ -1379,7 +1518,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1379
1518
|
}
|
|
1380
1519
|
await CreateObject(key, obj);
|
|
1381
1520
|
|
|
1382
|
-
key =
|
|
1521
|
+
key = SystemName + ".info.Color";
|
|
1383
1522
|
obj = {
|
|
1384
1523
|
type: "state",
|
|
1385
1524
|
common: {
|
|
@@ -1392,7 +1531,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1392
1531
|
}
|
|
1393
1532
|
await CreateObject(key, obj);
|
|
1394
1533
|
|
|
1395
|
-
key =
|
|
1534
|
+
key = SystemName + ".info.DevMode";
|
|
1396
1535
|
obj = {
|
|
1397
1536
|
type: "state",
|
|
1398
1537
|
common: {
|
|
@@ -1405,7 +1544,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1405
1544
|
}
|
|
1406
1545
|
await CreateObject(key, obj);
|
|
1407
1546
|
|
|
1408
|
-
key =
|
|
1547
|
+
key = SystemName + ".info.ChgState";
|
|
1409
1548
|
obj = {
|
|
1410
1549
|
type: "state",
|
|
1411
1550
|
common: {
|
|
@@ -1418,7 +1557,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1418
1557
|
}
|
|
1419
1558
|
await CreateObject(key, obj);
|
|
1420
1559
|
|
|
1421
|
-
key =
|
|
1560
|
+
key = SystemName + ".info.WifiOn";
|
|
1422
1561
|
obj = {
|
|
1423
1562
|
type: "state",
|
|
1424
1563
|
common: {
|
|
@@ -1431,7 +1570,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1431
1570
|
}
|
|
1432
1571
|
await CreateObject(key, obj);
|
|
1433
1572
|
|
|
1434
|
-
key =
|
|
1573
|
+
key = SystemName + ".info.AutoChg";
|
|
1435
1574
|
obj = {
|
|
1436
1575
|
type: "state",
|
|
1437
1576
|
common: {
|
|
@@ -1444,7 +1583,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1444
1583
|
}
|
|
1445
1584
|
await CreateObject(key, obj);
|
|
1446
1585
|
|
|
1447
|
-
key =
|
|
1586
|
+
key = SystemName + ".info.ChgContinue";
|
|
1448
1587
|
obj = {
|
|
1449
1588
|
type: "state",
|
|
1450
1589
|
common: {
|
|
@@ -1457,7 +1596,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1457
1596
|
}
|
|
1458
1597
|
await CreateObject(key, obj);
|
|
1459
1598
|
|
|
1460
|
-
key =
|
|
1599
|
+
key = SystemName + ".info.Err";
|
|
1461
1600
|
obj = {
|
|
1462
1601
|
type: "state",
|
|
1463
1602
|
common: {
|
|
@@ -1470,7 +1609,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1470
1609
|
}
|
|
1471
1610
|
await CreateObject(key, obj);
|
|
1472
1611
|
|
|
1473
|
-
key =
|
|
1612
|
+
key = SystemName + ".info.Battery";
|
|
1474
1613
|
obj = {
|
|
1475
1614
|
type: "state",
|
|
1476
1615
|
common: {
|
|
@@ -1483,7 +1622,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1483
1622
|
}
|
|
1484
1623
|
await CreateObject(key, obj);
|
|
1485
1624
|
|
|
1486
|
-
key =
|
|
1625
|
+
key = SystemName + ".info.Phases";
|
|
1487
1626
|
obj = {
|
|
1488
1627
|
type: "state",
|
|
1489
1628
|
common: {
|
|
@@ -1496,7 +1635,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1496
1635
|
}
|
|
1497
1636
|
await CreateObject(key, obj);
|
|
1498
1637
|
|
|
1499
|
-
key =
|
|
1638
|
+
key = SystemName + ".info.Cable";
|
|
1500
1639
|
obj = {
|
|
1501
1640
|
type: "state",
|
|
1502
1641
|
common: {
|
|
@@ -1509,7 +1648,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1509
1648
|
}
|
|
1510
1649
|
await CreateObject(key, obj);
|
|
1511
1650
|
|
|
1512
|
-
key =
|
|
1651
|
+
key = SystemName + ".info.Auth";
|
|
1513
1652
|
obj = {
|
|
1514
1653
|
type: "state",
|
|
1515
1654
|
common: {
|
|
@@ -1522,7 +1661,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1522
1661
|
}
|
|
1523
1662
|
await CreateObject(key, obj);
|
|
1524
1663
|
|
|
1525
|
-
key =
|
|
1664
|
+
key = SystemName + ".info.DsoEnabled";
|
|
1526
1665
|
obj = {
|
|
1527
1666
|
type: "state",
|
|
1528
1667
|
common: {
|
|
@@ -1535,7 +1674,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1535
1674
|
}
|
|
1536
1675
|
await CreateObject(key, obj);
|
|
1537
1676
|
|
|
1538
|
-
key =
|
|
1677
|
+
key = SystemName + ".info.EmEnabled";
|
|
1539
1678
|
obj = {
|
|
1540
1679
|
type: "state",
|
|
1541
1680
|
common: {
|
|
@@ -1548,7 +1687,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1548
1687
|
}
|
|
1549
1688
|
await CreateObject(key, obj);
|
|
1550
1689
|
|
|
1551
|
-
key =
|
|
1690
|
+
key = SystemName + ".info.MaxCurr";
|
|
1552
1691
|
obj = {
|
|
1553
1692
|
type: "state",
|
|
1554
1693
|
common: {
|
|
@@ -1562,7 +1701,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1562
1701
|
}
|
|
1563
1702
|
await CreateObject(key, obj);
|
|
1564
1703
|
|
|
1565
|
-
key =
|
|
1704
|
+
key = SystemName + ".info.MaxPwr";
|
|
1566
1705
|
obj = {
|
|
1567
1706
|
type: "state",
|
|
1568
1707
|
common: {
|
|
@@ -1576,7 +1715,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1576
1715
|
}
|
|
1577
1716
|
await CreateObject(key, obj);
|
|
1578
1717
|
|
|
1579
|
-
key =
|
|
1718
|
+
key = SystemName + ".info.MaxCurrWb";
|
|
1580
1719
|
obj = {
|
|
1581
1720
|
type: "state",
|
|
1582
1721
|
common: {
|
|
@@ -1591,8 +1730,18 @@ async function checkVariables_MHCP(system) {
|
|
|
1591
1730
|
await CreateObject(key, obj);
|
|
1592
1731
|
|
|
1593
1732
|
//dev charge data
|
|
1733
|
+
key = SystemName + ".charge"
|
|
1734
|
+
obj = {
|
|
1735
|
+
type: "channel",
|
|
1736
|
+
common: {
|
|
1737
|
+
name: "charge",
|
|
1738
|
+
role: "value",
|
|
1739
|
+
}
|
|
1740
|
+
}
|
|
1741
|
+
await CreateObject(key, obj);
|
|
1742
|
+
|
|
1594
1743
|
|
|
1595
|
-
key =
|
|
1744
|
+
key = SystemName + ".charge.ChgState";
|
|
1596
1745
|
obj = {
|
|
1597
1746
|
type: "state",
|
|
1598
1747
|
common: {
|
|
@@ -1605,7 +1754,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1605
1754
|
}
|
|
1606
1755
|
await CreateObject(key, obj);
|
|
1607
1756
|
|
|
1608
|
-
key =
|
|
1757
|
+
key = SystemName + ".charge.Tariff";
|
|
1609
1758
|
obj = {
|
|
1610
1759
|
type: "state",
|
|
1611
1760
|
common: {
|
|
@@ -1618,7 +1767,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1618
1767
|
}
|
|
1619
1768
|
await CreateObject(key, obj);
|
|
1620
1769
|
|
|
1621
|
-
key =
|
|
1770
|
+
key = SystemName + ".charge.Price";
|
|
1622
1771
|
obj = {
|
|
1623
1772
|
type: "state",
|
|
1624
1773
|
common: {
|
|
@@ -1631,7 +1780,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1631
1780
|
}
|
|
1632
1781
|
await CreateObject(key, obj);
|
|
1633
1782
|
|
|
1634
|
-
key =
|
|
1783
|
+
key = SystemName + ".charge.Uid";
|
|
1635
1784
|
obj = {
|
|
1636
1785
|
type: "state",
|
|
1637
1786
|
common: {
|
|
@@ -1644,7 +1793,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1644
1793
|
}
|
|
1645
1794
|
await CreateObject(key, obj);
|
|
1646
1795
|
|
|
1647
|
-
key =
|
|
1796
|
+
key = SystemName + ".charge.ChgDuration";
|
|
1648
1797
|
obj = {
|
|
1649
1798
|
type: "state",
|
|
1650
1799
|
common: {
|
|
@@ -1657,7 +1806,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1657
1806
|
}
|
|
1658
1807
|
await CreateObject(key, obj);
|
|
1659
1808
|
|
|
1660
|
-
key =
|
|
1809
|
+
key = SystemName + ".charge.ChgNrg";
|
|
1661
1810
|
obj = {
|
|
1662
1811
|
type: "state",
|
|
1663
1812
|
common: {
|
|
@@ -1671,7 +1820,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1671
1820
|
}
|
|
1672
1821
|
await CreateObject(key, obj);
|
|
1673
1822
|
|
|
1674
|
-
key =
|
|
1823
|
+
key = SystemName + ".charge.NrgDemand";
|
|
1675
1824
|
obj = {
|
|
1676
1825
|
type: "state",
|
|
1677
1826
|
common: {
|
|
@@ -1685,7 +1834,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1685
1834
|
}
|
|
1686
1835
|
await CreateObject(key, obj);
|
|
1687
1836
|
|
|
1688
|
-
key =
|
|
1837
|
+
key = SystemName + ".charge.Solar";
|
|
1689
1838
|
obj = {
|
|
1690
1839
|
type: "state",
|
|
1691
1840
|
common: {
|
|
@@ -1698,7 +1847,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1698
1847
|
}
|
|
1699
1848
|
await CreateObject(key, obj);
|
|
1700
1849
|
|
|
1701
|
-
key =
|
|
1850
|
+
key = SystemName + ".charge.EmTime";
|
|
1702
1851
|
obj = {
|
|
1703
1852
|
type: "state",
|
|
1704
1853
|
common: {
|
|
@@ -1711,7 +1860,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1711
1860
|
}
|
|
1712
1861
|
await CreateObject(key, obj);
|
|
1713
1862
|
|
|
1714
|
-
key =
|
|
1863
|
+
key = SystemName + ".charge.RemTime";
|
|
1715
1864
|
obj = {
|
|
1716
1865
|
type: "state",
|
|
1717
1866
|
common: {
|
|
@@ -1724,7 +1873,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1724
1873
|
}
|
|
1725
1874
|
await CreateObject(key, obj);
|
|
1726
1875
|
|
|
1727
|
-
key =
|
|
1876
|
+
key = SystemName + ".charge.ActPwr";
|
|
1728
1877
|
obj = {
|
|
1729
1878
|
type: "state",
|
|
1730
1879
|
common: {
|
|
@@ -1737,7 +1886,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1737
1886
|
}
|
|
1738
1887
|
await CreateObject(key, obj);
|
|
1739
1888
|
|
|
1740
|
-
key =
|
|
1889
|
+
key = SystemName + ".charge.ActCurr";
|
|
1741
1890
|
obj = {
|
|
1742
1891
|
type: "state",
|
|
1743
1892
|
common: {
|
|
@@ -1751,7 +1900,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1751
1900
|
}
|
|
1752
1901
|
await CreateObject(key, obj);
|
|
1753
1902
|
|
|
1754
|
-
key =
|
|
1903
|
+
key = SystemName + ".charge.MaxCurrT1";
|
|
1755
1904
|
obj = {
|
|
1756
1905
|
type: "state",
|
|
1757
1906
|
common: {
|
|
@@ -1765,7 +1914,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1765
1914
|
}
|
|
1766
1915
|
await CreateObject(key, obj);
|
|
1767
1916
|
|
|
1768
|
-
key =
|
|
1917
|
+
key = SystemName + ".charge.BeginH_T1";
|
|
1769
1918
|
obj = {
|
|
1770
1919
|
type: "state",
|
|
1771
1920
|
common: {
|
|
@@ -1778,7 +1927,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1778
1927
|
}
|
|
1779
1928
|
await CreateObject(key, obj);
|
|
1780
1929
|
|
|
1781
|
-
key =
|
|
1930
|
+
key = SystemName + ".charge.BeginM_T1";
|
|
1782
1931
|
obj = {
|
|
1783
1932
|
type: "state",
|
|
1784
1933
|
common: {
|
|
@@ -1792,7 +1941,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1792
1941
|
}
|
|
1793
1942
|
await CreateObject(key, obj);
|
|
1794
1943
|
|
|
1795
|
-
key =
|
|
1944
|
+
key = SystemName + ".charge.PriceT1";
|
|
1796
1945
|
obj = {
|
|
1797
1946
|
type: "state",
|
|
1798
1947
|
common: {
|
|
@@ -1805,7 +1954,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1805
1954
|
}
|
|
1806
1955
|
await CreateObject(key, obj);
|
|
1807
1956
|
|
|
1808
|
-
key =
|
|
1957
|
+
key = SystemName + ".charge.MaxCurrT2";
|
|
1809
1958
|
obj = {
|
|
1810
1959
|
type: "state",
|
|
1811
1960
|
common: {
|
|
@@ -1818,7 +1967,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1818
1967
|
}
|
|
1819
1968
|
await CreateObject(key, obj);
|
|
1820
1969
|
|
|
1821
|
-
key =
|
|
1970
|
+
key = SystemName + ".charge.BeginH_T2";
|
|
1822
1971
|
obj = {
|
|
1823
1972
|
type: "state",
|
|
1824
1973
|
common: {
|
|
@@ -1831,7 +1980,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1831
1980
|
}
|
|
1832
1981
|
await CreateObject(key, obj);
|
|
1833
1982
|
|
|
1834
|
-
key =
|
|
1983
|
+
key = SystemName + ".charge.BeginM_T2";
|
|
1835
1984
|
obj = {
|
|
1836
1985
|
type: "state",
|
|
1837
1986
|
common: {
|
|
@@ -1844,7 +1993,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1844
1993
|
}
|
|
1845
1994
|
await CreateObject(key, obj);
|
|
1846
1995
|
|
|
1847
|
-
key =
|
|
1996
|
+
key = SystemName + ".charge.PriceT2";
|
|
1848
1997
|
obj = {
|
|
1849
1998
|
type: "state",
|
|
1850
1999
|
common: {
|
|
@@ -1857,7 +2006,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1857
2006
|
}
|
|
1858
2007
|
await CreateObject(key, obj);
|
|
1859
2008
|
|
|
1860
|
-
key =
|
|
2009
|
+
key = SystemName + ".charge.RemoteCurr";
|
|
1861
2010
|
obj = {
|
|
1862
2011
|
type: "state",
|
|
1863
2012
|
common: {
|
|
@@ -1871,7 +2020,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1871
2020
|
}
|
|
1872
2021
|
await CreateObject(key, obj);
|
|
1873
2022
|
|
|
1874
|
-
key =
|
|
2023
|
+
key = SystemName + ".charge.SolarPrice";
|
|
1875
2024
|
obj = {
|
|
1876
2025
|
type: "state",
|
|
1877
2026
|
common: {
|
|
@@ -1884,7 +2033,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1884
2033
|
}
|
|
1885
2034
|
await CreateObject(key, obj);
|
|
1886
2035
|
|
|
1887
|
-
key =
|
|
2036
|
+
key = SystemName + ".charge.ExcessNrg";
|
|
1888
2037
|
obj = {
|
|
1889
2038
|
type: "state",
|
|
1890
2039
|
common: {
|
|
@@ -1897,7 +2046,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1897
2046
|
}
|
|
1898
2047
|
await CreateObject(key, obj);
|
|
1899
2048
|
|
|
1900
|
-
key =
|
|
2049
|
+
key = SystemName + ".charge.HCCP";
|
|
1901
2050
|
obj = {
|
|
1902
2051
|
type: "state",
|
|
1903
2052
|
common: {
|
|
@@ -1915,7 +2064,7 @@ async function checkVariables_MHCP(system) {
|
|
|
1915
2064
|
await checkVariables_MHCP_Statistic(system, "Month");
|
|
1916
2065
|
await checkVariables_MHCP_Statistic(system, "Year");
|
|
1917
2066
|
|
|
1918
|
-
key =
|
|
2067
|
+
key = SystemName + ".Statistics.Annual.Years";
|
|
1919
2068
|
obj = {
|
|
1920
2069
|
type: "state",
|
|
1921
2070
|
common: {
|
|
@@ -1937,7 +2086,30 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
1937
2086
|
|
|
1938
2087
|
//statistic data
|
|
1939
2088
|
|
|
1940
|
-
|
|
2089
|
+
const SystemName = system.Name.replace(adapter.FORBIDDEN_CHARS, '_');
|
|
2090
|
+
|
|
2091
|
+
key = SystemName + ".Statistics";
|
|
2092
|
+
obj = {
|
|
2093
|
+
type: "channel",
|
|
2094
|
+
common: {
|
|
2095
|
+
name: "Statistics",
|
|
2096
|
+
role: "value",
|
|
2097
|
+
}
|
|
2098
|
+
}
|
|
2099
|
+
await CreateObject(key, obj);
|
|
2100
|
+
|
|
2101
|
+
key = SystemName + ".Statistics" + period;
|
|
2102
|
+
obj = {
|
|
2103
|
+
type: "channel",
|
|
2104
|
+
common: {
|
|
2105
|
+
name: "Statistics period " + period,
|
|
2106
|
+
role: "value",
|
|
2107
|
+
}
|
|
2108
|
+
}
|
|
2109
|
+
await CreateObject(key, obj);
|
|
2110
|
+
|
|
2111
|
+
|
|
2112
|
+
key = SystemName + ".Statistics." + period + ".ChgNrg";
|
|
1941
2113
|
obj = {
|
|
1942
2114
|
type: "state",
|
|
1943
2115
|
common: {
|
|
@@ -1951,7 +2123,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
1951
2123
|
}
|
|
1952
2124
|
await CreateObject(key, obj);
|
|
1953
2125
|
|
|
1954
|
-
key =
|
|
2126
|
+
key = SystemName + ".Statistics." + period + ".HybridNrg";
|
|
1955
2127
|
obj = {
|
|
1956
2128
|
type: "state",
|
|
1957
2129
|
common: {
|
|
@@ -1964,7 +2136,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
1964
2136
|
}
|
|
1965
2137
|
await CreateObject(key, obj);
|
|
1966
2138
|
|
|
1967
|
-
key =
|
|
2139
|
+
key = SystemName + ".Statistics." + period + ".Solar";
|
|
1968
2140
|
obj = {
|
|
1969
2141
|
type: "state",
|
|
1970
2142
|
common: {
|
|
@@ -1977,7 +2149,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
1977
2149
|
}
|
|
1978
2150
|
await CreateObject(key, obj);
|
|
1979
2151
|
|
|
1980
|
-
key =
|
|
2152
|
+
key = SystemName + ".Statistics." + period + ".Tariff1";
|
|
1981
2153
|
obj = {
|
|
1982
2154
|
type: "state",
|
|
1983
2155
|
common: {
|
|
@@ -1990,7 +2162,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
1990
2162
|
}
|
|
1991
2163
|
await CreateObject(key, obj);
|
|
1992
2164
|
|
|
1993
|
-
key =
|
|
2165
|
+
key = SystemName + ".Statistics." + period + ".Tariff2";
|
|
1994
2166
|
obj = {
|
|
1995
2167
|
type: "state",
|
|
1996
2168
|
common: {
|
|
@@ -2003,7 +2175,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2003
2175
|
}
|
|
2004
2176
|
await CreateObject(key, obj);
|
|
2005
2177
|
|
|
2006
|
-
key =
|
|
2178
|
+
key = SystemName + ".Statistics." + period + ".Hybrid";
|
|
2007
2179
|
obj = {
|
|
2008
2180
|
type: "state",
|
|
2009
2181
|
common: {
|
|
@@ -2016,7 +2188,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2016
2188
|
}
|
|
2017
2189
|
await CreateObject(key, obj);
|
|
2018
2190
|
|
|
2019
|
-
key =
|
|
2191
|
+
key = SystemName + ".Statistics." + period + ".ChgCosts";
|
|
2020
2192
|
obj = {
|
|
2021
2193
|
type: "state",
|
|
2022
2194
|
common: {
|
|
@@ -2029,7 +2201,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2029
2201
|
}
|
|
2030
2202
|
await CreateObject(key, obj);
|
|
2031
2203
|
|
|
2032
|
-
key =
|
|
2204
|
+
key = SystemName + ".Statistics." + period + ".HybridCosts";
|
|
2033
2205
|
obj = {
|
|
2034
2206
|
type: "state",
|
|
2035
2207
|
common: {
|
|
@@ -2045,7 +2217,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2045
2217
|
|
|
2046
2218
|
if (period == "Week" || period == "Month" || period == "Year") {
|
|
2047
2219
|
|
|
2048
|
-
key =
|
|
2220
|
+
key = SystemName + ".Statistics." + period + ".AvgCosts";
|
|
2049
2221
|
obj = {
|
|
2050
2222
|
type: "state",
|
|
2051
2223
|
common: {
|
|
@@ -2058,7 +2230,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2058
2230
|
}
|
|
2059
2231
|
await CreateObject(key, obj);
|
|
2060
2232
|
|
|
2061
|
-
key =
|
|
2233
|
+
key = SystemName + ".Statistics." + period + ".FixCosts";
|
|
2062
2234
|
obj = {
|
|
2063
2235
|
type: "state",
|
|
2064
2236
|
common: {
|
|
@@ -2071,7 +2243,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2071
2243
|
}
|
|
2072
2244
|
await CreateObject(key, obj);
|
|
2073
2245
|
|
|
2074
|
-
key =
|
|
2246
|
+
key = SystemName + ".Statistics." + period + ".OldCosts";
|
|
2075
2247
|
obj = {
|
|
2076
2248
|
type: "state",
|
|
2077
2249
|
common: {
|
|
@@ -2084,7 +2256,7 @@ async function checkVariables_MHCP_Statistic(system, period) {
|
|
|
2084
2256
|
}
|
|
2085
2257
|
await CreateObject(key, obj);
|
|
2086
2258
|
|
|
2087
|
-
key =
|
|
2259
|
+
key = SystemName + ".Statistics." + period + ".KmDiff";
|
|
2088
2260
|
obj = {
|
|
2089
2261
|
type: "state",
|
|
2090
2262
|
common: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.amtronwallbox",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.5",
|
|
4
4
|
"description": "ioBroker Adapter for AMTRON wallboxes",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "René G.",
|
|
@@ -21,9 +21,9 @@
|
|
|
21
21
|
"url": "https://github.com/rg-engineering/ioBroker.amtronwallbox"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@iobroker/adapter-core": "
|
|
24
|
+
"@iobroker/adapter-core": "3.0.3",
|
|
25
25
|
"axios": "1.4.0",
|
|
26
|
-
"cron": "2.4.
|
|
26
|
+
"cron": "2.4.1"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
29
|
"@iobroker/adapter-dev": "1.2.0",
|
|
@@ -32,15 +32,15 @@
|
|
|
32
32
|
"@types/chai-as-promised": "7.1.5",
|
|
33
33
|
"@types/gulp": "4.0.13",
|
|
34
34
|
"@types/mocha": "10.0.1",
|
|
35
|
-
"@types/node": "20.
|
|
35
|
+
"@types/node": "20.5.6",
|
|
36
36
|
"@types/proxyquire": "1.3.28",
|
|
37
37
|
"@types/request-promise-native": "1.0.18",
|
|
38
|
-
"@types/sinon": "10.0.
|
|
38
|
+
"@types/sinon": "10.0.16",
|
|
39
39
|
"@types/sinon-chai": "3.2.9",
|
|
40
40
|
"axios": "1.4.0",
|
|
41
|
-
"chai": "4.3.
|
|
41
|
+
"chai": "4.3.8",
|
|
42
42
|
"chai-as-promised": "7.1.1",
|
|
43
|
-
"eslint": "8.
|
|
43
|
+
"eslint": "8.47.0",
|
|
44
44
|
"gulp": "4.0.2",
|
|
45
45
|
"mocha": "10.2.0",
|
|
46
46
|
"proxyquire": "2.1.3",
|