Method ToggleAllAsync
- Namespace
- Yeelight
- Assembly
- YeelightClient.dll
ToggleAllAsync(CancellationToken)
Switches the main light and the background light, as they are, at the same time: on when it was off and the other way round. This
is the dev_toggle method, which a device that has no background light may not list.
public Task ToggleAllAsync(CancellationToken cancellationToken = default)
Parameters
cancellationTokenCancellationTokenTo stop waiting for the answer.
Returns
- Task
A task that ends when the light has answered.
Exceptions
- NotSupportedException
The device lists the methods that it supports, and
dev_toggleis not one of them.