|
| 1 | +--- |
| 2 | +tags: |
| 3 | + - package |
| 4 | + - automated |
| 5 | +version: 1.0.0 |
| 6 | +--- |
| 7 | + |
1 | 8 | # Package: Airthings |
2 | 9 |
|
| 10 | +**Version:** 1.0.0 |
| 11 | +**Description:** Normalizes Airthings Wave sensors (Temp, Humidity, CO2) |
| 12 | + |
| 13 | +<!-- START_IMAGE --> |
| 14 | + |
| 15 | +<!-- END_IMAGE --> |
| 16 | + |
3 | 17 | ## Executive Summary |
4 | | -This package normalizes data from the Airthings Wave Plus device (Living Room). It uses **Template Sensors** to extract and round temperature, humidity, and CO2 values from the raw Bluetooth/Cloud integration sensors, providing cleaner data for the frontend. |
5 | | - |
6 | | -## Architecture |
7 | | -```mermaid |
8 | | -sequenceDiagram |
9 | | - participant Raw as sensor.airthings_wave_living_room_* |
10 | | - participant Template as HA Template Engine |
11 | | - participant Sensor as sensor.airthings_wave_* |
12 | | - |
13 | | - Raw->>Template: State Change (e.g. 21.5432) |
14 | | - Template->>Template: Round to 1 decimal |
15 | | - Template->>Sensor: Update State (21.5) |
16 | | -``` |
| 18 | +<!-- START_SUMMARY --> |
| 19 | +> ⚠️ **Update Required:** Analysis for v0.0.0. Code is v1.0.0. |
| 20 | +
|
| 21 | +*No executive summary generated yet.* |
| 22 | +<!-- END_SUMMARY --> |
| 23 | + |
| 24 | +## Process Description (Non-Technical) |
| 25 | +<!-- START_DETAILED --> |
| 26 | +> ⚠️ **Update Required:** Analysis for v0.0.0. Code is v1.0.0. |
| 27 | +
|
| 28 | +*No detailed non-technical description generated yet.* |
| 29 | +<!-- END_DETAILED --> |
17 | 30 |
|
18 | | -## Backend Configuration |
| 31 | +## Architecture Diagram |
| 32 | +<!-- START_MERMAID_DESC --> |
| 33 | +> ⚠️ **Update Required:** Analysis for v0.0.0. Code is v1.0.0. |
| 34 | +
|
| 35 | +*No architecture explanation generated yet.* |
| 36 | +<!-- END_MERMAID_DESC --> |
| 37 | + |
| 38 | +<!-- START_MERMAID --> |
| 39 | +> ⚠️ **Update Required:** Analysis for v0.0.0. Code is v1.0.0. |
| 40 | +
|
| 41 | +*No architecture diagram generated yet.* |
| 42 | +<!-- END_MERMAID --> |
| 43 | + |
| 44 | +## Configuration (Source Code) |
19 | 45 | ```yaml |
| 46 | +# ------------------------------------------------------------------------------ |
| 47 | +# Package: Airthings |
| 48 | +# Version: 1.0.0 |
| 49 | +# Description: Normalizes Airthings Wave sensors (Temp, Humidity, CO2) |
| 50 | +# Dependencies: sensor.airthings_wave_living_room_temperature |
| 51 | +# ------------------------------------------------------------------------------ |
20 | 52 | template: |
21 | 53 | - sensor: |
22 | 54 | - name: "Airthings Wave Temperature" |
@@ -45,40 +77,12 @@ template: |
45 | 77 | state: > |
46 | 78 | {% set value = states('sensor.airthings_wave_living_room_co2') | float(0) %} |
47 | 79 | {{ value | round(1) }} |
48 | | -``` |
49 | 80 |
|
50 | | -## Frontend Connection |
51 | | -**Key Entities**: |
52 | | -- `sensor.airthings_wave_temperature` |
53 | | -- `sensor.airthings_wave_humidity` |
54 | | -- `sensor.airthings_wave_co2` |
55 | | - |
56 | | -**Dashboard Usage**: |
57 | | -These sensors are used in `dashboard_demo` and `dashboard_dev2` within custom cards (likely `button-card` or composite cards). |
58 | | - |
59 | | -**Card Configuration (Snippet)**: |
60 | | -```json |
61 | | -// From lovelace.dashboard_demo |
62 | | -{ |
63 | | - "type": "custom:button-card", |
64 | | - "template": "card_generic_swap", |
65 | | - "variables": { |
66 | | - "temperature_sensor": "sensor.airthings_wave_temperature" |
67 | | - } |
68 | | -} |
69 | 81 | ``` |
70 | 82 |
|
71 | | -### UI Simulation |
72 | | -<div style="border: 1px solid #444; border-radius: 12px; padding: 16px; width: 300px; background: #222; color: white; font-family: sans-serif;"> |
73 | | - <div style="display: flex; justify-content: space-between; align-items: center;"> |
74 | | - <div style="display: flex; align-items: center; gap: 8px;"> |
75 | | - <span style="font-size: 24px;">🌡️</span> |
76 | | - <span style="font-weight: bold;">Living Room</span> |
77 | | - </div> |
78 | | - <span style="font-size: 1.5em; font-weight: bold;">21.5 °C</span> |
79 | | - </div> |
80 | | - <div style="margin-top: 12px; display: flex; gap: 16px; font-size: 0.9em; color: #aaa;"> |
81 | | - <span>💧 45.2 %</span> |
82 | | - <span>☁️ 850 ppm</span> |
83 | | - </div> |
84 | | -</div> |
| 83 | +## Dashboard Connections |
| 84 | +<!-- START_DASHBOARD --> |
| 85 | +This package powers the following dashboard views: |
| 86 | +
|
| 87 | +* **[Living Room](../dashboards/main/living_room.md)** (Uses 3 entities) |
| 88 | +<!-- END_DASHBOARD --> |
0 commit comments