iobroker.lorawan 1.18.38 → 1.18.40

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 CHANGED
@@ -23,6 +23,12 @@ For now there is documentation in English here: https://wiki.hafenmeister.de
23
23
  Placeholder for the next version (at the beginning of the line):
24
24
  ### **WORK IN PROGRESS**
25
25
  -->
26
+ ### 1.18.40 (2025-12-01)
27
+ * (BenAhrdt) change hash
28
+
29
+ ### 1.18.39 (2025-11-30)
30
+ * (BenAhrdt) build more roles for contactsensors, in case of role. (window, door, gate ...)
31
+
26
32
  ### 1.18.38 (2025-11-30)
27
33
  * (BenAhrdt) add device class to cover in config
28
34
 
package/io-package.json CHANGED
@@ -1,8 +1,34 @@
1
1
  {
2
2
  "common": {
3
3
  "name": "lorawan",
4
- "version": "1.18.38",
4
+ "version": "1.18.40",
5
5
  "news": {
6
+ "1.18.40": {
7
+ "en": "change hash",
8
+ "de": "ändern hash",
9
+ "ru": "изменить хеш",
10
+ "pt": "mudar hash",
11
+ "nl": "hash veranderen",
12
+ "fr": "changement hash",
13
+ "it": "cambiamento hash",
14
+ "es": "cambio hash",
15
+ "pl": "zmień hasz",
16
+ "uk": "зміна хеш",
17
+ "zh-cn": "变化散列"
18
+ },
19
+ "1.18.39": {
20
+ "en": "build more roles for contactsensors, in case of role. (window, door, gate ...)",
21
+ "de": "bauen mehr rollen für kontaktsensoren, im falle der rolle. (fenster, tür, tor ...)",
22
+ "ru": "построить больше ролей для контактенсоров, в случае роли. (окно, дверь, ворота...)",
23
+ "pt": "constrói mais papéis para os agentes de contacto, em caso de papel. (janela, porta, portão...)",
24
+ "nl": "meer rollen voor contactpersonen te creëren, in geval van rol. (raam, deur, poort ...)",
25
+ "fr": "construire plus de rôles pour les capteurs de contacts, en cas de rôle. (fenêtre, porte, portail...)",
26
+ "it": "costruire più ruoli per i sensori di contatto, in caso di ruolo. (finestra, porta, cancello ...)",
27
+ "es": "crear más roles para los contactensores, en caso de papel. (ventana, puerta, puerta...)",
28
+ "pl": "budować więcej ról dla czujników kontaktu, w przypadku roli. (okno, drzwi, brama...)",
29
+ "uk": "будувати більше ролей для контакторів, у разі ролі. (вікно, двері, ворота ...)",
30
+ "zh-cn": "为联系人建立更多的角色,如果是角色的话。 (窗,门,门"
31
+ },
6
32
  "1.18.38": {
7
33
  "en": "add device class to cover in config",
8
34
  "de": "geräteklasse in config hinzufügen",
@@ -67,32 +93,6 @@
67
93
  "pl": "zmienione tłumaczenie",
68
94
  "uk": "зміни перекладу",
69
95
  "zh-cn": "翻译更改"
70
- },
71
- "1.18.33": {
72
- "en": "change state in Lock entity",
73
- "de": "änderungszustand in Sperreinrichtung",
74
- "ru": "изменение состояния Lock entity",
75
- "pt": "mudar o estado na entidade Bloquear",
76
- "nl": "veranderingstoestand in Lock-entiteit",
77
- "fr": "changement d'état dans l'entité de verrouillage",
78
- "it": "cambiamento stato in entità Lock",
79
- "es": "estado de cambio en la entidad Lock",
80
- "pl": "zmiana stanu w jednostce blokującej",
81
- "uk": "змінити стан в суб'єкті блокування",
82
- "zh-cn": "锁定实体中的变化状态"
83
- },
84
- "1.18.32": {
85
- "en": "Changes in cover and add Lock",
86
- "de": "Änderungen im Cover und hinzufügen Lock",
87
- "ru": "Изменения в покрытии и добавление блокировки",
88
- "pt": "Alterações na capa e adicionar bloqueio",
89
- "nl": "Wijzigingen in dekking en vergrendelen toevoegen",
90
- "fr": "Changements dans la couverture et ajouter Lock",
91
- "it": "Modifiche in copertina e aggiungere Lock",
92
- "es": "Cambios en la cubierta y añadir bloqueo",
93
- "pl": "Zmiany w okładce i dodać blokadę",
94
- "uk": "Зміни в кришці і додати блокування",
95
- "zh-cn": "封面和加锁的变化"
96
96
  }
97
97
  },
98
98
  "titleLang": {
@@ -1529,8 +1529,18 @@ class bridgeClass {
1529
1529
  if (entityType === 'binary_sensor') {
1530
1530
  if (role.includes('motion')) {
1531
1531
  attributes.device_class = 'motion';
1532
- } else if (role.includes('window') || role.includes('door')) {
1532
+ } else if (role.includes('window')) {
1533
+ attributes.device_class = 'window';
1534
+ } else if (role.includes('door')) {
1533
1535
  attributes.device_class = 'door';
1536
+ } else if (role.includes('gate')) {
1537
+ attributes.device_class = 'gate';
1538
+ } else if (role.includes('lock')) {
1539
+ attributes.device_class = 'lock';
1540
+ } else if (role.includes('garage')) {
1541
+ attributes.device_class = 'garage_door';
1542
+ } else if (role.includes('blind') || role.includes('shutter') || role.includes('open')) {
1543
+ attributes.device_class = 'opening';
1534
1544
  } else if (role.includes('smoke')) {
1535
1545
  attributes.device_class = 'smoke';
1536
1546
  } else if (role.includes('presence')) {
@@ -97,7 +97,15 @@ class bridgeMqttClientClass {
97
97
  this.adapter.log.debug(`incomming bridge topic: ${topic}`);
98
98
  this.adapter.log.debug(`incomming bridge message: ${message}`);
99
99
 
100
+ // String zuweisen, wenn JSON.parse ein Fehler auswirft.
100
101
  let payload = message.toString('utf8');
102
+
103
+ // Write into debug
104
+ if (await this.adapter.objectExists('bridge.debug.incommingTopic')) {
105
+ await this.adapter.setState('bridge.debug.incommingTopic', topic, true);
106
+ await this.adapter.setState('bridge.debug.incommingPayload', payload, true);
107
+ }
108
+
101
109
  // Message Parsen => Wenn nicht pasebar, dann string weitergeben
102
110
  try {
103
111
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
package/main.js CHANGED
@@ -45,7 +45,7 @@ class Lorawan extends utils.Adapter {
45
45
  this.version;
46
46
 
47
47
  this.secret = {
48
- hash: 'feda26376e3d3b38eae8efa48d055754eb0c388d6dbc7ced2ddb5f2f8166f417',
48
+ hash: 'f3988f71e0d6248fbf690c414bcb46b0500c3a8b3ec9adb9c66be2774ec12291',
49
49
  salt: 'LoRaWANBeScJoFr',
50
50
  };
51
51
  }
@@ -671,7 +671,13 @@ class Lorawan extends utils.Adapter {
671
671
  });
672
672
  this.extendObject('bridge.debug.topic', {
673
673
  type: 'state',
674
- common: { name: 'topic of mqtt message', type: 'string', def: '' },
674
+ common: {
675
+ name: 'topic of mqtt message',
676
+ type: 'string',
677
+ read: true,
678
+ write: true,
679
+ def: '',
680
+ },
675
681
  native: {},
676
682
  });
677
683
  this.extendObject('bridge.debug.payload', {
@@ -680,6 +686,8 @@ class Lorawan extends utils.Adapter {
680
686
  name: 'payload of mqtt message',
681
687
  type: 'string',
682
688
  role: 'json',
689
+ read: true,
690
+ write: true,
683
691
  def: '',
684
692
  },
685
693
  native: {},
@@ -690,10 +698,36 @@ class Lorawan extends utils.Adapter {
690
698
  name: 'payload of mqtt message',
691
699
  type: 'boolean',
692
700
  role: 'button',
701
+ read: false,
702
+ write: true,
693
703
  def: false,
694
704
  },
695
705
  native: {},
696
706
  });
707
+ // Incomming
708
+ this.extendObject('bridge.debug.incommingTopic', {
709
+ type: 'state',
710
+ common: {
711
+ name: 'topic of mqtt message',
712
+ type: 'string',
713
+ read: true,
714
+ write: false,
715
+ def: '',
716
+ },
717
+ native: {},
718
+ });
719
+ this.extendObject('bridge.debug.incommingPayload', {
720
+ type: 'state',
721
+ common: {
722
+ name: 'payload of mqtt message',
723
+ type: 'string',
724
+ role: 'json',
725
+ read: true,
726
+ write: false,
727
+ def: '',
728
+ },
729
+ native: {},
730
+ });
697
731
  await this.setState(id, '', true);
698
732
  }
699
733
  } else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "iobroker.lorawan",
3
- "version": "1.18.38",
3
+ "version": "1.18.40",
4
4
  "description": "converts the desired lora gateway data to a ioBroker structure",
5
5
  "author": {
6
6
  "name": "BenAhrdt",