edilkamin
    Preparing search index...

    Function deriveEasyTimer

    • Derives the Easy Timer state from an existing DeviceInfo response. This is a pure function that extracts data without API calls.

      Parameters

      Returns EasyTimerStateType

      • Object containing active status and timer time.
      const info = await api.deviceInfo(token, mac);
      const timer = deriveEasyTimer(info);
      console.log(`Timer active: ${timer.active}, Time: ${timer.time} minutes`);