@thecloudseeker/homebridge-skoda 0.3.0 → 0.4.0-beta.1

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 CHANGED
@@ -1,5 +1,21 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.4.0-beta.1
4
+
5
+ - **Fixed:** a vehicle whose config entry became invalid, for example with an empty API key while the key was being replaced, was removed from HomeKit with its rooms, names and automations. If the entry still has a valid VIN, the vehicle now stays in HomeKit and shows "No Response" until the entry is fixed; the log says so.
6
+ - **"Plugged In" sensor** for automations: an optional occupancy sensor that detects a plugged-in charging cable (`features.pluggedIn`). The cable state on the charging outlet (_Outlet In Use_) cannot trigger automations in the Home app.
7
+ - **"Locked" is now a lock**, so the Home app says _locked_ or _unlocked_ instead of _closed_ or _open_. It is read-only: changing it in the Home app fails right away. The contact sensor of 0.3.x is replaced, so automations that used it need to be set up again.
8
+ - The README explains the room summary and _Show as Separate Tiles_ in the Home app.
9
+ - **Renaming a vehicle** in the config now renames it in Homebridge and HomeKit. Before, a vehicle kept the name it had when it was first added. The Home app may keep a name you set there yourself.
10
+ - **Plug Locked** no longer shows _open_ while no cable is plugged in. Without a cable the vehicle reports the plug as unlocked, which would trigger an alert after every unplug.
11
+ - The log line listing what the vehicle supports names a missing S-PIN or home location, instead of the feature switch, for auxiliary heating and the "Home" sensor.
12
+ - **Debug log:** each update logs what the vehicle reported for charging (state, cable, plug lock, limit, automatic unlock), air conditioning, auxiliary heating, ventilation and the lock, each with the time the vehicle captured it. No VIN, no position. This helps answer open questions with electric vehicles.
13
+ - When the vehicle declines a command, the log mentions a low 12 V battery as a possible cause, as the API documentation does.
14
+
15
+ ## 0.3.1
16
+
17
+ - **Fixed:** after updating to 0.3.0, the settings form could mark the config as invalid. The option for air conditioning when not plugged in used to be a checkbox; the 0.3.0 form turned its saved value into the text `"false"` or `"true"`, which the new choice does not accept, and the plugin then ignored it. The option now has a new name, `airConditioningOnBattery` (`"vehicle"`, `"allow"` or `"deny"`). The old `airConditioningWithoutExternalPower` is still read in every form until you choose the option again in the settings; the log reminds you once per start.
18
+
3
19
  ## 0.3.0
4
20
 
5
21
  - **Window heating** as an optional read-only contact sensor, open while the front or rear window heating is on (`features.windowHeating`). The API has no command for it.
package/README.md CHANGED
@@ -20,25 +20,28 @@ Each vehicle becomes one HomeKit accessory. A service is only created if it is e
20
20
  config **and** the vehicle reports that it supports it. For the controls, that is the list of
21
21
  remote operations the API reports for the vehicle. If two updates report a control as no longer
22
22
  supported, or the vehicle rejects a command as unsupported, the service is removed. A single odd
23
- update or an unreachable API never removes services.
24
-
25
- | HomeKit service | Shows | Controls | Default |
26
- | ---------------------------------------------------------------- | -------------------------------------------------------------- | ---------------------------------------------- | ------- |
27
- | Battery | State of charge, charging state, low battery below a threshold | – | on |
28
- | Humidity sensor "State of Charge" | State of charge in %, so you can build automations on it | – | off |
29
- | Battery "Fuel" | Fuel level, low below the threshold (petrol, diesel, CNG, LPG) | – | on |
30
- | Humidity sensor "Fuel Level" | Fuel level in %, so you can build automations on it | – | off |
31
- | Outlet "Charging" | _On_ = charging, _Outlet In Use_ = cable plugged in | Start / stop charging | on |
32
- | Lightbulb "Charge Limit" | Brightness = charging limit (50–100 % in steps of 10) | Set charging limit | on |
33
- | Heater Cooler "Climate" | Active, heating / cooling, target temperature | Start / stop air conditioning, set temperature | on |
34
- | Switch "Auxiliary Heating" | Running | Start / stop (needs your S-PIN) | on |
35
- | Switch "Ventilation" | Running, as far as the vehicle reports it (see notes) | Start / stop active ventilation | off |
36
- | Occupancy sensor "Home" | Parked within a radius around your home | – | on |
37
- | Contact sensors "Doors", "Windows", "Trunk", "Bonnet", "Sunroof" | Open / closed | – | on |
38
- | Contact sensor "Locked" | Closed = locked, open = unlocked | – (the API cannot lock or unlock) | on |
39
- | Contact sensor "Lights" | Open = lights on | – | off |
40
- | Contact sensor "Window Heating" | Open = front or rear window heating on | – (the API has no command for it) | off |
41
- | Contact sensor "Plug Locked" | Closed = charging cable locked | – | off |
23
+ update or an unreachable API never removes services. If a vehicle's entry in the config becomes invalid, for
24
+ example while you replace its API key, the vehicle stays in HomeKit and shows "No Response" until
25
+ the entry is fixed.
26
+
27
+ | HomeKit service | Shows | Controls | Default |
28
+ | ---------------------------------------------------------------- | -------------------------------------------------------------------------- | ---------------------------------------------- | ------- |
29
+ | Battery | State of charge, charging state, low battery below a threshold | – | on |
30
+ | Humidity sensor "State of Charge" | State of charge in %, so you can build automations on it | – | off |
31
+ | Battery "Fuel" | Fuel level, low below the threshold (petrol, diesel, CNG, LPG) | – | on |
32
+ | Humidity sensor "Fuel Level" | Fuel level in %, so you can build automations on it | – | off |
33
+ | Outlet "Charging" | _On_ = charging, _Outlet In Use_ = cable plugged in | Start / stop charging | on |
34
+ | Lightbulb "Charge Limit" | Brightness = charging limit (50–100 % in steps of 10) | Set charging limit | on |
35
+ | Heater Cooler "Climate" | Active, heating / cooling, target temperature | Start / stop air conditioning, set temperature | on |
36
+ | Switch "Auxiliary Heating" | Running | Start / stop (needs your S-PIN) | on |
37
+ | Switch "Ventilation" | Running, as far as the vehicle reports it (see notes) | Start / stop active ventilation | off |
38
+ | Occupancy sensor "Home" | Parked within a radius around your home | – | on |
39
+ | Contact sensors "Doors", "Windows", "Trunk", "Bonnet", "Sunroof" | Open / closed | – | on |
40
+ | Lock "Locked" | Locked / unlocked | – (read-only, the API cannot lock or unlock) | on |
41
+ | Contact sensor "Lights" | Open = lights on | – | off |
42
+ | Contact sensor "Window Heating" | Open = front or rear window heating on | – (the API has no command for it) | off |
43
+ | Occupancy sensor "Plugged In" | Detected = charging cable plugged in, for automations | – | off |
44
+ | Contact sensor "Plug Locked" | Closed = charging cable locked or no cable; open = plugged in but unlocked | – | off |
42
45
 
43
46
  HomeKit has no services for range or mileage, so the plugin does not show them.
44
47
 
@@ -66,8 +69,16 @@ and flashing, waking the vehicle up, cabin temperature, and push updates.
66
69
  that cannot be charged. Low battery uses `lowBatteryThreshold`. Plug-in hybrids keep the
67
70
  high-voltage battery in the battery service; their fuel level is available as the "Fuel Level"
68
71
  humidity sensor.
69
- - **Lock.** Exposed as a read-only contact sensor rather than a lock, because the API cannot
70
- lock or unlock. A lock tile in the Home app would suggest otherwise.
72
+ - **Lock.** Shown as a lock, so the Home app says _locked_ or _unlocked_. The API cannot lock or
73
+ unlock, so the lock is read-only: changing it in the Home app fails right away, and Siri
74
+ answers "lock all doors" with "no response" for the vehicle.
75
+ - **Separate tiles.** The Home app groups the vehicle's controls into one tile. To give the
76
+ ventilation, air conditioning, charging and lock tiles of their own, open the vehicle's settings
77
+ in the Home app and choose _Show as Separate Tiles_. The sensors appear in the room's summary
78
+ either way.
79
+ - **Room summary.** The Home app counts the sensors in the room's summary: "Home" and "Plugged In"
80
+ as presence, the "Fuel Level" and "State of Charge" sensors as humidity. Put the vehicle in a
81
+ room of its own, for example "Car", to keep your other rooms' summaries clean.
71
82
  - **Expected state after a command.** HomeKit shows the expected state right away and keeps it
72
83
  until the vehicle reports that part again, at most 15 minutes. If the vehicle reports something
73
84
  else, for example because charging could not start, HomeKit shows what the vehicle reports.
@@ -130,20 +141,20 @@ The easiest way is the Homebridge UI. In `config.json` it looks like this:
130
141
  }
131
142
  ```
132
143
 
133
- | Option | Default | Description |
134
- | ------------------------------------- | ----------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
135
- | `name` | `Škoda <last 4 of VIN>` | Accessory name in HomeKit |
136
- | `vin` | – | Vehicle identification number (required) |
137
- | `token` | – | API key (required) |
138
- | `spin` | – | S-PIN, only needed for the auxiliary heating |
139
- | `home.lat`, `home.lon` | – | Home coordinates for the "Home" sensor |
140
- | `home.radiusMeters` | `150` | Radius around home, at least 10 m |
141
- | `pollingIntervalMinutes` | `5` | Polling interval, at least 4 (see below) |
142
- | `lowBatteryThreshold` | `20` | Low battery below this state of charge or fuel level (%) |
143
- | `climateTemperature` | `21` | Cabin temperature (°C) until the vehicle reports one |
144
- | `airConditioningWithoutExternalPower` | – | `"allow"` or `"deny"` air conditioning from the drive battery when not plugged in; unset keeps the vehicle setting |
145
- | `auxiliaryHeatingDurationMinutes` | – | Auxiliary heating run time; unset keeps the vehicle setting |
146
- | `features.*` | see table above | `battery`, `stateOfChargeSensor`, `fuelLevel`, `fuelLevelSensor`, `charging`, `chargingLimit`, `climate`, `auxiliaryHeating`, `activeVentilation`, `presence`, `doors`, `windows`, `trunk`, `bonnet`, `sunroof`, `lock`, `lights`, `windowHeating`, `plugLock` |
144
+ | Option | Default | Description |
145
+ | --------------------------------- | ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
146
+ | `name` | `Škoda <last 4 of VIN>` | Accessory name in HomeKit |
147
+ | `vin` | – | Vehicle identification number (required) |
148
+ | `token` | – | API key (required) |
149
+ | `spin` | – | S-PIN, only needed for the auxiliary heating |
150
+ | `home.lat`, `home.lon` | – | Home coordinates for the "Home" sensor |
151
+ | `home.radiusMeters` | `150` | Radius around home, at least 10 m |
152
+ | `pollingIntervalMinutes` | `5` | Polling interval, at least 4 (see below) |
153
+ | `lowBatteryThreshold` | `20` | Low battery below this state of charge or fuel level (%) |
154
+ | `climateTemperature` | `21` | Cabin temperature (°C) until the vehicle reports one |
155
+ | `airConditioningOnBattery` | – | `"allow"` or `"deny"` air conditioning from the drive battery when not plugged in; unset keeps the vehicle setting |
156
+ | `auxiliaryHeatingDurationMinutes` | – | Auxiliary heating run time; unset keeps the vehicle setting |
157
+ | `features.*` | see table above | `battery`, `stateOfChargeSensor`, `fuelLevel`, `fuelLevelSensor`, `charging`, `chargingLimit`, `climate`, `auxiliaryHeating`, `activeVentilation`, `presence`, `doors`, `windows`, `trunk`, `bonnet`, `sunroof`, `lock`, `lights`, `windowHeating`, `plugLock`, `pluggedIn` |
147
158
 
148
159
  ## Rate limit
149
160
 
@@ -179,15 +190,15 @@ suggests, and a command may take a minute or two to show up.
179
190
 
180
191
  ## Troubleshooting
181
192
 
182
- | Log message | Meaning |
183
- | ------------------------------------------------------ | --------------------------------------------------------------- |
184
- | `The API key has expired` | Create or renew a key in the MyŠkoda app and update the config |
185
- | `The API key does not cover this vehicle or operation` | The key was created for another vehicle, or the VIN is wrong |
186
- | `No vehicle found for the configured VIN` | Check the VIN |
187
- | `rate limit budget exhausted` | Too many commands in the last hour; try again later |
188
- | `the vehicle declined the request` | The vehicle refused for now (e.g. low battery); try again later |
189
- | `this function is currently disabled for the vehicle` | Enable the service for the vehicle in the MyŠkoda app |
190
- | `The vehicle does not support …` | The vehicle rejected the command; its control is removed |
193
+ | Log message | Meaning |
194
+ | ------------------------------------------------------ | -------------------------------------------------------------------- |
195
+ | `The API key has expired` | Create or renew a key in the MyŠkoda app and update the config |
196
+ | `The API key does not cover this vehicle or operation` | The key was created for another vehicle, or the VIN is wrong |
197
+ | `No vehicle found for the configured VIN` | Check the VIN |
198
+ | `rate limit budget exhausted` | Too many commands in the last hour; try again later |
199
+ | `the vehicle declined the request` | The vehicle refused for now (e.g. low 12 V battery); try again later |
200
+ | `this function is currently disabled for the vehicle` | Enable the service for the vehicle in the MyŠkoda app |
201
+ | `The vehicle does not support …` | The vehicle rejected the command; its control is removed |
191
202
 
192
203
  ## Development
193
204
 
@@ -202,7 +213,8 @@ npm run build
202
213
  The tests mock the API completely and contain no real keys or vehicle data.
203
214
 
204
215
  Upstream changes worth following (the API, the Python library and the Home Assistant integration)
205
- are listed in [MAINTAINING.md](MAINTAINING.md).
216
+ are listed in [dev/MAINTAINING.md](dev/MAINTAINING.md), planned releases in
217
+ [dev/ROADMAP.md](dev/ROADMAP.md).
206
218
 
207
219
  ## License
208
220
 
@@ -3,7 +3,7 @@
3
3
  "pluginType": "platform",
4
4
  "singular": true,
5
5
  "strictValidation": false,
6
- "headerDisplay": "Connects Škoda vehicles through the official **MyŠkoda Public API**. Create an API key in the MyŠkoda app under *Profile › Smart Home* (or open [go.skoda.eu/api-keys](https://go.skoda.eu/api-keys) on your phone). The API allows **20 requests per hour per vehicle**, so data is polled every few minutes and commands take a moment to show up. This is not an official Škoda project.",
6
+ "headerDisplay": "Škoda vehicles via the official **MyŠkoda Public API**. Create an API key in the MyŠkoda app under *Profile › Smart Home*. Not an official Škoda project.",
7
7
  "footerDisplay": "See the [README](https://github.com/thecloudseeker/homebridge-skoda#readme) for details on each feature.",
8
8
  "schema": {
9
9
  "type": "object",
@@ -18,7 +18,7 @@
18
18
  "title": "Name",
19
19
  "type": "string",
20
20
  "placeholder": "Enyaq",
21
- "description": "Name of the accessory in HomeKit."
21
+ "description": "Name in HomeKit."
22
22
  },
23
23
  "vin": {
24
24
  "title": "VIN",
@@ -27,18 +27,18 @@
27
27
  "minLength": 17,
28
28
  "maxLength": 17,
29
29
  "pattern": "^[A-HJ-NPR-Za-hj-npr-z0-9]{17}$",
30
- "description": "17-character vehicle identification number."
30
+ "description": "17 characters."
31
31
  },
32
32
  "token": {
33
33
  "title": "API key",
34
34
  "type": "string",
35
35
  "required": true,
36
- "description": "API key from the MyŠkoda app (Profile › Smart Home). Used for reading the vehicle and for commands."
36
+ "description": "From the MyŠkoda app, Profile › Smart Home."
37
37
  },
38
38
  "spin": {
39
39
  "title": "S-PIN (optional)",
40
40
  "type": "string",
41
- "description": "Security PIN of your MyŠkoda account. Only needed to start the auxiliary heating; it is sent with each start and never logged."
41
+ "description": "Only for the auxiliary heating. Never logged."
42
42
  },
43
43
  "home": {
44
44
  "title": "Home location",
@@ -48,19 +48,22 @@
48
48
  "title": "Latitude",
49
49
  "type": "number",
50
50
  "minimum": -90,
51
- "maximum": 90
51
+ "maximum": 90,
52
+ "description": "e.g. 50.4128"
52
53
  },
53
54
  "lon": {
54
55
  "title": "Longitude",
55
56
  "type": "number",
56
57
  "minimum": -180,
57
- "maximum": 180
58
+ "maximum": 180,
59
+ "description": "e.g. 14.9069"
58
60
  },
59
61
  "radiusMeters": {
60
62
  "title": "Radius (m)",
61
63
  "type": "integer",
62
64
  "minimum": 10,
63
- "placeholder": 150
65
+ "placeholder": 150,
66
+ "description": "Default 150."
64
67
  }
65
68
  }
66
69
  },
@@ -70,7 +73,7 @@
70
73
  "minimum": 4,
71
74
  "maximum": 1440,
72
75
  "placeholder": 5,
73
- "description": "How often the plugin fetches the vehicle's state. At least 4, default 5: the API allows 20 requests per hour, and 4 are kept free for commands."
76
+ "description": "Minimum 4, default 5. The API allows 20 requests per hour."
74
77
  },
75
78
  "lowBatteryThreshold": {
76
79
  "title": "Low battery / fuel warning below (%)",
@@ -78,7 +81,7 @@
78
81
  "minimum": 0,
79
82
  "maximum": 100,
80
83
  "placeholder": 20,
81
- "description": "HomeKit shows low battery when the battery or fuel level drops below this value. Default 20."
84
+ "description": "Default 20."
82
85
  },
83
86
  "climateTemperature": {
84
87
  "title": "Default temperature (°C)",
@@ -87,9 +90,9 @@
87
90
  "maximum": 29.5,
88
91
  "multipleOf": 0.5,
89
92
  "placeholder": 21,
90
- "description": "Used for the first start until the vehicle reports its own target temperature. 16-29.5 in steps of 0.5, default 21."
93
+ "description": "Until the vehicle reports its own. 16–29.5, default 21."
91
94
  },
92
- "airConditioningWithoutExternalPower": {
95
+ "airConditioningOnBattery": {
93
96
  "title": "Air conditioning when not plugged in",
94
97
  "type": "string",
95
98
  "oneOf": [
@@ -107,14 +110,14 @@
107
110
  }
108
111
  ],
109
112
  "placeholder": "vehicle",
110
- "description": "For electric vehicles: whether the air conditioning may run from the drive battery when no charging cable is connected."
113
+ "description": "Electric vehicles: run the air conditioning from the drive battery."
111
114
  },
112
115
  "auxiliaryHeatingDurationMinutes": {
113
116
  "title": "Auxiliary heating run time (minutes, optional)",
114
117
  "type": "integer",
115
118
  "minimum": 1,
116
119
  "maximum": 60,
117
- "description": "1-60. Leave empty to use the run time set in the vehicle."
120
+ "description": "1–60. Empty uses the vehicle setting."
118
121
  },
119
122
  "features": {
120
123
  "title": "Features",
@@ -123,97 +126,122 @@
123
126
  "battery": {
124
127
  "title": "Battery (electric and plug-in hybrid)",
125
128
  "type": "boolean",
126
- "default": true
129
+ "default": true,
130
+ "description": "Level, charging state, low warning."
127
131
  },
128
132
  "stateOfChargeSensor": {
129
133
  "title": "State of charge as extra sensor, for automations",
130
134
  "type": "boolean",
131
- "default": false
135
+ "default": false,
136
+ "description": "Humidity sensor in %. Counts as the room's humidity."
132
137
  },
133
138
  "fuelLevel": {
134
139
  "title": "Fuel level as battery (petrol, diesel, CNG, LPG)",
135
140
  "type": "boolean",
136
- "default": true
141
+ "default": true,
142
+ "description": "Shown as a battery, as HomeKit has no fuel service."
137
143
  },
138
144
  "fuelLevelSensor": {
139
145
  "title": "Fuel level as extra sensor, for automations",
140
146
  "type": "boolean",
141
- "default": false
147
+ "default": false,
148
+ "description": "Humidity sensor in %. Counts as the room's humidity."
142
149
  },
143
150
  "charging": {
144
151
  "title": "Start / stop charging (outlet)",
145
152
  "type": "boolean",
146
- "default": true
153
+ "default": true,
154
+ "description": "Outlet: on starts, off stops charging."
147
155
  },
148
156
  "chargingLimit": {
149
157
  "title": "Charge limit (lightbulb brightness)",
150
158
  "type": "boolean",
151
- "default": true
159
+ "default": true,
160
+ "description": "Brightness = limit, 50–100 %."
152
161
  },
153
162
  "climate": {
154
163
  "title": "Air conditioning (heater cooler)",
155
164
  "type": "boolean",
156
- "default": true
165
+ "default": true,
166
+ "description": "Start and stop at the target temperature."
157
167
  },
158
168
  "auxiliaryHeating": {
159
169
  "title": "Auxiliary heating (switch, needs S-PIN)",
160
170
  "type": "boolean",
161
- "default": true
171
+ "default": true,
172
+ "description": "Start and stop. Needs the S-PIN."
162
173
  },
163
174
  "activeVentilation": {
164
175
  "title": "Ventilation (switch)",
165
176
  "type": "boolean",
166
- "default": false
177
+ "default": false,
178
+ "description": "Start and stop the ventilation."
167
179
  },
168
180
  "presence": {
169
181
  "title": "\"Home\" sensor (needs home location)",
170
182
  "type": "boolean",
171
- "default": true
183
+ "default": true,
184
+ "description": "Detected while parked at home. Counts as presence in the room."
172
185
  },
173
186
  "doors": {
174
187
  "title": "Doors",
175
188
  "type": "boolean",
176
- "default": true
189
+ "default": true,
190
+ "description": "Open while a door is open."
177
191
  },
178
192
  "windows": {
179
193
  "title": "Windows",
180
194
  "type": "boolean",
181
- "default": true
195
+ "default": true,
196
+ "description": "Open while a window is open."
182
197
  },
183
198
  "trunk": {
184
199
  "title": "Trunk",
185
200
  "type": "boolean",
186
- "default": true
201
+ "default": true,
202
+ "description": "Open while the trunk is open."
187
203
  },
188
204
  "bonnet": {
189
205
  "title": "Bonnet",
190
206
  "type": "boolean",
191
- "default": true
207
+ "default": true,
208
+ "description": "Open while the bonnet is open."
192
209
  },
193
210
  "sunroof": {
194
211
  "title": "Sunroof",
195
212
  "type": "boolean",
196
- "default": true
213
+ "default": true,
214
+ "description": "Open while the sunroof is open."
197
215
  },
198
216
  "lock": {
199
- "title": "Locked (sensor)",
217
+ "title": "Locked (lock, read-only)",
200
218
  "type": "boolean",
201
- "default": true
219
+ "default": true,
220
+ "description": "Locked or unlocked. Cannot lock or unlock."
202
221
  },
203
222
  "lights": {
204
223
  "title": "Lights on (sensor)",
205
224
  "type": "boolean",
206
- "default": false
225
+ "default": false,
226
+ "description": "Open while the lights are on."
207
227
  },
208
228
  "windowHeating": {
209
229
  "title": "Window heating on (sensor)",
210
230
  "type": "boolean",
211
- "default": false
231
+ "default": false,
232
+ "description": "Open while on. Read-only."
212
233
  },
213
234
  "plugLock": {
214
235
  "title": "Charging plug locked (sensor)",
215
236
  "type": "boolean",
216
- "default": false
237
+ "default": false,
238
+ "description": "Open while a plugged-in cable is unlocked."
239
+ },
240
+ "pluggedIn": {
241
+ "title": "Plugged in (sensor, for automations)",
242
+ "type": "boolean",
243
+ "default": false,
244
+ "description": "Detected while the cable is plugged in. Counts as presence in the room."
217
245
  }
218
246
  }
219
247
  }
@@ -240,7 +268,7 @@
240
268
  },
241
269
  {
242
270
  "type": "help",
243
- "helpvalue": "<p>The plugin detects what your vehicle supports and only creates those services in HomeKit, so you can keep the defaults below. Switches marked <em>sensor</em> or <em>for automations</em> are off by default. After the first update the Homebridge log lists everything your vehicle supports, including what is turned off.</p>"
271
+ "helpvalue": "<p>Only services your vehicle supports are created, so the defaults are fine. The log lists what your vehicle supports.</p>"
244
272
  },
245
273
  {
246
274
  "type": "fieldset",
@@ -255,7 +283,8 @@
255
283
  "vehicles[].features.sunroof",
256
284
  "vehicles[].features.lock",
257
285
  "vehicles[].features.lights"
258
- ]
286
+ ],
287
+ "description": "Read-only sensors."
259
288
  },
260
289
  {
261
290
  "type": "fieldset",
@@ -271,7 +300,8 @@
271
300
  "key": "vehicles[].lowBatteryThreshold",
272
301
  "type": "number"
273
302
  }
274
- ]
303
+ ],
304
+ "description": "Battery for electric vehicles, fuel level for combustion engines."
275
305
  },
276
306
  {
277
307
  "type": "fieldset",
@@ -282,6 +312,7 @@
282
312
  "items": [
283
313
  "vehicles[].features.charging",
284
314
  "vehicles[].features.chargingLimit",
315
+ "vehicles[].features.pluggedIn",
285
316
  "vehicles[].features.plugLock"
286
317
  ]
287
318
  },
@@ -296,15 +327,16 @@
296
327
  "key": "vehicles[].climateTemperature",
297
328
  "type": "number"
298
329
  },
299
- "vehicles[].airConditioningWithoutExternalPower",
330
+ "vehicles[].airConditioningOnBattery",
300
331
  "vehicles[].features.windowHeating",
301
332
  "vehicles[].features.activeVentilation"
302
- ]
333
+ ],
334
+ "description": "Remote climate control."
303
335
  },
304
336
  {
305
337
  "type": "fieldset",
306
338
  "title": "Auxiliary heating",
307
- "description": "Vehicles with a fuel-operated auxiliary heater.",
339
+ "description": "Vehicles with a fuel-operated heater.",
308
340
  "expandable": true,
309
341
  "expanded": false,
310
342
  "items": [
@@ -322,7 +354,7 @@
322
354
  {
323
355
  "type": "fieldset",
324
356
  "title": "Home location",
325
- "description": "Used for the \"Home\" occupancy sensor.",
357
+ "description": "For the \"Home\" sensor.",
326
358
  "expandable": true,
327
359
  "expanded": false,
328
360
  "items": [
@@ -2,7 +2,7 @@ import type { Service } from "homebridge";
2
2
  import type { Vehicle } from "../../api/types.js";
3
3
  import type { FeatureToggles } from "../../config.js";
4
4
  import { ServiceBinding, type BindingContext, type ServiceType } from "./common.js";
5
- type ContactFeature = Extract<keyof FeatureToggles, "doors" | "windows" | "trunk" | "bonnet" | "sunroof" | "lock" | "lights" | "windowHeating" | "plugLock">;
5
+ type ContactFeature = Extract<keyof FeatureToggles, "doors" | "windows" | "trunk" | "bonnet" | "sunroof" | "lights" | "windowHeating" | "plugLock">;
6
6
  interface ContactDefinition {
7
7
  feature: ContactFeature;
8
8
  displayName: string;
@@ -19,7 +19,32 @@ export declare class ContactBinding extends ServiceBinding {
19
19
  protected get hasStatusFault(): boolean;
20
20
  protected render(_service: Service, vehicle: Vehicle): void;
21
21
  }
22
- export declare function contactBindings(ctx: BindingContext): ContactBinding[];
22
+ /** The contact sensors, with the lock after the sunroof so the support log keeps its order. */
23
+ export declare function contactBindings(ctx: BindingContext): ServiceBinding[];
24
+ /**
25
+ * Lock "Locked": shows "locked" or "unlocked" with a lock icon. The API cannot lock or unlock, so
26
+ * the target state is read-only and HomeKit answers writes with "read-only characteristic". It
27
+ * replaces the "Locked" contact sensor of 0.3.x (subtype "lock"), see `removeLegacyLockSensor`.
28
+ */
29
+ export declare class LockBinding extends ServiceBinding {
30
+ readonly feature = "lock";
31
+ protected readonly serviceType: ServiceType;
32
+ protected readonly subtype = "lock";
33
+ protected readonly displayName = "Locked";
34
+ protected configure(service: Service): void;
35
+ protected render(_service: Service, vehicle: Vehicle): void;
36
+ }
37
+ /** Removes the "Locked" contact sensor of 0.3.x, which `LockBinding` replaces. Returns whether it existed. */
38
+ export declare function removeLegacyLockSensor(ctx: BindingContext): boolean;
39
+ /** Occupancy sensor "Plugged In": detected while the charging cable is plugged in, for automations. */
40
+ export declare class PluggedInBinding extends ServiceBinding {
41
+ readonly feature = "pluggedIn";
42
+ protected readonly serviceType: ServiceType;
43
+ protected readonly subtype = "plugged-in";
44
+ protected readonly displayName = "Plugged In";
45
+ protected get hasStatusFault(): boolean;
46
+ protected render(_service: Service, vehicle: Vehicle): void;
47
+ }
23
48
  /** Occupancy sensor "Home": parked within the configured radius around the home coordinates. */
24
49
  export declare class PresenceBinding extends ServiceBinding {
25
50
  readonly feature = "presence";