@camstack/addon-provider-reolink 1.2.95 → 1.2.96

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/addon.js CHANGED
@@ -6472,6 +6472,21 @@ var CameraStreamSchema = object({
6472
6472
  */
6473
6473
  autoEligible: boolean().optional(),
6474
6474
  /**
6475
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
6476
+ * whose only sensible role is the low-bandwidth one, `high` for a main
6477
+ * stream. Consulted by the broker's automatic ranking
6478
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
6479
+ * an operator's manual assignment still wins, and an absent hint is the
6480
+ * pixel-ranked default every camera had before this field existed.
6481
+ *
6482
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
6483
+ * storage class is written for on its own (`recordings` is high|mid,
6484
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
6485
+ * camera's single 720p relay is a `low` in every respect except the slot the
6486
+ * heuristic put it in.
6487
+ */
6488
+ profileHint: CamProfileSchema.optional(),
6489
+ /**
6475
6490
  * Transport-specific opaque metadata. The broker passes it through to
6476
6491
  * the source reader without inspecting it. Currently used by
6477
6492
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -8184,7 +8199,22 @@ var RecordingTriggersSchema = object({
8184
8199
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
8185
8200
  * registrare.
8186
8201
  */
8187
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
8202
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
8203
+ /**
8204
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
8205
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
8206
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
8207
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
8208
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
8209
+ *
8210
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
8211
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
8212
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
8213
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
8214
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
8215
+ * (`holdTrigger` / `releaseTrigger`).
8216
+ */
8217
+ deviceSignal: boolean().optional()
8188
8218
  });
8189
8219
  /**
8190
8220
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -11929,6 +11959,8 @@ method(object({
11929
11959
  label: string().optional(),
11930
11960
  deviceFeatures: array(string()).optional(),
11931
11961
  autoEligible: boolean().optional(),
11962
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
11963
+ profileHint: CamProfileSchema.optional(),
11932
11964
  metadata: record(string(), unknown()).optional(),
11933
11965
  /** Required when kind === 'derived' — the source camStreamId the
11934
11966
  * derived broker reads its encoded plane from.
@@ -30739,6 +30771,77 @@ method(object({
30739
30771
  auth: "protected"
30740
30772
  });
30741
30773
  /**
30774
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
30775
+ * something it knows about is happening (a robot vacuum cleaning, a machine
30776
+ * running, a gate open) and lowers when it stops.
30777
+ *
30778
+ * It is a level, not an edge. The sensor triggers the recorder already listens
30779
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
30780
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
30781
+ * still happening" cannot be expressed as an edge plus a post-buffer without
30782
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
30783
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
30784
+ * which records the dock for that long after every short one. So the recorder
30785
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
30786
+ * own post-buffer once it falls.
30787
+ *
30788
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
30789
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
30790
+ * writes this slice on every change; consumers subscribe to the kernel's
30791
+ * `DeviceStateChanged` for it and read it back through
30792
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
30793
+ * against the device (D224, D8/D11).
30794
+ *
30795
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
30796
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
30797
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
30798
+ * about the camera, on the camera.
30799
+ */
30800
+ var RecordingSignalStatusSchema = object({
30801
+ /** True while the device asks to be recorded. */
30802
+ active: boolean(),
30803
+ /**
30804
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
30805
+ * …). Free text for the log line and the UI badge; the recorder never
30806
+ * branches on it.
30807
+ */
30808
+ reason: string(),
30809
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
30810
+ lastChangedAt: number()
30811
+ });
30812
+ /** The runtime-state slice: the status plus the clock every slice carries. */
30813
+ var RecordingSignalRuntimeStateSchema = RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
30814
+ var recordingSignalCapability = {
30815
+ name: "recording-signal",
30816
+ scope: "device",
30817
+ deviceNative: true,
30818
+ mode: "singleton",
30819
+ deviceTypes: [DeviceType.Camera],
30820
+ methods: {
30821
+ /** The current level, straight from the slice the provider keeps fresh. */
30822
+ getStatus: method(object({ deviceId: number() }), RecordingSignalStatusSchema) },
30823
+ status: {
30824
+ schema: RecordingSignalStatusSchema,
30825
+ kind: "push",
30826
+ empty: {
30827
+ active: false,
30828
+ reason: "unknown",
30829
+ lastChangedAt: 0
30830
+ }
30831
+ },
30832
+ runtimeState: RecordingSignalRuntimeStateSchema,
30833
+ /**
30834
+ * Runtime-state durability: **session** — a restored `active: true` from
30835
+ * before a restart is exactly the stale level the recorder's reconcile bound
30836
+ * exists to end, and the provider re-derives the true level on activation
30837
+ * anyway. Nothing is lost by forgetting it; a lie is avoided.
30838
+ *
30839
+ * See `RuntimeStateDurability`. Enforced by
30840
+ * `scripts/check-runtime-state-durability.ts`.
30841
+ */
30842
+ durability: "session"
30843
+ };
30844
+ /**
30742
30845
  * scene-monitor — device-scoped reference-region state cap. An operator marks
30743
30846
  * a rect ROI on a camera frame and names one or more states; the engine
30744
30847
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -31236,6 +31339,8 @@ var CamStreamDescriptorSchema = object({
31236
31339
  deviceFeatures: array(string()).optional(),
31237
31340
  /** Eligible for automatic profile assignment. Absent = `true`. */
31238
31341
  autoEligible: boolean().optional(),
31342
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
31343
+ profileHint: CamProfileSchema.optional(),
31239
31344
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
31240
31345
  metadata: record(string(), unknown()).optional()
31241
31346
  });
@@ -33588,6 +33693,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33588
33693
  pressureSensor: pressureSensorCapability,
33589
33694
  privacyMask: privacyMaskCapability,
33590
33695
  ptzAutotrack: ptzAutotrackCapability,
33696
+ recordingSignal: recordingSignalCapability,
33591
33697
  sceneMonitor: sceneMonitorCapability,
33592
33698
  scriptRunner: scriptRunnerCapability,
33593
33699
  smoke: smokeCapability,
@@ -39498,6 +39604,12 @@ Object.freeze({
39498
39604
  addonId: null,
39499
39605
  access: "view"
39500
39606
  },
39607
+ "recordingSignal.getStatus": {
39608
+ capName: "recording-signal",
39609
+ capScope: "device",
39610
+ addonId: null,
39611
+ access: "view"
39612
+ },
39501
39613
  "sceneMonitor.captureReference": {
39502
39614
  capName: "scene-monitor",
39503
39615
  capScope: "device",
@@ -42490,6 +42602,11 @@ Object.freeze({
42490
42602
  form: "single",
42491
42603
  optional: true
42492
42604
  }],
42605
+ "recordingSignal.getStatus": [{
42606
+ name: "deviceId",
42607
+ form: "single",
42608
+ optional: false
42609
+ }],
42493
42610
  "sceneMonitor.captureReference": [{
42494
42611
  name: "deviceId",
42495
42612
  form: "single",
package/dist/addon.mjs CHANGED
@@ -6467,6 +6467,21 @@ var CameraStreamSchema = object({
6467
6467
  */
6468
6468
  autoEligible: boolean().optional(),
6469
6469
  /**
6470
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
6471
+ * whose only sensible role is the low-bandwidth one, `high` for a main
6472
+ * stream. Consulted by the broker's automatic ranking
6473
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
6474
+ * an operator's manual assignment still wins, and an absent hint is the
6475
+ * pixel-ranked default every camera had before this field existed.
6476
+ *
6477
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
6478
+ * storage class is written for on its own (`recordings` is high|mid,
6479
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
6480
+ * camera's single 720p relay is a `low` in every respect except the slot the
6481
+ * heuristic put it in.
6482
+ */
6483
+ profileHint: CamProfileSchema.optional(),
6484
+ /**
6470
6485
  * Transport-specific opaque metadata. The broker passes it through to
6471
6486
  * the source reader without inspecting it. Currently used by
6472
6487
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -8179,7 +8194,22 @@ var RecordingTriggersSchema = object({
8179
8194
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
8180
8195
  * registrare.
8181
8196
  */
8182
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
8197
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
8198
+ /**
8199
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
8200
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
8201
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
8202
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
8203
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
8204
+ *
8205
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
8206
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
8207
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
8208
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
8209
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
8210
+ * (`holdTrigger` / `releaseTrigger`).
8211
+ */
8212
+ deviceSignal: boolean().optional()
8183
8213
  });
8184
8214
  /**
8185
8215
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -11924,6 +11954,8 @@ method(object({
11924
11954
  label: string().optional(),
11925
11955
  deviceFeatures: array(string()).optional(),
11926
11956
  autoEligible: boolean().optional(),
11957
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
11958
+ profileHint: CamProfileSchema.optional(),
11927
11959
  metadata: record(string(), unknown()).optional(),
11928
11960
  /** Required when kind === 'derived' — the source camStreamId the
11929
11961
  * derived broker reads its encoded plane from.
@@ -30734,6 +30766,77 @@ method(object({
30734
30766
  auth: "protected"
30735
30767
  });
30736
30768
  /**
30769
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
30770
+ * something it knows about is happening (a robot vacuum cleaning, a machine
30771
+ * running, a gate open) and lowers when it stops.
30772
+ *
30773
+ * It is a level, not an edge. The sensor triggers the recorder already listens
30774
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
30775
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
30776
+ * still happening" cannot be expressed as an edge plus a post-buffer without
30777
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
30778
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
30779
+ * which records the dock for that long after every short one. So the recorder
30780
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
30781
+ * own post-buffer once it falls.
30782
+ *
30783
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
30784
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
30785
+ * writes this slice on every change; consumers subscribe to the kernel's
30786
+ * `DeviceStateChanged` for it and read it back through
30787
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
30788
+ * against the device (D224, D8/D11).
30789
+ *
30790
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
30791
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
30792
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
30793
+ * about the camera, on the camera.
30794
+ */
30795
+ var RecordingSignalStatusSchema = object({
30796
+ /** True while the device asks to be recorded. */
30797
+ active: boolean(),
30798
+ /**
30799
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
30800
+ * …). Free text for the log line and the UI badge; the recorder never
30801
+ * branches on it.
30802
+ */
30803
+ reason: string(),
30804
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
30805
+ lastChangedAt: number()
30806
+ });
30807
+ /** The runtime-state slice: the status plus the clock every slice carries. */
30808
+ var RecordingSignalRuntimeStateSchema = RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
30809
+ var recordingSignalCapability = {
30810
+ name: "recording-signal",
30811
+ scope: "device",
30812
+ deviceNative: true,
30813
+ mode: "singleton",
30814
+ deviceTypes: [DeviceType.Camera],
30815
+ methods: {
30816
+ /** The current level, straight from the slice the provider keeps fresh. */
30817
+ getStatus: method(object({ deviceId: number() }), RecordingSignalStatusSchema) },
30818
+ status: {
30819
+ schema: RecordingSignalStatusSchema,
30820
+ kind: "push",
30821
+ empty: {
30822
+ active: false,
30823
+ reason: "unknown",
30824
+ lastChangedAt: 0
30825
+ }
30826
+ },
30827
+ runtimeState: RecordingSignalRuntimeStateSchema,
30828
+ /**
30829
+ * Runtime-state durability: **session** — a restored `active: true` from
30830
+ * before a restart is exactly the stale level the recorder's reconcile bound
30831
+ * exists to end, and the provider re-derives the true level on activation
30832
+ * anyway. Nothing is lost by forgetting it; a lie is avoided.
30833
+ *
30834
+ * See `RuntimeStateDurability`. Enforced by
30835
+ * `scripts/check-runtime-state-durability.ts`.
30836
+ */
30837
+ durability: "session"
30838
+ };
30839
+ /**
30737
30840
  * scene-monitor — device-scoped reference-region state cap. An operator marks
30738
30841
  * a rect ROI on a camera frame and names one or more states; the engine
30739
30842
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -31231,6 +31334,8 @@ var CamStreamDescriptorSchema = object({
31231
31334
  deviceFeatures: array(string()).optional(),
31232
31335
  /** Eligible for automatic profile assignment. Absent = `true`. */
31233
31336
  autoEligible: boolean().optional(),
31337
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
31338
+ profileHint: CamProfileSchema.optional(),
31234
31339
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
31235
31340
  metadata: record(string(), unknown()).optional()
31236
31341
  });
@@ -33583,6 +33688,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33583
33688
  pressureSensor: pressureSensorCapability,
33584
33689
  privacyMask: privacyMaskCapability,
33585
33690
  ptzAutotrack: ptzAutotrackCapability,
33691
+ recordingSignal: recordingSignalCapability,
33586
33692
  sceneMonitor: sceneMonitorCapability,
33587
33693
  scriptRunner: scriptRunnerCapability,
33588
33694
  smoke: smokeCapability,
@@ -39493,6 +39599,12 @@ Object.freeze({
39493
39599
  addonId: null,
39494
39600
  access: "view"
39495
39601
  },
39602
+ "recordingSignal.getStatus": {
39603
+ capName: "recording-signal",
39604
+ capScope: "device",
39605
+ addonId: null,
39606
+ access: "view"
39607
+ },
39496
39608
  "sceneMonitor.captureReference": {
39497
39609
  capName: "scene-monitor",
39498
39610
  capScope: "device",
@@ -42485,6 +42597,11 @@ Object.freeze({
42485
42597
  form: "single",
42486
42598
  optional: true
42487
42599
  }],
42600
+ "recordingSignal.getStatus": [{
42601
+ name: "deviceId",
42602
+ form: "single",
42603
+ optional: false
42604
+ }],
42488
42605
  "sceneMonitor.captureReference": [{
42489
42606
  name: "deviceId",
42490
42607
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-reolink",
3
- "version": "1.2.95",
3
+ "version": "1.2.96",
4
4
  "description": "Reolink camera device provider addon for CamStack — native Baichuan protocol",
5
5
  "keywords": [
6
6
  "camstack",