toggleBuzzer method

Future<CommandResponse> toggleBuzzer({
  1. required dynamic deviceId,
  2. required bool enabled,
})

Toggles the buzzer on or off based on the enabled flag.

deviceId - The identifier of the target device. enabled - A boolean indicating whether to enable or disable the buzzer.

Implementation

Future<CommandResponse> toggleBuzzer(
    {required deviceId, required bool enabled}) async {
  return sendCommand(deviceId, enabled ? buzzerEnabled : buzzerDisabled);
}