@camstack/addon-provider-homematic 1.2.201 → 1.2.202
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/dist/_stub.js +2 -2
- package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-BxV59wdC.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_page-Co16X8r0.mjs} +5 -5
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-CSC-ziPZ.mjs +26 -0
- package/dist/addon-provider-homematic.css +1 -1
- package/dist/addon.js +617 -48
- package/dist/addon.mjs +617 -48
- package/dist/{hostInit-CNluvxTs.mjs → hostInit-DNi48_tT.mjs} +4 -4
- package/dist/remoteEntry.js +1 -1
- package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-6snx-90f.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_provider_homematic_page__remoteEntry_js-CWpmn0LZ.mjs} +1 -1
- package/dist/widgets/_stub.js +1 -1
- package/dist/widgets/{_virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_widgets-DHK12kT3.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_provider_homematic_widgets-D7OMUSRg.mjs} +3 -3
- package/dist/widgets/_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-DCfwscwZ.mjs +26 -0
- package/dist/widgets/{hostInit-DTRrkNyS.mjs → hostInit-BADUDAz-.mjs} +3 -3
- package/dist/widgets/remoteEntry.js +1 -1
- package/package.json +3 -3
- package/dist/_virtual_mf___mfe_internal__addon_provider_homematic_page__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-skuvsVHe.mjs +0 -26
- package/dist/widgets/_virtual_mf___mfe_internal__addon_provider_homematic_widgets__loadShare___mf_0_camstack_mf_1_ui_mf_2_library__loadShare__.js-DGJJvlsA.mjs +0 -26
package/dist/addon.js
CHANGED
|
@@ -832,7 +832,7 @@ var EventCategory = /* @__PURE__ */ function(EventCategory) {
|
|
|
832
832
|
return EventCategory;
|
|
833
833
|
}({});
|
|
834
834
|
//#endregion
|
|
835
|
-
//#region ../types/dist/composed-stable-id-
|
|
835
|
+
//#region ../types/dist/composed-stable-id-RvQIEpqg.mjs
|
|
836
836
|
/**
|
|
837
837
|
import { errMsg } from '@camstack/types'
|
|
838
838
|
* Extract a human-readable message from an unknown error value.
|
|
@@ -914,6 +914,9 @@ var DeviceType = /* @__PURE__ */ function(DeviceType) {
|
|
|
914
914
|
/** Weather provider (HA `weather.*`). Tier-3, low MVP priority.
|
|
915
915
|
* `weather` cap. */
|
|
916
916
|
DeviceType["Weather"] = "weather";
|
|
917
|
+
/** A physical weather station (Ecowitt outdoor array). `weather-station`
|
|
918
|
+
* cap. Distinct from {@link Weather}, which is a forecast provider. */
|
|
919
|
+
DeviceType["WeatherStation"] = "weather-station";
|
|
917
920
|
/** Robot vacuum (HA `vacuum.*`). Tier-3. `vacuum-control` cap. */
|
|
918
921
|
DeviceType["Vacuum"] = "vacuum";
|
|
919
922
|
/** Robotic lawn mower (HA `lawn_mower.*`). Tier-3.
|
|
@@ -6081,7 +6084,7 @@ var ZodIssueCode = {
|
|
|
6081
6084
|
var ZodFirstPartyTypeKind;
|
|
6082
6085
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
6083
6086
|
//#endregion
|
|
6084
|
-
//#region ../types/dist/sleep-
|
|
6087
|
+
//#region ../types/dist/sleep-BnR9qGOv.mjs
|
|
6085
6088
|
/**
|
|
6086
6089
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
6087
6090
|
* window to float samples (D455).
|
|
@@ -18619,6 +18622,183 @@ var CAP_VOCABULARY_BY_NAME = {
|
|
|
18619
18622
|
}
|
|
18620
18623
|
]
|
|
18621
18624
|
},
|
|
18625
|
+
"weather-station": {
|
|
18626
|
+
scope: "device",
|
|
18627
|
+
noun: {
|
|
18628
|
+
en: "Weather station",
|
|
18629
|
+
it: "Stazione meteo"
|
|
18630
|
+
},
|
|
18631
|
+
state: [
|
|
18632
|
+
{
|
|
18633
|
+
kind: "numeric",
|
|
18634
|
+
field: "temperature",
|
|
18635
|
+
quantity: {
|
|
18636
|
+
en: "the outdoor temperature",
|
|
18637
|
+
it: "la temperatura esterna"
|
|
18638
|
+
},
|
|
18639
|
+
label: {
|
|
18640
|
+
en: "Temperature",
|
|
18641
|
+
it: "Temperatura"
|
|
18642
|
+
},
|
|
18643
|
+
unit: "°C",
|
|
18644
|
+
icon: "thermometer"
|
|
18645
|
+
},
|
|
18646
|
+
{
|
|
18647
|
+
kind: "numeric",
|
|
18648
|
+
field: "humidity",
|
|
18649
|
+
quantity: {
|
|
18650
|
+
en: "the outdoor humidity",
|
|
18651
|
+
it: "l’umidità esterna"
|
|
18652
|
+
},
|
|
18653
|
+
label: {
|
|
18654
|
+
en: "Humidity",
|
|
18655
|
+
it: "Umidità"
|
|
18656
|
+
},
|
|
18657
|
+
unit: "%",
|
|
18658
|
+
icon: "droplets"
|
|
18659
|
+
},
|
|
18660
|
+
{
|
|
18661
|
+
kind: "numeric",
|
|
18662
|
+
field: "pressure",
|
|
18663
|
+
quantity: {
|
|
18664
|
+
en: "the air pressure",
|
|
18665
|
+
it: "la pressione atmosferica"
|
|
18666
|
+
},
|
|
18667
|
+
label: {
|
|
18668
|
+
en: "Pressure",
|
|
18669
|
+
it: "Pressione"
|
|
18670
|
+
},
|
|
18671
|
+
unit: "hPa",
|
|
18672
|
+
icon: "gauge"
|
|
18673
|
+
},
|
|
18674
|
+
{
|
|
18675
|
+
kind: "numeric",
|
|
18676
|
+
field: "windSpeed",
|
|
18677
|
+
quantity: {
|
|
18678
|
+
en: "the wind speed",
|
|
18679
|
+
it: "la velocità del vento"
|
|
18680
|
+
},
|
|
18681
|
+
label: {
|
|
18682
|
+
en: "Wind",
|
|
18683
|
+
it: "Vento"
|
|
18684
|
+
},
|
|
18685
|
+
unit: "m/s",
|
|
18686
|
+
icon: "wind"
|
|
18687
|
+
},
|
|
18688
|
+
{
|
|
18689
|
+
kind: "numeric",
|
|
18690
|
+
field: "windGust",
|
|
18691
|
+
quantity: {
|
|
18692
|
+
en: "the wind gust",
|
|
18693
|
+
it: "la raffica di vento"
|
|
18694
|
+
},
|
|
18695
|
+
label: {
|
|
18696
|
+
en: "Gust",
|
|
18697
|
+
it: "Raffica"
|
|
18698
|
+
},
|
|
18699
|
+
unit: "m/s",
|
|
18700
|
+
icon: "wind"
|
|
18701
|
+
},
|
|
18702
|
+
{
|
|
18703
|
+
kind: "numeric",
|
|
18704
|
+
field: "windBearing",
|
|
18705
|
+
quantity: {
|
|
18706
|
+
en: "the wind bearing",
|
|
18707
|
+
it: "la direzione del vento"
|
|
18708
|
+
},
|
|
18709
|
+
label: {
|
|
18710
|
+
en: "Wind bearing",
|
|
18711
|
+
it: "Direzione del vento"
|
|
18712
|
+
},
|
|
18713
|
+
unit: "°",
|
|
18714
|
+
icon: "wind"
|
|
18715
|
+
},
|
|
18716
|
+
{
|
|
18717
|
+
kind: "numeric",
|
|
18718
|
+
field: "rainRate",
|
|
18719
|
+
quantity: {
|
|
18720
|
+
en: "the rain rate",
|
|
18721
|
+
it: "l’intensità della pioggia"
|
|
18722
|
+
},
|
|
18723
|
+
label: {
|
|
18724
|
+
en: "Rain rate",
|
|
18725
|
+
it: "Intensità pioggia"
|
|
18726
|
+
},
|
|
18727
|
+
unit: "mm/h",
|
|
18728
|
+
icon: "droplets"
|
|
18729
|
+
},
|
|
18730
|
+
{
|
|
18731
|
+
kind: "numeric",
|
|
18732
|
+
field: "rainDaily",
|
|
18733
|
+
quantity: {
|
|
18734
|
+
en: "the rain today",
|
|
18735
|
+
it: "la pioggia di oggi"
|
|
18736
|
+
},
|
|
18737
|
+
label: {
|
|
18738
|
+
en: "Rain today",
|
|
18739
|
+
it: "Pioggia oggi"
|
|
18740
|
+
},
|
|
18741
|
+
unit: "mm",
|
|
18742
|
+
icon: "droplets"
|
|
18743
|
+
},
|
|
18744
|
+
{
|
|
18745
|
+
kind: "numeric",
|
|
18746
|
+
field: "rainEvent",
|
|
18747
|
+
quantity: {
|
|
18748
|
+
en: "the rain this event",
|
|
18749
|
+
it: "la pioggia di questo evento"
|
|
18750
|
+
},
|
|
18751
|
+
label: {
|
|
18752
|
+
en: "Rain event",
|
|
18753
|
+
it: "Evento di pioggia"
|
|
18754
|
+
},
|
|
18755
|
+
unit: "mm",
|
|
18756
|
+
icon: "droplets"
|
|
18757
|
+
},
|
|
18758
|
+
{
|
|
18759
|
+
kind: "numeric",
|
|
18760
|
+
field: "uv",
|
|
18761
|
+
quantity: {
|
|
18762
|
+
en: "the UV index",
|
|
18763
|
+
it: "l’indice UV"
|
|
18764
|
+
},
|
|
18765
|
+
label: {
|
|
18766
|
+
en: "UV",
|
|
18767
|
+
it: "UV"
|
|
18768
|
+
},
|
|
18769
|
+
unit: "",
|
|
18770
|
+
icon: "cloud-sun"
|
|
18771
|
+
},
|
|
18772
|
+
{
|
|
18773
|
+
kind: "numeric",
|
|
18774
|
+
field: "solarRadiation",
|
|
18775
|
+
quantity: {
|
|
18776
|
+
en: "the solar radiation",
|
|
18777
|
+
it: "la radiazione solare"
|
|
18778
|
+
},
|
|
18779
|
+
label: {
|
|
18780
|
+
en: "Solar",
|
|
18781
|
+
it: "Sole"
|
|
18782
|
+
},
|
|
18783
|
+
unit: "W/m²",
|
|
18784
|
+
icon: "cloud-sun"
|
|
18785
|
+
},
|
|
18786
|
+
{
|
|
18787
|
+
kind: "numeric",
|
|
18788
|
+
field: "dewPoint",
|
|
18789
|
+
quantity: {
|
|
18790
|
+
en: "the dew point",
|
|
18791
|
+
it: "il punto di rugiada"
|
|
18792
|
+
},
|
|
18793
|
+
label: {
|
|
18794
|
+
en: "Dew point",
|
|
18795
|
+
it: "Punto di rugiada"
|
|
18796
|
+
},
|
|
18797
|
+
unit: "°C",
|
|
18798
|
+
icon: "thermometer"
|
|
18799
|
+
}
|
|
18800
|
+
]
|
|
18801
|
+
},
|
|
18622
18802
|
"battery": {
|
|
18623
18803
|
scope: "device",
|
|
18624
18804
|
noun: {
|
|
@@ -18843,6 +19023,30 @@ var CAP_VOCABULARY_BY_NAME = {
|
|
|
18843
19023
|
icon: "wifi-off"
|
|
18844
19024
|
}]
|
|
18845
19025
|
},
|
|
19026
|
+
"error": {
|
|
19027
|
+
scope: "device",
|
|
19028
|
+
noun: {
|
|
19029
|
+
en: "Fault",
|
|
19030
|
+
it: "Guasto"
|
|
19031
|
+
},
|
|
19032
|
+
state: [{
|
|
19033
|
+
kind: "boolean",
|
|
19034
|
+
field: "active",
|
|
19035
|
+
label: {
|
|
19036
|
+
en: "Fault",
|
|
19037
|
+
it: "Guasto"
|
|
19038
|
+
},
|
|
19039
|
+
whenTrue: {
|
|
19040
|
+
en: "When {device} reports a fault",
|
|
19041
|
+
it: "Quando {device} segnala un guasto"
|
|
19042
|
+
},
|
|
19043
|
+
whenFalse: {
|
|
19044
|
+
en: "When the fault of {device} clears",
|
|
19045
|
+
it: "Quando il guasto di {device} si risolve"
|
|
19046
|
+
},
|
|
19047
|
+
icon: "triangle-alert"
|
|
19048
|
+
}]
|
|
19049
|
+
},
|
|
18846
19050
|
"doorbell": {
|
|
18847
19051
|
scope: "device",
|
|
18848
19052
|
noun: {
|
|
@@ -19573,6 +19777,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
19573
19777
|
"embedding-encoder",
|
|
19574
19778
|
"energy-system",
|
|
19575
19779
|
"enum-sensor",
|
|
19780
|
+
"error",
|
|
19576
19781
|
"event-emitter",
|
|
19577
19782
|
"face-gallery",
|
|
19578
19783
|
"failure-contribution",
|
|
@@ -19703,6 +19908,7 @@ var CAP_NAMES = Object.freeze([
|
|
|
19703
19908
|
"viewer-ui",
|
|
19704
19909
|
"water-heater",
|
|
19705
19910
|
"weather",
|
|
19911
|
+
"weather-station",
|
|
19706
19912
|
"webrtc-session",
|
|
19707
19913
|
"zone-analytics",
|
|
19708
19914
|
"zone-rules",
|
|
@@ -20462,6 +20668,29 @@ Object.freeze({
|
|
|
20462
20668
|
"path": "timestamp",
|
|
20463
20669
|
"valueType": "boolean"
|
|
20464
20670
|
}],
|
|
20671
|
+
"error": [
|
|
20672
|
+
{
|
|
20673
|
+
"path": "active",
|
|
20674
|
+
"valueType": "boolean"
|
|
20675
|
+
},
|
|
20676
|
+
{
|
|
20677
|
+
"path": "code",
|
|
20678
|
+
"valueType": "string"
|
|
20679
|
+
},
|
|
20680
|
+
{
|
|
20681
|
+
"path": "label",
|
|
20682
|
+
"valueType": "string"
|
|
20683
|
+
},
|
|
20684
|
+
{
|
|
20685
|
+
"path": "severity",
|
|
20686
|
+
"valueType": "enum",
|
|
20687
|
+
"enumValues": ["warning", "error"]
|
|
20688
|
+
},
|
|
20689
|
+
{
|
|
20690
|
+
"path": "since",
|
|
20691
|
+
"valueType": "number"
|
|
20692
|
+
}
|
|
20693
|
+
],
|
|
20465
20694
|
"event-emitter": [
|
|
20466
20695
|
{
|
|
20467
20696
|
"path": "lastEvent.deviceId",
|
|
@@ -21681,6 +21910,56 @@ Object.freeze({
|
|
|
21681
21910
|
"valueType": "number"
|
|
21682
21911
|
}
|
|
21683
21912
|
],
|
|
21913
|
+
"weather-station": [
|
|
21914
|
+
{
|
|
21915
|
+
"path": "temperature",
|
|
21916
|
+
"valueType": "number"
|
|
21917
|
+
},
|
|
21918
|
+
{
|
|
21919
|
+
"path": "humidity",
|
|
21920
|
+
"valueType": "number"
|
|
21921
|
+
},
|
|
21922
|
+
{
|
|
21923
|
+
"path": "pressure",
|
|
21924
|
+
"valueType": "number"
|
|
21925
|
+
},
|
|
21926
|
+
{
|
|
21927
|
+
"path": "windSpeed",
|
|
21928
|
+
"valueType": "number"
|
|
21929
|
+
},
|
|
21930
|
+
{
|
|
21931
|
+
"path": "windGust",
|
|
21932
|
+
"valueType": "number"
|
|
21933
|
+
},
|
|
21934
|
+
{
|
|
21935
|
+
"path": "windBearing",
|
|
21936
|
+
"valueType": "number"
|
|
21937
|
+
},
|
|
21938
|
+
{
|
|
21939
|
+
"path": "rainRate",
|
|
21940
|
+
"valueType": "number"
|
|
21941
|
+
},
|
|
21942
|
+
{
|
|
21943
|
+
"path": "rainDaily",
|
|
21944
|
+
"valueType": "number"
|
|
21945
|
+
},
|
|
21946
|
+
{
|
|
21947
|
+
"path": "rainEvent",
|
|
21948
|
+
"valueType": "number"
|
|
21949
|
+
},
|
|
21950
|
+
{
|
|
21951
|
+
"path": "uv",
|
|
21952
|
+
"valueType": "number"
|
|
21953
|
+
},
|
|
21954
|
+
{
|
|
21955
|
+
"path": "solarRadiation",
|
|
21956
|
+
"valueType": "number"
|
|
21957
|
+
},
|
|
21958
|
+
{
|
|
21959
|
+
"path": "dewPoint",
|
|
21960
|
+
"valueType": "number"
|
|
21961
|
+
}
|
|
21962
|
+
],
|
|
21684
21963
|
"zone-analytics": [
|
|
21685
21964
|
{
|
|
21686
21965
|
"path": "ts",
|
|
@@ -21773,7 +22052,7 @@ Object.freeze({
|
|
|
21773
22052
|
}
|
|
21774
22053
|
});
|
|
21775
22054
|
//#endregion
|
|
21776
|
-
//#region ../types/dist/implemented-methods-
|
|
22055
|
+
//#region ../types/dist/implemented-methods-C5FMXLGP.mjs
|
|
21777
22056
|
/**
|
|
21778
22057
|
* The ffmpeg build every CamStack node downloads, per platform and arch.
|
|
21779
22058
|
*
|
|
@@ -57766,7 +58045,7 @@ var mediaPlayerCapability = {
|
|
|
57766
58045
|
]
|
|
57767
58046
|
}
|
|
57768
58047
|
};
|
|
57769
|
-
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Climate, DeviceType.EventEmitter, DeviceType.Climate, DeviceType.Climate, DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Camera, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Lock, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Gateway, DeviceType.Camera, DeviceType.Sensor, DeviceType.MediaPlayer, DeviceType.Vacuum, DeviceType.Generic, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.PetFountain, DeviceType.Fan, DeviceType.Humidifier, DeviceType.Climate, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.PetFeeder, DeviceType.MediaPlayer;
|
|
58048
|
+
DeviceType.Camera, DeviceType.Sensor, DeviceType.Button, DeviceType.Switch, DeviceType.PetFeeder, DeviceType.Container, DeviceType.Climate, DeviceType.EventEmitter, DeviceType.Climate, DeviceType.Climate, DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Camera, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Fan, DeviceType.Lock, DeviceType.Camera, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Switch, DeviceType.Light, DeviceType.Fan, DeviceType.Climate, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.PetFeeder, DeviceType.Gateway, DeviceType.Camera, DeviceType.Sensor, DeviceType.MediaPlayer, DeviceType.Vacuum, DeviceType.Generic, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.PetFountain, DeviceType.Fan, DeviceType.Humidifier, DeviceType.Climate, DeviceType.WaterHeater, DeviceType.MediaPlayer, DeviceType.Washer, DeviceType.Dryer, DeviceType.Dishwasher, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.MediaPlayer, DeviceType.WaterHeater, DeviceType.Humidifier, DeviceType.Fan, DeviceType.Climate, DeviceType.PetFeeder, DeviceType.MediaPlayer;
|
|
57770
58049
|
var NUMBER = {
|
|
57771
58050
|
kind: "fixed",
|
|
57772
58051
|
result: ["number"]
|
|
@@ -57831,7 +58110,7 @@ var CHANGED = {
|
|
|
57831
58110
|
fieldPath: "lastChangedAt",
|
|
57832
58111
|
expr: "now"
|
|
57833
58112
|
};
|
|
57834
|
-
function numeric(input) {
|
|
58113
|
+
function numeric$1(input) {
|
|
57835
58114
|
const { alsoFrom, ...base } = input;
|
|
57836
58115
|
return {
|
|
57837
58116
|
...base,
|
|
@@ -57866,7 +58145,7 @@ function binary(input) {
|
|
|
57866
58145
|
};
|
|
57867
58146
|
}
|
|
57868
58147
|
var GROUP_TEMPLATES = [
|
|
57869
|
-
numeric({
|
|
58148
|
+
numeric$1({
|
|
57870
58149
|
id: "temperature",
|
|
57871
58150
|
summary: "Mean, median, min, max or sum of temperatures. Offline and unknown members are left out, never read as 0 °C.",
|
|
57872
58151
|
role: DeviceRole.TemperatureSensor,
|
|
@@ -57884,7 +58163,7 @@ var GROUP_TEMPLATES = [
|
|
|
57884
58163
|
}
|
|
57885
58164
|
}
|
|
57886
58165
|
}),
|
|
57887
|
-
numeric({
|
|
58166
|
+
numeric$1({
|
|
57888
58167
|
id: "humidity",
|
|
57889
58168
|
summary: "Humidity in percent. Offline and unknown members are left out, never read as 0 %.",
|
|
57890
58169
|
role: DeviceRole.HumiditySensor,
|
|
@@ -57902,7 +58181,7 @@ var GROUP_TEMPLATES = [
|
|
|
57902
58181
|
}
|
|
57903
58182
|
}
|
|
57904
58183
|
}),
|
|
57905
|
-
numeric({
|
|
58184
|
+
numeric$1({
|
|
57906
58185
|
id: "pressure",
|
|
57907
58186
|
summary: "Pressure in hectopascals. Offline and unknown members are left out, never read as 0 hPa.",
|
|
57908
58187
|
role: DeviceRole.PressureSensor,
|
|
@@ -57913,7 +58192,7 @@ var GROUP_TEMPLATES = [
|
|
|
57913
58192
|
empty: "null",
|
|
57914
58193
|
companions: [NOW$3]
|
|
57915
58194
|
}),
|
|
57916
|
-
numeric({
|
|
58195
|
+
numeric$1({
|
|
57917
58196
|
id: "illuminance",
|
|
57918
58197
|
summary: "Illuminance in lux. Offline and unknown members are left out, never read as 0 lx.",
|
|
57919
58198
|
role: DeviceRole.AmbientLightSensor,
|
|
@@ -57924,7 +58203,7 @@ var GROUP_TEMPLATES = [
|
|
|
57924
58203
|
empty: "null",
|
|
57925
58204
|
companions: [NOW$3]
|
|
57926
58205
|
}),
|
|
57927
|
-
numeric({
|
|
58206
|
+
numeric$1({
|
|
57928
58207
|
id: "power",
|
|
57929
58208
|
summary: "Power in watts, summed by default. Nobody reporting omits the key rather than writing 0 W.",
|
|
57930
58209
|
role: DeviceRole.PowerSensor,
|
|
@@ -57935,7 +58214,7 @@ var GROUP_TEMPLATES = [
|
|
|
57935
58214
|
empty: "omit",
|
|
57936
58215
|
companions: [NOW$3]
|
|
57937
58216
|
}),
|
|
57938
|
-
numeric({
|
|
58217
|
+
numeric$1({
|
|
57939
58218
|
id: "energy",
|
|
57940
58219
|
summary: "Energy in kilowatt-hours, summed by default. Nobody reporting omits the key rather than writing 0 kWh.",
|
|
57941
58220
|
role: DeviceRole.EnergySensor,
|
|
@@ -57946,7 +58225,7 @@ var GROUP_TEMPLATES = [
|
|
|
57946
58225
|
empty: "omit",
|
|
57947
58226
|
companions: [NOW$3]
|
|
57948
58227
|
}),
|
|
57949
|
-
numeric({
|
|
58228
|
+
numeric$1({
|
|
57950
58229
|
id: "battery",
|
|
57951
58230
|
summary: "Battery charge in percent. Offline and unknown members are left out, never read as 0 %.",
|
|
57952
58231
|
role: DeviceRole.BatterySensor,
|
|
@@ -57970,7 +58249,7 @@ var GROUP_TEMPLATES = [
|
|
|
57970
58249
|
}
|
|
57971
58250
|
]
|
|
57972
58251
|
}),
|
|
57973
|
-
numeric({
|
|
58252
|
+
numeric$1({
|
|
57974
58253
|
id: "numeric",
|
|
57975
58254
|
summary: "A numeric reading in the members’ shared quantity. Mixed quantities are refused. Nobody reporting publishes null, not 0.",
|
|
57976
58255
|
role: DeviceRole.NumericSensor,
|
|
@@ -63574,6 +63853,85 @@ var enumSensorCapability = {
|
|
|
63574
63853
|
}]
|
|
63575
63854
|
}
|
|
63576
63855
|
};
|
|
63856
|
+
/** How loudly a fault wants the operator. Both tiers raise the attention event. */
|
|
63857
|
+
var DeviceErrorSeveritySchema = _enum(["warning", "error"]);
|
|
63858
|
+
/** One fault of a device that can raise several at once. */
|
|
63859
|
+
var DeviceFaultSchema = object({
|
|
63860
|
+
/** The device's own code, as the vendor names it. */
|
|
63861
|
+
code: string(),
|
|
63862
|
+
/** Already translated by the provider (it owns the vendor vocabulary). */
|
|
63863
|
+
label: string(),
|
|
63864
|
+
severity: DeviceErrorSeveritySchema
|
|
63865
|
+
});
|
|
63866
|
+
/**
|
|
63867
|
+
* The fault a device reports right now. One slice per device.
|
|
63868
|
+
*
|
|
63869
|
+
* `active` is tri-state: `null` is "the provider has not read it yet" and is
|
|
63870
|
+
* never drawn as "no fault" nor as a fault (D315, D393). The provider filters
|
|
63871
|
+
* what is not a fault (a completion or reminder code) BEFORE it writes `true`.
|
|
63872
|
+
*
|
|
63873
|
+
* The cap's name is the key a template reads (`{{ alias.error.label }}`, D1021).
|
|
63874
|
+
*/
|
|
63875
|
+
var ErrorStatusSchema = object({
|
|
63876
|
+
active: boolean().nullable(),
|
|
63877
|
+
/** The code of the principal fault; `null` when none (or unknown). */
|
|
63878
|
+
code: string().nullable(),
|
|
63879
|
+
/** The principal fault's words, provider-translated; `null` when none. */
|
|
63880
|
+
label: string().nullable(),
|
|
63881
|
+
severity: DeviceErrorSeveritySchema,
|
|
63882
|
+
/** Ms epoch the current fault started; `null` when none or not known. */
|
|
63883
|
+
since: number$1().nullable(),
|
|
63884
|
+
/** Every fault, for a device that raises several. The principal is the first. */
|
|
63885
|
+
faults: array(DeviceFaultSchema).optional(),
|
|
63886
|
+
/** Ms epoch of the last read the provider made of the fault. */
|
|
63887
|
+
lastFetchedAt: number$1()
|
|
63888
|
+
});
|
|
63889
|
+
/** The slice before the provider has read anything: unknown, not "fine". */
|
|
63890
|
+
var ERROR_STATUS_COLD = {
|
|
63891
|
+
active: null,
|
|
63892
|
+
code: null,
|
|
63893
|
+
label: null,
|
|
63894
|
+
severity: "error",
|
|
63895
|
+
since: null,
|
|
63896
|
+
lastFetchedAt: 0
|
|
63897
|
+
};
|
|
63898
|
+
var errorCapability = {
|
|
63899
|
+
name: "error",
|
|
63900
|
+
scope: "device",
|
|
63901
|
+
deviceNative: true,
|
|
63902
|
+
mode: "singleton",
|
|
63903
|
+
methods: {},
|
|
63904
|
+
status: {
|
|
63905
|
+
schema: ErrorStatusSchema,
|
|
63906
|
+
kind: "push",
|
|
63907
|
+
empty: ERROR_STATUS_COLD
|
|
63908
|
+
},
|
|
63909
|
+
runtimeState: ErrorStatusSchema,
|
|
63910
|
+
/**
|
|
63911
|
+
* Runtime-state durability: **restored** — the previous observation is what
|
|
63912
|
+
* lets the first reading after a restart be a COMPARISON: a fault that was
|
|
63913
|
+
* already open must not announce itself a second time.
|
|
63914
|
+
*
|
|
63915
|
+
* See `RuntimeStateDurability`. Enforced by
|
|
63916
|
+
* `scripts/check-runtime-state-durability.ts`.
|
|
63917
|
+
*/
|
|
63918
|
+
durability: "restored",
|
|
63919
|
+
volatileStateFields: ["lastFetchedAt"],
|
|
63920
|
+
/** The fault itself is carried by the attention alerts; no series is recorded. */
|
|
63921
|
+
history: "none",
|
|
63922
|
+
vocabulary: {
|
|
63923
|
+
noun: t("Fault", "Guasto"),
|
|
63924
|
+
order: 5265,
|
|
63925
|
+
state: [{
|
|
63926
|
+
kind: "boolean",
|
|
63927
|
+
field: "active",
|
|
63928
|
+
label: t("Fault", "Guasto"),
|
|
63929
|
+
whenTrue: t("When {device} reports a fault", "Quando {device} segnala un guasto"),
|
|
63930
|
+
whenFalse: t("When the fault of {device} clears", "Quando il guasto di {device} si risolve"),
|
|
63931
|
+
icon: "triangle-alert"
|
|
63932
|
+
}]
|
|
63933
|
+
}
|
|
63934
|
+
};
|
|
63577
63935
|
var IdentitySchema = object({
|
|
63578
63936
|
id: string(),
|
|
63579
63937
|
name: string(),
|
|
@@ -66040,7 +66398,7 @@ var HeroSceneSchema = object({
|
|
|
66040
66398
|
/** 0..1: volume, cover position, cycle progress. */
|
|
66041
66399
|
level: number$1().min(0).max(1).nullable()
|
|
66042
66400
|
});
|
|
66043
|
-
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
66401
|
+
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
66044
66402
|
DeviceRole.Siren, DeviceRole.Floodlight, DeviceRole.Spotlight, DeviceRole.PirSensor, DeviceRole.Chime, DeviceRole.Autotrack, DeviceRole.Nightvision, DeviceRole.PrivacyMask, DeviceRole.Doorbell, DeviceRole.CoverBlind, DeviceRole.CoverShutter, DeviceRole.CoverAwning, DeviceRole.CoverCurtain, DeviceRole.CoverGarage, DeviceRole.CoverGate, DeviceRole.CoverDoor, DeviceRole.CoverWindow, DeviceRole.BinaryHelper, DeviceRole.Outlet, DeviceRole.SwitchHeater, DeviceRole.SwitchFan, DeviceRole.SwitchLight, DeviceRole.ClimateAc, DeviceRole.ClimateThermostat, DeviceRole.ClimateFloor, DeviceRole.ClimateRadiator, DeviceRole.ClimateHeater, DeviceRole.ClimateHeatPumpCircuit, DeviceRole.MotionSensor, DeviceRole.ContactSensor, DeviceRole.LeakSensor, DeviceRole.SmokeSensor, DeviceRole.COSensor, DeviceRole.GasSensor, DeviceRole.TamperSensor, DeviceRole.VibrationSensor, DeviceRole.ConnectivitySensor, DeviceRole.SoundSensor, DeviceRole.BinarySensor, DeviceRole.TemperatureSensor, DeviceRole.HumiditySensor, DeviceRole.AmbientLightSensor, DeviceRole.PressureSensor, DeviceRole.WindSensor, DeviceRole.RainSensor, DeviceRole.UvSensor, DeviceRole.SolarRadiationSensor, DeviceRole.SoilMoistureSensor, DeviceRole.PowerSensor, DeviceRole.EnergySensor, DeviceRole.VoltageSensor, DeviceRole.CurrentSensor, DeviceRole.AirQualitySensor, DeviceRole.BatterySensor, DeviceRole.NumericSensor, DeviceRole.EnumSensor, DeviceRole.DateTimeSensor, DeviceRole.GenericSensor, DeviceRole.NumericControl, DeviceRole.SelectControl, DeviceRole.TextControl, DeviceRole.DateTimeControl, DeviceRole.MobilePushNotifier, DeviceRole.MessagingNotifier, DeviceRole.EmailNotifier, DeviceRole.GenericNotifier, DeviceRole.IrTransmitter;
|
|
66045
66403
|
var HeroRowIdSchema = _enum([
|
|
66046
66404
|
"progress",
|
|
@@ -90524,6 +90882,17 @@ var TerminalOutputEventSchema = discriminatedUnion("kind", [object({
|
|
|
90524
90882
|
exitCode: number$1().int(),
|
|
90525
90883
|
signal: number$1().int().optional()
|
|
90526
90884
|
})]);
|
|
90885
|
+
var ServerShellRefusalSchema = object({
|
|
90886
|
+
code: literal("server-shell-disabled"),
|
|
90887
|
+
nodeId: string(),
|
|
90888
|
+
message: string()
|
|
90889
|
+
});
|
|
90890
|
+
var ServerShellStatusSchema = object({
|
|
90891
|
+
nodeId: string(),
|
|
90892
|
+
enabled: boolean(),
|
|
90893
|
+
idleMinutes: number$1().int().positive(),
|
|
90894
|
+
refusal: ServerShellRefusalSchema.nullable()
|
|
90895
|
+
});
|
|
90527
90896
|
var TerminalOutputBatchSchema = object({
|
|
90528
90897
|
cursor: number$1().int().nonnegative(),
|
|
90529
90898
|
reset: boolean(),
|
|
@@ -90536,7 +90905,7 @@ method(_void(), array(TerminalProfileInfoSchema).readonly(), { auth: "admin" }),
|
|
|
90536
90905
|
}), TerminalInstanceInfoSchema, {
|
|
90537
90906
|
kind: "mutation",
|
|
90538
90907
|
auth: "admin"
|
|
90539
|
-
}), method(_void(), array(TerminalSessionInfoSchema).readonly(), { auth: "admin" }), method(object({
|
|
90908
|
+
}), method(_void(), array(TerminalSessionInfoSchema).readonly(), { auth: "admin" }), method(_void(), ServerShellStatusSchema, { auth: "admin" }), method(object({
|
|
90540
90909
|
profileId: string(),
|
|
90541
90910
|
cols: number$1().int().positive(),
|
|
90542
90911
|
rows: number$1().int().positive(),
|
|
@@ -90546,7 +90915,8 @@ method(_void(), array(TerminalProfileInfoSchema).readonly(), { auth: "admin" }),
|
|
|
90546
90915
|
environment: array(string().max(4096)).max(64).optional()
|
|
90547
90916
|
}), TerminalSessionInfoSchema, {
|
|
90548
90917
|
kind: "mutation",
|
|
90549
|
-
auth: "admin"
|
|
90918
|
+
auth: "admin",
|
|
90919
|
+
caller: "required"
|
|
90550
90920
|
}), method(object({
|
|
90551
90921
|
sessionId: string(),
|
|
90552
90922
|
cols: number$1().int().positive(),
|
|
@@ -90567,6 +90937,7 @@ method(_void(), array(TerminalProfileInfoSchema).readonly(), { auth: "admin" }),
|
|
|
90567
90937
|
}), TerminalOutputBatchSchema, {
|
|
90568
90938
|
kind: "mutation",
|
|
90569
90939
|
auth: "admin",
|
|
90940
|
+
caller: "required",
|
|
90570
90941
|
timeoutMs: 15e3
|
|
90571
90942
|
}), method(object({
|
|
90572
90943
|
sessionId: string(),
|
|
@@ -90576,7 +90947,8 @@ method(_void(), array(TerminalProfileInfoSchema).readonly(), { auth: "admin" }),
|
|
|
90576
90947
|
auth: "admin"
|
|
90577
90948
|
}), method(object({ sessionId: string() }), _void(), {
|
|
90578
90949
|
kind: "mutation",
|
|
90579
|
-
auth: "admin"
|
|
90950
|
+
auth: "admin",
|
|
90951
|
+
caller: "required"
|
|
90580
90952
|
}), NOT_A_DEVICE.CLUSTER;
|
|
90581
90953
|
/**
|
|
90582
90954
|
* toast — system-scoped singleton capability that streams toast
|
|
@@ -92530,6 +92902,71 @@ var weatherCapability = {
|
|
|
92530
92902
|
]
|
|
92531
92903
|
}
|
|
92532
92904
|
};
|
|
92905
|
+
var WeatherStationStatusSchema = object({
|
|
92906
|
+
temperature: number$1().nullable().meta(readingMeta("temperature", { precision: 1 })),
|
|
92907
|
+
humidity: number$1().min(0).max(100).nullable().meta(readingMeta("humidity")),
|
|
92908
|
+
pressure: number$1().nullable().meta(readingMeta("pressure")),
|
|
92909
|
+
windSpeed: number$1().nullable().meta(readingMeta("speed")),
|
|
92910
|
+
windGust: number$1().nullable().meta(readingMeta("speed")),
|
|
92911
|
+
windBearing: number$1().nullable().meta(readingMeta("angle")),
|
|
92912
|
+
rainRate: number$1().nullable().meta(readingMeta("precipitation-rate", { precision: 1 })),
|
|
92913
|
+
rainDaily: number$1().nullable().meta(readingMeta("precipitation", { precision: 1 })),
|
|
92914
|
+
rainEvent: number$1().nullable().meta(readingMeta("precipitation", { precision: 1 })),
|
|
92915
|
+
uv: number$1().nullable().meta(readingMeta("index", { precision: 1 })),
|
|
92916
|
+
solarRadiation: number$1().nullable().meta(readingMeta("irradiance")),
|
|
92917
|
+
dewPoint: number$1().nullable().meta(readingMeta("temperature", { precision: 1 }))
|
|
92918
|
+
}).extend({
|
|
92919
|
+
/** Ms epoch of the poll that produced this slice. 0 before the first one. */
|
|
92920
|
+
lastFetchedAt: number$1() });
|
|
92921
|
+
var numeric = (field, quantity, label, unit, icon) => ({
|
|
92922
|
+
kind: "numeric",
|
|
92923
|
+
field,
|
|
92924
|
+
quantity,
|
|
92925
|
+
label,
|
|
92926
|
+
unit,
|
|
92927
|
+
icon
|
|
92928
|
+
});
|
|
92929
|
+
var weatherStationCapability = {
|
|
92930
|
+
name: "weather-station",
|
|
92931
|
+
scope: "device",
|
|
92932
|
+
deviceNative: true,
|
|
92933
|
+
mode: "singleton",
|
|
92934
|
+
deviceTypes: [DeviceType.WeatherStation],
|
|
92935
|
+
methods: {},
|
|
92936
|
+
status: {
|
|
92937
|
+
schema: WeatherStationStatusSchema,
|
|
92938
|
+
kind: "push"
|
|
92939
|
+
},
|
|
92940
|
+
runtimeState: WeatherStationStatusSchema,
|
|
92941
|
+
/**
|
|
92942
|
+
* The sensor children already record each reading. The station slice is the
|
|
92943
|
+
* live aggregate a template reads; it does not keep a second series.
|
|
92944
|
+
*/
|
|
92945
|
+
history: "none",
|
|
92946
|
+
/**
|
|
92947
|
+
* Runtime-state durability: **session** — a station reading is stale the
|
|
92948
|
+
* moment the hub is down; the provider re-reads on the next poll.
|
|
92949
|
+
*/
|
|
92950
|
+
durability: "session",
|
|
92951
|
+
vocabulary: {
|
|
92952
|
+
noun: t("Weather station", "Stazione meteo"),
|
|
92953
|
+
order: 5235,
|
|
92954
|
+
state: [
|
|
92955
|
+
numeric("temperature", t("the outdoor temperature", "la temperatura esterna"), t("Temperature", "Temperatura"), "°C", "thermometer"),
|
|
92956
|
+
numeric("humidity", t("the outdoor humidity", "l’umidità esterna"), t("Humidity", "Umidità"), "%", "droplets"),
|
|
92957
|
+
numeric("pressure", t("the air pressure", "la pressione atmosferica"), t("Pressure", "Pressione"), "hPa", "gauge"),
|
|
92958
|
+
numeric("windSpeed", t("the wind speed", "la velocità del vento"), t("Wind", "Vento"), "m/s", "wind"),
|
|
92959
|
+
numeric("windGust", t("the wind gust", "la raffica di vento"), t("Gust", "Raffica"), "m/s", "wind"),
|
|
92960
|
+
numeric("windBearing", t("the wind bearing", "la direzione del vento"), t("Wind bearing", "Direzione del vento"), "°", "wind"),
|
|
92961
|
+
numeric("rainRate", t("the rain rate", "l’intensità della pioggia"), t("Rain rate", "Intensità pioggia"), "mm/h", "droplets"),
|
|
92962
|
+
numeric("rainDaily", t("the rain today", "la pioggia di oggi"), t("Rain today", "Pioggia oggi"), "mm", "droplets"),
|
|
92963
|
+
numeric("rainEvent", t("the rain this event", "la pioggia di questo evento"), t("Rain event", "Evento di pioggia"), "mm", "droplets"),
|
|
92964
|
+
numeric("uv", t("the UV index", "l’indice UV"), t("UV", "UV"), "", "cloud-sun"),
|
|
92965
|
+
numeric("solarRadiation", t("the solar radiation", "la radiazione solare"), t("Solar", "Sole"), "W/m²", "cloud-sun"),
|
|
92966
|
+
numeric("dewPoint", t("the dew point", "il punto di rugiada"), t("Dew point", "Punto di rugiada"), "°C", "thermometer")
|
|
92967
|
+
]
|
|
92968
|
+
}
|
|
92969
|
+
};
|
|
92533
92970
|
/**
|
|
92534
92971
|
* Optional client-side hints sent at session creation to help the provider
|
|
92535
92972
|
* pick the best native source. All fields optional — a viewer that knows
|
|
@@ -94095,6 +94532,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
|
|
|
94095
94532
|
doorbell: doorbellCapability,
|
|
94096
94533
|
energySystem: energySystemCapability,
|
|
94097
94534
|
enumSensor: enumSensorCapability,
|
|
94535
|
+
error: errorCapability,
|
|
94098
94536
|
eventEmitter: eventEmitterCapability,
|
|
94099
94537
|
fanControl: fanControlCapability,
|
|
94100
94538
|
featureProbe: featureProbeCapability,
|
|
@@ -94151,10 +94589,59 @@ var DEVICE_LOCAL_STATE_CAPS = {
|
|
|
94151
94589
|
vibration: vibrationCapability,
|
|
94152
94590
|
waterHeater: waterHeaterCapability,
|
|
94153
94591
|
weather: weatherCapability,
|
|
94592
|
+
weatherStation: weatherStationCapability,
|
|
94154
94593
|
zoneAnalytics: zoneAnalyticsCapability,
|
|
94155
94594
|
zoneRules: zoneRulesCapability,
|
|
94156
94595
|
zones: zonesCapability
|
|
94157
94596
|
};
|
|
94597
|
+
/**
|
|
94598
|
+
* The edge between two readings, or `null` for no edge.
|
|
94599
|
+
*
|
|
94600
|
+
* - `null`/cold → `true` is a START (a fault already open at boot is one);
|
|
94601
|
+
* - `true` → `false` is a RESOLVE;
|
|
94602
|
+
* - an UNKNOWN reading (`active: null`) is never an edge, in either direction —
|
|
94603
|
+
* a failed read must neither raise nor close an episode (D393, D49);
|
|
94604
|
+
* - `true` → `true` is the same episode, whatever the code did.
|
|
94605
|
+
*/
|
|
94606
|
+
function deviceErrorEdge(previous, next) {
|
|
94607
|
+
if (next.active === true && previous?.active !== true) return "start";
|
|
94608
|
+
if (next.active === false && previous?.active === true) return "resolve";
|
|
94609
|
+
return null;
|
|
94610
|
+
}
|
|
94611
|
+
function deviceErrorAlertId(deviceId) {
|
|
94612
|
+
return `device-error:${String(deviceId)}`;
|
|
94613
|
+
}
|
|
94614
|
+
/** The alert that opens an episode. `since` is the fault's own start, else `now`. */
|
|
94615
|
+
function buildDeviceErrorAlert(deviceId, deviceName, status, now) {
|
|
94616
|
+
const label = status.label ?? status.code ?? "Fault";
|
|
94617
|
+
const startedAt = status.since ?? now;
|
|
94618
|
+
const alertId = deviceErrorAlertId(deviceId);
|
|
94619
|
+
return {
|
|
94620
|
+
id: alertId,
|
|
94621
|
+
category: "device.error",
|
|
94622
|
+
severity: "critical",
|
|
94623
|
+
title: `${deviceName}: ${label}`,
|
|
94624
|
+
message: `${deviceName} reports a fault: ${label}.`,
|
|
94625
|
+
action: {
|
|
94626
|
+
label: "Open device",
|
|
94627
|
+
href: `/devices/${String(deviceId)}`,
|
|
94628
|
+
navigation: "app"
|
|
94629
|
+
},
|
|
94630
|
+
status: "active",
|
|
94631
|
+
read: false,
|
|
94632
|
+
createdAt: now,
|
|
94633
|
+
updatedAt: now,
|
|
94634
|
+
source: {
|
|
94635
|
+
type: "device",
|
|
94636
|
+
id: String(deviceId)
|
|
94637
|
+
},
|
|
94638
|
+
metadata: {
|
|
94639
|
+
episodeId: `${alertId}@${String(startedAt)}`,
|
|
94640
|
+
code: status.code,
|
|
94641
|
+
deviceSeverity: status.severity
|
|
94642
|
+
}
|
|
94643
|
+
};
|
|
94644
|
+
}
|
|
94158
94645
|
var BaseDevice = class {
|
|
94159
94646
|
id;
|
|
94160
94647
|
stableId;
|
|
@@ -94454,6 +94941,68 @@ var BaseDevice = class {
|
|
|
94454
94941
|
} catch (err) {}
|
|
94455
94942
|
}
|
|
94456
94943
|
/**
|
|
94944
|
+
* Declare that this device can report a fault (the `error` cap). The slice
|
|
94945
|
+
* starts UNKNOWN — a restored slice is kept, so a fault that was open before
|
|
94946
|
+
* a restart is compared, not announced again.
|
|
94947
|
+
*/
|
|
94948
|
+
registerErrorCap() {
|
|
94949
|
+
this.ctx.registerNativeCap?.(errorCapability, {});
|
|
94950
|
+
if (this.runtimeState.getCapState(errorCapability.name) === void 0) this.setCapSlice(errorCapability, ERROR_STATUS_COLD);
|
|
94951
|
+
}
|
|
94952
|
+
/**
|
|
94953
|
+
* Publish the device's fault. The slice is written; on an EDGE (a fault
|
|
94954
|
+
* starts, or one resolves) an attention episode opens or closes through the
|
|
94955
|
+
* alerts cap, which the notification center announces as
|
|
94956
|
+
* `device-attention-required` / `-resolved`. An unknown reading is never an
|
|
94957
|
+
* edge. No rule exists by default: it notifies when the operator makes one.
|
|
94958
|
+
*/
|
|
94959
|
+
async publishError(reading) {
|
|
94960
|
+
const previous = this.getCapSlice(errorCapability);
|
|
94961
|
+
if (reading.active === null && previous !== null && previous.active !== null) return;
|
|
94962
|
+
const now = Date.now();
|
|
94963
|
+
const edge = deviceErrorEdge(previous, reading);
|
|
94964
|
+
const next = edge === "start" && reading.since === null ? {
|
|
94965
|
+
...reading,
|
|
94966
|
+
since: now
|
|
94967
|
+
} : reading;
|
|
94968
|
+
this.setCapSlice(errorCapability, next);
|
|
94969
|
+
if (edge === null) return;
|
|
94970
|
+
const alerts = this.ctx.api.alerts;
|
|
94971
|
+
if (alerts === void 0) {
|
|
94972
|
+
this.ctx.logger.warn("device error: attention event skipped — alerts capability missing", {
|
|
94973
|
+
tags: { deviceId: this.id },
|
|
94974
|
+
meta: { edge }
|
|
94975
|
+
});
|
|
94976
|
+
return;
|
|
94977
|
+
}
|
|
94978
|
+
try {
|
|
94979
|
+
if (edge === "start") await alerts.emit.mutate(buildDeviceErrorAlert(this.id, this.name, next, now));
|
|
94980
|
+
else await alerts.update.mutate({
|
|
94981
|
+
alertId: deviceErrorAlertId(this.id),
|
|
94982
|
+
patch: {
|
|
94983
|
+
status: "completed",
|
|
94984
|
+
read: true,
|
|
94985
|
+
updatedAt: now
|
|
94986
|
+
}
|
|
94987
|
+
});
|
|
94988
|
+
this.ctx.logger.info(`device error: ${edge === "start" ? "raised" : "resolved"}`, {
|
|
94989
|
+
tags: { deviceId: this.id },
|
|
94990
|
+
meta: {
|
|
94991
|
+
code: next.code,
|
|
94992
|
+
label: next.label
|
|
94993
|
+
}
|
|
94994
|
+
});
|
|
94995
|
+
} catch (err) {
|
|
94996
|
+
this.ctx.logger.warn("device error: attention event failed", {
|
|
94997
|
+
tags: { deviceId: this.id },
|
|
94998
|
+
meta: {
|
|
94999
|
+
edge,
|
|
95000
|
+
error: errMsg(err)
|
|
95001
|
+
}
|
|
95002
|
+
});
|
|
95003
|
+
}
|
|
95004
|
+
}
|
|
95005
|
+
/**
|
|
94457
95006
|
* Typed read-through to a cap-keyed runtime-state slice. Drivers
|
|
94458
95007
|
* call `this.getCapSlice(batteryCapability)` and the return type
|
|
94459
95008
|
* is inferred from the cap's `runtimeState` Zod schema — no string
|
|
@@ -95401,7 +95950,7 @@ var BaseDeviceProvider = class extends BaseAddon {
|
|
|
95401
95950
|
}
|
|
95402
95951
|
};
|
|
95403
95952
|
DeviceType.HeatPump;
|
|
95404
|
-
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Camera, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
95953
|
+
DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Camera, DeviceType.Switch, DeviceType.Siren, DeviceType.Light, DeviceType.Fan, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
95405
95954
|
new Set(Object.values(DeviceType));
|
|
95406
95955
|
/** Parses the raw slice with the cap's own schema; `undefined` when it does not parse. */
|
|
95407
95956
|
function contribution(cap, schema, build) {
|
|
@@ -96770,6 +97319,17 @@ var SENSORS_FAMILY_CONTRIBUTIONS = {
|
|
|
96770
97319
|
doorbell: doorbellContribution,
|
|
96771
97320
|
meter: meterContribution,
|
|
96772
97321
|
weather: weatherContribution,
|
|
97322
|
+
"weather-station": contribution("weather-station", WeatherStationStatusSchema, (slice) => {
|
|
97323
|
+
if (slice === void 0 || slice.temperature === null) return { reading: reading$1("weather", "unknown") };
|
|
97324
|
+
const celsius = `${number(slice.temperature)}°C`;
|
|
97325
|
+
const facts = [fact("reading", "thermometer", t(celsius, celsius), "primary")];
|
|
97326
|
+
if (slice.humidity !== null) facts.push(fact("reading", "droplets", t(`${Math.round(slice.humidity)}%`, `${Math.round(slice.humidity)}%`)));
|
|
97327
|
+
if (slice.windSpeed !== null) facts.push(fact("reading", "wind", t(`${number(slice.windSpeed)} m/s`, `${number(slice.windSpeed)} m/s`)));
|
|
97328
|
+
return {
|
|
97329
|
+
reading: reading$1("weather", "on", false, t(celsius, celsius)),
|
|
97330
|
+
facts
|
|
97331
|
+
};
|
|
97332
|
+
}),
|
|
96773
97333
|
update: updateContribution,
|
|
96774
97334
|
image: imageContribution,
|
|
96775
97335
|
button: buttonContribution,
|
|
@@ -97446,7 +98006,7 @@ var HEAT_PUMP_FAMILY_CONTRIBUTIONS = { "heat-pump-status": contribution("heat-pu
|
|
|
97446
98006
|
...Object.values(CLIMATE_FAMILY_CONTRIBUTIONS),
|
|
97447
98007
|
...Object.values(HEAT_PUMP_FAMILY_CONTRIBUTIONS)
|
|
97448
98008
|
];
|
|
97449
|
-
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
98009
|
+
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
97450
98010
|
/**
|
|
97451
98011
|
* Who looks like what (D1023). One look per {@link DeviceType}, refined by a
|
|
97452
98012
|
* {@link DeviceRole} where the role changes how the device reads (a leak
|
|
@@ -98090,7 +98650,7 @@ lookOf({
|
|
|
98090
98650
|
standby: MUTED
|
|
98091
98651
|
});
|
|
98092
98652
|
DeviceType.Climate;
|
|
98093
|
-
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
98653
|
+
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
98094
98654
|
DeviceRole.Siren, DeviceRole.Floodlight, DeviceRole.Spotlight, DeviceRole.PirSensor, DeviceRole.Chime, DeviceRole.Autotrack, DeviceRole.Nightvision, DeviceRole.PrivacyMask, DeviceRole.Doorbell, DeviceRole.CoverBlind, DeviceRole.CoverShutter, DeviceRole.CoverAwning, DeviceRole.CoverCurtain, DeviceRole.CoverGarage, DeviceRole.CoverGate, DeviceRole.CoverDoor, DeviceRole.CoverWindow, DeviceRole.BinaryHelper, DeviceRole.Outlet, DeviceRole.SwitchHeater, DeviceRole.SwitchFan, DeviceRole.SwitchLight, DeviceRole.ClimateAc, DeviceRole.ClimateThermostat, DeviceRole.ClimateFloor, DeviceRole.ClimateRadiator, DeviceRole.ClimateHeater, DeviceRole.ClimateHeatPumpCircuit, DeviceRole.MotionSensor, DeviceRole.ContactSensor, DeviceRole.LeakSensor, DeviceRole.SmokeSensor, DeviceRole.COSensor, DeviceRole.GasSensor, DeviceRole.TamperSensor, DeviceRole.VibrationSensor, DeviceRole.ConnectivitySensor, DeviceRole.SoundSensor, DeviceRole.BinarySensor, DeviceRole.TemperatureSensor, DeviceRole.HumiditySensor, DeviceRole.AmbientLightSensor, DeviceRole.PressureSensor, DeviceRole.WindSensor, DeviceRole.RainSensor, DeviceRole.UvSensor, DeviceRole.SolarRadiationSensor, DeviceRole.SoilMoistureSensor, DeviceRole.PowerSensor, DeviceRole.EnergySensor, DeviceRole.VoltageSensor, DeviceRole.CurrentSensor, DeviceRole.AirQualitySensor, DeviceRole.BatterySensor, DeviceRole.NumericSensor, DeviceRole.EnumSensor, DeviceRole.DateTimeSensor, DeviceRole.GenericSensor, DeviceRole.NumericControl, DeviceRole.SelectControl, DeviceRole.TextControl, DeviceRole.DateTimeControl, DeviceRole.MobilePushNotifier, DeviceRole.MessagingNotifier, DeviceRole.EmailNotifier, DeviceRole.GenericNotifier, DeviceRole.IrTransmitter;
|
|
98095
98655
|
Object.freeze({
|
|
98096
98656
|
"accessories.getStatus": {
|
|
@@ -101383,6 +101943,13 @@ Object.freeze({
|
|
|
101383
101943
|
access: "view",
|
|
101384
101944
|
role: "viewer"
|
|
101385
101945
|
},
|
|
101946
|
+
"error.getStatus": {
|
|
101947
|
+
capName: "error",
|
|
101948
|
+
capScope: "device",
|
|
101949
|
+
addonId: null,
|
|
101950
|
+
access: "view",
|
|
101951
|
+
role: "viewer"
|
|
101952
|
+
},
|
|
101386
101953
|
"eventEmitter.getStatus": {
|
|
101387
101954
|
capName: "event-emitter",
|
|
101388
101955
|
capScope: "device",
|
|
@@ -107641,6 +108208,13 @@ Object.freeze({
|
|
|
107641
108208
|
access: "create",
|
|
107642
108209
|
role: "admin"
|
|
107643
108210
|
},
|
|
108211
|
+
"terminalSession.serverShellStatus": {
|
|
108212
|
+
capName: "terminal-session",
|
|
108213
|
+
capScope: "system",
|
|
108214
|
+
addonId: null,
|
|
108215
|
+
access: "view",
|
|
108216
|
+
role: "admin"
|
|
108217
|
+
},
|
|
107644
108218
|
"terminalSession.writeInput": {
|
|
107645
108219
|
capName: "terminal-session",
|
|
107646
108220
|
capScope: "system",
|
|
@@ -108376,6 +108950,13 @@ Object.freeze({
|
|
|
108376
108950
|
access: "view",
|
|
108377
108951
|
role: "viewer"
|
|
108378
108952
|
},
|
|
108953
|
+
"weatherStation.getStatus": {
|
|
108954
|
+
capName: "weather-station",
|
|
108955
|
+
capScope: "device",
|
|
108956
|
+
addonId: null,
|
|
108957
|
+
access: "view",
|
|
108958
|
+
role: "viewer"
|
|
108959
|
+
},
|
|
108379
108960
|
"webrtcSession.addIceCandidate": {
|
|
108380
108961
|
capName: "webrtc-session",
|
|
108381
108962
|
capScope: "device",
|
|
@@ -108589,7 +109170,7 @@ function offered(received) {
|
|
|
108589
109170
|
};
|
|
108590
109171
|
}
|
|
108591
109172
|
offered(HA_AS), withheld(HOMEKIT_REASON), withheld(ALEXA_REASON), withheld(GOOGLE_REASON), withheld(MATTER_REASON);
|
|
108592
|
-
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
109173
|
+
DeviceType.Camera, DeviceType.Light, DeviceType.Siren, DeviceType.Switch, DeviceType.Sensor, DeviceType.Climate, DeviceType.HeatPump, DeviceType.EnergySystem, DeviceType.Button, DeviceType.EventEmitter, DeviceType.Update, DeviceType.Generic, DeviceType.Notifier, DeviceType.Script, DeviceType.Automation, DeviceType.Lock, DeviceType.Cover, DeviceType.Valve, DeviceType.Humidifier, DeviceType.WaterHeater, DeviceType.Fan, DeviceType.MediaPlayer, DeviceType.AlarmPanel, DeviceType.Control, DeviceType.Presence, DeviceType.Weather, DeviceType.WeatherStation, DeviceType.Vacuum, DeviceType.LawnMower, DeviceType.Container, DeviceType.Image, DeviceType.PetFeeder, DeviceType.PetFountain, DeviceType.Dishwasher, DeviceType.Washer, DeviceType.Dryer, DeviceType.Gateway;
|
|
108593
109174
|
DeviceRole.Siren, DeviceRole.Floodlight, DeviceRole.Spotlight, DeviceRole.PirSensor, DeviceRole.Chime, DeviceRole.Autotrack, DeviceRole.Nightvision, DeviceRole.PrivacyMask, DeviceRole.Doorbell, DeviceRole.CoverBlind, DeviceRole.CoverShutter, DeviceRole.CoverAwning, DeviceRole.CoverCurtain, DeviceRole.CoverGarage, DeviceRole.CoverGate, DeviceRole.CoverDoor, DeviceRole.CoverWindow, DeviceRole.BinaryHelper, DeviceRole.Outlet, DeviceRole.SwitchHeater, DeviceRole.SwitchFan, DeviceRole.SwitchLight, DeviceRole.ClimateAc, DeviceRole.ClimateThermostat, DeviceRole.ClimateFloor, DeviceRole.ClimateRadiator, DeviceRole.ClimateHeater, DeviceRole.ClimateHeatPumpCircuit, DeviceRole.MotionSensor, DeviceRole.ContactSensor, DeviceRole.LeakSensor, DeviceRole.SmokeSensor, DeviceRole.COSensor, DeviceRole.GasSensor, DeviceRole.TamperSensor, DeviceRole.VibrationSensor, DeviceRole.ConnectivitySensor, DeviceRole.SoundSensor, DeviceRole.BinarySensor, DeviceRole.TemperatureSensor, DeviceRole.HumiditySensor, DeviceRole.AmbientLightSensor, DeviceRole.PressureSensor, DeviceRole.WindSensor, DeviceRole.RainSensor, DeviceRole.UvSensor, DeviceRole.SolarRadiationSensor, DeviceRole.SoilMoistureSensor, DeviceRole.PowerSensor, DeviceRole.EnergySensor, DeviceRole.VoltageSensor, DeviceRole.CurrentSensor, DeviceRole.AirQualitySensor, DeviceRole.BatterySensor, DeviceRole.NumericSensor, DeviceRole.EnumSensor, DeviceRole.DateTimeSensor, DeviceRole.GenericSensor, DeviceRole.NumericControl, DeviceRole.SelectControl, DeviceRole.TextControl, DeviceRole.DateTimeControl, DeviceRole.MobilePushNotifier, DeviceRole.MessagingNotifier, DeviceRole.EmailNotifier, DeviceRole.GenericNotifier, DeviceRole.IrTransmitter;
|
|
108594
109175
|
new Set(Object.values(DeviceType));
|
|
108595
109176
|
new Set(Object.values(DeviceRole));
|
|
@@ -109720,6 +110301,11 @@ Object.freeze({
|
|
|
109720
110301
|
form: "single",
|
|
109721
110302
|
optional: false
|
|
109722
110303
|
}],
|
|
110304
|
+
"error.getStatus": [{
|
|
110305
|
+
name: "deviceId",
|
|
110306
|
+
form: "single",
|
|
110307
|
+
optional: false
|
|
110308
|
+
}],
|
|
109723
110309
|
"eventEmitter.getStatus": [{
|
|
109724
110310
|
name: "deviceId",
|
|
109725
110311
|
form: "single",
|
|
@@ -111761,6 +112347,11 @@ Object.freeze({
|
|
|
111761
112347
|
form: "single",
|
|
111762
112348
|
optional: false
|
|
111763
112349
|
}],
|
|
112350
|
+
"weatherStation.getStatus": [{
|
|
112351
|
+
name: "deviceId",
|
|
112352
|
+
form: "single",
|
|
112353
|
+
optional: false
|
|
112354
|
+
}],
|
|
111764
112355
|
"webrtcSession.addIceCandidate": [{
|
|
111765
112356
|
name: "deviceId",
|
|
111766
112357
|
form: "single",
|
|
@@ -112546,6 +113137,7 @@ var STATE_SUMMARY_VARS = [
|
|
|
112546
113137
|
[...RULE_TEXT],
|
|
112547
113138
|
[...RULE_TEXT],
|
|
112548
113139
|
[...RULE_TEXT],
|
|
113140
|
+
[...RULE_TEXT],
|
|
112549
113141
|
[...RULE_BODY_ONLY],
|
|
112550
113142
|
[...RULE_TEXT],
|
|
112551
113143
|
([...RULE_TEXT], [...DEVICE_EVENTS]),
|
|
@@ -113550,7 +114142,10 @@ object({
|
|
|
113550
114142
|
* duplicating them. Pure: no `BaseDevice` / facade dependency.
|
|
113551
114143
|
*/
|
|
113552
114144
|
/**
|
|
113553
|
-
* Cold-start defaults so reads never miss a slice before the first push.
|
|
114145
|
+
* Cold-start defaults so reads never miss a slice before the first push. They
|
|
114146
|
+
* are READ fallbacks (`getCapState(...) ?? COLD_X`), never written: a placeholder
|
|
114147
|
+
* published at construction overwrote the hydrated slice and diffed against the
|
|
114148
|
+
* CCU replay as phantom device transitions after every boot (planning#561).
|
|
113554
114149
|
* `lastChangedAt: 0` marks each as a PLACEHOLDER — the value is a guess, and
|
|
113555
114150
|
* consumers read it as unknown. A replayed CCU value is stamped
|
|
113556
114151
|
* `HM_SEEDED_CHANGED_AT` instead (`hm-change-stamp.ts`).
|
|
@@ -113574,20 +114169,6 @@ var COLD_MOTION = {
|
|
|
113574
114169
|
lastDetectedAt: null,
|
|
113575
114170
|
autoClearAfterMs: null
|
|
113576
114171
|
};
|
|
113577
|
-
/**
|
|
113578
|
-
* The motion seed a constructor writes OVER the slice hydrated from the
|
|
113579
|
-
* persisted runtime state. The level is a placeholder (`false`) until the
|
|
113580
|
-
* CCU says otherwise, but a stored rise is a fact: `lastDetectedAt: null`
|
|
113581
|
-
* means "never detected" (`motion.cap.ts`), and a restart must not turn
|
|
113582
|
-
* "fired an hour ago" into that.
|
|
113583
|
-
*/
|
|
113584
|
-
function coldMotionKeepingRise(stored) {
|
|
113585
|
-
const rise = stored?.lastDetectedAt;
|
|
113586
|
-
return {
|
|
113587
|
-
...COLD_MOTION,
|
|
113588
|
-
lastDetectedAt: typeof rise === "number" && Number.isFinite(rise) && rise > 0 ? rise : null
|
|
113589
|
-
};
|
|
113590
|
-
}
|
|
113591
114172
|
var COLD_CLIMATE = {
|
|
113592
114173
|
mode: "auto",
|
|
113593
114174
|
availableModes: [...[
|
|
@@ -141339,7 +141920,6 @@ var HmActuatorDevice = class HmActuatorDevice extends HmChildDevice {
|
|
|
141339
141920
|
else await facade.switchTurnOff(this.address, channel);
|
|
141340
141921
|
}
|
|
141341
141922
|
});
|
|
141342
|
-
this.runtimeState.setCapState("switch", COLD_SWITCH);
|
|
141343
141923
|
this.registeredCap = "switch";
|
|
141344
141924
|
}
|
|
141345
141925
|
registerCoverCap() {
|
|
@@ -141360,7 +141940,6 @@ var HmActuatorDevice = class HmActuatorDevice extends HmChildDevice {
|
|
|
141360
141940
|
},
|
|
141361
141941
|
setTiltPosition: async () => this.unsupported("cover tilt")
|
|
141362
141942
|
});
|
|
141363
|
-
this.runtimeState.setCapState("cover", COLD_COVER);
|
|
141364
141943
|
this.registeredCap = "cover";
|
|
141365
141944
|
}
|
|
141366
141945
|
registerLockCap() {
|
|
@@ -141377,7 +141956,6 @@ var HmActuatorDevice = class HmActuatorDevice extends HmChildDevice {
|
|
|
141377
141956
|
await this.requireFacade().lockOpen(this.address, channel);
|
|
141378
141957
|
}
|
|
141379
141958
|
});
|
|
141380
|
-
this.runtimeState.setCapState("lock-control", COLD_LOCK);
|
|
141381
141959
|
this.registeredCap = "lock-control";
|
|
141382
141960
|
}
|
|
141383
141961
|
registerClimateCap() {
|
|
@@ -141412,7 +141990,6 @@ var HmActuatorDevice = class HmActuatorDevice extends HmChildDevice {
|
|
|
141412
141990
|
};
|
|
141413
141991
|
this.ctx.registerNativeCap(climateControlCapability, provider);
|
|
141414
141992
|
registerPowerSwitch(this, climateControlCapability, provider);
|
|
141415
|
-
this.runtimeState.setCapState("climate-control", COLD_CLIMATE);
|
|
141416
141993
|
this.registeredCap = "climate-control";
|
|
141417
141994
|
}
|
|
141418
141995
|
/**
|
|
@@ -141546,19 +142123,15 @@ var COLD_AMBIENT_LIGHT = {
|
|
|
141546
142123
|
var COLD_POWER = { lastFetchedAt: 0 };
|
|
141547
142124
|
function registerTemperatureCap(ctx, runtimeState) {
|
|
141548
142125
|
ctx.registerNativeCap(temperatureSensorCapability, { getStatus: async () => runtimeState.getCapState("temperature-sensor") ?? COLD_TEMPERATURE });
|
|
141549
|
-
runtimeState.setCapState("temperature-sensor", COLD_TEMPERATURE);
|
|
141550
142126
|
}
|
|
141551
142127
|
function registerHumidityCap(ctx, runtimeState) {
|
|
141552
142128
|
ctx.registerNativeCap(humiditySensorCapability, { getStatus: async () => runtimeState.getCapState("humidity-sensor") ?? COLD_HUMIDITY });
|
|
141553
|
-
runtimeState.setCapState("humidity-sensor", COLD_HUMIDITY);
|
|
141554
142129
|
}
|
|
141555
142130
|
function registerAmbientLightCap(ctx, runtimeState) {
|
|
141556
142131
|
ctx.registerNativeCap(ambientLightSensorCapability, { getStatus: async () => runtimeState.getCapState("ambient-light-sensor") ?? COLD_AMBIENT_LIGHT });
|
|
141557
|
-
runtimeState.setCapState("ambient-light-sensor", COLD_AMBIENT_LIGHT);
|
|
141558
142132
|
}
|
|
141559
142133
|
function registerPowerMeterCap(ctx, runtimeState) {
|
|
141560
142134
|
ctx.registerNativeCap(powerMeterCapability, { getStatus: async () => runtimeState.getCapState("power-meter") ?? COLD_POWER });
|
|
141561
|
-
runtimeState.setCapState("power-meter", COLD_POWER);
|
|
141562
142135
|
}
|
|
141563
142136
|
//#endregion
|
|
141564
142137
|
//#region src/devices/hm-sensor-device.ts
|
|
@@ -141614,7 +142187,6 @@ var HmSensorDevice = class extends HmChildDevice {
|
|
|
141614
142187
|
getStatus: async () => this.runtimeState.getCapState("motion") ?? COLD_MOTION,
|
|
141615
142188
|
isDetected: async () => (this.runtimeState.getCapState("motion") ?? COLD_MOTION).detected
|
|
141616
142189
|
});
|
|
141617
|
-
this.runtimeState.setCapState("motion", coldMotionKeepingRise(this.runtimeState.getCapState("motion")));
|
|
141618
142190
|
}
|
|
141619
142191
|
handleValueChanged(event, origin) {
|
|
141620
142192
|
const now = event.ts || Date.now();
|
|
@@ -142071,16 +142643,13 @@ var HmDiagnosticDevice = class extends HmChildDevice {
|
|
|
142071
142643
|
switch (this.capName) {
|
|
142072
142644
|
case "binary":
|
|
142073
142645
|
this.ctx.registerNativeCap(binaryCapability, { getStatus: async () => this.runtimeState.getCapState("binary") ?? COLD_BINARY });
|
|
142074
|
-
this.runtimeState.setCapState("binary", COLD_BINARY);
|
|
142075
142646
|
return;
|
|
142076
142647
|
case "temperature-sensor":
|
|
142077
142648
|
this.ctx.registerNativeCap(temperatureSensorCapability, { getStatus: async () => this.runtimeState.getCapState("temperature-sensor") ?? COLD_TEMP });
|
|
142078
|
-
this.runtimeState.setCapState("temperature-sensor", COLD_TEMP);
|
|
142079
142649
|
return;
|
|
142080
142650
|
default: {
|
|
142081
142651
|
const cold = COLD_NUMERIC;
|
|
142082
142652
|
this.ctx.registerNativeCap(numericSensorCapability, { getStatus: async () => this.runtimeState.getCapState("numeric-sensor") ?? cold });
|
|
142083
|
-
this.runtimeState.setCapState("numeric-sensor", cold);
|
|
142084
142653
|
return;
|
|
142085
142654
|
}
|
|
142086
142655
|
}
|