iobroker.lorawan 1.6.6 → 1.7.0
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 +5 -0
- package/io-package.json +16 -16
- package/lib/modules/assignhandler.js +11 -0
- package/main.js +27 -23
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -23,6 +23,11 @@ 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.7.0 (2025-02-18)
|
|
27
|
+
* (BenAhrdt) add Volt to assignhandler with unit "V"
|
|
28
|
+
* (BenAhrdt) update dependency for admin and js-controller
|
|
29
|
+
* (BenAhrdt) update release script dependecie to 3.8
|
|
30
|
+
|
|
26
31
|
### 1.6.6 (2025-01-27)
|
|
27
32
|
* (BenAhrdt) start with known profiles
|
|
28
33
|
|
package/io-package.json
CHANGED
|
@@ -1,8 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "lorawan",
|
|
4
|
-
"version": "1.
|
|
4
|
+
"version": "1.7.0",
|
|
5
5
|
"news": {
|
|
6
|
+
"1.7.0": {
|
|
7
|
+
"en": "add Volt to assignhandler with unit \"V\"\nupdate dependency for admin and js-controller\nupdate release script dependecie to 3.8",
|
|
8
|
+
"de": "volt zuzuordnende Handler mit Einheit \"V\" hinzufügen\naktualisierung der abhängigkeit von admin und js-controller\nupdate release script abhängigecie to 3.8",
|
|
9
|
+
"ru": "добавить Volt для цедентификатора с блоком \"V\"\nобновление зависимости для admin и js-controller\nобновление сценария выхода зависит от 3,8",
|
|
10
|
+
"pt": "adicionar Volt ao asignhandler com unidade \"V\"\ndependência de atualização para admin e js-controller\nupdate script dependcie to 3.8",
|
|
11
|
+
"nl": "voeg Volt toe aan de toewijsmachine met eenheid \"V\"\nupdate afhankelijkheid voor admin en js-controller\nupdate release script afhankelijk van 3,8",
|
|
12
|
+
"fr": "ajouter Volt à l'adjudant avec l'unité \"V\"\nmettre à jour la dépendance pour admin et js-controller\nmettre à jour le script de sortie de dépendance à 3.8",
|
|
13
|
+
"it": "aggiungere Volt a assegnatore con unità \"V\"\naggiornamento della dipendenza da admin e js-controller\naggiornamento dello script di rilascio dipendeecie a 3.8",
|
|
14
|
+
"es": "añadir Volt al cedente con unidad \"V\"\nactualización dependencia para administración y js-controller\nactualización script dependcie de 3.8",
|
|
15
|
+
"pl": "dodać Volt do assignhandlera z jednostką \"V\"\naktualizacja zależności dla administratora i kontrolera js-\nupdate release script dependecie to 3.8",
|
|
16
|
+
"uk": "додати Волт до приставки з блоком \"В\"\nоновлення залежності для адміністратора та js-controller\nоновити сценарій релізу залежно від 3,8",
|
|
17
|
+
"zh-cn": "添加Volt 以指定“ V” 单元的手列\n更新管理员和js控制器的依赖性\n将发布脚本依赖性更新到 3. 8"
|
|
18
|
+
},
|
|
6
19
|
"1.6.6": {
|
|
7
20
|
"en": "start with known profiles",
|
|
8
21
|
"de": "beginnen mit bekannten profilen",
|
|
@@ -80,19 +93,6 @@
|
|
|
80
93
|
"pl": "korekta roli w odniesieniu do stanu ExtenalTemperatur",
|
|
81
94
|
"uk": "корекція ролі для держави ExtenalTemperatur",
|
|
82
95
|
"zh-cn": "校正状态ExtenalTemperatur的作用"
|
|
83
|
-
},
|
|
84
|
-
"1.6.0": {
|
|
85
|
-
"en": "update eslint",
|
|
86
|
-
"de": "update eslint",
|
|
87
|
-
"ru": "обновление eslint",
|
|
88
|
-
"pt": "atualização eslint",
|
|
89
|
-
"nl": "eslint bijwerken",
|
|
90
|
-
"fr": "mettre à jour eslint",
|
|
91
|
-
"it": "aggiornamento eslint",
|
|
92
|
-
"es": "update eslint",
|
|
93
|
-
"pl": "update eslint",
|
|
94
|
-
"uk": "оновлення eslint",
|
|
95
|
-
"zh-cn": "更新埃斯林特"
|
|
96
96
|
}
|
|
97
97
|
},
|
|
98
98
|
"titleLang": {
|
|
@@ -150,12 +150,12 @@
|
|
|
150
150
|
},
|
|
151
151
|
"dependencies": [
|
|
152
152
|
{
|
|
153
|
-
"js-controller": ">=
|
|
153
|
+
"js-controller": ">=7.0.6"
|
|
154
154
|
}
|
|
155
155
|
],
|
|
156
156
|
"globalDependencies": [
|
|
157
157
|
{
|
|
158
|
-
"admin": ">=
|
|
158
|
+
"admin": ">=7.4.10"
|
|
159
159
|
}
|
|
160
160
|
]
|
|
161
161
|
},
|
|
@@ -42,6 +42,17 @@ class assignhandlerClass {
|
|
|
42
42
|
},
|
|
43
43
|
},
|
|
44
44
|
},
|
|
45
|
+
Volt: {
|
|
46
|
+
approvedFolders: {
|
|
47
|
+
'uplink.decoded': {
|
|
48
|
+
assignfunction: this.commonAssign,
|
|
49
|
+
common: {
|
|
50
|
+
role: 'value.voltage',
|
|
51
|
+
unit: 'V',
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
},
|
|
45
56
|
BatteryVoltage: {
|
|
46
57
|
approvedFolders: {
|
|
47
58
|
'uplink.decoded': {
|
package/main.js
CHANGED
|
@@ -75,7 +75,9 @@ class Lorawan extends utils.Adapter {
|
|
|
75
75
|
);
|
|
76
76
|
/*
|
|
77
77
|
setTimeout(async () => {
|
|
78
|
+
this.log.debug('vor Simulation');
|
|
78
79
|
await this.startSimulation();
|
|
80
|
+
this.log.debug('nach Simulation');
|
|
79
81
|
}, 5000);
|
|
80
82
|
*/
|
|
81
83
|
/*this.simulation.timeout = setTimeout(async () => {
|
|
@@ -191,53 +193,52 @@ class Lorawan extends utils.Adapter {
|
|
|
191
193
|
// Chipstack
|
|
192
194
|
const topic = 'application/d63c10b6-9263-4ab3-9299-4308fa19a2ad/device/a84041f621857cd2/event/up';
|
|
193
195
|
const message = {
|
|
194
|
-
deduplicationId: '
|
|
195
|
-
time: '
|
|
196
|
+
deduplicationId: '6abe80d5-96a0-43c6-a098-2959cdbbf932',
|
|
197
|
+
time: '2025-02-18T13:49:19.477286+00:00',
|
|
196
198
|
deviceInfo: {
|
|
197
199
|
tenantId: '52f14cd4-c6f1-4fbd-8f87-4025e1d49242',
|
|
198
200
|
tenantName: 'ChirpStack',
|
|
199
|
-
applicationId: '
|
|
200
|
-
applicationName: '
|
|
201
|
-
deviceProfileId: '
|
|
201
|
+
applicationId: 'bac5ba56-f9c6-4d98-a609-8366e048495d',
|
|
202
|
+
applicationName: 'Pool',
|
|
203
|
+
deviceProfileId: 'e847fd4b-a87e-452c-91b8-a4fbaa51acfa',
|
|
202
204
|
deviceProfileName: 'Dragino Feuchtesenor',
|
|
203
205
|
deviceName: 'Skimmer',
|
|
204
206
|
devEui: 'a84041f621857cd2',
|
|
205
207
|
deviceClassEnabled: 'CLASS_A',
|
|
206
208
|
tags: {},
|
|
207
209
|
},
|
|
208
|
-
devAddr: '
|
|
210
|
+
devAddr: '01cdf20a',
|
|
209
211
|
adr: true,
|
|
210
212
|
dr: 5,
|
|
211
|
-
fCnt:
|
|
213
|
+
fCnt: 169,
|
|
212
214
|
fPort: 2,
|
|
213
215
|
confirmed: false,
|
|
214
|
-
data: '
|
|
216
|
+
data: 'DPYBAZ///AA9',
|
|
215
217
|
object: {
|
|
216
|
-
Test: { zweite: { dritte: { a: 4 } } },
|
|
217
|
-
soilconductivity: 0.0,
|
|
218
|
-
soiltemperature: -0.1,
|
|
219
218
|
volt: 3.318,
|
|
220
|
-
|
|
219
|
+
soiltemperature: -0.4,
|
|
220
|
+
soilconductivity: 61,
|
|
221
|
+
devicetype: 'Dragino',
|
|
222
|
+
soilmoisture: 41.5,
|
|
221
223
|
},
|
|
222
224
|
rxInfo: [
|
|
223
225
|
{
|
|
224
|
-
gatewayId: '
|
|
225
|
-
uplinkId:
|
|
226
|
-
gwTime: '
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
context: 'qESemw==',
|
|
233
|
-
metadata: { region_config_id: 'eu868', region_common_name: 'EU868' },
|
|
226
|
+
gatewayId: '503035416e314750',
|
|
227
|
+
uplinkId: 3073,
|
|
228
|
+
gwTime: '2025-02-18T13:49:19.477286+00:00',
|
|
229
|
+
rssi: -110,
|
|
230
|
+
snr: 2,
|
|
231
|
+
channel: 7,
|
|
232
|
+
location: { latitude: 50.693467319817266, longitude: 8.47676753997803 },
|
|
233
|
+
context: 'woEwlA==',
|
|
234
234
|
crcStatus: 'CRC_OK',
|
|
235
235
|
},
|
|
236
236
|
],
|
|
237
237
|
txInfo: {
|
|
238
|
-
frequency:
|
|
238
|
+
frequency: 867900000,
|
|
239
239
|
modulation: { lora: { bandwidth: 125000, spreadingFactor: 7, codeRate: 'CR_4_5' } },
|
|
240
240
|
},
|
|
241
|
+
regionConfigId: 'eu868',
|
|
241
242
|
};
|
|
242
243
|
//const topic = "application/d63c10b6-9263-4ab3-9299-4308fa19a2ad/device/a84041f621857cd2/command/down";
|
|
243
244
|
//const message = {"devEui":"a84041f621857cd2","confirmed":false,"fPort":1,"data":"AQAqMA=="};
|
|
@@ -276,6 +277,9 @@ class Lorawan extends utils.Adapter {
|
|
|
276
277
|
//const topic = "application/59bcc5a7-59e2-4481-9615-fc4e58791915/device/70b3d52dd300ed31/command/down";
|
|
277
278
|
//const message = {"devEui": "70b3d52dd300ed31", "confirmed": false,"fPort": 1,"data": "DQEYDQEY"};
|
|
278
279
|
|
|
280
|
+
this.log.debug(`incomming topic: ${topic}`);
|
|
281
|
+
this.log.debug(`incomming message: ${JSON.stringify(message)}`);
|
|
282
|
+
|
|
279
283
|
await this.messagehandler?.handleMessage(topic, message);
|
|
280
284
|
}
|
|
281
285
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.lorawan",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.7.0",
|
|
4
4
|
"description": "converts the desired lora gateway data to a ioBroker structure",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "BenAhrdt",
|
|
@@ -31,18 +31,18 @@
|
|
|
31
31
|
"node-schedule": "^2.1.1"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@alcalzone/release-script": "^3.
|
|
34
|
+
"@alcalzone/release-script": "^3.8.0",
|
|
35
35
|
"@alcalzone/release-script-plugin-iobroker": "^3.7.2",
|
|
36
36
|
"@alcalzone/release-script-plugin-license": "^3.7.0",
|
|
37
37
|
"@alcalzone/release-script-plugin-manual-review": "^3.7.0",
|
|
38
38
|
"@iobroker/adapter-dev": "^1.3.0",
|
|
39
39
|
"@iobroker/eslint-config": "^1.0.0",
|
|
40
|
-
"@iobroker/testing": "^5.0.
|
|
40
|
+
"@iobroker/testing": "^5.0.3",
|
|
41
41
|
"@tsconfig/node18": "^18.2.2",
|
|
42
42
|
"@types/chai": "^4.3.11",
|
|
43
43
|
"@types/chai-as-promised": "^8.0.1",
|
|
44
44
|
"@types/mocha": "^10.0.10",
|
|
45
|
-
"@types/node": "^22.
|
|
45
|
+
"@types/node": "^22.13.0",
|
|
46
46
|
"@types/proxyquire": "^1.3.31",
|
|
47
47
|
"@types/sinon": "^17.0.3",
|
|
48
48
|
"@types/sinon-chai": "^3.2.12",
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"proxyquire": "^2.1.3",
|
|
53
53
|
"sinon": "^19.0.2",
|
|
54
54
|
"sinon-chai": "^3.7.0",
|
|
55
|
-
"typescript": "~5.7.
|
|
55
|
+
"typescript": "~5.7.3"
|
|
56
56
|
},
|
|
57
57
|
"main": "main.js",
|
|
58
58
|
"files": [
|