@camstack/addon-mqtt-broker 1.2.71 → 1.2.73

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.
@@ -5451,6 +5451,12 @@ Object.fromEntries([
5451
5451
  icon: "move",
5452
5452
  order: 40
5453
5453
  },
5454
+ {
5455
+ id: "navigation",
5456
+ label: "Navigation",
5457
+ icon: "compass",
5458
+ order: 41
5459
+ },
5454
5460
  {
5455
5461
  id: "consumables",
5456
5462
  label: "Consumables",
@@ -6484,6 +6490,21 @@ var CameraStreamSchema = object({
6484
6490
  */
6485
6491
  autoEligible: boolean().optional(),
6486
6492
  /**
6493
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
6494
+ * whose only sensible role is the low-bandwidth one, `high` for a main
6495
+ * stream. Consulted by the broker's automatic ranking
6496
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
6497
+ * an operator's manual assignment still wins, and an absent hint is the
6498
+ * pixel-ranked default every camera had before this field existed.
6499
+ *
6500
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
6501
+ * storage class is written for on its own (`recordings` is high|mid,
6502
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
6503
+ * camera's single 720p relay is a `low` in every respect except the slot the
6504
+ * heuristic put it in.
6505
+ */
6506
+ profileHint: CamProfileSchema.optional(),
6507
+ /**
6487
6508
  * Transport-specific opaque metadata. The broker passes it through to
6488
6509
  * the source reader without inspecting it. Currently used by
6489
6510
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -7917,7 +7938,22 @@ var RecordingTriggersSchema = object({
7917
7938
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
7918
7939
  * registrare.
7919
7940
  */
7920
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
7941
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
7942
+ /**
7943
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
7944
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
7945
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
7946
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
7947
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
7948
+ *
7949
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
7950
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
7951
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
7952
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
7953
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
7954
+ * (`holdTrigger` / `releaseTrigger`).
7955
+ */
7956
+ deviceSignal: boolean().optional()
7921
7957
  });
7922
7958
  /**
7923
7959
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -11430,6 +11466,8 @@ method(object({
11430
11466
  label: string().optional(),
11431
11467
  deviceFeatures: array(string()).optional(),
11432
11468
  autoEligible: boolean().optional(),
11469
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
11470
+ profileHint: CamProfileSchema.optional(),
11433
11471
  metadata: record(string(), unknown()).optional(),
11434
11472
  /** Required when kind === 'derived' — the source camStreamId the
11435
11473
  * derived broker reads its encoded plane from.
@@ -27758,6 +27796,47 @@ method(object({
27758
27796
  auth: "protected"
27759
27797
  });
27760
27798
  /**
27799
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
27800
+ * something it knows about is happening (a robot vacuum cleaning, a machine
27801
+ * running, a gate open) and lowers when it stops.
27802
+ *
27803
+ * It is a level, not an edge. The sensor triggers the recorder already listens
27804
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
27805
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
27806
+ * still happening" cannot be expressed as an edge plus a post-buffer without
27807
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
27808
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
27809
+ * which records the dock for that long after every short one. So the recorder
27810
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
27811
+ * own post-buffer once it falls.
27812
+ *
27813
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
27814
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
27815
+ * writes this slice on every change; consumers subscribe to the kernel's
27816
+ * `DeviceStateChanged` for it and read it back through
27817
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
27818
+ * against the device (D224, D8/D11).
27819
+ *
27820
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
27821
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
27822
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
27823
+ * about the camera, on the camera.
27824
+ */
27825
+ var RecordingSignalStatusSchema = object({
27826
+ /** True while the device asks to be recorded. */
27827
+ active: boolean(),
27828
+ /**
27829
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
27830
+ * …). Free text for the log line and the UI badge; the recorder never
27831
+ * branches on it.
27832
+ */
27833
+ reason: string(),
27834
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
27835
+ lastChangedAt: number()
27836
+ });
27837
+ RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
27838
+ DeviceType.Camera, method(object({ deviceId: number() }), RecordingSignalStatusSchema);
27839
+ /**
27761
27840
  * scene-monitor — device-scoped reference-region state cap. An operator marks
27762
27841
  * a rect ROI on a camera frame and names one or more states; the engine
27763
27842
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -28130,6 +28209,8 @@ var CamStreamDescriptorSchema = object({
28130
28209
  deviceFeatures: array(string()).optional(),
28131
28210
  /** Eligible for automatic profile assignment. Absent = `true`. */
28132
28211
  autoEligible: boolean().optional(),
28212
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
28213
+ profileHint: CamProfileSchema.optional(),
28133
28214
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
28134
28215
  metadata: record(string(), unknown()).optional()
28135
28216
  });
@@ -34075,6 +34156,12 @@ Object.freeze({
34075
34156
  addonId: null,
34076
34157
  access: "view"
34077
34158
  },
34159
+ "recordingSignal.getStatus": {
34160
+ capName: "recording-signal",
34161
+ capScope: "device",
34162
+ addonId: null,
34163
+ access: "view"
34164
+ },
34078
34165
  "sceneMonitor.captureReference": {
34079
34166
  capName: "scene-monitor",
34080
34167
  capScope: "device",
@@ -37067,6 +37154,11 @@ Object.freeze({
37067
37154
  form: "single",
37068
37155
  optional: true
37069
37156
  }],
37157
+ "recordingSignal.getStatus": [{
37158
+ name: "deviceId",
37159
+ form: "single",
37160
+ optional: false
37161
+ }],
37070
37162
  "sceneMonitor.captureReference": [{
37071
37163
  name: "deviceId",
37072
37164
  form: "single",
@@ -5446,6 +5446,12 @@ Object.fromEntries([
5446
5446
  icon: "move",
5447
5447
  order: 40
5448
5448
  },
5449
+ {
5450
+ id: "navigation",
5451
+ label: "Navigation",
5452
+ icon: "compass",
5453
+ order: 41
5454
+ },
5449
5455
  {
5450
5456
  id: "consumables",
5451
5457
  label: "Consumables",
@@ -6479,6 +6485,21 @@ var CameraStreamSchema = object({
6479
6485
  */
6480
6486
  autoEligible: boolean().optional(),
6481
6487
  /**
6488
+ * The profile slot the PUBLISHER says this stream is: `low` for a stream
6489
+ * whose only sensible role is the low-bandwidth one, `high` for a main
6490
+ * stream. Consulted by the broker's automatic ranking
6491
+ * (`rankInitialAssignment`) BEFORE the pixel-count heuristic, and only there:
6492
+ * an operator's manual assignment still wins, and an absent hint is the
6493
+ * pixel-ranked default every camera had before this field existed.
6494
+ *
6495
+ * Why it exists: a camera with ONE stream ranked to `mid` — the slot no
6496
+ * storage class is written for on its own (`recordings` is high|mid,
6497
+ * `recordingsLow` is low) and the one profile scrub does not read. The robot
6498
+ * camera's single 720p relay is a `low` in every respect except the slot the
6499
+ * heuristic put it in.
6500
+ */
6501
+ profileHint: CamProfileSchema.optional(),
6502
+ /**
6482
6503
  * Transport-specific opaque metadata. The broker passes it through to
6483
6504
  * the source reader without inspecting it. Currently used by
6484
6505
  * `pull-rfc4571` streams to carry the upstream SDP (so the reader can
@@ -7912,7 +7933,22 @@ var RecordingTriggersSchema = object({
7912
7933
  * il livello: un contatto trovato già aperto al riavvio del runner non fa
7913
7934
  * registrare.
7914
7935
  */
7915
- sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional()
7936
+ sensorDeviceIds: array(number().int().positive()).min(1).max(16).refine(noDuplicates, { message: "sensorDeviceIds must not repeat a device" }).optional(),
7937
+ /**
7938
+ * La camera registra per tutta la durata del SEGNALE che lei stessa
7939
+ * pubblica — la cap `recording-signal` (`active: true` mentre il device è in
7940
+ * funzione: un robot che pulisce). È un LIVELLO, non un fronte: la finestra
7941
+ * resta aperta finché il segnale è alto e si chiude `postBufferSec` dopo la
7942
+ * caduta, così una pulizia di quaranta minuti è UNA clip.
7943
+ *
7944
+ * Non nomina un device: il segnale è della camera stessa, tenuto fresco dal
7945
+ * suo provider (D224); il recorder lo ascolta su `DeviceStateChanged` e lo
7946
+ * riconcilia leggendo la slice via RPC, con un tetto oltre il quale un
7947
+ * segnale mai abbassato (un evento perso) non può tenere aperta una
7948
+ * registrazione (D11). Vedi `recorder/addon/band-decision.ts`
7949
+ * (`holdTrigger` / `releaseTrigger`).
7950
+ */
7951
+ deviceSignal: boolean().optional()
7916
7952
  });
7917
7953
  /**
7918
7954
  * Mode of a single recording band — the recorder per-band vocabulary.
@@ -11425,6 +11461,8 @@ method(object({
11425
11461
  label: string().optional(),
11426
11462
  deviceFeatures: array(string()).optional(),
11427
11463
  autoEligible: boolean().optional(),
11464
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
11465
+ profileHint: CamProfileSchema.optional(),
11428
11466
  metadata: record(string(), unknown()).optional(),
11429
11467
  /** Required when kind === 'derived' — the source camStreamId the
11430
11468
  * derived broker reads its encoded plane from.
@@ -27753,6 +27791,47 @@ method(object({
27753
27791
  auth: "protected"
27754
27792
  });
27755
27793
  /**
27794
+ * A camera's own "record me NOW" LEVEL — a signal the device raises while
27795
+ * something it knows about is happening (a robot vacuum cleaning, a machine
27796
+ * running, a gate open) and lowers when it stops.
27797
+ *
27798
+ * It is a level, not an edge. The sensor triggers the recorder already listens
27799
+ * to (`SOURCE_CAP_ACTIVE_FIELD`) fire on a rising edge and record for a fixed
27800
+ * post-buffer; a cleaning lasts forty minutes, and forty minutes of "this is
27801
+ * still happening" cannot be expressed as an edge plus a post-buffer without
27802
+ * either re-triggering on a timer (polling — D224 forbids the consumer keeping
27803
+ * the fact fresh) or picking a post-buffer long enough to cover every job,
27804
+ * which records the dock for that long after every short one. So the recorder
27805
+ * reads the LEVEL: it records for as long as `active` is true, plus the band's
27806
+ * own post-buffer once it falls.
27807
+ *
27808
+ * Who owns the fact: the PROVIDER of the device, which already reads the state
27809
+ * the signal is derived from (the vacuum's lifecycle state, for Dreame). It
27810
+ * writes this slice on every change; consumers subscribe to the kernel's
27811
+ * `DeviceStateChanged` for it and read it back through
27812
+ * `deviceState.getCapSlice` to reconcile — never a second copy, never a poll
27813
+ * against the device (D224, D8/D11).
27814
+ *
27815
+ * Deliberately NOT a `binary` sensor on the camera: a binary sensor is exported
27816
+ * to Home Assistant, HomeKit and the sensor picker as a thing an operator can
27817
+ * bind, and "the camera wants to record" is not a room sensor. It is a fact
27818
+ * about the camera, on the camera.
27819
+ */
27820
+ var RecordingSignalStatusSchema = object({
27821
+ /** True while the device asks to be recorded. */
27822
+ active: boolean(),
27823
+ /**
27824
+ * Why, in the provider's own vocabulary (a vacuum's `cleaning` / `docked`,
27825
+ * …). Free text for the log line and the UI badge; the recorder never
27826
+ * branches on it.
27827
+ */
27828
+ reason: string(),
27829
+ /** Ms epoch of the last `active` transition. 0 if never observed. */
27830
+ lastChangedAt: number()
27831
+ });
27832
+ RecordingSignalStatusSchema.extend({ lastFetchedAt: number() });
27833
+ DeviceType.Camera, method(object({ deviceId: number() }), RecordingSignalStatusSchema);
27834
+ /**
27756
27835
  * scene-monitor — device-scoped reference-region state cap. An operator marks
27757
27836
  * a rect ROI on a camera frame and names one or more states; the engine
27758
27837
  * (pipeline-analytics, designated post-processing node) reports which state is
@@ -28125,6 +28204,8 @@ var CamStreamDescriptorSchema = object({
28125
28204
  deviceFeatures: array(string()).optional(),
28126
28205
  /** Eligible for automatic profile assignment. Absent = `true`. */
28127
28206
  autoEligible: boolean().optional(),
28207
+ /** The slot the publisher says this stream IS — see `CameraStreamSchema.profileHint`. */
28208
+ profileHint: CamProfileSchema.optional(),
28128
28209
  /** Transport-specific opaque metadata (e.g. rfc4571 SDP). */
28129
28210
  metadata: record(string(), unknown()).optional()
28130
28211
  });
@@ -34070,6 +34151,12 @@ Object.freeze({
34070
34151
  addonId: null,
34071
34152
  access: "view"
34072
34153
  },
34154
+ "recordingSignal.getStatus": {
34155
+ capName: "recording-signal",
34156
+ capScope: "device",
34157
+ addonId: null,
34158
+ access: "view"
34159
+ },
34073
34160
  "sceneMonitor.captureReference": {
34074
34161
  capName: "scene-monitor",
34075
34162
  capScope: "device",
@@ -37062,6 +37149,11 @@ Object.freeze({
37062
37149
  form: "single",
37063
37150
  optional: true
37064
37151
  }],
37152
+ "recordingSignal.getStatus": [{
37153
+ name: "deviceId",
37154
+ form: "single",
37155
+ optional: false
37156
+ }],
37065
37157
  "sceneMonitor.captureReference": [{
37066
37158
  name: "deviceId",
37067
37159
  form: "single",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camstack/addon-mqtt-broker",
3
- "version": "1.2.71",
3
+ "version": "1.2.73",
4
4
  "description": "MQTT broker registry addon for CamStack — manages external broker entries + an optional embedded aedes broker. Consumers spin up their own `mqtt.js` clients via the `mqtt-broker` cap.",
5
5
  "keywords": [
6
6
  "camstack",