Skip to content

Commit

Permalink
chore: release v0.3.4
Browse files Browse the repository at this point in the history
* (DutchmanNL) Added doorOpen indicator, Fixes [DrozmotiX#115](DrozmotiX#115)
  • Loading branch information
DutchmanNL committed Oct 28, 2024
1 parent 9bc273f commit 1a690a6
Show file tree
Hide file tree
Showing 7 changed files with 35 additions and 6 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ Thumbs.db

# i18n intermediate files
admin/i18n/flat.txt
admin/i18n/*/flat.txt
admin/i18n/*/flat.txt
warnMessages.json
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ All of this helps me to provide error-free adapters that basically never crash.
Placeholder for the next version (at the beginning of the line):
### **WORK IN PROGRESS**
-->
### 0.3.4 (2024-10-28) - Door Indicator Fixes #115
* (DutchmanNL) Added doorOpen indicator, Fixes [#115](https://github.com/DrozmotiX/ioBroker.bambulab/issues/115)

### 0.3.3 (2024-10-27) - Bugfixes
* (DutchmanNL) update state definitions, (solves [#77](https://github.com/DrozmotiX/ioBroker.bambulab/issues/77) [#58](https://github.com/DrozmotiX/ioBroker.bambulab/issues/58))
* (DutchmanNL) update connection handling, show connection error only once (Solves #99 #78 #74)
Expand Down
15 changes: 14 additions & 1 deletion io-package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,21 @@
{
"common": {
"name": "bambulab",
"version": "0.3.3",
"version": "0.3.4",
"news": {
"0.3.4": {
"en": "Added doorOpen indicator",
"de": "Tür Indikator hinzugefügt",
"ru": "Добавленная дверь Open indicator",
"pt": "Porta adicionada Indicador aberto",
"nl": "Toegevoegde deur Open indicator",
"fr": "Porte ajoutée Indicateur ouvert",
"it": "Aggiunto la porta Indicatore aperto",
"es": "Puerta Open indicator",
"pl": "Dodano drzwi Inne informacje",
"uk": "Додані двері Відкрити індикатор",
"zh-cn": "添加门 开放指标"
},
"0.3.3": {
"en": "update state definitions, (solves #77 #58)\nupdate connection handling, show connection error only once (Solves #99 #78 #74)",
"de": "aktualisierung von zustandsdefinitionen, (lösungen #77 #58)\nupdate-Verbindungshandling, Verbindungsfehler nur einmal anzeigen (Solves #99 #78 #74)",
Expand Down
7 changes: 6 additions & 1 deletion lib/state_attr.js
Original file line number Diff line number Diff line change
Expand Up @@ -819,7 +819,12 @@ const state_attrb = {
'name': 'RFID',
'type': 'number',
'role': 'state'
}
},
'doorOpen': {
'name': 'Door indicator',
'type': 'boolean',
'role': 'indicator'
},
};


Expand Down
7 changes: 7 additions & 0 deletions main.js
Original file line number Diff line number Diff line change
Expand Up @@ -248,6 +248,13 @@ class Bambulab extends utils.Adapter {
}
}

// Translate home_flag to door state
if (message.print.home_flag === 14796168) {
message.print.doorOpen = true;
} else if (message.print.home_flag === 6407560) {
message.print.doorOpen = false;
}

// Explore JSON & create states
const returnJONexplorer = await jsonExplorer.traverseJson(message.print, this.config.serial, false, false, 0);
this.log.debug(`Response of JSONexploer: ${JSON.stringify(returnJONexplorer)}`);
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "iobroker.bambulab",
"version": "0.3.3",
"version": "0.3.4",
"description": "Connects to Bambulab 3d printers to retrieve data of current print and control main aspects",
"author": {
"name": "DutchmanNL",
Expand Down

0 comments on commit 1a690a6

Please sign in to comment.