@camstack/addon-export-alexa 1.2.117 → 1.2.119
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/dist/export-alexa.addon.js +209 -7
- package/dist/export-alexa.addon.mjs +209 -7
- package/package.json +1 -1
|
@@ -5387,7 +5387,7 @@ var ZodIssueCode = {
|
|
|
5387
5387
|
var ZodFirstPartyTypeKind;
|
|
5388
5388
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5389
5389
|
//#endregion
|
|
5390
|
-
//#region ../types/dist/sleep-
|
|
5390
|
+
//#region ../types/dist/sleep-vl6nBE8d.mjs
|
|
5391
5391
|
/**
|
|
5392
5392
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5393
5393
|
* window to float samples (D455).
|
|
@@ -29071,14 +29071,81 @@ DeviceType.Camera, method(object({ deviceId: number() }), PrivacyMaskOptionsSche
|
|
|
29071
29071
|
kind: "mutation",
|
|
29072
29072
|
auth: "admin"
|
|
29073
29073
|
});
|
|
29074
|
+
/**
|
|
29075
|
+
* What a preset id DOES on this camera.
|
|
29076
|
+
*
|
|
29077
|
+
* On several PTZ firmwares the preset namespace is shared: low ids are stored
|
|
29078
|
+
* positions, a reserved band triggers camera FUNCTIONS. The dispensa camera
|
|
29079
|
+
* (Hikvision) returns its own reserved band in the preset list, named by the
|
|
29080
|
+
* firmware:
|
|
29081
|
+
*
|
|
29082
|
+
* 34 Back to origin · 39 Day mode · 40 Night mode · 46 Day/Night Auto Mode
|
|
29083
|
+
* 92 Set manual limits · 93 Save manual limits · 94 Remote reboot
|
|
29084
|
+
* 95 Call OSD menu
|
|
29085
|
+
*
|
|
29086
|
+
* We used to hand all of these to the UI as ordinary presets. Saving over one
|
|
29087
|
+
* is what produced `PUT /ISAPI/PTZCtrl/channels/1/presets/34 -> HTTP 500`: the
|
|
29088
|
+
* camera refusing to let "Back to origin" be overwritten, surfaced to the
|
|
29089
|
+
* operator as a transport failure.
|
|
29090
|
+
*
|
|
29091
|
+
* A function preset stays fully usable as a DESTINATION -- `goToPreset('34')`
|
|
29092
|
+
* is the single most useful thing that camera can do. Only `savePreset` and
|
|
29093
|
+
* `deletePreset` are gated.
|
|
29094
|
+
*/
|
|
29095
|
+
var PtzPresetFunctionSchema = _enum([
|
|
29096
|
+
"home",
|
|
29097
|
+
"day-mode",
|
|
29098
|
+
"night-mode",
|
|
29099
|
+
"day-night-auto",
|
|
29100
|
+
"set-limits",
|
|
29101
|
+
"save-limits",
|
|
29102
|
+
"reboot",
|
|
29103
|
+
"osd-menu"
|
|
29104
|
+
]);
|
|
29074
29105
|
var PtzPresetSchema = object({
|
|
29075
29106
|
id: string(),
|
|
29076
|
-
name: string()
|
|
29107
|
+
name: string(),
|
|
29108
|
+
/**
|
|
29109
|
+
* The firmware function this id performs, when the provider KNOWS the id is
|
|
29110
|
+
* reserved. `null` = an ordinary stored position, OR a reserved id this
|
|
29111
|
+
* provider does not recognise -- the two are told apart by `writable`.
|
|
29112
|
+
*/
|
|
29113
|
+
fn: PtzPresetFunctionSchema.nullable(),
|
|
29114
|
+
/**
|
|
29115
|
+
* Whether `savePreset` / `deletePreset` may target this id. A provider sets
|
|
29116
|
+
* it false only for a band it KNOWS is reserved; where the firmware is not
|
|
29117
|
+
* documented it stays true and a refusal comes from the camera, named.
|
|
29118
|
+
*/
|
|
29119
|
+
writable: boolean()
|
|
29077
29120
|
});
|
|
29121
|
+
/**
|
|
29122
|
+
* Where the head is pointing -- per axis, and `null` when the driver cannot
|
|
29123
|
+
* read it.
|
|
29124
|
+
*
|
|
29125
|
+
* It used to be three REQUIRED numbers, which left a provider that cannot read
|
|
29126
|
+
* position no way to say so. All four said `0`:
|
|
29127
|
+
*
|
|
29128
|
+
* reolink `return { pan: 0, tilt: 0, zoom: 0 }` "until a position-query
|
|
29129
|
+
* path lands upstream"
|
|
29130
|
+
* hikvision stub, "firmware-dependent and frequently absent"
|
|
29131
|
+
* amcrest stub, "no generic absolute-position read for this model family"
|
|
29132
|
+
* onvif throws
|
|
29133
|
+
*
|
|
29134
|
+
* So every consumer asking where a camera points was told "perfectly centred"
|
|
29135
|
+
* by four cameras that had never looked. That is D393 -- a measurement that
|
|
29136
|
+
* FAILED is `null`, never `0`, and the type says so all the way to the
|
|
29137
|
+
* decision -- the same shape as the unreadable `statfs` folded into "0 bytes of
|
|
29138
|
+
* headroom", which evacuated a healthy disk.
|
|
29139
|
+
*
|
|
29140
|
+
* D393 also says to check for a narrower structural TWIN of the result type.
|
|
29141
|
+
* There is one: `PtzStatusSchema` extends this, so the lie had already
|
|
29142
|
+
* propagated into `getStatus`, which is the surface `getPosition`'s own comment
|
|
29143
|
+
* tells callers to migrate to.
|
|
29144
|
+
*/
|
|
29078
29145
|
var PtzPositionSchema = object({
|
|
29079
|
-
pan: number(),
|
|
29080
|
-
tilt: number(),
|
|
29081
|
-
zoom: number()
|
|
29146
|
+
pan: number().nullable(),
|
|
29147
|
+
tilt: number().nullable(),
|
|
29148
|
+
zoom: number().nullable()
|
|
29082
29149
|
});
|
|
29083
29150
|
var PtzMoveCommandSchema = object({
|
|
29084
29151
|
pan: number().optional(),
|
|
@@ -29097,7 +29164,72 @@ var PtzOptionsSchema = object({
|
|
|
29097
29164
|
maxPresets: number().optional(),
|
|
29098
29165
|
/** Whether the camera exposes a controllable autofocus toggle
|
|
29099
29166
|
* (boolean `hasX` per the getOptions availability convention). */
|
|
29100
|
-
hasAutofocus: boolean()
|
|
29167
|
+
hasAutofocus: boolean(),
|
|
29168
|
+
/**
|
|
29169
|
+
* How many distinct speeds this camera's NATIVE scale offers.
|
|
29170
|
+
*
|
|
29171
|
+
* The cap's `speed` is normalized 0..1 and each provider maps it down --
|
|
29172
|
+
* Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
|
|
29173
|
+
* value hides how coarse that really is: asking an amcrest for `0.37` is
|
|
29174
|
+
* meaningless, because it has eight steps and three of them round to the
|
|
29175
|
+
* same one. A loop that tunes its own gain has to know the granularity of
|
|
29176
|
+
* the knob it is turning.
|
|
29177
|
+
*
|
|
29178
|
+
* `null` = the driver does not know, or the scale is continuous (ONVIF takes
|
|
29179
|
+
* a float). Never a made-up number.
|
|
29180
|
+
*/
|
|
29181
|
+
speedSteps: number().int().positive().nullable(),
|
|
29182
|
+
/**
|
|
29183
|
+
* How long ONE `move` pulse runs on this driver, ms.
|
|
29184
|
+
*
|
|
29185
|
+
* `move` is a self-terminating burst everywhere, but every provider hardcoded
|
|
29186
|
+
* its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
|
|
29187
|
+
* 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
|
|
29188
|
+
* did the head travel per pulse": without it a measured displacement has no
|
|
29189
|
+
* gain to be divided into.
|
|
29190
|
+
*
|
|
29191
|
+
* `null` = the driver cannot say.
|
|
29192
|
+
*/
|
|
29193
|
+
moveImpulseMs: number().int().positive().nullable()
|
|
29194
|
+
});
|
|
29195
|
+
/**
|
|
29196
|
+
* Which preset `goHome` goes to, and WHO decided.
|
|
29197
|
+
*
|
|
29198
|
+
* `goHome` used to be three vendor "conventions" written in three comments --
|
|
29199
|
+
* Reolink preset 0, Hikvision preset '1', Dahua preset 1 -- and on this fleet
|
|
29200
|
+
* not one of the three cameras honours its own:
|
|
29201
|
+
*
|
|
29202
|
+
* 592 Videocamera camera Daniel (reolink) preset 0 holds "stanza"
|
|
29203
|
+
* 1438 Videocamera dispensa (hikvision) preset 1 holds "Credenza"
|
|
29204
|
+
* 3836 Videocamera studio (amcrest) preset 1 holds "Preset1"
|
|
29205
|
+
*
|
|
29206
|
+
* So `goHome` meant "go wherever the operator happened to save in slot 0 or 1",
|
|
29207
|
+
* and two of the three swallowed the failure in a bare `catch`. For autotrack
|
|
29208
|
+
* this is the HOTTEST path -- it runs every time a subject is released -- so it
|
|
29209
|
+
* needs an answer that is true per camera and audible when it is missing.
|
|
29210
|
+
*
|
|
29211
|
+
* `source` is what makes it honest:
|
|
29212
|
+
* - `operator` -- picked in the UI, stored by the provider.
|
|
29213
|
+
* - `firmware` -- the camera itself named a preset `fn: 'home'` (Hikvision's
|
|
29214
|
+
* "Back to origin"), adopted as the default with nothing to configure.
|
|
29215
|
+
* - `native` -- the driver homes WITHOUT a preset at all. ONVIF does:
|
|
29216
|
+
* `goHome` is `ptzAbsoluteMove({x:0, y:0, zoom:0})`. `presetId` is null and
|
|
29217
|
+
* that is not a failure -- there is nothing to pick, and the UI must offer
|
|
29218
|
+
* no picker.
|
|
29219
|
+
* - `none` -- nothing is configured and the camera names nothing.
|
|
29220
|
+
* `goHome` REFUSES rather than moving the head somewhere arbitrary.
|
|
29221
|
+
*
|
|
29222
|
+
* `source === 'none'` is the refusal condition, NOT `presetId === null`: the
|
|
29223
|
+
* native case has no preset and homes perfectly well.
|
|
29224
|
+
*/
|
|
29225
|
+
var PtzHomePresetSchema = object({
|
|
29226
|
+
presetId: string().nullable(),
|
|
29227
|
+
source: _enum([
|
|
29228
|
+
"operator",
|
|
29229
|
+
"firmware",
|
|
29230
|
+
"native",
|
|
29231
|
+
"none"
|
|
29232
|
+
])
|
|
29101
29233
|
});
|
|
29102
29234
|
DeviceType.Camera, method(PtzMoveCommandSchema.extend({ deviceId: number() }), _void(), { kind: "mutation" }), method(PtzMoveCommandSchema.extend({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), array(PtzPresetSchema)), method(object({
|
|
29103
29235
|
deviceId: number(),
|
|
@@ -29115,7 +29247,22 @@ DeviceType.Camera, method(PtzMoveCommandSchema.extend({ deviceId: number() }), _
|
|
|
29115
29247
|
}), _void(), {
|
|
29116
29248
|
kind: "mutation",
|
|
29117
29249
|
auth: "admin"
|
|
29118
|
-
}), method(object({ deviceId: number() }), PtzOptionsSchema), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }),
|
|
29250
|
+
}), method(object({ deviceId: number() }), PtzOptionsSchema), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), PtzHomePresetSchema), method(object({
|
|
29251
|
+
deviceId: number(),
|
|
29252
|
+
presetId: string().nullable()
|
|
29253
|
+
}), _void(), {
|
|
29254
|
+
kind: "mutation",
|
|
29255
|
+
auth: "admin"
|
|
29256
|
+
}), method(object({ deviceId: number() }), _void(), {
|
|
29257
|
+
kind: "mutation",
|
|
29258
|
+
auth: "admin"
|
|
29259
|
+
}), method(object({ deviceId: number() }), number().int().nullable()), method(object({
|
|
29260
|
+
deviceId: number(),
|
|
29261
|
+
seconds: number().int().min(0).max(3600)
|
|
29262
|
+
}), _void(), {
|
|
29263
|
+
kind: "mutation",
|
|
29264
|
+
auth: "admin"
|
|
29265
|
+
}), method(object({ deviceId: number() }), PtzPositionSchema), method(object({
|
|
29119
29266
|
deviceId: number(),
|
|
29120
29267
|
enabled: boolean()
|
|
29121
29268
|
}), _void(), { kind: "mutation" });
|
|
@@ -36118,6 +36265,12 @@ Object.freeze({
|
|
|
36118
36265
|
addonId: null,
|
|
36119
36266
|
access: "create"
|
|
36120
36267
|
},
|
|
36268
|
+
"ptz.captureHomeHere": {
|
|
36269
|
+
capName: "ptz",
|
|
36270
|
+
capScope: "device",
|
|
36271
|
+
addonId: null,
|
|
36272
|
+
access: "create"
|
|
36273
|
+
},
|
|
36121
36274
|
"ptz.continuousMove": {
|
|
36122
36275
|
capName: "ptz",
|
|
36123
36276
|
capScope: "device",
|
|
@@ -36130,6 +36283,18 @@ Object.freeze({
|
|
|
36130
36283
|
addonId: null,
|
|
36131
36284
|
access: "delete"
|
|
36132
36285
|
},
|
|
36286
|
+
"ptz.getHomePreset": {
|
|
36287
|
+
capName: "ptz",
|
|
36288
|
+
capScope: "device",
|
|
36289
|
+
addonId: null,
|
|
36290
|
+
access: "view"
|
|
36291
|
+
},
|
|
36292
|
+
"ptz.getHomeReturnSeconds": {
|
|
36293
|
+
capName: "ptz",
|
|
36294
|
+
capScope: "device",
|
|
36295
|
+
addonId: null,
|
|
36296
|
+
access: "view"
|
|
36297
|
+
},
|
|
36133
36298
|
"ptz.getOptions": {
|
|
36134
36299
|
capName: "ptz",
|
|
36135
36300
|
capScope: "device",
|
|
@@ -36178,6 +36343,18 @@ Object.freeze({
|
|
|
36178
36343
|
addonId: null,
|
|
36179
36344
|
access: "create"
|
|
36180
36345
|
},
|
|
36346
|
+
"ptz.setHomePreset": {
|
|
36347
|
+
capName: "ptz",
|
|
36348
|
+
capScope: "device",
|
|
36349
|
+
addonId: null,
|
|
36350
|
+
access: "create"
|
|
36351
|
+
},
|
|
36352
|
+
"ptz.setHomeReturnSeconds": {
|
|
36353
|
+
capName: "ptz",
|
|
36354
|
+
capScope: "device",
|
|
36355
|
+
addonId: null,
|
|
36356
|
+
access: "create"
|
|
36357
|
+
},
|
|
36181
36358
|
"ptz.stop": {
|
|
36182
36359
|
capName: "ptz",
|
|
36183
36360
|
capScope: "device",
|
|
@@ -39341,6 +39518,11 @@ Object.freeze({
|
|
|
39341
39518
|
form: "single",
|
|
39342
39519
|
optional: false
|
|
39343
39520
|
}],
|
|
39521
|
+
"ptz.captureHomeHere": [{
|
|
39522
|
+
name: "deviceId",
|
|
39523
|
+
form: "single",
|
|
39524
|
+
optional: false
|
|
39525
|
+
}],
|
|
39344
39526
|
"ptz.continuousMove": [{
|
|
39345
39527
|
name: "deviceId",
|
|
39346
39528
|
form: "single",
|
|
@@ -39351,6 +39533,16 @@ Object.freeze({
|
|
|
39351
39533
|
form: "single",
|
|
39352
39534
|
optional: false
|
|
39353
39535
|
}],
|
|
39536
|
+
"ptz.getHomePreset": [{
|
|
39537
|
+
name: "deviceId",
|
|
39538
|
+
form: "single",
|
|
39539
|
+
optional: false
|
|
39540
|
+
}],
|
|
39541
|
+
"ptz.getHomeReturnSeconds": [{
|
|
39542
|
+
name: "deviceId",
|
|
39543
|
+
form: "single",
|
|
39544
|
+
optional: false
|
|
39545
|
+
}],
|
|
39354
39546
|
"ptz.getOptions": [{
|
|
39355
39547
|
name: "deviceId",
|
|
39356
39548
|
form: "single",
|
|
@@ -39391,6 +39583,16 @@ Object.freeze({
|
|
|
39391
39583
|
form: "single",
|
|
39392
39584
|
optional: false
|
|
39393
39585
|
}],
|
|
39586
|
+
"ptz.setHomePreset": [{
|
|
39587
|
+
name: "deviceId",
|
|
39588
|
+
form: "single",
|
|
39589
|
+
optional: false
|
|
39590
|
+
}],
|
|
39591
|
+
"ptz.setHomeReturnSeconds": [{
|
|
39592
|
+
name: "deviceId",
|
|
39593
|
+
form: "single",
|
|
39594
|
+
optional: false
|
|
39595
|
+
}],
|
|
39394
39596
|
"ptz.stop": [{
|
|
39395
39597
|
name: "deviceId",
|
|
39396
39598
|
form: "single",
|
|
@@ -5360,7 +5360,7 @@ var ZodIssueCode = {
|
|
|
5360
5360
|
var ZodFirstPartyTypeKind;
|
|
5361
5361
|
ZodFirstPartyTypeKind || (ZodFirstPartyTypeKind = {});
|
|
5362
5362
|
//#endregion
|
|
5363
|
-
//#region ../types/dist/sleep-
|
|
5363
|
+
//#region ../types/dist/sleep-vl6nBE8d.mjs
|
|
5364
5364
|
/**
|
|
5365
5365
|
* The audio chunk plane's byte format, and the ONE expansion from a coded
|
|
5366
5366
|
* window to float samples (D455).
|
|
@@ -29044,14 +29044,81 @@ DeviceType.Camera, method(object({ deviceId: number() }), PrivacyMaskOptionsSche
|
|
|
29044
29044
|
kind: "mutation",
|
|
29045
29045
|
auth: "admin"
|
|
29046
29046
|
});
|
|
29047
|
+
/**
|
|
29048
|
+
* What a preset id DOES on this camera.
|
|
29049
|
+
*
|
|
29050
|
+
* On several PTZ firmwares the preset namespace is shared: low ids are stored
|
|
29051
|
+
* positions, a reserved band triggers camera FUNCTIONS. The dispensa camera
|
|
29052
|
+
* (Hikvision) returns its own reserved band in the preset list, named by the
|
|
29053
|
+
* firmware:
|
|
29054
|
+
*
|
|
29055
|
+
* 34 Back to origin · 39 Day mode · 40 Night mode · 46 Day/Night Auto Mode
|
|
29056
|
+
* 92 Set manual limits · 93 Save manual limits · 94 Remote reboot
|
|
29057
|
+
* 95 Call OSD menu
|
|
29058
|
+
*
|
|
29059
|
+
* We used to hand all of these to the UI as ordinary presets. Saving over one
|
|
29060
|
+
* is what produced `PUT /ISAPI/PTZCtrl/channels/1/presets/34 -> HTTP 500`: the
|
|
29061
|
+
* camera refusing to let "Back to origin" be overwritten, surfaced to the
|
|
29062
|
+
* operator as a transport failure.
|
|
29063
|
+
*
|
|
29064
|
+
* A function preset stays fully usable as a DESTINATION -- `goToPreset('34')`
|
|
29065
|
+
* is the single most useful thing that camera can do. Only `savePreset` and
|
|
29066
|
+
* `deletePreset` are gated.
|
|
29067
|
+
*/
|
|
29068
|
+
var PtzPresetFunctionSchema = _enum([
|
|
29069
|
+
"home",
|
|
29070
|
+
"day-mode",
|
|
29071
|
+
"night-mode",
|
|
29072
|
+
"day-night-auto",
|
|
29073
|
+
"set-limits",
|
|
29074
|
+
"save-limits",
|
|
29075
|
+
"reboot",
|
|
29076
|
+
"osd-menu"
|
|
29077
|
+
]);
|
|
29047
29078
|
var PtzPresetSchema = object({
|
|
29048
29079
|
id: string(),
|
|
29049
|
-
name: string()
|
|
29080
|
+
name: string(),
|
|
29081
|
+
/**
|
|
29082
|
+
* The firmware function this id performs, when the provider KNOWS the id is
|
|
29083
|
+
* reserved. `null` = an ordinary stored position, OR a reserved id this
|
|
29084
|
+
* provider does not recognise -- the two are told apart by `writable`.
|
|
29085
|
+
*/
|
|
29086
|
+
fn: PtzPresetFunctionSchema.nullable(),
|
|
29087
|
+
/**
|
|
29088
|
+
* Whether `savePreset` / `deletePreset` may target this id. A provider sets
|
|
29089
|
+
* it false only for a band it KNOWS is reserved; where the firmware is not
|
|
29090
|
+
* documented it stays true and a refusal comes from the camera, named.
|
|
29091
|
+
*/
|
|
29092
|
+
writable: boolean()
|
|
29050
29093
|
});
|
|
29094
|
+
/**
|
|
29095
|
+
* Where the head is pointing -- per axis, and `null` when the driver cannot
|
|
29096
|
+
* read it.
|
|
29097
|
+
*
|
|
29098
|
+
* It used to be three REQUIRED numbers, which left a provider that cannot read
|
|
29099
|
+
* position no way to say so. All four said `0`:
|
|
29100
|
+
*
|
|
29101
|
+
* reolink `return { pan: 0, tilt: 0, zoom: 0 }` "until a position-query
|
|
29102
|
+
* path lands upstream"
|
|
29103
|
+
* hikvision stub, "firmware-dependent and frequently absent"
|
|
29104
|
+
* amcrest stub, "no generic absolute-position read for this model family"
|
|
29105
|
+
* onvif throws
|
|
29106
|
+
*
|
|
29107
|
+
* So every consumer asking where a camera points was told "perfectly centred"
|
|
29108
|
+
* by four cameras that had never looked. That is D393 -- a measurement that
|
|
29109
|
+
* FAILED is `null`, never `0`, and the type says so all the way to the
|
|
29110
|
+
* decision -- the same shape as the unreadable `statfs` folded into "0 bytes of
|
|
29111
|
+
* headroom", which evacuated a healthy disk.
|
|
29112
|
+
*
|
|
29113
|
+
* D393 also says to check for a narrower structural TWIN of the result type.
|
|
29114
|
+
* There is one: `PtzStatusSchema` extends this, so the lie had already
|
|
29115
|
+
* propagated into `getStatus`, which is the surface `getPosition`'s own comment
|
|
29116
|
+
* tells callers to migrate to.
|
|
29117
|
+
*/
|
|
29051
29118
|
var PtzPositionSchema = object({
|
|
29052
|
-
pan: number(),
|
|
29053
|
-
tilt: number(),
|
|
29054
|
-
zoom: number()
|
|
29119
|
+
pan: number().nullable(),
|
|
29120
|
+
tilt: number().nullable(),
|
|
29121
|
+
zoom: number().nullable()
|
|
29055
29122
|
});
|
|
29056
29123
|
var PtzMoveCommandSchema = object({
|
|
29057
29124
|
pan: number().optional(),
|
|
@@ -29070,7 +29137,72 @@ var PtzOptionsSchema = object({
|
|
|
29070
29137
|
maxPresets: number().optional(),
|
|
29071
29138
|
/** Whether the camera exposes a controllable autofocus toggle
|
|
29072
29139
|
* (boolean `hasX` per the getOptions availability convention). */
|
|
29073
|
-
hasAutofocus: boolean()
|
|
29140
|
+
hasAutofocus: boolean(),
|
|
29141
|
+
/**
|
|
29142
|
+
* How many distinct speeds this camera's NATIVE scale offers.
|
|
29143
|
+
*
|
|
29144
|
+
* The cap's `speed` is normalized 0..1 and each provider maps it down --
|
|
29145
|
+
* Baichuan 1..63, Dahua 1..8, ISAPI's percentage -100..100. The normalized
|
|
29146
|
+
* value hides how coarse that really is: asking an amcrest for `0.37` is
|
|
29147
|
+
* meaningless, because it has eight steps and three of them round to the
|
|
29148
|
+
* same one. A loop that tunes its own gain has to know the granularity of
|
|
29149
|
+
* the knob it is turning.
|
|
29150
|
+
*
|
|
29151
|
+
* `null` = the driver does not know, or the scale is continuous (ONVIF takes
|
|
29152
|
+
* a float). Never a made-up number.
|
|
29153
|
+
*/
|
|
29154
|
+
speedSteps: number().int().positive().nullable(),
|
|
29155
|
+
/**
|
|
29156
|
+
* How long ONE `move` pulse runs on this driver, ms.
|
|
29157
|
+
*
|
|
29158
|
+
* `move` is a self-terminating burst everywhere, but every provider hardcoded
|
|
29159
|
+
* its own duration in private -- 200 reolink, 350 amcrest, 500 hikvision,
|
|
29160
|
+
* 1000 onvif -- so no caller could read it. It is the DENOMINATOR of "how far
|
|
29161
|
+
* did the head travel per pulse": without it a measured displacement has no
|
|
29162
|
+
* gain to be divided into.
|
|
29163
|
+
*
|
|
29164
|
+
* `null` = the driver cannot say.
|
|
29165
|
+
*/
|
|
29166
|
+
moveImpulseMs: number().int().positive().nullable()
|
|
29167
|
+
});
|
|
29168
|
+
/**
|
|
29169
|
+
* Which preset `goHome` goes to, and WHO decided.
|
|
29170
|
+
*
|
|
29171
|
+
* `goHome` used to be three vendor "conventions" written in three comments --
|
|
29172
|
+
* Reolink preset 0, Hikvision preset '1', Dahua preset 1 -- and on this fleet
|
|
29173
|
+
* not one of the three cameras honours its own:
|
|
29174
|
+
*
|
|
29175
|
+
* 592 Videocamera camera Daniel (reolink) preset 0 holds "stanza"
|
|
29176
|
+
* 1438 Videocamera dispensa (hikvision) preset 1 holds "Credenza"
|
|
29177
|
+
* 3836 Videocamera studio (amcrest) preset 1 holds "Preset1"
|
|
29178
|
+
*
|
|
29179
|
+
* So `goHome` meant "go wherever the operator happened to save in slot 0 or 1",
|
|
29180
|
+
* and two of the three swallowed the failure in a bare `catch`. For autotrack
|
|
29181
|
+
* this is the HOTTEST path -- it runs every time a subject is released -- so it
|
|
29182
|
+
* needs an answer that is true per camera and audible when it is missing.
|
|
29183
|
+
*
|
|
29184
|
+
* `source` is what makes it honest:
|
|
29185
|
+
* - `operator` -- picked in the UI, stored by the provider.
|
|
29186
|
+
* - `firmware` -- the camera itself named a preset `fn: 'home'` (Hikvision's
|
|
29187
|
+
* "Back to origin"), adopted as the default with nothing to configure.
|
|
29188
|
+
* - `native` -- the driver homes WITHOUT a preset at all. ONVIF does:
|
|
29189
|
+
* `goHome` is `ptzAbsoluteMove({x:0, y:0, zoom:0})`. `presetId` is null and
|
|
29190
|
+
* that is not a failure -- there is nothing to pick, and the UI must offer
|
|
29191
|
+
* no picker.
|
|
29192
|
+
* - `none` -- nothing is configured and the camera names nothing.
|
|
29193
|
+
* `goHome` REFUSES rather than moving the head somewhere arbitrary.
|
|
29194
|
+
*
|
|
29195
|
+
* `source === 'none'` is the refusal condition, NOT `presetId === null`: the
|
|
29196
|
+
* native case has no preset and homes perfectly well.
|
|
29197
|
+
*/
|
|
29198
|
+
var PtzHomePresetSchema = object({
|
|
29199
|
+
presetId: string().nullable(),
|
|
29200
|
+
source: _enum([
|
|
29201
|
+
"operator",
|
|
29202
|
+
"firmware",
|
|
29203
|
+
"native",
|
|
29204
|
+
"none"
|
|
29205
|
+
])
|
|
29074
29206
|
});
|
|
29075
29207
|
DeviceType.Camera, method(PtzMoveCommandSchema.extend({ deviceId: number() }), _void(), { kind: "mutation" }), method(PtzMoveCommandSchema.extend({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), array(PtzPresetSchema)), method(object({
|
|
29076
29208
|
deviceId: number(),
|
|
@@ -29088,7 +29220,22 @@ DeviceType.Camera, method(PtzMoveCommandSchema.extend({ deviceId: number() }), _
|
|
|
29088
29220
|
}), _void(), {
|
|
29089
29221
|
kind: "mutation",
|
|
29090
29222
|
auth: "admin"
|
|
29091
|
-
}), method(object({ deviceId: number() }), PtzOptionsSchema), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }),
|
|
29223
|
+
}), method(object({ deviceId: number() }), PtzOptionsSchema), method(object({ deviceId: number() }), _void(), { kind: "mutation" }), method(object({ deviceId: number() }), PtzHomePresetSchema), method(object({
|
|
29224
|
+
deviceId: number(),
|
|
29225
|
+
presetId: string().nullable()
|
|
29226
|
+
}), _void(), {
|
|
29227
|
+
kind: "mutation",
|
|
29228
|
+
auth: "admin"
|
|
29229
|
+
}), method(object({ deviceId: number() }), _void(), {
|
|
29230
|
+
kind: "mutation",
|
|
29231
|
+
auth: "admin"
|
|
29232
|
+
}), method(object({ deviceId: number() }), number().int().nullable()), method(object({
|
|
29233
|
+
deviceId: number(),
|
|
29234
|
+
seconds: number().int().min(0).max(3600)
|
|
29235
|
+
}), _void(), {
|
|
29236
|
+
kind: "mutation",
|
|
29237
|
+
auth: "admin"
|
|
29238
|
+
}), method(object({ deviceId: number() }), PtzPositionSchema), method(object({
|
|
29092
29239
|
deviceId: number(),
|
|
29093
29240
|
enabled: boolean()
|
|
29094
29241
|
}), _void(), { kind: "mutation" });
|
|
@@ -36091,6 +36238,12 @@ Object.freeze({
|
|
|
36091
36238
|
addonId: null,
|
|
36092
36239
|
access: "create"
|
|
36093
36240
|
},
|
|
36241
|
+
"ptz.captureHomeHere": {
|
|
36242
|
+
capName: "ptz",
|
|
36243
|
+
capScope: "device",
|
|
36244
|
+
addonId: null,
|
|
36245
|
+
access: "create"
|
|
36246
|
+
},
|
|
36094
36247
|
"ptz.continuousMove": {
|
|
36095
36248
|
capName: "ptz",
|
|
36096
36249
|
capScope: "device",
|
|
@@ -36103,6 +36256,18 @@ Object.freeze({
|
|
|
36103
36256
|
addonId: null,
|
|
36104
36257
|
access: "delete"
|
|
36105
36258
|
},
|
|
36259
|
+
"ptz.getHomePreset": {
|
|
36260
|
+
capName: "ptz",
|
|
36261
|
+
capScope: "device",
|
|
36262
|
+
addonId: null,
|
|
36263
|
+
access: "view"
|
|
36264
|
+
},
|
|
36265
|
+
"ptz.getHomeReturnSeconds": {
|
|
36266
|
+
capName: "ptz",
|
|
36267
|
+
capScope: "device",
|
|
36268
|
+
addonId: null,
|
|
36269
|
+
access: "view"
|
|
36270
|
+
},
|
|
36106
36271
|
"ptz.getOptions": {
|
|
36107
36272
|
capName: "ptz",
|
|
36108
36273
|
capScope: "device",
|
|
@@ -36151,6 +36316,18 @@ Object.freeze({
|
|
|
36151
36316
|
addonId: null,
|
|
36152
36317
|
access: "create"
|
|
36153
36318
|
},
|
|
36319
|
+
"ptz.setHomePreset": {
|
|
36320
|
+
capName: "ptz",
|
|
36321
|
+
capScope: "device",
|
|
36322
|
+
addonId: null,
|
|
36323
|
+
access: "create"
|
|
36324
|
+
},
|
|
36325
|
+
"ptz.setHomeReturnSeconds": {
|
|
36326
|
+
capName: "ptz",
|
|
36327
|
+
capScope: "device",
|
|
36328
|
+
addonId: null,
|
|
36329
|
+
access: "create"
|
|
36330
|
+
},
|
|
36154
36331
|
"ptz.stop": {
|
|
36155
36332
|
capName: "ptz",
|
|
36156
36333
|
capScope: "device",
|
|
@@ -39314,6 +39491,11 @@ Object.freeze({
|
|
|
39314
39491
|
form: "single",
|
|
39315
39492
|
optional: false
|
|
39316
39493
|
}],
|
|
39494
|
+
"ptz.captureHomeHere": [{
|
|
39495
|
+
name: "deviceId",
|
|
39496
|
+
form: "single",
|
|
39497
|
+
optional: false
|
|
39498
|
+
}],
|
|
39317
39499
|
"ptz.continuousMove": [{
|
|
39318
39500
|
name: "deviceId",
|
|
39319
39501
|
form: "single",
|
|
@@ -39324,6 +39506,16 @@ Object.freeze({
|
|
|
39324
39506
|
form: "single",
|
|
39325
39507
|
optional: false
|
|
39326
39508
|
}],
|
|
39509
|
+
"ptz.getHomePreset": [{
|
|
39510
|
+
name: "deviceId",
|
|
39511
|
+
form: "single",
|
|
39512
|
+
optional: false
|
|
39513
|
+
}],
|
|
39514
|
+
"ptz.getHomeReturnSeconds": [{
|
|
39515
|
+
name: "deviceId",
|
|
39516
|
+
form: "single",
|
|
39517
|
+
optional: false
|
|
39518
|
+
}],
|
|
39327
39519
|
"ptz.getOptions": [{
|
|
39328
39520
|
name: "deviceId",
|
|
39329
39521
|
form: "single",
|
|
@@ -39364,6 +39556,16 @@ Object.freeze({
|
|
|
39364
39556
|
form: "single",
|
|
39365
39557
|
optional: false
|
|
39366
39558
|
}],
|
|
39559
|
+
"ptz.setHomePreset": [{
|
|
39560
|
+
name: "deviceId",
|
|
39561
|
+
form: "single",
|
|
39562
|
+
optional: false
|
|
39563
|
+
}],
|
|
39564
|
+
"ptz.setHomeReturnSeconds": [{
|
|
39565
|
+
name: "deviceId",
|
|
39566
|
+
form: "single",
|
|
39567
|
+
optional: false
|
|
39568
|
+
}],
|
|
39367
39569
|
"ptz.stop": [{
|
|
39368
39570
|
name: "deviceId",
|
|
39369
39571
|
form: "single",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@camstack/addon-export-alexa",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.119",
|
|
4
4
|
"description": "Alexa Smart Home Skill export — hub-side OAuth provider + directive handler. The companion AWS Lambda forwards Alexa directives to this addon's /addon/export-alexa/directive endpoint.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"camstack",
|