* Add working support for color temperature * Lint fixes * Fix to config json version to make it build * Clean up and BLE constants and prepare for lightlevel UUID * Eagerly send HA discovery, standardize colorTemp, clean up MQTT subscribe * Fix typo in MqttClient * Listen to HA birth messages to make devices available after HA restart - Extract constants to common file * Prepare for 0.17.0 release
39 lines
908 B
TypeScript
39 lines
908 B
TypeScript
/* eslint-disable no-use-before-define */
|
|
|
|
import { OutputSettingColorTemperature } from "./ApiSite";
|
|
|
|
export type OutputDevices = { [deviceIdAndOutput: string]: OutputDevice };
|
|
|
|
export interface OutputDevice {
|
|
bleOutputAddress: number;
|
|
colorTemp: number?;
|
|
colorTempSettings?: OutputSettingColorTemperature
|
|
deviceId: string;
|
|
dim?: number;
|
|
dimmable: boolean;
|
|
name: string;
|
|
output: number;
|
|
roomId: string | undefined;
|
|
roomName: string | undefined;
|
|
state: boolean | undefined;
|
|
type: string;
|
|
typeDescription: string;
|
|
typeName: string;
|
|
version: string;
|
|
uniqueId: string;
|
|
}
|
|
|
|
export type InputDevices = { [deviceIdAndOutput: string]: InputDevice };
|
|
|
|
export interface InputDevice {
|
|
bleInputAddress: number;
|
|
deviceId: string;
|
|
name: string;
|
|
input: number;
|
|
roomId: string;
|
|
type: string;
|
|
typeDescription: string;
|
|
typeName: string;
|
|
version: string;
|
|
uniqueId: string;
|
|
}
|