@@ -343,6 +343,7 @@ async def master(
343343 brightness : int | None = None ,
344344 on : bool | None = None ,
345345 transition : int | None = None ,
346+ cct : int | None = None
346347 ) -> None :
347348 """Change master state of a WLED Light device.
348349
@@ -353,6 +354,7 @@ async def master(
353354 transition: Duration of the crossfade between different
354355 colors/brightness levels. One unit is 100ms, so a value of 4
355356 results in a transition of 400ms.
357+ cct:
356358 """
357359 state : dict [str , bool | int ] = {}
358360
@@ -365,6 +367,9 @@ async def master(
365367 if transition is not None :
366368 state ["tt" ] = transition
367369
370+ if cct is not None :
371+ state ["cct" ] = cct
372+
368373 await self .request ("/json/state" , method = "POST" , data = state )
369374
370375 # pylint: disable=too-many-locals, too-many-branches, too-many-arguments
@@ -392,6 +397,7 @@ async def segment( # noqa: PLR0912, PLR0913
392397 start : int | None = None ,
393398 stop : int | None = None ,
394399 transition : int | None = None ,
400+ cct : int | None = None
395401 ) -> None :
396402 """Change state of a WLED Light segment.
397403
@@ -420,6 +426,7 @@ async def segment( # noqa: PLR0912, PLR0913
420426 transition: Duration of the crossfade between different
421427 colors/brightness levels. One unit is 100ms, so a value of 4
422428 results in a transition of 400ms.
429+ cct: The white spectrum color temperature.
423430
424431 Raises:
425432 ------
@@ -447,6 +454,7 @@ async def segment( # noqa: PLR0912, PLR0913
447454 "start" : start ,
448455 "stop" : stop ,
449456 "sx" : speed ,
457+ "cct" : cct
450458 }
451459
452460 # > WLED 0.10.0, does not support segment control on/bri.
0 commit comments