aendue / ioBroker.reolink

Reolink adapter for ioBroker
MIT License
21 stars 9 forks source link

white LED status #25

Open oelison opened 1 year ago

oelison commented 1 year ago

white LED status
white LED status is auto after switching off

To Reproduce
Steps to reproduce the behavior:

  1. LED status is in off mode
  2. switch LED on
  3. switch LED off
  4. LED now in auto mode (every time)

Expected behavior
LED is in the old state or LED is selectable in AUTO or OFF (store the old state may be not the best solution)

oelison commented 7 months ago

Cannot find the auto state in the API. Only on and off (0, 1) is possible.

johndoetheanimal commented 6 months ago

don't know how the light will be triggered, but with [ { "cmd":"SetWhiteLed", "action":0, "param":{ "WhiteLed":{ "channel":0, "state":1 } } } ] and [ { "cmd":"SetWhiteLed", "action":0, "param":{ "WhiteLed":{ "channel":0, "state":0 } } } ]

Nightmode doesn't switch on automaticly

johndoetheanimal commented 6 months ago

ok - so mode refers to the LED Mode mode 0 = off mode 1 = night mode mode 2 = unknown atm // €: https://github.com/home-assistant/core/issues/100250 says it would be always-on, but my RLC811-A doesn't support it mode 3 = Timer mode

API Documentation v8 is wrong !

Lights on in mode0 means, that the LEDs are on for 3 minutes and afterwards they are shut off. seems to be hardcoded.

If you need more than 3 minutes, you have to go on mode3 and set the begintime -1 minute before now() and end time +x minutes you want to have - fe 20 minutes LED:

[ { "cmd":"SetWhiteLed", "action":0, "param":{ "WhiteLed":{ "LightingSchedule":{ "EndHour":23, "EndMin":50, "StartHour":23, "StartMin":29 }, "mode":3, "channel":0 } } } ] But this has to be reset afterwards or you have fun the next day :) Alternativ toggle on: set Start to now()-1minute and End to now()-2 minutes (so lights are on 23:59 and just one minute offline) toggle off: set mode 0 & state 0

Tested with RLC-811A

Nibbels commented 2 months ago

Ich bin eben über dasselbe Phänomen gestolpert. Immer, wenn ich die Led oder die Led-Brightness im IoBroker geändert habe, hat sich der "Nacht Smart Modus" aktiviert.

Also müsste man hier wohl den mode = 1 entfernen? https://github.com/aendue/ioBroker.reolink/blob/aab5b645be7217574aa4c602c50e13774eb042db/main.js#L530 https://github.com/aendue/ioBroker.reolink/blob/aab5b645be7217574aa4c602c50e13774eb042db/main.js#L542

Ich meine man sollte den LedMode(int mode) gesondert setzen können.

Nibbels commented 2 months ago

Laut https://community.reolink.com/topic/4196/reolink-camera-api-user-guide_v8-updated-in-april-2023 -> https://drive.google.com/drive/folders/1qvKcKswNJP_-G0tTbs_JQOuO67QqujfB -> Seite 343 SetWhiteLed ist "mode" nicht mandatory =M sondern optional =O Man sollte mode im Request-Json weglassen oder gesondert setzen dürfen.