@camstack/addon-provider-rademacher 0.2.71 → 0.2.72

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
@@ -7430,6 +7430,21 @@ var CameraStreamSchema = object({
7430
7430
  */
7431
7431
  autoEligible: boolean().optional(),
7432
7432
  /**
7433
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
7434
+ * whose only sensible role is the low-bandwidth one, `high` for a main
7435
+ * stream. Consulted by the broker's automatic ranking
7436
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
7437
+ * an operator's manual assignment still wins, and an absent hint is the
7438
+ * pixel-ranked default every camera had before this field existed.
7439
+ *
7440
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
7441
+ * storage class is written for on its own (`recordings` is high|mid,
7442
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
7443
+ * camera's single 720p relay is a `low` in every respect except the slot the
7444
+ * heuristic put it in.
7445
+ */
7446
+ profileHint: CamProfileSchema.optional(),
7447
+ /**
7433
7448
  * Transport-specific opaque metadata. The broker passes it through to
7434
7449
  * the source reader without inspecting it. Currently used by
7435
7450
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -8879,7 +8894,22 @@ var RecordingTriggersSchema = object({
8879
8894
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
8880
8895
  * registrare.
8881
8896
  */
8882
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
8897
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
8898
+ /**
8899
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
8900
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
8901
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
8902
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
8903
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
8904
+ *
8905
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
8906
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
8907
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
8908
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
8909
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
8910
+ * (`holdTrigger` / `releaseTrigger`).
8911
+ */
8912
+ deviceSignal: boolean().optional()
8883
8913
  });
8884
8914
  /**
8885
8915
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -12343,6 +12373,8 @@ method(object({
12343
12373
  label: string().optional(),
12344
12374
  deviceFeatures: array(string()).optional(),
12345
12375
  autoEligible: boolean().optional(),
12376
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
12377
+ profileHint: CamProfileSchema.optional(),
12346
12378
  metadata: record(string(), unknown()).optional(),
12347
12379
  /** Required when kind === 'derived' — the source camStreamId the
12348
12380
  * derived broker reads its encoded plane from.
@@ -30868,6 +30900,77 @@ method(object({
30868
30900
  auth: "protected"
30869
30901
  });
30870
30902
  /**
30903
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
30904
+ * something it knows about is happening (a robot vacuum cleaning, a machine
30905
+ * running, a gate open) and lowers when it stops.
30906
+ *
30907
+ * It is a level, not an edge. The sensor triggers the recorder already listens
30908
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
30909
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
30910
+ * still happening" cannot be expressed as an edge plus a post-buffer without
30911
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
30912
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
30913
+ * which records the dock for that long after every short one. So the recorder
30914
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
30915
+ * own post-buffer once it falls.
30916
+ *
30917
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
30918
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
30919
+ * writes this slice on every change; consumers subscribe to the kernel's
30920
+ * `DeviceStateChanged` for it and read it back through
30921
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
30922
+ * against the device (D224, D8/D11).
30923
+ *
30924
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
30925
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
30926
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
30927
+ * about the camera, on the camera.
30928
+ */
30929
+ var RecordingSignalStatusSchema = object({
30930
+ /** True while the device asks to be recorded. */
30931
+ active: boolean(),
30932
+ /**
30933
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
30934
+ * …). Free text for the log line and the UI badge; the recorder never
30935
+ * branches on it.
30936
+ */
30937
+ reason: string(),
30938
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
30939
+ lastChangedAt: number()
30940
+ });
30941
+ /** The runtime-state slice: the status plus the clock every slice carries. */
30942
+ var RecordingSignalRuntimeStateSchema = RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
30943
+ var recordingSignalCapability = {
30944
+ name: "recording-signal",
30945
+ scope: "device",
30946
+ deviceNative: true,
30947
+ mode: "singleton",
30948
+ deviceTypes: [DeviceType.Camera],
30949
+ methods: {
30950
+ /** The current level, straight from the slice the provider keeps fresh. */
30951
+ getStatus: method(object({ deviceId: number() }), RecordingSignalStatusSchema) },
30952
+ status: {
30953
+ schema: RecordingSignalStatusSchema,
30954
+ kind: "push",
30955
+ empty: {
30956
+ active: false,
30957
+ reason: "unknown",
30958
+ lastChangedAt: 0
30959
+ }
30960
+ },
30961
+ runtimeState: RecordingSignalRuntimeStateSchema,
30962
+ /**
30963
+ * Runtime-state durability: **session** — a restored `active: true` from
30964
+ * before a restart is exactly the stale level the recorder's reconcile bound
30965
+ * exists to end, and the provider re-derives the true level on activation
30966
+ * anyway. Nothing is lost by forgetting it; a lie is avoided.
30967
+ *
30968
+ * See `RuntimeStateDurability`. Enforced by
30969
+ * `scripts/check-runtime-state-durability.ts`.
30970
+ */
30971
+ durability: "session"
30972
+ };
30973
+ /**
30871
30974
  * scene-monitor — device-scoped reference-region state cap. An operator marks
30872
30975
  * a rect ROI on a camera frame and names one or more states; the engine
30873
30976
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -31365,6 +31468,8 @@ var CamStreamDescriptorSchema = object({
31365
31468
  deviceFeatures: array(string()).optional(),
31366
31469
  /** Eligible for automatic profile assignment. Absent = `true`. */
31367
31470
  autoEligible: boolean().optional(),
31471
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
31472
+ profileHint: CamProfileSchema.optional(),
31368
31473
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
31369
31474
  metadata: record(string(), unknown()).optional()
31370
31475
  });
@@ -33504,6 +33609,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33504
33609
  pressureSensor: pressureSensorCapability,
33505
33610
  privacyMask: privacyMaskCapability,
33506
33611
  ptzAutotrack: ptzAutotrackCapability,
33612
+ recordingSignal: recordingSignalCapability,
33507
33613
  sceneMonitor: sceneMonitorCapability,
33508
33614
  scriptRunner: scriptRunnerCapability,
33509
33615
  smoke: smokeCapability,
@@ -39251,6 +39357,12 @@ Object.freeze({
39251
39357
  addonId: null,
39252
39358
  access: "view"
39253
39359
  },
39360
+ "recordingSignal.getStatus": {
39361
+ capName: "recording-signal",
39362
+ capScope: "device",
39363
+ addonId: null,
39364
+ access: "view"
39365
+ },
39254
39366
  "sceneMonitor.captureReference": {
39255
39367
  capName: "scene-monitor",
39256
39368
  capScope: "device",
@@ -42243,6 +42355,11 @@ Object.freeze({
42243
42355
  form: "single",
42244
42356
  optional: true
42245
42357
  }],
42358
+ "recordingSignal.getStatus": [{
42359
+ name: "deviceId",
42360
+ form: "single",
42361
+ optional: false
42362
+ }],
42246
42363
  "sceneMonitor.captureReference": [{
42247
42364
  name: "deviceId",
42248
42365
  form: "single",
package/dist/addon.mjs CHANGED
@@ -7429,6 +7429,21 @@ var CameraStreamSchema = object({
7429
7429
  */
7430
7430
  autoEligible: boolean().optional(),
7431
7431
  /**
7432
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
7433
+ * whose only sensible role is the low-bandwidth one, `high` for a main
7434
+ * stream. Consulted by the broker's automatic ranking
7435
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
7436
+ * an operator's manual assignment still wins, and an absent hint is the
7437
+ * pixel-ranked default every camera had before this field existed.
7438
+ *
7439
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
7440
+ * storage class is written for on its own (`recordings` is high|mid,
7441
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
7442
+ * camera's single 720p relay is a `low` in every respect except the slot the
7443
+ * heuristic put it in.
7444
+ */
7445
+ profileHint: CamProfileSchema.optional(),
7446
+ /**
7432
7447
  * Transport-specific opaque metadata. The broker passes it through to
7433
7448
  * the source reader without inspecting it. Currently used by
7434
7449
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -8878,7 +8893,22 @@ var RecordingTriggersSchema = object({
8878
8893
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
8879
8894
  * registrare.
8880
8895
  */
8881
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
8896
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
8897
+ /**
8898
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
8899
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
8900
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
8901
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
8902
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
8903
+ *
8904
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
8905
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
8906
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
8907
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
8908
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
8909
+ * (`holdTrigger` / `releaseTrigger`).
8910
+ */
8911
+ deviceSignal: boolean().optional()
8882
8912
  });
8883
8913
  /**
8884
8914
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -12342,6 +12372,8 @@ method(object({
12342
12372
  label: string().optional(),
12343
12373
  deviceFeatures: array(string()).optional(),
12344
12374
  autoEligible: boolean().optional(),
12375
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
12376
+ profileHint: CamProfileSchema.optional(),
12345
12377
  metadata: record(string(), unknown()).optional(),
12346
12378
  /** Required when kind === 'derived' — the source camStreamId the
12347
12379
  * derived broker reads its encoded plane from.
@@ -30867,6 +30899,77 @@ method(object({
30867
30899
  auth: "protected"
30868
30900
  });
30869
30901
  /**
30902
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
30903
+ * something it knows about is happening (a robot vacuum cleaning, a machine
30904
+ * running, a gate open) and lowers when it stops.
30905
+ *
30906
+ * It is a level, not an edge. The sensor triggers the recorder already listens
30907
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
30908
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
30909
+ * still happening" cannot be expressed as an edge plus a post-buffer without
30910
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
30911
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
30912
+ * which records the dock for that long after every short one. So the recorder
30913
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
30914
+ * own post-buffer once it falls.
30915
+ *
30916
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
30917
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
30918
+ * writes this slice on every change; consumers subscribe to the kernel's
30919
+ * `DeviceStateChanged` for it and read it back through
30920
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
30921
+ * against the device (D224, D8/D11).
30922
+ *
30923
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
30924
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
30925
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
30926
+ * about the camera, on the camera.
30927
+ */
30928
+ var RecordingSignalStatusSchema = object({
30929
+ /** True while the device asks to be recorded. */
30930
+ active: boolean(),
30931
+ /**
30932
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
30933
+ * …). Free text for the log line and the UI badge; the recorder never
30934
+ * branches on it.
30935
+ */
30936
+ reason: string(),
30937
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
30938
+ lastChangedAt: number()
30939
+ });
30940
+ /** The runtime-state slice: the status plus the clock every slice carries. */
30941
+ var RecordingSignalRuntimeStateSchema = RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
30942
+ var recordingSignalCapability = {
30943
+ name: "recording-signal",
30944
+ scope: "device",
30945
+ deviceNative: true,
30946
+ mode: "singleton",
30947
+ deviceTypes: [DeviceType.Camera],
30948
+ methods: {
30949
+ /** The current level, straight from the slice the provider keeps fresh. */
30950
+ getStatus: method(object({ deviceId: number() }), RecordingSignalStatusSchema) },
30951
+ status: {
30952
+ schema: RecordingSignalStatusSchema,
30953
+ kind: "push",
30954
+ empty: {
30955
+ active: false,
30956
+ reason: "unknown",
30957
+ lastChangedAt: 0
30958
+ }
30959
+ },
30960
+ runtimeState: RecordingSignalRuntimeStateSchema,
30961
+ /**
30962
+ * Runtime-state durability: **session** — a restored `active: true` from
30963
+ * before a restart is exactly the stale level the recorder's reconcile bound
30964
+ * exists to end, and the provider re-derives the true level on activation
30965
+ * anyway. Nothing is lost by forgetting it; a lie is avoided.
30966
+ *
30967
+ * See `RuntimeStateDurability`. Enforced by
30968
+ * `scripts/check-runtime-state-durability.ts`.
30969
+ */
30970
+ durability: "session"
30971
+ };
30972
+ /**
30870
30973
  * scene-monitor — device-scoped reference-region state cap. An operator marks
30871
30974
  * a rect ROI on a camera frame and names one or more states; the engine
30872
30975
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -31364,6 +31467,8 @@ var CamStreamDescriptorSchema = object({
31364
31467
  deviceFeatures: array(string()).optional(),
31365
31468
  /** Eligible for automatic profile assignment. Absent = `true`. */
31366
31469
  autoEligible: boolean().optional(),
31470
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
31471
+ profileHint: CamProfileSchema.optional(),
31367
31472
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
31368
31473
  metadata: record(string(), unknown()).optional()
31369
31474
  });
@@ -33503,6 +33608,7 @@ var DEVICE_LOCAL_STATE_CAPS = {
33503
33608
  pressureSensor: pressureSensorCapability,
33504
33609
  privacyMask: privacyMaskCapability,
33505
33610
  ptzAutotrack: ptzAutotrackCapability,
33611
+ recordingSignal: recordingSignalCapability,
33506
33612
  sceneMonitor: sceneMonitorCapability,
33507
33613
  scriptRunner: scriptRunnerCapability,
33508
33614
  smoke: smokeCapability,
@@ -39250,6 +39356,12 @@ Object.freeze({
39250
39356
  addonId: null,
39251
39357
  access: "view"
39252
39358
  },
39359
+ "recordingSignal.getStatus": {
39360
+ capName: "recording-signal",
39361
+ capScope: "device",
39362
+ addonId: null,
39363
+ access: "view"
39364
+ },
39253
39365
  "sceneMonitor.captureReference": {
39254
39366
  capName: "scene-monitor",
39255
39367
  capScope: "device",
@@ -42242,6 +42354,11 @@ Object.freeze({
42242
42354
  form: "single",
42243
42355
  optional: true
42244
42356
  }],
42357
+ "recordingSignal.getStatus": [{
42358
+ name: "deviceId",
42359
+ form: "single",
42360
+ optional: false
42361
+ }],
42245
42362
  "sceneMonitor.captureReference": [{
42246
42363
  name: "deviceId",
42247
42364
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-provider-rademacher",
3
- "version": "0.2.71",
3
+ "version": "0.2.72",
4
4
  "description": "Rademacher HomePilot device-provider addon for CamStack — wraps the @apocaliss92/noderademacher local-hub client (roller shutters over the cover cap)",
5
5
  "keywords": [
6
6
  "camstack",