GithubHelp home page GithubHelp logo

iobroker-community-adapters / iobroker.philips-air Goto Github PK

View Code? Open in Web Editor NEW
6.0 8.0 6.0 741 KB

Connects Philips air purifier with ioBroker

License: MIT License

HTML 9.95% CSS 0.55% JavaScript 89.51%
iobroker philips air-purifier

iobroker.philips-air's Introduction

Logo

ioBroker.philips-air

Number of Installations Number of Installations NPM version

Test and Release Translation status Downloads

This adapter uses Sentry libraries to automatically report exceptions and code errors to the developers. For more details and for information how to disable the error reporting see Sentry-Plugin Documentation! Sentry reporting is used starting with js-controller 3.0.

Philips air purifier adapter for ioBroker

Connects Philips air purifier with ioBroker. Tested only with AC2729, but should work with new purifier that communicate via COAP with encryption. AC2729

Link to philips website

Usage

Only IP address of device is required. Find it in your router (e.g. MiCO). It can happen, that some devices have not all variables, and they will stay unfilled in object tree.

Objects

Changelog

1.1.0 (2024-04-25)

  • (mcm1957) Adapter requires node.js >= 18 and js-controller >= 5 now
  • (mcm1957) Dependencies have been updated

1.0.3 (2022-12-23)

  • (Apollon77) Finalized and optimized HTTP communication protocol
  • (Apollon77) Fixed type issues with device.error

1.0.2 (2022-11-16)

  • (bluefox) Small fixes done
  • (bluefox) Added HTTP communication protocol (untested!)
  • (mdax82) Added gentle/GT for AC2939

0.1.7 (2022-05-19)

  • (Apollon77) Upgrade coap library

0.1.4 (2022-03-23)

  • (Apollon77) Downgrade coap library to restore functionality for some devices
  • (Apollon77) Prevent crash case and make control more flexible
  • (Apollon77) correctly handle control.function state

0.1.3 (2022-03-12)

  • (Apollon77) General updates and optimizations

0.1.1 (2020-10-14)

  • (bluefox) initial release

License

MIT License

Copyright (c) 2023-2024 ioBroker Community Developers [email protected]
Copyright (c) 2020-2022 ioBroker [email protected]

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

iobroker.philips-air's People

Contributors

apollon77 avatar dependabot[bot] avatar germanbluefox avatar mcm1957 avatar mdax82 avatar rg-engineering avatar schmakus avatar stefan200583 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

iobroker.philips-air's Issues

Add Modes

Hi,

for my model of the Philips Air, the “Mode” is shown as:
“AG” for Automatic
“T” for Turbo
“silent” for Sleepmode
The problem is that the selection “auto” and “turbo” in the selection is not setting anything on the device and even if I write “AG” or “T” manually into the mode, it is not reacting.

The newly introduced manual speed settings 1 and 2 by FW update are working perfect.

these modes are not defined so I can not add them only to the filed in ioBroker:

philips-air.0 2021-01-09 16:04:48.343 error at processImmediate (internal/timers.js:461:21)
philips-air.0 2021-01-09 16:04:48.343 error at Immediate. (/opt/iobroker/node_modules/iobroker.js-controller/lib/adapter.js:5384:37)
philips-air.0 2021-01-09 16:04:48.343 error at Object.stateChange (/opt/iobroker/node_modules/iobroker.philips-air/main.js:64:48)
philips-air.0 2021-01-09 16:04:48.343 error at AirPurifier.control (/opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:256:78)
philips-air.0 2021-01-09 16:04:48.343 error at Array.forEach ()
philips-air.0 2021-01-09 16:04:48.343 error at /opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:263:31
philips-air.0 2021-01-09 16:04:48.343 error (21240) Error: Invalid option for mode: A. Supported only: {"P":"auto","A":"allergen","S":"sleep","M":"manual","B":"bacteria","N":"night"}
philips-air.0 2021-01-09 16:04:48.333 error (21240) uncaught exception: Invalid option for mode: A. Supported only: {"P":"auto","A":"allergen","S":"sleep","M":"manual","B":"bacteria","N":"night"}

Philips Air purifier loses contact to Philips App

Hey everyone,

my Philips Air purifier 3000i loses contact to the Philips App when connected to this adapter and is shown "offline" in the app; the integration into ioBroker works like a charm, but is there a way to enable the app connection again (so parallel to the ioBroker connection)? Seems like the adapter is capturing the connection rights completely for itself.

Thanks!

Air fryer

Possible to add the Phillips air fryer ?

Please add support for AC3737/10

I bought the 2-in-1 air purifier and humidifier AC3737/10. The adapter is also connected for a short time (according to the adapter status).
A few states also have a value:

  • device.connectType: Online
  • device.deviceId: 09xxxxxxxxxxxxxxxxxxxxxxxxxxxxx637a
  • device.productId: 32xxxxxxxxxxxxxxxxxxxxxxxxxxx4e4a
  • device.started: 2023-11-25T17:40:29.113Z
  • statusType: status
  • device.uptime: 15130075
  • device.wifiVersion: [email protected]
  • info.connection: alternates between true and false
    Log after instance starts:
    starting. Version 1.0.3 in /opt/iobroker/node_modules/iobroker.philips-air, node: v16.17.1, js-controller: 4.0.23
    State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"
    State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"
    State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"
    ...

Is there a chance here? That would be great!
Let me know if you need more infos.

Compatibility check and testing for Node.js 14 and 16

Dear Adapter developer,

Node.js 14 is now available for a year and Node.js 16 was release just some days ago and will become LTS by October 2021. We plan to update the ioBroker Node.js recommendation (currently 12.x) to 14.x later this year.

Please check your adapter with Node.js 14 especially, and ideally also directly with Node.js 16

Please add both versions to the adapter testing which is executed on commits.

If your adapter requires a certain minimum version of Node.js please set the 'engine' setting in package.json accordingly! Please also do this if the adapter is not able to work in certain Node.js versions, so that ioBroker can prevent users from installing te adapter if not compatible!

On questions please talk to us at ioBroker/ioBroker.js-controller#1138

Please close the issue after you checked it.

Thank you very much for your support!

Please add support for AC0850/11

My AC0850/11 is basically being detected (and connected) via COAP and some values are being updated in the "device" folder, like
"connectType", "deviceId", "productId", started", "statusType", "uptime", "wifiVersion", and in the "info" folder, like "connection".
The other values are all null. Including support for the AC0850/11 would really be great!

object "fanSpeed" occures with different types and therefore causes Influxdb warnings

In opposite to my first impression, this issue is not new in version 0.1.4 but happens only occasionaly and was first noticed while helping @Apollon77 debugging 0.1.3 to 0.1.4.

The problem is that the object "fanSpeed" can have numeric and non-numeric contents - possible values in my logs are "silent", "1", "2", "3" and "turbo" whereas "1" is most often. Now, when "fanSpeed" is "silent" or "turbo", Influxdb logs warnings like this

1 Zeit warn Nachricht
influxdb.0 2022-03-23 11:06:12.492 warn Add Wb-Arbeitszimmer-Luftreiniger-fanSpeed to conflicting Points (2 now)
influxdb.0 2022-03-23 11:06:12.491 warn Error on writePoint("{"value":"silent","time":"2022-03-23T10:06:12.359Z","from":"system.adapter.influxdb.0","q":0,"ack":true}): Error: {"error":"partial write: field type conflict: input field "value" on measurement "Wb-Arbeitszimmer-Luftreiniger-fanSpeed" is type string, already exists as type float dropped=1"} / "{"error":"partial write: field type conflict: input field \"value\" on measurement \"Wb-Arbeitszimmer-Luftreiniger-fanSpeed\" is type string, already exists as type float dropped=1"}\n""

because the field already exists as a numeric field and the string "silent" cannot be stored in such a field.

Possible solutions:

  • map "silent" to "0" and "turbo" to "4" or "5" in the philips-air driver so that Influxdb gets numeric values always
  • maybe it is also possible to force Influxdb to store "fanSpeed" as strings always - I don't know - but for graphing numeric values are more handy

Compatibility check to js-controller 3.3 and Admin5 React UI

Dear Adapter developer,

with js-controller 3.2 and js-controller 3.3 some additional checks were added to make sure that created objects match to the specifications and also written state values match to the object definition.

If something is not correct this is logged as 'warning' or 'info' log.

Please take the time to verify your adapter by ideally starting with a fresh instance and do some actions and verify the log. If you see a warn log there from these checks please adjust the adapter and fix the relevant cases.

For questions please refer to ioBroker/ioBroker.js-controller#1301

Additionally we are preparing Admin 5 which will have a completely rewritten UI. Please install Admin 5, activate that new UI and verify that the configuration of you adapter works as expected also there.

More informations on Admin 5 can be found in Forum https://forum.iobroker.net/topic/44282/test-adapter-admin-5-0-x-alpha-der-neuen-ui

Please close the issue after you checked it.

Thank you very much for your support!

Mode settings different for AC4236/10

Hi,

for my model of the Philips Air, the “Mode” is shown as:
“AG” for Automatic
“T” for Turbo
“silent” for Sleepmode
The problem is that the selection “auto” and “turbo” in the selection is not setting anything on the device and even if I write “AG” or “T” manually into the mode, it is not reacting.

The newly introduced manual speed settings 1 and 2 by FW update are working perfect.

some warnings with js-controller 3.3

There are some warnings with js-controller 3.3:

philips-air.0 | 2021-05-16 14:56:43.710 | warn | State  "philips-air.0.status.totalVolatileOrganicCompounds" has no existing  object, this might lead to an error in future versions
philips-air.0 | 2021-05-16 14:56:42.668 | info | State value to set for "philips-air.0.status.rddp" has to be type "number" but received type "string"
philips-air.0 | 2021-05-16 14:52:33.917 | info | starting. Version 0.1.0 in /opt/iobroker/node_modules/iobroker.philips-air, node: v14.15.4, js-controller: 3.3.8

AC2889 - Verbindet nicht zum Gerät

Hallo,

der Adapter, egal welche Version, kann sich nicht mit meinen beiden Luftreinigern verbinden. AC2889

image

pythen airctrl funktioniert:

image

Was auch geht, manuel per Browser auf die Geräte zugreifen und folgende URLs aufrufen:

GET: User Info
http://10.0.1.51/di/v1/products/0/userinfo

Returns 200 but base64 Content-Type: application/octet-stream
GET: Device
http://10.0.1.51/di/v1/products/1/device

Returns 200 but base64 Content-Type: application/octet-stream
PUT: Air
http://10.0.1.51:80/di/v1/products/1/air This is the API that controls the purifier, I can repeat the command and it'll start the fan.

GET: UPNP
http://10.0.1.51/upnp/description.xml UPnP Description, returns XML

Beide Geräte sind auch mit der Airmatters App verbunden. Laut Airmatters Firmware 1.0.4.

Logfile wie folgt:

2022-06-21 23:21:00.701  - error: philips-air.0 (3630) Error by sending: Error: No reply in 247 seconds.
2022-06-21 23:21:23.678  - debug: philips-air.0 (3630) POST /sys/dev/sync to 192.168.178.23
2022-06-21 23:21:27.974  - warn: philips-air.0 (3630) Got terminate signal. Checking desired PID: 0 vs own PID 3630
2022-06-21 23:21:28.002  - warn: philips-air.0 (3630) Got terminate signal. Checking desired PID: 3801 vs own PID 3630
Error by sending: Error: No reply in 247 seconds.
2022-06-21 23:21:30.682  - error: philips-air.0 (3630) Error by sending: Error: No reply in 247 seconds.
2022-06-21 23:21:53.678  - debug: philips-air.0 (3630) POST /sys/dev/sync to 192.168.178.23
2022-06-21 23:21:59.969  - warn: philips-air.0 (3630) Got terminate signal. Checking desired PID: 0 vs own PID 3630
2022-06-21 23:21:59.990  - warn: philips-air.0 (3630) Got terminate signal. Checking desired PID: 3827 vs own PID 3630
Error by sending: Error: No reply in 247 seconds.

HTTP protocol not working

Describe the bug
I have an older purifier (AC3829/10) which most likely did not support COAP (don't know if there is a firmware update available).
Therefore I tested the HTTP protocol and found at least two bugs.
The first one happens directly when doing the Http Request, because the time is past as string and not as integer.
Line 74 of lib/http.js: options.aliveTimeout should most likely be this.aliveTimeout

After fixing that, most states are not updated because of incorrect mapping.
Line 74 of main.js: AirPurifier.getMapping is used in all cases (COAP and HTTP). For HTTP it should be AirHttpPurifier.getMapping. Even changing this in the source returns only very few states (e.g. pm25). Most others are still "(null)" (e.g. temp).

To Reproduce
Steps to reproduce the behavior:

  1. Just start the adapter in Http Mode

Expected behavior
Connection is established and correct values are returned.

Versions:

  • Adapter version: 1.0.1

Please add support for AC1715/11 model.

Please add support for AC1715/11 model. Device is accessible via COAP in principle. But object names seam to be different (in comparison to AC4236/10).

Here the structure with some meanings, I found out already:
{
"D01-02":"Purifier product",
"D01-03":"Schlafzimmer", -------> Name
"D01-04":"Nala",
"D01-05":"AC1715/11", -------> Product
"D01-07":"English",
"D01-08":2,
"D01-09":1,
"D01-10":0,
"D01-11":0,
"D01-20":"0.0.1",
"D01-21":"0.6.0",
"MCUBoot":true,
"Runtime":1308046,
"rssi":-61,
"otacheck":false,
"wifilog":false,
"free_memory":49088,
"WifiVersion":"[email protected]",
"ProductId":"32d3e652179d11ec99f70217247a73aa",
"DeviceId":"7d1472c290fd11ed80591b26a7bbebfa",
"StatusType":"status",
"ConnectType":"Online",
"D03-02":"ON", -------> Power "ON"->"OFF"
"D03-03":false,
"D03-04":0, -------> Licht (?) 0 -> 100
"D03-05":0, -------> Licht(?) 0 -> 100
"D03-11":"A", -------> Mode
"D03-12":"Auto General", -------> Mode Text
"D03-13":"1", -------> Fan Speed
"D03-32":1, -------> IAI (Allergene)
"D03-33":1, -------> PM2.5
"D03-42":"PM2.5",
"D03-43":"PM2.5",
"D03-44":4,
"aqit_ext":0,
"D03-64":0,
"D05-02":"A3",
"D05-03":"none",
"D05-07":720,
"D05-08":4800,
"D05-09":0,
"D05-13":720,
"D05-14":4800,
"D05-15":0
}

Error : Cannot parse: undefined

Hello,
i have many Errors in my LOG when control the air-purifier with Objekts/VIS. ---> Cannot parse: undefined.
But the functions over iobroker is ok ! My protocol is HTTP.
Air Purifier : AC1214/10, AC5659/10 and AC2889/10

Philips-Air Adapter V 1.03

LOG :

philips-air.0 | 2023-05-08 04:52:08.369 | debug | Data: undefined
philips-air.0 | 2023-05-08 04:52:08.369 | error | Cannot parse: undefined
philips-air.0 | 2023-05-08 04:52:08.332 | debug | State change: "(val":2,"ack":false,"ts":1683514328330,"q":0,"from":"system.adapter.socketio.0","user":"system.user.admin","lc":1683514328330}
philips-air.0 | 2023-05-08 04:52:08.331 | silly | States user redis pmessage philips-air.0.control.*/philips-air.0.control.fanSpeed:{"val":2,"ack":false,"ts":1683514328330,"q":0,"from":"system.adapter.socketio.0","user":"system.user.admin","lc":1683514328330}
socketio.0 | 2023-05-08 04:52:08.330 | info | State value to set for "philips-air.0.control.fanSpeed" has to be type "string" but received type "number"

JS-Controller 4.0.24 nodejs 18.16.0 npm 9.5.1 admin 6.4.3

Think about to fix the issues found by adapter checker

I am an automatic service that looks for possible errors in ioBroker and creates an issue for it. The link below leads directly to the test:

https://adapter-check.iobroker.in/?q=https://raw.githubusercontent.com/iobroker-community-adapters/ioBroker.philips-air

  • [E605] No actual year found in copyright. Please add "Copyright (c) 2020-2023 bdeluefox [email protected]" at the end of README.md
  • [E701] No actual year found in LICENSE. Please add "Copyright (c) 2020-2023 bdeluefox [email protected]" at the start of LICENSE

I have also found warnings that may be fixed if possible.

  • [W171] "common.title" is deprecated in io-package.json

Thanks,
your automatic adapter checker.

v1.0.3 shows "has to be type "number" but received type "string"" for AC2939

Updating from 1.0.2 to 1.0.3 I see plenty of:

2022-12-27 13:37:12.997 - info: philips-air.1 (13159) starting. Version 1.0.3 in /opt/iobroker/node_modules/iobroker.philips-air, node: v14.21.1, js-controller: 4.0.23
2022-12-27 13:37:15.013 - info: philips-air.1 (13159) State value to set for "philips-air.1.control.lightBrightness" has to be type "number" but received type "string"
2022-12-27 13:37:15.076 - info: philips-air.1 (13159) State value to set for "philips-air.1.control.airQualityNotificationThreshold" has to be type "number" but received type "string"
2022-12-27 13:37:15.091 - info: philips-air.1 (13159) State value to set for "philips-air.1.status.allergenIndex" has to be type "number" but received type "string"
2022-12-27 13:37:15.098 - info: philips-air.1 (13159) State value to set for "philips-air.1.control.childLock" has to be type "boolean" but received type "string"
2022-12-27 13:37:15.190 - info: philips-air.1 (13159) State value to set for "philips-air.1.device.uptime" has to be type "number" but received type "string"
2022-12-27 13:37:15.241 - info: philips-air.1 (13159) State value to set for "philips-air.1.status.pm25" has to be type "number" but received type "string"
2022-12-27 13:37:15.247 - info: philips-air.1 (13159) State value to set for "philips-air.1.status.totalVolatileOrganicCompounds" has to be type "number" but received type "string"
2022-12-27 13:37:15.280 - info: philips-air.1 (13159) State value to set for "philips-air.1.filter.preFilterCleanInHours" has to be type "number" but received type "string"
2022-12-27 13:37:15.287 - info: philips-air.1 (13159) State value to set for "philips-air.1.filter.hepaFilterReplaceInHours" has to be type "number" but received type "string"
2022-12-27 13:37:15.336 - info: philips-air.1 (13159) State value to set for "philips-air.1.filter.activeCarbonFilterReplaceInHours" has to be type "number" but received type "string"

which was not the case in v1.0.2 used with device AC2939.

Rolled back to v1.0.2 as it was blowing up the log quite a bit.

Is this just a info message or causing some further issues downstream at processing?

Thank you! :)

Error by sending: Error: No reply in 247 seconds

Describe the bug
Device: Philips AC3033/10 Air Purifier
A lot of error messages appears in the logfile that the device is not answering. Maybe this is because the device is off but connected to the power supply. The led behind the power knob lights up.

To Reproduce
Steps to reproduce the behavior:

  1. Switch the device off but keep the power connected.
  2. Wait some minutes.
  3. Open the iobroker log.
  4. See errors.

Expected behavior
In my opinion this messages should not be displayed as an error, but as info or better as debug. It would be even better if these messages could be suppressed at all in the configuration.

Screenshots & Logfiles
philips-air.0 | 2023-06-16 11:47:54.301 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:47:50.269 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:47:47.607 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:45:21.410 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:44:04.624 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:43:35.622 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:43:06.622 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:42:37.620 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:42:08.621 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:59.136 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:57.335 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:56.379 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:53.586 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:51.289 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:46.417 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:40.745 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:39.620 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:36.009 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:23.926 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:17.981 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:41:12.725 | error | Error by sending: Error: No reply in 247 seconds.
philips-air.0 | 2023-06-16 11:40:10.656 | error | Error by sending: Error: No reply in 247 seconds.

Versions:

  • Adapter version: 1.0.3
  • JS-Controller version: 4.0.24
  • Node version: 18.16.0
  • Operating system: Ubuntu 22.04.2 LTS

Additional context
Configuration:
Lebenszeitüberschreitung: 30000 ms
Wiederverbindungsintervall: 30000 ms
Kommunikationsprotokoll: CoAP

AC4236 States

In your code, coupé you mayen also add the mode turbo which is existent for the AC4236?
In this model A is Auto, S is Sleep and T is Turbo.
The names are not so interesting as I can rename the states but the “T” is missing for the Turbo Mode.
mode: {name: 'mode', options: {'P': 'auto', 'A': 'allergen', 'S': 'sleep', 'M': 'manual', 'B': 'bacteria', 'N': 'night', 'T': 'turbo'}, control: true},

Wont Connect with AC2889/10

Thx for the Adapter, i would tested with AC2889. is that Coap Compability? I have to Put the Ip, but dont Connected.
i open the Ip Adress from Puffer, the only feedback ist

{"error":"Badly formed (DI Comm) request "}

exception "req.abort is not a function"

Adapter does not run anymore at all.
Getting exceptions:

host.ioBrokerHost | 2021-09-24 10:48:34.544 | error | Caught by controller[0]: Error by sending: Error: No reply in 247s
philips-air.0 | 2021-09-24 10:48:33.934 | error | req.abort is not a function
philips-air.0 | 2021-09-24 10:48:33.933 | error | TypeError:  req.abort is not a function    at OutgoingMessage.<anonymous>  (/opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:118:21)     at OutgoingMessage.emit (events.js:314:20)    at RetrySend.emit  (events.js:314:20)    at Timeout._onTimeout  (/opt/iobroker/node_modules/coap/lib/retry_send.js:77:12)    at  listOnTimeout (internal/timers.js:554:17)    at processTimers  (internal/timers.js:497:7)
philips-air.0 | 2021-09-24 10:48:33.930 | error | uncaught exception: req.abort is not a function
host.ioBrokerHost | 2021-09-24 10:43:55.053 | error | instance system.adapter.philips-air.0 terminated with code 6 (UNCAUGHT_EXCEPTION)
host.ioBrokerHost | 2021-09-24 10:43:55.052 | error | Caught by controller[0]: Error by sending: Error: No reply in 247s
philips-air.0 | 2021-09-24 10:43:54.444 | error | req.abort is not a function
philips-air.0 | 2021-09-24 10:43:54.442 | error | TypeError:  req.abort is not a function    at OutgoingMessage.<anonymous>  (/opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:118:21)     at OutgoingMessage.emit (events.js:314:20)    at RetrySend.emit  (events.js:314:20)    at Timeout._onTimeout  (/opt/iobroker/node_modules/coap/lib/retry_send.js:77:12)    at  listOnTimeout (internal/timers.js:554:17)    at processTimers  (internal/timers.js:497:7)
philips-air.0 | 2021-09-24 10:43:54.439 | error | uncaught exception: req.abort is not a function
host.ioBrokerHost | 2021-09-24 10:39:15.817 | error | instance system.adapter.philips-air.0 terminated with code 6 (UNCAUGHT_EXCEPTION)
host.ioBrokerHost | 2021-09-24 10:39:15.814 | error | Caught by controller[0]: Error by sending: Error: No reply in 247s
philips-air.0 | 2021-09-24 10:39:15.194 | error | req.abort is not a function
philips-air.0 | 2021-09-24 10:39:15.193 | error | TypeError:  req.abort is not a function    at OutgoingMessage.<anonymous>  (/opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:118:21)     at OutgoingMessage.emit (events.js:314:20)    at RetrySend.emit  (events.js:314:20)    at Timeout._onTimeout  (/opt/iobroker/node_modules/coap/lib/retry_send.js:77:12)    at  listOnTimeout (internal/timers.js:554:17)    at processTimers  (internal/timers.js:497:7)
philips-air.0 | 2021-09-24 10:39:15.189 | error | uncaught exception: req.abort is not a function

Doesn't connect to AC3829/10 since version 0.1.3

Since the latest update to 0.1.3, this adapter doesn't connect to my AC3829/10 anymore. With version 0.1.0 I had installed before, connection has always been a bit unstable and the adapter needed a restart from time to time but in general it worked okay.

Debug log isn't very useful to identify the problem (at least to me):

philips-air.0 2022-03-21 14:23:03.977 debug started
philips-air.0 2022-03-21 14:23:03.957 debug start with 10.100.255.35 {"host":"10.100.255.35","aliveTimeout":"30000","reconnectInterval":"30000"}
philips-air.0 2022-03-21 14:23:03.889 silly States system redis pmessage system.adapter.philips-air.0.logLevel/system.adapter.philips-air.0.logLevel:{"val":"silly","ack":true,"ts":1647868983869,"q":0,"from":"system.adapter.philips-air.0","lc":1647868837519}
philips-air.0 2022-03-21 14:23:03.770 debug Schedule restart: 0 15 * * *
philips-air.0 2022-03-21 14:23:03.659 info starting. Version 0.1.3 in /opt/iobroker/node_modules/iobroker.philips-air, node: v14.19.1, js-controller: 4.0.21
philips-air.0 2022-03-21 14:23:02.253 debug Plugin sentry Initialize Plugin (enabled=true)
philips-air.0 2022-03-21 14:22:55.465 info Terminated (ADAPTER_REQUESTED_TERMINATION): Without reason
philips-air.0 2022-03-21 14:22:55.462 debug Plugin sentry destroyed
philips-air.0 2022-03-21 14:22:55.460 info terminating
philips-air.0 2022-03-21 14:22:55.455 info Got terminate signal TERMINATE_YOURSELF
philips-air.0 2022-03-21 14:22:55.453 silly States system redis pmessage system.adapter.philips-air.0.sigKill/system.adapter.philips-air.0.sigKill:{"val":-1,"ack":false,"ts":1647868975111,"q":0,"from":"system.host.iobroker","lc":1647868975111}
philips-air.0 2022-03-21 14:22:55.465 info Terminated (ADAPTER_REQUESTED_TERMINATION): Without reason
philips-air.0 2022-03-21 14:22:55.462 debug Plugin sentry destroyed
philips-air.0 2022-03-21 14:22:55.460 info terminating
philips-air.0 2022-03-21 14:22:55.455 info Got terminate signal TERMINATE_YOURSELF
philips-air.0 2022-03-21 14:22:55.453 silly States system redis pmessage system.adapter.philips-air.0.sigKill/system.adapter.philips-air.0.sigKill:{"val":-1,"ack":false,"ts":1647868975111,"q":0,"from":"system.host.iobroker","lc":1647868975111}

Looks like everything is working okay ... except that no values are coming in and the "Instances" tab is showing this adapter as "Not connected to device or service" (last checkmark is red instead of green).
Anything I can do to help fix this bug? I really would love to get my values recorded again! ;-)

Speed mode not changeable / AC4236/14

Hello

I have the AC4236/14 in operation. The adapter can basically connect to CoAP. However, I can only set the FanSpeed to 1 or 2. With other actions with the Fanspeed (auto or Tubro) the Adpater crashes / or turns yellow. In the app from Phillips I have "Auto mode" "1" "2" and "Turbo mode" to choose from.

On / Off works.

Regards
Claudio


Hallo

Ich habe den AC4236/14 in Betrieb. Der Adpater kann sich mit CoAP grundsätzlich verbinden. Allerdings kann ich den FanSpeed nur auf 1 oder 2 Setzten. Bei anderen Aktionen mit dem Fanspeed (auto oder Tubro) stürzt der Adpater ab / bzw. wird Gelb. In der App von Phillips habe ich "Auto-Modus" "1" "2" und "Turbomodus" zur Auswahl.

An/Aus funktioniert.

Leibe Grüsse

Claudio

Think about to fix the issues found by adapter checker

I am an automatic service that looks for possible errors in ioBroker and creates an issue for it. The link below leads directly to the test:

https://adapter-check.iobroker.in/?q=https://raw.githubusercontent.com/iobroker-community-adapters/ioBroker.philips-air

  • [E150] No common.connectionType found in io-package.json
  • [E152] No common.dataSource found in io-package.json
  • [E154] common.dependencies must contain{"js-controller": ">=2.0.0"} or {"js-controller": ">=3.0.0"}
  • [E300] Not found on travis. Please setup travis
  • [E605] No actual year found in copyright. Please add "Copyright (c) 2022 bdeluefox [email protected]" at the end of README.md

Thanks,
your automatic adapter checker.

fanSpeed Control throws exception

Hey,
when using this adapter with the Jarvis Vis, i get an exception when controlling the fan speed in Level 1 to 3. Mode silent,turbo are working.

philips-air.0 | 2021-05-24 18:49:07.972 | error | Invalid option for fanSpeed: 1. Supported only: {"1":"1","2":"2","3":"3","s":"silent","t":"turbo","a":"auto"}
philips-air.0 | 2021-05-24 18:49:07.971 | error | Error: Invalid option for fanSpeed: 1. Supported only: {"1":"1","2":"2","3":"3","s":"silent","t":"turbo","a":"auto"}     at /opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:263:31     at Array.forEach (&lt;anonymous&gt;)     at AirPurifier.control (/opt/iobroker/node_modules/iobroker.philips-air/lib/coap.js:256:78)     at Object.stateChange (/opt/iobroker/node_modules/iobroker.philips-air/main.js:64:48)     at Immediate.&lt;anonymous&gt; (/opt/iobroker/node_modules/iobroker.js-controller/lib/adapter.js:5555:41)     at processImmediate (internal/timers.js:461:21)
philips-air.0 | 2021-05-24 18:49:07.968 | error | uncaught  exception: Invalid option for fanSpeed: 1. Supported only:  {"1":"1","2":"2","3":"3","s":"silent","t":"turbo","a":"auto"}

My Datapoint Setting in Jarvis is:
{"1":"1","2":"2","3":"3","silent":"s","turbo":"t","auto":"a"}

Am i using it wrong, or is there maybe a check/conversion error?

Second issue: switching to "auto", does not make the device beep and nothing happens. Do i need to set any other attribute too, to get it back to Auto?

Lucas

ioBroker shows errors in the LOG. Sometimes it is working fine

grafik

philips-air.0 14424 2022-12-06 08:34:21.248 info starting. Version 0.1.7 in /opt/iobroker/node_modules/iobroker.philips-air, node: v16.18.1, js-controller: 4.0.23
philips-air.0 14386 2022-12-06 08:34:15.481 info Terminated (ADAPTER_REQUESTED_TERMINATION): Without reason
philips-air.0 14386 2022-12-06 08:34:15.479 info terminating
philips-air.0 14386 2022-12-06 08:34:15.476 info Got terminate signal TERMINATE_YOURSELF
philips-air.0 14386 2022-12-06 08:33:01.699 info starting. Version 0.1.7 in /opt/iobroker/node_modules/iobroker.philips-air, node: v16.18.1, js-controller: 4.0.23
philips-air.0 17456 2022-12-06 08:32:56.000 info Terminated (ADAPTER_REQUESTED_TERMINATION): Without reason
philips-air.0 17456 2022-12-06 08:32:55.998 info terminating
philips-air.0 17456 2022-12-06 08:32:55.993 info Got terminate signal TERMINATE_YOURSELF
philips-air.0 17456 2022-12-06 08:32:49.023 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:32:19.023 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:31:49.021 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:30:35.260 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:30:05.259 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:29:35.258 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:29:05.258 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:28:35.256 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:27:24.591 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:26:54.590 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:26:24.591 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:25:54.589 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:25:24.590 error Error by sending: Error: No reply in 247 seconds.
philips-air.0 17456 2022-12-06 08:24:06.917 error Error by sending: Error: No reply in 247 seconds.

Expected behavior
Connection is stable and no errors in the log

Allergy Mode is missing

Right now I cannot change the Allergy Night Mode. When I change it within the App the mode is set to "AS" within the iobroker objects. But when I try to change it via javascript to "AS" nothing happens. I guess the mode can be read but node be changed.

It would be great if you change the Adapter and add the missing mode.

Regards
Jan

Update stable version in repo from 1.0.3 to 1.1.0

Think about update stable version to 1.1.0

Version: stable=1.0.3 (504 days old) => latest=1.1.0 (15 days old)
Installs: stable=341 (81.19%), latest=38 (9.05%), total=420

Click to use developer portal
Click to edit

Do not close this issue manually as a new issue will be created if condition for update still exists.

Please drop a comment if any reason exists which blocks updating to version 1.1.0 at this time.

Note: This is an automatically generated message and not personally authored by bluefox!
@mcm1957 for evidence

AC2889/10: Hex values in info lines

First of all: thank you very much for the Philips Luftreiniger/philips-air adapter!

I just started using it with my new Philips Luftreiniger Series 2000 AC2889/10

Installierte Version: 0.1.4
root@smarthome:/opt/iobroker# iobroker -v
4.0.23
root@smarthome:/opt/iobroker# node -v
v17.9.0

Screenshot_2022-05-02_20-02-58

In the IOBroker log is see log entries every 30s
philips-air.0 73536 2022-05-02 19:57:41.467 info Received: 419EC9FE
philips-air.0 73536 2022-05-02 19:57:11.466 info Received: 0B421D56
philips-air.0 73536 2022-05-02 19:56:41.466 info Received: 44738F67
philips-air.0 73536 2022-05-02 19:56:10.686 info Received: 51901F98
philips-air.0 73536 2022-05-02 19:55:40.683 info Received: 05C9084F

Could someone enlighten me what the hex values in the info lines mean?
Is is any kind of useful information? And if not, can it be suppressed?

Thank you in advance.

Compatibility check to js-controller 4.0

Dear Adapter developer,

with js-controller 4.0 object definitions are now also checked that min/max in only provided for number/mixed objects and that the type of the default value matches to the object type.

If something is not correct this is logged as 'warning' or 'info' log.

Please also make sure to update to the lastest @iobroker/testing dependency 2.5.4 or to accept the PR from Apollon77 for legacy testing!

Please spent some time to verify your adapter by ideally starting with a fresh instance and do some actions and verify the log. If you see a warn or info log there from these checks please adjust the adapter and fix the relevant cases.

For questions please refer to ioBroker/ioBroker.js-controller#1749

Please close the issue after you checked it.

Thank you very much for your support to get the best experience for the growing numbers of ioBroker users!

Falscher Object Typ

Hallo.

Der Adapter in der Version 1.0.3 erzeugt Info Meldungen im Protokoll wegen falschem Type.

System: Windows 10 x64
Node: 18.19.0
NPM: 10.2.3

philips-air.0
2023-12-31 06:24:31.607	info	State value to set for "philips-air.0.filter.activeCarbonFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.605	info	State value to set for "philips-air.0.filter.hepaFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.602	info	State value to set for "philips-air.0.filter.preFilterCleanInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.596	info	State value to set for "philips-air.0.status.timerMinutes" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.593	info	State value to set for "philips-air.0.control.timerHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.587	info	State value to set for "philips-air.0.status.pm25" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.583	info	State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.556	info	State value to set for "philips-air.0.control.childLock" has to be type "boolean" but received type "string"

philips-air.0
2023-12-31 06:24:31.552	info	State value to set for "philips-air.0.status.allergenIndex" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.545	info	State value to set for "philips-air.0.control.airQualityNotificationThreshold" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:31.541	info	State value to set for "philips-air.0.control.lightBrightness" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.426	info	State value to set for "philips-air.0.filter.activeCarbonFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.423	info	State value to set for "philips-air.0.filter.hepaFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.421	info	State value to set for "philips-air.0.filter.preFilterCleanInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.415	info	State value to set for "philips-air.0.status.timerMinutes" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.413	info	State value to set for "philips-air.0.control.timerHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.407	info	State value to set for "philips-air.0.status.pm25" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.403	info	State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.383	info	State value to set for "philips-air.0.control.childLock" has to be type "boolean" but received type "string"

philips-air.0
2023-12-31 06:24:28.380	info	State value to set for "philips-air.0.status.allergenIndex" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.376	info	State value to set for "philips-air.0.control.airQualityNotificationThreshold" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:24:28.374	info	State value to set for "philips-air.0.control.lightBrightness" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.381	info	State value to set for "philips-air.0.filter.activeCarbonFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.379	info	State value to set for "philips-air.0.filter.hepaFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.376	info	State value to set for "philips-air.0.filter.preFilterCleanInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.370	info	State value to set for "philips-air.0.status.timerMinutes" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.367	info	State value to set for "philips-air.0.control.timerHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.361	info	State value to set for "philips-air.0.status.pm25" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.355	info	State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.336	info	State value to set for "philips-air.0.control.childLock" has to be type "boolean" but received type "string"

philips-air.0
2023-12-31 06:21:30.333	info	State value to set for "philips-air.0.status.allergenIndex" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.322	info	State value to set for "philips-air.0.control.airQualityNotificationThreshold" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:30.317	info	State value to set for "philips-air.0.control.lightBrightness" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.190	info	State value to set for "philips-air.0.filter.activeCarbonFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.187	info	State value to set for "philips-air.0.filter.hepaFilterReplaceInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.185	info	State value to set for "philips-air.0.filter.preFilterCleanInHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.178	info	State value to set for "philips-air.0.status.timerMinutes" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.176	info	State value to set for "philips-air.0.control.timerHours" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.171	info	State value to set for "philips-air.0.status.pm25" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.167	info	State value to set for "philips-air.0.device.uptime" has to be type "number" but received type "string"

philips-air.0
2023-12-31 06:21:27.151	info	State value to set for "philips-air.0.control.childLock" has to be type "boolean" but received type "string"

philips-air.0
2023-12-31 06:21:27.149	info	State value to set for "philips-air.0.status.allergenIndex" has to be type "number" but received type "string"

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.