Compare commits

...
2 Commits
Author SHA1 Message Date
arnie 1d3f3477c0 Fix HSV dpt 2026-10-03 01:21:59 +02:00
arnie dd22bc5381 Use ambient in the bathroom 2026-10-03 01:10:29 +02:00
2 changed files with 8 additions and 16 deletions
@@ -374,8 +374,8 @@ function C3CKnxCreateGroupAddresses()
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient", "2/1/30", "DPT_5"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient FB", "2/1/31", "DPT_5"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient Dimming", "2/1/32", "DPT_3"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient HSV", "2/1/35", "DPT_1"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient HSV FB", "2/1/36", "DPT_1"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient HSV", "2/1/35", "DPT_232"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient HSV FB", "2/1/36", "DPT_232"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient Hue Dimming", "2/1/37", "DPT_3"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Ambient Saturation Dimming", "2/1/38", "DPT_3"),
C3C.KnxGroupAddress("Dimmer UF Bathroom Vanity", "2/1/45", "DPT_5"),
+6 -14
View File
@@ -91,9 +91,6 @@
C3C.KnxAddresses.Watch("Switch UF Bathroom Ambient", overrideLight)
C3C.KnxAddresses.Watch("Switch UF Bathroom Ambient CTRL", overrideLight)
C3C.KnxAddresses.Watch("Switch UF Bathroom Ambient Light 1", overrideLight)
C3C.KnxAddresses.Watch("Switch UF Bathroom Ambient Light 2", overrideLight)
C3C.KnxAddresses.Watch("Switch UF Bathroom Ambient Toilet", overrideLight)
C3C.KnxAddresses.Watch("Dimmer UF Bathroom Ambient", overrideLight)
C3C.KnxAddresses.Watch("Dimmer UF Bathroom Ambient Dimming", overrideLight)
@@ -123,16 +120,14 @@
C3C.Logger.Debug("Light overridden, skipping automatic light control", ctx)
elseif lux < 50 then
if C3C.Lib.State.DayTime.IsDay() or (time.hour >= 7 and time.hour <= 19) then
C3C.Logger.Debug("Switching on primary light", ctx)
C3C.KnxAddresses.Get("Switch UF Bathroom Primary CTRL"):Send(1)
C3C.KnxAddresses.Get("Switch UF Bathroom Primary Light 1"):Send(1)
C3C.KnxAddresses.Get("Switch UF Bathroom Primary Light 2"):Send(1)
C3C.Logger.Debug("Switching on ambient light", ctx)
C3C.KnxAddresses.Get("Dimmer UF Bathroom Ambient HSV"):Send(tonumber("2057FF", 16))
elseif time.hour == 20 then
C3C.Logger.Debug("Switching on primary light with dimmed control during evening", ctx)
C3C.KnxAddresses.Get("Dimmer UF Bathroom Primary"):Send(12)
C3C.Logger.Debug("Switching on ambient light with dimmed control during evening", ctx)
C3C.KnxAddresses.Get("Dimmer UF Bathroom Ambient HSV"):Send(tonumber("179442", 16))
else
C3C.Logger.Debug("Switching on primary light with dimmed control during nighttime", ctx)
C3C.KnxAddresses.Get("Dimmer UF Bathroom Primary"):Send(2)
C3C.Logger.Debug("Switching on ambient light with dimmed control during nighttime", ctx)
C3C.KnxAddresses.Get("Dimmer UF Bathroom Ambient HSV"):Send(tonumber("E1CF05", 16))
end
end
@@ -162,9 +157,6 @@
if gaAmbientLightCTRLFB.Value ~= 0 then
C3C.Logger.Debug("Switching off ambient light", ctx)
C3C.KnxAddresses.Get("Switch UF Bathroom Ambient CTRL"):Send(0)
C3C.KnxAddresses.Get("Switch UF Bathroom Ambient Light 1"):Send(0)
C3C.KnxAddresses.Get("Switch UF Bathroom Ambient Light 2"):Send(0)
C3C.KnxAddresses.Get("Switch UF Bathroom Ambient Toilet"):Send(0)
end
end