1234567891011121314151617181920212223242526272829303132 |
- """Humidifier adv parser."""
- from __future__ import annotations
- import logging
- _LOGGER = logging.getLogger(__name__)
- def process_wohumidifier(
- data: bytes | None, mfr_data: bytes | None
- ) -> dict[str, bool | int]:
- """Process WoHumi services data."""
- if data is None:
- return {
- "isOn": None,
- "level": None,
- "switchMode": True,
- }
- return {
- "isOn": bool(data[1]),
- "level": data[4],
- "switchMode": True,
- }
|