Compare commits
37 Commits
api_messag
...
826d73990b
| Author | SHA1 | Date | |
|---|---|---|---|
|
826d73990b
|
|||
|
86587402b6
|
|||
|
110b903dc8
|
|||
|
a8f6ad800d
|
|||
|
52a50e1cd4
|
|||
|
9d7e26677f
|
|||
|
ebd459bfc1
|
|||
|
e49c5affe9
|
|||
|
5595cf4f37
|
|||
|
f61417a631
|
|||
|
6d62732d1d
|
|||
|
73814df01e
|
|||
|
4b7ac9b82b
|
|||
|
850d810cb3
|
|||
|
5bdfbacc3c
|
|||
|
3d9043b8fa
|
|||
|
1890a83939
|
|||
|
23edd42fca
|
|||
|
5fbaab3c11
|
|||
|
2eefbcd44b
|
|||
|
d09caa9d92
|
|||
|
127b5857c3
|
|||
|
c2dcb733d8
|
|||
|
168b2c4b12
|
|||
|
66872703c1
|
|||
|
d4b44fa73e
|
|||
|
87a86524d4
|
|||
|
91fdfde280
|
|||
|
d138d7bf0a
|
|||
|
8b08ded0c6
|
|||
|
6a0601742a
|
|||
|
99580f8ff9
|
|||
|
381f8521d4
|
|||
|
a382d58601
|
|||
|
0ca5ffaca0
|
|||
|
ec193a92f8
|
|||
|
c473ea341e
|
219
apps/api/main.py
219
apps/api/main.py
@@ -1,146 +1,3 @@
|
||||
|
||||
"""API main entry point.
|
||||
|
||||
API-Analyse für HomeKit-Bridge Kompatibilität
|
||||
==============================================
|
||||
|
||||
1) GET /devices
|
||||
Status: ✅ VORHANDEN (Zeile 325-343)
|
||||
|
||||
Aktuelles Response-Modell (DeviceInfo, Zeile 189-194):
|
||||
{
|
||||
"device_id": str, ✅ OK
|
||||
"type": str, ✅ OK
|
||||
"name": str, ⚠️ ABWEICHUNG: Erwartet wurde "short_name" (optional)
|
||||
"features": dict ✅ OK
|
||||
}
|
||||
|
||||
Bewertung:
|
||||
- ✅ Liefert device_id, type, features wie erwartet
|
||||
- ⚠️ Verwendet "name" statt "short_name"
|
||||
- ✅ Fallback auf device_id wenn name nicht vorhanden
|
||||
- Kompatibilität: HOCH - einfach "name" als "short_name" verwenden
|
||||
|
||||
|
||||
2) GET /layout
|
||||
Status: ✅ VORHANDEN (Zeile 354-387)
|
||||
|
||||
Aktuelles Response-Format:
|
||||
{
|
||||
"rooms": [
|
||||
{
|
||||
"name": "Schlafzimmer",
|
||||
"devices": [
|
||||
{
|
||||
"device_id": "thermostat_wolfgang",
|
||||
"title": "Thermostat Wolfgang", ← friendly_name
|
||||
"icon": "thermometer",
|
||||
"rank": 1
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
Mapping device_id -> room, friendly_name:
|
||||
- room: Durch Iteration über rooms[].devices[] ableitbar
|
||||
- friendly_name: Im Feld "title" enthalten
|
||||
|
||||
Bewertung:
|
||||
- ✅ Alle erforderlichen Informationen vorhanden
|
||||
- ⚠️ ABWEICHUNG: Verschachtelte Struktur (rooms -> devices)
|
||||
- ⚠️ ABWEICHUNG: friendly_name heißt "title"
|
||||
- Kompatibilität: HOCH - einfache Transformation möglich:
|
||||
```python
|
||||
for room in layout["rooms"]:
|
||||
for device in room["devices"]:
|
||||
mapping[device["device_id"]] = {
|
||||
"room": room["name"],
|
||||
"friendly_name": device["title"]
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
3) POST /devices/{device_id}/set
|
||||
Status: ✅ VORHANDEN (Zeile 406-504)
|
||||
|
||||
Aktuelles Request-Modell (SetDeviceRequest, Zeile 182-185):
|
||||
{
|
||||
"type": str, ✅ OK - muss zum Gerätetyp passen
|
||||
"payload": dict ✅ OK - abstraktes Kommando
|
||||
}
|
||||
|
||||
Beispiel Light:
|
||||
POST /devices/leselampe_esszimmer/set
|
||||
{"type": "light", "payload": {"power": "on", "brightness": 80}}
|
||||
|
||||
Beispiel Thermostat:
|
||||
POST /devices/thermostat_wolfgang/set
|
||||
{"type": "thermostat", "payload": {"target": 21.0}}
|
||||
|
||||
Validierung:
|
||||
- ✅ Type-spezifische Payload-Validierung (Zeile 437-487)
|
||||
- ✅ Read-only Check → 405 METHOD_NOT_ALLOWED (Zeile 431-435)
|
||||
- ✅ Ungültige Payload → 422 UNPROCESSABLE_ENTITY
|
||||
- ✅ Device nicht gefunden → 404 NOT_FOUND
|
||||
|
||||
Bewertung:
|
||||
- ✅ Exakt wie erwartet implementiert
|
||||
- ✅ Alle geforderten Error Codes vorhanden
|
||||
- Kompatibilität: PERFEKT
|
||||
|
||||
|
||||
4) Realtime-Endpoint (SSE)
|
||||
Status: ✅ VORHANDEN als GET /realtime (Zeile 608-632)
|
||||
|
||||
Implementierung:
|
||||
- ✅ Server-Sent Events (media_type="text/event-stream")
|
||||
- ✅ Redis Pub/Sub basiert (event_generator, Zeile 510-607)
|
||||
- ✅ Safari-kompatibel (Heartbeats, Retry-Hints)
|
||||
|
||||
Aktuelles Event-Format (aus apps/abstraction/main.py:250-256):
|
||||
{
|
||||
"type": "state", ✅ OK
|
||||
"device_id": str, ✅ OK
|
||||
"payload": dict, ✅ OK - z.B. {"power":"on","brightness":80}
|
||||
"ts": str ✅ OK - ISO-8601 format von datetime.now(timezone.utc)
|
||||
}
|
||||
|
||||
Beispiel-Event:
|
||||
{
|
||||
"type": "state",
|
||||
"device_id": "thermostat_wolfgang",
|
||||
"payload": {"current": 19.5, "target": 21.0},
|
||||
"ts": "2025-11-17T14:23:45.123456+00:00"
|
||||
}
|
||||
|
||||
Bewertung:
|
||||
- ✅ Alle geforderten Felder vorhanden
|
||||
- ✅ Timestamp im korrekten Format
|
||||
- ✅ SSE mit proper headers und error handling
|
||||
- Kompatibilität: PERFEKT
|
||||
|
||||
|
||||
ZUSAMMENFASSUNG
|
||||
===============
|
||||
|
||||
Alle 4 geforderten Endpunkte sind implementiert!
|
||||
|
||||
Kompatibilität mit HomeKit-Bridge Anforderungen:
|
||||
- GET /devices: HOCH (nur Name-Feld unterschiedlich)
|
||||
- GET /layout: HOCH (Struktur-Transformation nötig)
|
||||
- POST /devices/{id}/set: PERFEKT (1:1 wie gefordert)
|
||||
- GET /realtime (SSE): PERFEKT (1:1 wie gefordert)
|
||||
|
||||
Erforderliche Anpassungen für Bridge:
|
||||
1. GET /devices: "name" als "short_name" interpretieren ✓ trivial
|
||||
2. GET /layout: Verschachtelte Struktur zu flat mapping umwandeln ✓ einfach
|
||||
|
||||
Keine Code-Änderungen in der API erforderlich!
|
||||
Die Bridge kann die bestehenden Endpoints direkt nutzen.
|
||||
|
||||
"""
|
||||
|
||||
import asyncio
|
||||
import json
|
||||
import logging
|
||||
@@ -180,9 +37,12 @@ from apps.api.resolvers import (
|
||||
clear_room_cache,
|
||||
)
|
||||
|
||||
logging.basicConfig(
|
||||
level=logging.DEBUG,
|
||||
format="%(asctime)s - %(name)s - %(levelname)s - %(message)s"
|
||||
)
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
# ============================================================================
|
||||
# STATE CACHES
|
||||
# ============================================================================
|
||||
@@ -231,21 +91,12 @@ async def get_device_layout(device_id: str):
|
||||
|
||||
@app.get("/devices/{device_id}/state")
|
||||
async def get_device_state(device_id: str):
|
||||
"""Gibt den aktuellen State für ein einzelnes Gerät zurück."""
|
||||
state_path = Path(__file__).parent.parent.parent / "config" / "devices.yaml"
|
||||
if not state_path.exists():
|
||||
raise HTTPException(status_code=500, detail="State file not found")
|
||||
with open(state_path, "r") as f:
|
||||
config = yaml.safe_load(f)
|
||||
states = config.get("states", {})
|
||||
state = states.get(device_id)
|
||||
if state is None:
|
||||
try:
|
||||
logger.debug(f"Fetching state for device {device_id}")
|
||||
state = device_states[device_id]
|
||||
return state
|
||||
except KeyError:
|
||||
raise HTTPException(status_code=404, detail="Device state not found")
|
||||
return state
|
||||
# --- Minimal-invasive: Einzelgerät-Layout-Endpunkt ---
|
||||
from fastapi import Query
|
||||
|
||||
|
||||
|
||||
# --- Minimal-invasive: Einzelgerät-Layout-Endpunkt ---
|
||||
@app.get("/devices/{device_id}/layout")
|
||||
@@ -265,22 +116,6 @@ async def get_device_layout(device_id: str):
|
||||
}
|
||||
raise HTTPException(status_code=404, detail="Device layout not found")
|
||||
|
||||
# --- Minimal-invasive: Einzelgerät-State-Endpunkt ---
|
||||
@app.get("/devices/{device_id}/state")
|
||||
async def get_device_state(device_id: str):
|
||||
"""Gibt den aktuellen State für ein einzelnes Gerät zurück."""
|
||||
# States werden wie im Bulk-Endpoint geladen
|
||||
state_path = Path(__file__).parent.parent.parent / "config" / "devices.yaml"
|
||||
if not state_path.exists():
|
||||
raise HTTPException(status_code=500, detail="State file not found")
|
||||
with open(state_path, "r") as f:
|
||||
config = yaml.safe_load(f)
|
||||
states = config.get("states", {})
|
||||
state = states.get(device_id)
|
||||
if state is None:
|
||||
raise HTTPException(status_code=404, detail="Device state not found")
|
||||
return state
|
||||
|
||||
@app.on_event("startup")
|
||||
async def startup_event():
|
||||
"""Include routers after app is initialized to avoid circular imports."""
|
||||
@@ -530,6 +365,32 @@ async def publish_mqtt(topic: str, payload: dict[str, Any]) -> None:
|
||||
await client.publish(topic, message, qos=1)
|
||||
|
||||
|
||||
@app.get("/devices/states")
|
||||
async def get_device_states() -> dict[str, dict[str, Any]]:
|
||||
"""Get current states of all devices from in-memory cache.
|
||||
|
||||
Returns:
|
||||
dict: Dictionary mapping device_id to state payload
|
||||
"""
|
||||
logger.debug("Fetching all device states")
|
||||
return device_states
|
||||
|
||||
|
||||
@app.get("/devices/{device_id}")
|
||||
async def get_device(device_id: str) -> DeviceInfo:
|
||||
logger.debug(f"Fetching info for device {device_id}")
|
||||
devices = load_devices()
|
||||
device = next((d for d in devices if d["device_id"] == device_id), None)
|
||||
if not device:
|
||||
raise HTTPException(status_code=404, detail="Device not found")
|
||||
return DeviceInfo(
|
||||
device_id=device["device_id"],
|
||||
type=device["type"],
|
||||
name=device.get("name", device["device_id"]),
|
||||
features=device.get("features", {})
|
||||
)
|
||||
|
||||
|
||||
@app.get("/devices")
|
||||
async def get_devices() -> list[DeviceInfo]:
|
||||
"""Get list of available devices.
|
||||
@@ -537,6 +398,7 @@ async def get_devices() -> list[DeviceInfo]:
|
||||
Returns:
|
||||
list: List of device information including features
|
||||
"""
|
||||
logger.debug("Fetching list of devices")
|
||||
devices = load_devices()
|
||||
return [
|
||||
DeviceInfo(
|
||||
@@ -549,15 +411,6 @@ async def get_devices() -> list[DeviceInfo]:
|
||||
]
|
||||
|
||||
|
||||
@app.get("/devices/states")
|
||||
async def get_device_states() -> dict[str, dict[str, Any]]:
|
||||
"""Get current states of all devices from in-memory cache.
|
||||
|
||||
Returns:
|
||||
dict: Dictionary mapping device_id to state payload
|
||||
"""
|
||||
return device_states
|
||||
|
||||
|
||||
@app.get("/layout")
|
||||
async def get_layout() -> dict[str, Any]:
|
||||
|
||||
@@ -73,6 +73,10 @@ class HomeAutomationClient {
|
||||
return await this.fetch(this.api('/devices'));
|
||||
}
|
||||
|
||||
async getDevice(deviceId) {
|
||||
return await this.fetch(this.api(`/devices/${deviceId}`));
|
||||
}
|
||||
|
||||
/**
|
||||
* Get current state of a specific device
|
||||
* @param {string} deviceId - Device ID
|
||||
|
||||
@@ -324,11 +324,13 @@
|
||||
try {
|
||||
// Load device info using API client
|
||||
// NEW: Use new endpoints for device info and layout
|
||||
deviceData = await window.apiClient.getDeviceState(deviceId);
|
||||
deviceData = await window.apiClient.getDevice(deviceId);
|
||||
console.log("Loaded device data:", deviceData);
|
||||
deviceState = await window.apiClient.getDeviceState(deviceId);
|
||||
console.log("Loaded device state:", deviceState);
|
||||
const layoutInfo = await window.apiClient.getDeviceLayout(deviceId);
|
||||
console.log("Loaded layout info:", layoutInfo);
|
||||
roomName = layoutInfo.room;
|
||||
// deviceState is now the result of getDeviceState
|
||||
deviceState = deviceData;
|
||||
|
||||
// Update header
|
||||
document.getElementById('device-icon').textContent = deviceIcons[deviceData.type] || '📱';
|
||||
@@ -469,11 +471,11 @@
|
||||
stateGrid.className = 'state-grid';
|
||||
stateGrid.innerHTML = `
|
||||
<div class="state-item">
|
||||
<div class="state-value" id="current-temp">${deviceState.current_temp?.toFixed(1) || '--'}°C</div>
|
||||
<div class="state-value" id="current-temp">${deviceState.current?.toFixed(1) || '--'}°C</div>
|
||||
<div class="state-label">Aktuell</div>
|
||||
</div>
|
||||
<div class="state-item">
|
||||
<div class="state-value" id="target-temp">${deviceState.target_temp?.toFixed(1) || '--'}°C</div>
|
||||
<div class="state-value" id="target-temp">${deviceState.target?.toFixed(1) || '--'}°C</div>
|
||||
<div class="state-label">Ziel</div>
|
||||
</div>
|
||||
`;
|
||||
@@ -486,8 +488,8 @@
|
||||
sliderGroup.innerHTML = `
|
||||
<label class="control-label">Zieltemperatur</label>
|
||||
<div class="slider-container">
|
||||
<input type="range" class="slider" id="temp-slider" min="5" max="30" step="0.5" value="${deviceState.target_temp || 21}">
|
||||
<div class="slider-value" id="temp-value">${deviceState.target_temp?.toFixed(1) || '21.0'}°C</div>
|
||||
<input type="range" class="slider" id="temp-slider" min="5" max="30" step="0.5" value="${deviceState.target || 21}">
|
||||
<div class="slider-value" id="temp-value">${deviceState.target?.toFixed(1) || '21.0'}°C</div>
|
||||
</div>
|
||||
`;
|
||||
card.appendChild(sliderGroup);
|
||||
@@ -763,15 +765,15 @@
|
||||
const tempSlider = document.getElementById('temp-slider');
|
||||
const tempValue = document.getElementById('temp-value');
|
||||
|
||||
if (currentTemp && deviceState.current_temp != null) {
|
||||
currentTemp.textContent = deviceState.current_temp.toFixed(1) + '°C';
|
||||
if (currentTemp && deviceState.current != null) {
|
||||
currentTemp.textContent = deviceState.current.toFixed(1) + '°C';
|
||||
}
|
||||
if (targetTemp && deviceState.target_temp != null) {
|
||||
targetTemp.textContent = deviceState.target_temp.toFixed(1) + '°C';
|
||||
if (targetTemp && deviceState.target != null) {
|
||||
targetTemp.textContent = deviceState.target.toFixed(1) + '°C';
|
||||
}
|
||||
if (tempSlider && deviceState.target_temp != null) {
|
||||
tempSlider.value = deviceState.target_temp;
|
||||
tempValue.textContent = deviceState.target_temp.toFixed(1) + '°C';
|
||||
if (tempSlider && deviceState.target != null) {
|
||||
tempSlider.value = deviceState.target;
|
||||
tempValue.textContent = deviceState.target.toFixed(1) + '°C';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -23,6 +23,12 @@
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #333;
|
||||
font-size: 28px;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.header {
|
||||
background: rgba(255, 255, 255, 0.95);
|
||||
border-radius: 12px;
|
||||
@@ -47,21 +53,19 @@
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
h1 {
|
||||
color: #333;
|
||||
font-size: 28px;
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
|
||||
.room-info {
|
||||
color: #666;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
|
||||
.devices-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
gap: 16px;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
@media (min-width: 600px) {
|
||||
@@ -80,14 +84,18 @@
|
||||
background: rgba(255, 255, 255, 0.95);
|
||||
border-radius: 12px;
|
||||
padding: 16px;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s ease;
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
||||
min-height: 120px;
|
||||
min-height: 110px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
text-decoration: none;
|
||||
color: inherit;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.device-card:hover {
|
||||
@@ -111,7 +119,7 @@
|
||||
}
|
||||
|
||||
.device-title {
|
||||
font-size: 16px;
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: #333;
|
||||
flex: 1;
|
||||
@@ -223,8 +231,8 @@
|
||||
'thermostat': '🌡️',
|
||||
'contact': '🚪',
|
||||
'temp_humidity_sensor': '🌡️',
|
||||
'relay': '🔌',
|
||||
'outlet': '🔌',
|
||||
'relay': '💡',
|
||||
'outlet': '💡',
|
||||
'cover': '🪟'
|
||||
};
|
||||
|
||||
@@ -371,12 +379,9 @@
|
||||
|
||||
case 'thermostat':
|
||||
if (state.current != null) {
|
||||
html = `<div class="state-primary">${state.current.toFixed(1)}°C</div>`;
|
||||
html = `<div class="state-primary">${state.target.toFixed(1)}°C</div>`;
|
||||
if (state.target != null) {
|
||||
html += `<div class="state-secondary">Ziel: ${state.target}°C</div>`;
|
||||
}
|
||||
if (state.mode) {
|
||||
html += `<div class="state-secondary">Modus: ${state.mode}</div>`;
|
||||
html += `<div class="state-secondary">Ist: ${state.current}°C</div>`;
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -11,6 +11,7 @@ redis:
|
||||
channel: "ui:updates"
|
||||
devices:
|
||||
- device_id: lampe_semeniere_wohnzimmer
|
||||
name: Semeniere
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -25,6 +26,7 @@ devices:
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: stehlampe_esszimmer_spiegel
|
||||
name: Stehlampe Spiegel
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -35,6 +37,7 @@ devices:
|
||||
state: "zigbee2mqtt/0x001788010d06ea09"
|
||||
set: "zigbee2mqtt/0x001788010d06ea09/set"
|
||||
- device_id: stehlampe_esszimmer_schrank
|
||||
name: Stehlampe Schrank
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -45,6 +48,7 @@ devices:
|
||||
state: "zigbee2mqtt/0x001788010d09176c"
|
||||
set: "zigbee2mqtt/0x001788010d09176c/set"
|
||||
- device_id: grosse_lampe_wohnzimmer
|
||||
name: grosse Lampe
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -59,6 +63,7 @@ devices:
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: lampe_naehtischchen_wohnzimmer
|
||||
name: Nähtischchen
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -72,21 +77,8 @@ devices:
|
||||
ieee_address: "0x842e14fffee560ee"
|
||||
model: "HG06337"
|
||||
vendor: "Lidl"
|
||||
- device_id: kleine_lampe_rechts_esszimmer
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
features:
|
||||
power: true
|
||||
topics:
|
||||
state: "zigbee2mqtt/0xf0d1b80000156645"
|
||||
set: "zigbee2mqtt/0xf0d1b80000156645/set"
|
||||
metadata:
|
||||
friendly_name: "kleine Lampe rechts Esszimmer"
|
||||
ieee_address: "0xf0d1b80000156645"
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: kleine_lampe_links_esszimmer
|
||||
name: kleine Lampe
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -101,6 +93,7 @@ devices:
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: leselampe_esszimmer
|
||||
name: Leselampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -116,6 +109,7 @@ devices:
|
||||
model: "LED1842G3"
|
||||
vendor: "IKEA"
|
||||
- device_id: medusalampe_schlafzimmer
|
||||
name: Medusa-Lampe
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -131,6 +125,7 @@ devices:
|
||||
vendor: "OSRAM"
|
||||
- device_id: sportlicht_am_fernseher_studierzimmer
|
||||
type: light
|
||||
name: am Fernseher
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
features:
|
||||
@@ -146,6 +141,7 @@ devices:
|
||||
model: "LED1733G7"
|
||||
vendor: "IKEA"
|
||||
- device_id: deckenlampe_schlafzimmer
|
||||
name: Deckenlampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -161,6 +157,7 @@ devices:
|
||||
model: "8718699688882"
|
||||
vendor: "Philips"
|
||||
- device_id: bettlicht_wolfgang
|
||||
name: Bettlicht Wolfgang
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -176,6 +173,7 @@ devices:
|
||||
model: "9290020399"
|
||||
vendor: "Philips"
|
||||
- device_id: bettlicht_patty
|
||||
name: Bettlicht Patty
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -191,6 +189,7 @@ devices:
|
||||
model: "9290020399"
|
||||
vendor: "Philips"
|
||||
- device_id: schranklicht_hinten_patty
|
||||
name: Schranklicht hinten
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -206,6 +205,7 @@ devices:
|
||||
model: "8718699673147"
|
||||
vendor: "Philips"
|
||||
- device_id: schranklicht_vorne_patty
|
||||
name: Schranklicht vorne
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -220,6 +220,7 @@ devices:
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: leselampe_patty
|
||||
name: Leselampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -235,6 +236,7 @@ devices:
|
||||
model: "8718699673147"
|
||||
vendor: "Philips"
|
||||
- device_id: deckenlampe_esszimmer
|
||||
name: Deckenlampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -249,23 +251,8 @@ devices:
|
||||
ieee_address: "0x0017880108a03e45"
|
||||
model: "929002241201"
|
||||
vendor: "Philips"
|
||||
- device_id: standlampe_esszimmer
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
features:
|
||||
power: true
|
||||
brightness: true
|
||||
color_temperature: true
|
||||
topics:
|
||||
state: "zigbee2mqtt/0xbc33acfffe21f547"
|
||||
set: "zigbee2mqtt/0xbc33acfffe21f547/set"
|
||||
metadata:
|
||||
friendly_name: "Standlampe Esszimmer"
|
||||
ieee_address: "0xbc33acfffe21f547"
|
||||
model: "LED1732G11"
|
||||
vendor: "IKEA"
|
||||
- device_id: haustuer
|
||||
name: Haustür-Lampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -281,6 +268,7 @@ devices:
|
||||
model: "LED1842G3"
|
||||
vendor: "IKEA"
|
||||
- device_id: deckenlampe_flur_oben
|
||||
name: Deckenlampe oben
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -297,6 +285,7 @@ devices:
|
||||
model: "929003099001"
|
||||
vendor: "Philips"
|
||||
- device_id: kueche_deckenlampe
|
||||
name: Deckenlampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -312,6 +301,7 @@ devices:
|
||||
model: "929002469202"
|
||||
vendor: "Philips"
|
||||
- device_id: sportlicht_tisch
|
||||
name: am Tisch
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -327,6 +317,7 @@ devices:
|
||||
model: "4058075729063"
|
||||
vendor: "LEDVANCE"
|
||||
- device_id: sportlicht_regal
|
||||
name: am Regal
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -342,6 +333,7 @@ devices:
|
||||
model: "4058075729063"
|
||||
vendor: "LEDVANCE"
|
||||
- device_id: licht_flur_oben_am_spiegel
|
||||
name: Spiegel
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -358,6 +350,7 @@ devices:
|
||||
model: "LED1732G11"
|
||||
vendor: "IKEA"
|
||||
- device_id: experimentlabtest
|
||||
name: Test Lampe
|
||||
type: light
|
||||
cap_version: "light@1.2.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -373,6 +366,7 @@ devices:
|
||||
model: "4058075208421"
|
||||
vendor: "LEDVANCE"
|
||||
- device_id: thermostat_wolfgang
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -391,6 +385,7 @@ devices:
|
||||
model: "GS361A-H04"
|
||||
vendor: "Siterwell"
|
||||
- device_id: thermostat_kueche
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -409,6 +404,7 @@ devices:
|
||||
model: "GS361A-H04"
|
||||
vendor: "Siterwell"
|
||||
- device_id: thermostat_schlafzimmer
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -427,6 +423,7 @@ devices:
|
||||
peer_id: "42"
|
||||
channel: "1"
|
||||
- device_id: thermostat_esszimmer
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -445,6 +442,7 @@ devices:
|
||||
peer_id: "45"
|
||||
channel: "1"
|
||||
- device_id: thermostat_wohnzimmer
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -463,6 +461,7 @@ devices:
|
||||
peer_id: "46"
|
||||
channel: "1"
|
||||
- device_id: thermostat_patty
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -481,6 +480,7 @@ devices:
|
||||
peer_id: "39"
|
||||
channel: "1"
|
||||
- device_id: thermostat_bad_oben
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -499,6 +499,7 @@ devices:
|
||||
peer_id: "41"
|
||||
channel: "1"
|
||||
- device_id: thermostat_bad_unten
|
||||
name: Heizung
|
||||
type: thermostat
|
||||
cap_version: "thermostat@1.0.0"
|
||||
technology: max
|
||||
@@ -517,6 +518,7 @@ devices:
|
||||
peer_id: "48"
|
||||
channel: "1"
|
||||
- device_id: sterne_wohnzimmer
|
||||
name: Sterne
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: zigbee2mqtt
|
||||
@@ -531,8 +533,8 @@ devices:
|
||||
model: "AC10691"
|
||||
vendor: "OSRAM"
|
||||
- device_id: kontakt_schlafzimmer_strasse
|
||||
name: Fenster
|
||||
type: contact
|
||||
name: Kontakt Schlafzimmer Straße
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
@@ -540,39 +542,39 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_esszimmer_strasse_rechts
|
||||
type: contact
|
||||
name: Kontakt Esszimmer Straße rechts
|
||||
name: Fenster rechts
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
state: homegear/instance1/plain/26/1/STATE
|
||||
features: {}
|
||||
- device_id: kontakt_esszimmer_strasse_links
|
||||
name: Fenster links
|
||||
type: contact
|
||||
name: Kontakt Esszimmer Straße links
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
state: homegear/instance1/plain/27/1/STATE
|
||||
features: {}
|
||||
- device_id: kontakt_wohnzimmer_garten_rechts
|
||||
name: Fenster rechts
|
||||
type: contact
|
||||
name: Kontakt Wohnzimmer Garten rechts
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
state: homegear/instance1/plain/28/1/STATE
|
||||
features: {}
|
||||
- device_id: kontakt_wohnzimmer_garten_links
|
||||
name: Fenster links
|
||||
type: contact
|
||||
name: Kontakt Wohnzimmer Garten links
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
state: homegear/instance1/plain/29/1/STATE
|
||||
features: {}
|
||||
- device_id: kontakt_kueche_garten_fenster
|
||||
name: Fenster Garten
|
||||
type: contact
|
||||
name: Kontakt Küche Garten Fenster
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -580,23 +582,23 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_kueche_garten_tuer
|
||||
type: contact
|
||||
name: Kontakt Küche Garten Tür
|
||||
name: Terrassentür
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
state: zigbee2mqtt/0x00158d008b332788
|
||||
features: {}
|
||||
- device_id: kontakt_kueche_strasse_rechts
|
||||
name: Fenster Straße rechts
|
||||
type: contact
|
||||
name: Kontakt Küche Straße rechts
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
state: zigbee2mqtt/0x00158d008b151803
|
||||
features: {}
|
||||
- device_id: kontakt_kueche_strasse_links
|
||||
name: Fenster Straße links
|
||||
type: contact
|
||||
name: Kontakt Küche Straße links
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -604,7 +606,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_patty_garten_rechts
|
||||
type: contact
|
||||
name: Kontakt Patty Garten rechts
|
||||
name: Fenster Garten rechts
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
@@ -612,7 +614,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_patty_garten_links
|
||||
type: contact
|
||||
name: Kontakt Patty Garten links
|
||||
name: Fenster Garten links
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
@@ -620,7 +622,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_patty_strasse
|
||||
type: contact
|
||||
name: Kontakt Patty Straße
|
||||
name: Fenster Straße
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -628,7 +630,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_wolfgang_garten
|
||||
type: contact
|
||||
name: Kontakt Wolfgang Garten
|
||||
name: Fenster
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -636,7 +638,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_bad_oben_strasse
|
||||
type: contact
|
||||
name: Kontakt Bad Oben Straße
|
||||
name: Fenster
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -644,7 +646,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: kontakt_bad_unten_strasse
|
||||
type: contact
|
||||
name: Kontakt Bad Unten Straße
|
||||
name: Fenster
|
||||
cap_version: contact_sensor@1.0.0
|
||||
technology: max
|
||||
topics:
|
||||
@@ -652,7 +654,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_schlafzimmer
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -660,7 +662,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_wohnzimmer
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -668,7 +670,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_kueche
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -676,7 +678,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_arbeitszimmer_patty
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -684,7 +686,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_arbeitszimmer_wolfgang
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -692,7 +694,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_bad_oben
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -700,7 +702,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_bad_unten
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -708,7 +710,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_flur
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -716,7 +718,7 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_waschkueche
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
@@ -724,13 +726,14 @@ devices:
|
||||
features: {}
|
||||
- device_id: sensor_sportzimmer
|
||||
type: temp_humidity_sensor
|
||||
name: Temperatur & Luftfeuchte
|
||||
name: Thermometer
|
||||
cap_version: temp_humidity_sensor@1.0.0
|
||||
technology: zigbee2mqtt
|
||||
topics:
|
||||
state: zigbee2mqtt/0x00158d0009421422
|
||||
features: {}
|
||||
- device_id: licht_spuele_kueche
|
||||
name: Spüle
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: shelly
|
||||
@@ -740,6 +743,7 @@ devices:
|
||||
set: "shellies/LightKitchenSink/relay/0/command"
|
||||
state: "shellies/LightKitchenSink/relay/0"
|
||||
- device_id: licht_schrank_esszimmer
|
||||
name: Schrank
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: shelly
|
||||
@@ -750,6 +754,7 @@ devices:
|
||||
state: "shellies/schrankesszimmer/relay/0"
|
||||
- device_id: licht_regal_wohnzimmer
|
||||
type: relay
|
||||
name: Regal
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: shelly
|
||||
features:
|
||||
@@ -759,6 +764,7 @@ devices:
|
||||
state: "shellies/wohnzimmer-regal/relay/0"
|
||||
- device_id: licht_flur_schrank
|
||||
type: relay
|
||||
name: Schrank
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: shelly
|
||||
features:
|
||||
@@ -767,6 +773,7 @@ devices:
|
||||
set: "shellies/schrankflur/relay/0/command"
|
||||
state: "shellies/schrankflur/relay/0"
|
||||
- device_id: licht_terasse
|
||||
name: Terrasse
|
||||
type: relay
|
||||
cap_version: "relay@1.0.0"
|
||||
technology: shelly
|
||||
|
||||
@@ -39,10 +39,10 @@ rooms:
|
||||
title: Leselampe Esszimmer
|
||||
icon: 💡
|
||||
rank: 60
|
||||
- device_id: standlampe_esszimmer
|
||||
title: Standlampe Esszimmer
|
||||
icon: 💡
|
||||
rank: 70
|
||||
# - device_id: standlampe_esszimmer
|
||||
# title: Standlampe Esszimmer
|
||||
# icon: 💡
|
||||
# rank: 70
|
||||
- device_id: kleine_lampe_links_esszimmer
|
||||
title: kleine Lampe links Esszimmer
|
||||
icon: 💡
|
||||
@@ -55,10 +55,10 @@ rooms:
|
||||
title: Stehlampe Esszimmer Schrank
|
||||
icon: 💡
|
||||
rank: 82
|
||||
- device_id: kleine_lampe_rechts_esszimmer
|
||||
title: kleine Lampe rechts Esszimmer
|
||||
icon: 💡
|
||||
rank: 90
|
||||
# - device_id: kleine_lampe_rechts_esszimmer
|
||||
# title: kleine Lampe rechts Esszimmer
|
||||
# icon: 💡
|
||||
# rank: 90
|
||||
- device_id: licht_schrank_esszimmer
|
||||
title: Schranklicht Esszimmer
|
||||
icon: 💡
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
version: "3.9"
|
||||
|
||||
x-environment: &default-env
|
||||
MQTT_BROKER: "172.23.1.102"
|
||||
MQTT_PORT: 1883
|
||||
|
||||
Reference in New Issue
Block a user