IoT
Installation
SKILL.md
Protocol Selection
- MQTT for lightweight messaging — pub/sub, low bandwidth, ideal for sensors
- CoAP for constrained devices — UDP-based, REST-like, very low power
- HTTP/REST for capable devices — familiar but heavier, use when bandwidth allows
- WebSocket for real-time bidirectional — dashboards, live updates
- Zigbee/Z-Wave for mesh networks — no WiFi needed, battery-friendly
MQTT Essentials
- Broker is the central hub — Mosquitto most common self-hosted
- Topics are hierarchical — home/livingroom/temperature
- QoS levels: 0 (fire-forget), 1 (at least once), 2 (exactly once)
- Retain flag keeps last message — new subscribers get current state
- Will message announces disconnection — device offline detection