Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.2.5 #225

Merged
merged 1 commit into from
Aug 10, 2024
Merged

1.2.5 #225

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,11 @@ to be done in admin


## Changelog:
### 1.2.4

### 1.2.4 (npm)
* (foxthefox) eslint upgrade and corrections

### 1.2.4 (npm)
* (foxthefox) IOB checker corrections


Expand Down
19 changes: 19 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import globals from 'globals';
import pluginJs from '@eslint/js';

export default [
{ files: [ '**/*.js' ], languageOptions: { sourceType: 'commonjs' } },
{
ignores: [
'.dev-server/**/*',
'admin/build/**/*',
'admin/words.js',
'test/**/*',
'main.test.js',
'jeelink.js',
'lib/**/*'
]
},
{ languageOptions: { globals: globals.browser } },
pluginJs.configs.recommended
];
295 changes: 157 additions & 138 deletions io-package.json
Original file line number Diff line number Diff line change
@@ -1,140 +1,159 @@
{
"common": {
"name": "jeelink",
"version": "1.2.4",
"news": {
"1.2.4": {
"en": "IOB checker corrections",
"de": "Korrekturen des IOB-Checkers",
"ru": "Исправления проверки IOB",
"pt": "Correções do verificador IOB",
"nl": "IOB-checkercorrecties",
"fr": "Corrections du vérificateur IOB",
"it": "Correzioni del controllo IOB",
"es": "Correcciones del verificador IOB",
"pl": "Poprawki sprawdzania IOB",
"uk": "Виправлення перевірки IOB",
"zh-cn": "IOB 检查器更正"
},
"1.2.3": {
"en": "serialport12, translation with adapter-dev",
"de": "Serialport12, Übersetzung mit Adapter-Dev",
"ru": "серийный порт12, перевод с помощью адаптера-dev",
"pt": "serialport12, tradução com adaptador-dev",
"nl": "serialport12, vertaling met adapter-dev",
"fr": "Serialport12, traduction avec adapter-dev",
"it": "serialport12, traduzione con adattatore-dev",
"es": "serialport12, traducción con adaptador-dev",
"pl": "serialport12, tłumaczenie za pomocą adapter-dev",
"uk": "serialport12, переклад за допомогою adapter-dev",
"zh-cn": "Serialport12,使用适配器开发进行翻译"
}
},
"titleLang": {
"en": "jeelink devices",
"de": "Jeelink-Geräte",
"ru": "джилинк устройства",
"pt": "dispositivos jeelink",
"nl": "jeelink-apparaten",
"fr": "appareils jeelink",
"it": "dispositivi jeelink",
"es": "dispositivos jeelink",
"pl": "urządzenia jeelink",
"zh-cn": "捷联设备",
"uk": "пристрої jeelink"
},
"desc": {
"en": "read 868Mhz sensors of Technoline, emonTH, Lacrosse ",
"de": "lese 868Mhz Sensoren von Technoline, emonTH, Lacrosse",
"ru": "считывать датчики 868 МГц Technoline, emonTH, Lacrosse",
"pt": "ler sensores de 868Mhz de Technoline, emonTH, Lacrosse",
"nl": "lees 868Mhz sensoren van Technoline, emonTH, Lacrosse",
"fr": "lire les capteurs 868Mhz de Technoline, emonTH, Lacrosse",
"it": "leggere i sensori 868Mhz di Technoline, emonTH, Lacrosse",
"es": "leer sensores de 868Mhz de Technoline, emonTH, Lacrosse",
"pl": "odczytaj czujniki 868Mhz Technoline, emonTH, Lacrosse",
"zh-cn": "读取 Technoline、emonTH、Lacrosse 的 868Mhz 传感器",
"uk": "читати 868Mhz датчики Technoline, emonTH, Lacrosse"
},
"platform": "Javascript/Node.js",
"mode": "daemon",
"keywords": [ "jeelink", "openenergy", "RFM", "LaCrosse", "emonTH" ],
"type": "hardware",
"icon": "jeelab_logo.png",
"extIcon": "https://raw.githubusercontent.com/foxthefox/ioBroker.jeelink/master/admin/jeelab_logo.png",
"readme": "https://github.com/foxthefox/ioBroker.jeelink/blob/master/README.md",
"loglevel": "info",
"materialize": true,
"compact": true,
"tier": 3,
"licenseInformation": {
"license": "MIT",
"link": "https://opensource.org/license/mit/",
"type": "free"
},
"connectionType": "local",
"dataSource": "push",
"authors": [
{
"name": "foxthefox",
"email": "[email protected]"
}
],
"dependencies": [
{
"js-controller": ">=4.0.24"
}
]
},
"native": {
"serialport": "/dev/ttyUSB0",
"baudrate": 57600,
"command": "",
"command_en": false,
"sensors": [
{
"sid": "18",
"usid": "1",
"stype": "emonTH",
"name": "example emonTH"
},
{
"sid": "0",
"usid": "2",
"stype": "LaCrosseBMP180",
"name": "example superjee"
},
{
"sid": "55",
"usid": "3",
"stype": "LaCrosseDTH",
"name": "example LaCrosseDTH"
}
]
},
"objects": [],
"instanceObjects": [
{
"_id": "foundDevices",
"type": "channel",
"common": {
"name": "foundDevices",
"role": "device"
},
"native": {}
},
{
"_id": "foundDevices.state",
"type": "state",
"common": {
"name": "new Devices",
"type": "array",
"role": "list",
"read": true,
"write": true,
"desc": "new Devices"
},
"native": {}
}
]
"common": {
"name": "jeelink",
"version": "1.2.5",
"news": {
"1.2.5": {
"en": "eslint upgrade and corrections",
"de": "Eslint-Upgrade und Korrekturen",
"ru": "обновление и исправления eslint",
"pt": "atualização e correções do eslint",
"nl": "eslint-upgrade en correcties",
"fr": "mise à jour et corrections d'Eslint",
"it": "aggiornamento e correzioni di eslint",
"es": "actualización y correcciones de eslint",
"pl": "aktualizacja i poprawki eslint",
"uk": "оновлення та виправлення eslint",
"zh-cn": "eslint 升级和修正"
},
"1.2.4": {
"en": "IOB checker corrections",
"de": "Korrekturen des IOB-Checkers",
"ru": "Исправления проверки IOB",
"pt": "Correções do verificador IOB",
"nl": "IOB-checkercorrecties",
"fr": "Corrections du vérificateur IOB",
"it": "Correzioni del controllo IOB",
"es": "Correcciones del verificador IOB",
"pl": "Poprawki sprawdzania IOB",
"uk": "Виправлення перевірки IOB",
"zh-cn": "IOB 检查器更正"
},
"1.2.3": {
"en": "serialport12, translation with adapter-dev",
"de": "Serialport12, Übersetzung mit Adapter-Dev",
"ru": "серийный порт12, перевод с помощью адаптера-dev",
"pt": "serialport12, tradução com adaptador-dev",
"nl": "serialport12, vertaling met adapter-dev",
"fr": "Serialport12, traduction avec adapter-dev",
"it": "serialport12, traduzione con adattatore-dev",
"es": "serialport12, traducción con adaptador-dev",
"pl": "serialport12, tłumaczenie za pomocą adapter-dev",
"uk": "serialport12, переклад за допомогою adapter-dev",
"zh-cn": "Serialport12,使用适配器开发进行翻译"
}
},
"titleLang": {
"en": "jeelink devices",
"de": "Jeelink-Geräte",
"ru": "джилинк устройства",
"pt": "dispositivos jeelink",
"nl": "jeelink-apparaten",
"fr": "appareils jeelink",
"it": "dispositivi jeelink",
"es": "dispositivos jeelink",
"pl": "urządzenia jeelink",
"zh-cn": "捷联设备",
"uk": "пристрої jeelink"
},
"desc": {
"en": "read 868Mhz sensors of Technoline, emonTH, Lacrosse ",
"de": "lese 868Mhz Sensoren von Technoline, emonTH, Lacrosse",
"ru": "считывать датчики 868 МГц Technoline, emonTH, Lacrosse",
"pt": "ler sensores de 868Mhz de Technoline, emonTH, Lacrosse",
"nl": "lees 868Mhz sensoren van Technoline, emonTH, Lacrosse",
"fr": "lire les capteurs 868Mhz de Technoline, emonTH, Lacrosse",
"it": "leggere i sensori 868Mhz di Technoline, emonTH, Lacrosse",
"es": "leer sensores de 868Mhz de Technoline, emonTH, Lacrosse",
"pl": "odczytaj czujniki 868Mhz Technoline, emonTH, Lacrosse",
"zh-cn": "读取 Technoline、emonTH、Lacrosse 的 868Mhz 传感器",
"uk": "читати 868Mhz датчики Technoline, emonTH, Lacrosse"
},
"platform": "Javascript/Node.js",
"mode": "daemon",
"keywords": [
"jeelink",
"openenergy",
"RFM",
"LaCrosse",
"emonTH"
],
"type": "hardware",
"icon": "jeelab_logo.png",
"extIcon": "https://raw.githubusercontent.com/foxthefox/ioBroker.jeelink/master/admin/jeelab_logo.png",
"readme": "https://github.com/foxthefox/ioBroker.jeelink/blob/master/README.md",
"loglevel": "info",
"materialize": true,
"compact": true,
"tier": 3,
"licenseInformation": {
"license": "MIT",
"link": "https://opensource.org/license/mit/",
"type": "free"
},
"connectionType": "local",
"dataSource": "push",
"authors": [
{
"name": "foxthefox",
"email": "[email protected]"
}
],
"dependencies": [
{
"js-controller": ">=4.0.24"
}
]
},
"native": {
"serialport": "/dev/ttyUSB0",
"baudrate": 57600,
"command": "",
"command_en": false,
"sensors": [
{
"sid": "18",
"usid": "1",
"stype": "emonTH",
"name": "example emonTH"
},
{
"sid": "0",
"usid": "2",
"stype": "LaCrosseBMP180",
"name": "example superjee"
},
{
"sid": "55",
"usid": "3",
"stype": "LaCrosseDTH",
"name": "example LaCrosseDTH"
}
]
},
"objects": [],
"instanceObjects": [
{
"_id": "foundDevices",
"type": "channel",
"common": {
"name": "foundDevices",
"role": "device"
},
"native": {}
},
{
"_id": "foundDevices.state",
"type": "state",
"common": {
"name": "new Devices",
"type": "array",
"role": "list",
"read": true,
"write": true,
"desc": "new Devices"
},
"native": {}
}
]
}
13 changes: 7 additions & 6 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class Jeelink extends utils.Adapter {
if (obj[anz].stype == 'emonTH') {
await this.defineemonTH(obj[anz].usid, obj[anz].name);
} else if (obj[anz].stype == 'emonWater') {
await this.defineemonWater(obj[anz].usid, obj[anz].name);
await this.defineemonWater(obj[anz].usid);
} else if (obj[anz].stype.indexOf('LaCrosseDT') == 0) {
await this.defineLaCrosseDTH(obj[anz].usid, obj[anz].name, obj[anz].stype);
} else if (obj[anz].stype == 'LaCrosseBMP180') {
Expand Down Expand Up @@ -144,6 +144,7 @@ class Jeelink extends utils.Adapter {
//clearInterval(interval1);
callback();
} catch (e) {
this.log.error(e);
callback();
}
}
Expand Down Expand Up @@ -188,7 +189,7 @@ class Jeelink extends utils.Adapter {
// | |-------------------- [2]Sensor ID
// |----------------------- [0]fix "OK"

async defineemonWater(id, name) {
async defineemonWater(id) {
await this.setObjectNotExistsAsync('emonWater_' + id, {
type: 'channel',
common: {
Expand Down Expand Up @@ -1859,10 +1860,10 @@ class Jeelink extends utils.Adapter {
7 => 'WindGustRef',
8 => 'RainTipCount',
9 => 'RainSecs',
 10 => 'Solar',
 11 => 'VoltageSolar',
 12 => 'VoltageCapacity',
 13 => 'SoilLeaf',
10 => 'Solar',
11 => 'VoltageSolar',
12 => 'VoltageCapacity',
13 => 'SoilLeaf',
14 => 'UV',
15.1= SoilTemperature.1
16.1= SoilMoisture.1
Expand Down
Loading
Loading