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.
This adapter communicates with Sonoff devices with Tasmota firmware or ESP devices via MQTT.
Following topics are expected:
tele/DeviceNAME/STATE
tele/DeviceNAME/SENSOR
tele/DeviceNAME/INFOx
tele/DeviceNAME/ENERGY
cmnd/DeviceNAME/POWERx
stat/DeviceNAME/POWERx
/DeviceNAME/BM280/Temperature
/DeviceNAME/BM280/Humidity
/DeviceNAME/BM280/Temperatur
/DeviceNAME/BM280/Feuchtigkeit
/DeviceNAME/BM280/Vcc
/DeviceNAME/BM280/VCC
/DeviceNAME/BM280/Laufzeit
/DeviceNAME/BM280/RSSI
/DeviceNAME/BM280/POWER
/DeviceNAME/BM280/POWER1
/DeviceNAME/BM280/POWER2
/DeviceNAME/BM280/POWER3
/DeviceNAME/BM280/POWER4
/DeviceNAME/BM280/Switch1
/DeviceNAME/BM280/Switch2
/DeviceNAME/BM280/Total
/DeviceNAME/BM280/Today
/DeviceNAME/BM280/heute
/DeviceNAME/BM280/Yesterday
/DeviceNAME/BM280/gestern
/DeviceNAME/BM280/Faktor
/DeviceNAME/BM280/Factor
/DeviceNAME/BM280/Power
/DeviceNAME/BM280/Leistung
/DeviceNAME/BM280/Voltage
/DeviceNAME/BM280/Spannung
/DeviceNAME/BM280/Current
/DeviceNAME/BM280/Strom
/DeviceNAME/BM280/Punkt
/DeviceNAME/BM280/Counter1
/DeviceNAME/BM280/Counter2
/DeviceNAME/BM280/Counter3
/DeviceNAME/BM280/Counter4
/DeviceNAME/BM280/Pressure
/DeviceNAME/BM280/SeaPressure
/DeviceNAME/BM280/Druck
/DeviceNAME/BM280/Approx. Altitude
/DeviceNAME/BM280/Module
/DeviceNAME/BM280/Version
/DeviceNAME/BM280/Hostname
/DeviceNAME/BM280/IPAddress
/DeviceNAME/BM280/IPaddress
/DeviceNAME/BM280/RestartReason
/DeviceNAME/BM280/CarbonDioxide
/DeviceNAME/DHT11/Illuminance
/DeviceNAME/SonoffSC/Light
/DeviceNAME/SonoffSC/Noise
/DeviceNAME/SonoffSC/AirQuality
/DeviceNAME/SDS0X1/PM2.5
/DeviceNAME/SDS0X1/PM10
/DeviceNAME/SDS0X1/UvLevel
/DeviceNAME/SDS0X1/Latitude
/DeviceNAME/SDS0X1/Longitude
/DeviceNAME/SR04/Distance
Note: The list could be easily extended. Please send Pull Requests
or debug data for unknown states to developer (via issue).
In the web config you can determine which MQTT telegrams create the new objects not in default data points:
TELE_SENSOR
- creates objects fromtele/xxx/SENSOR
telegramsTELE_STATE
- creates objects fromtele/xxx/STATE
telegramsSTAT_RESULT
- creates objects fromstat/xxx/RESULT
telegrams
Usually TELE_SENSOR should be sufficient for most users.
Create object tree
creates objects as tree structure
Warning! This option will mess up your sonoff object tree! You have to redo all the settings for storage... Store the object structure as JSON file, so you can recreate your old structure. Best is to stop the adapter, delete all objects under sonoff and start the adapter again.
The mode states will be created only if device has one of the states:
Red
,Green
,Blue
,WW
,CW
,Color
,RGB_POWER
,WW_POWER
,CW_POWER
,Hue
,Saturation
States:
modeLedExor
- exor for white LEDs and color LEDs => if the white LEDs are switched on, color LEDs are switched off and vice versa (default true)modeReadColors
- allow for color read from MQTT (default false)
- (Apollon77) Fix crash case (Sentry IOBROKER-SONOFF-1S)
- (Apollon77) Fix some crash cases reported by Sentry (IOBROKER-SONOFF-B, IOBROKER-SONOFF-R, IOBROKER-SONOFF-4, IOBROKER-SONOFF-1, IOBROKER-SONOFF-13, IOBROKER-SONOFF-1J, IOBROKER-SONOFF-16, IOBROKER-SONOFF-3, IOBROKER-SONOFF-H)
- (Apollon77) Adjust Uptime to mixed because it seems that it can be number or string
- (Apollon77) Fix some crash cases reported by Sentry
- (bluefox) Added UvaIntensity and UvbIntensity
- (bluefox) Better type detection for non-described states
- (bluefox) Optimize for js-controller 3.3
- (Apollon77/bluefox) Optimize for js-controller 3.3
- (Apollon77) Add Sentry for error reporting with js-controller 3.x+
- (anwa) add several data points
- (anwa) Fix translation for 'ignorePings'
- (anwa) Fix wrong unit for humidity
- (anwa) Config option to create a complete object tree instead of a flat structure
- (anwa) Change Action type to string
- (Apollon77) js-controller 2.0 is required at least
- (bluefox) Error with empty packet was caught
- (bluefox) Fixed the password input in the configuration
- (bluefox) Allowed to set the IP interface for server
- (bluefox) Fixed tests for js-controller 2.0
- (bluefox) Fixed the monitoring of the client connection
- (bluefox) Changed "indicator.connected" to "indicator.reachable" for clients
- (bluefox) Supported
{POWERn: "true"}
- (bluefox) Correct processing of
{temp: nan}
- (simatec) Support for compact mode
- (bluefox) Configuration was fixed
- (bluefox) '-' in names was allowed again
- (gemu2015) auto generate objects, support for arrays (channel), led-controllers improved
- (bluefox) Added HC-SR04 Ultrasonic Sensor
- (bluefox) Added support of UvLight, Longitude and Latitude
- (bluefox) Support of the particle concentration sensor
- (gemu2015) Support of the devices control (many thanks :)
- (gemu2015) Support of many new values
- (modmax) Update alive status of the clients
- (modmax) Added POWER5-8 and Switch3-4
- (modmax) Fixing reconnection of clients
- (bluefox) Add SeaPressure
- (bluefox) Replace stream handler
- (bluefox) Add timeout for clients
- (bluefox) Add Light/Noise/AirQuality
- (bluefox) Do not send pingresp for invalid clients
- (bluefox) Add Analog0/1/2/3 sensor
- (Apollon77) Add Illuminance sensor
- (bluefox) Ready for admin3
- (bluefox) Added CO2 sensor
- (AlZiBa) typo @ alive
- (AlZiBa) add Today's power consumption for Sonoff POW
- (AlZiBa) unit of power consumption is kWh
- (bluefox) Add counters
- (Tan-DE) Small change for Switch1. Switch2 and additional IPaddress added.
- (bluefox) Fix tests and LWT
- (bluefox) Add INFO and ESP
- (bluefox) Add ENERGY and DS18x20
- (bluefox) initial commit
The MIT License (MIT)
Copyright (c) 2017-2021, bluefox [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.