@apocaliss92/nodelink-js 0.4.35 → 0.5.0
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/{chunk-N6TCSER3.js → chunk-6ILAHQF5.js} +22 -3
- package/dist/{chunk-N6TCSER3.js.map → chunk-6ILAHQF5.js.map} +1 -1
- package/dist/cli/rtsp-server.cjs +21 -2
- package/dist/cli/rtsp-server.cjs.map +1 -1
- package/dist/cli/rtsp-server.js +1 -1
- package/dist/index.cjs +978 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +237 -2
- package/dist/index.d.ts +242 -1
- package/dist/index.js +949 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/cli/rtsp-server.cjs
CHANGED
|
@@ -26897,8 +26897,18 @@ ${xml}`
|
|
|
26897
26897
|
* This is more reliable than autoPt in SupportInfo which can be a false positive
|
|
26898
26898
|
* (e.g., NVR channels report autoPt=1 but don't actually support autotracking).
|
|
26899
26899
|
*
|
|
26900
|
+
* Doorbell exception (mirrors the {@link computeDeviceCapabilities} floodlight
|
|
26901
|
+
* rule): video-doorbell firmwares (doorbellVersion > 0) ship AiCfg with
|
|
26902
|
+
* `smartTrackMode=1` (the current mode) yet `smartTrackModeAbility=0` (the
|
|
26903
|
+
* firmware's own "no, this device cannot autotrack" flag). Without a PT
|
|
26904
|
+
* motor a doorbell physically cannot autotrack, so when the caller flags the
|
|
26905
|
+
* device as a doorbell AND the firmware admits `smartTrackModeAbility=0`,
|
|
26906
|
+
* trust the firmware and return false. Verified against UID
|
|
26907
|
+
* 9527000ICL1T1MDS: smartTrackMode=1, smartTrackModeAbility=0,
|
|
26908
|
+
* ptzType=0, ptzMode="none", doorbellVersion=31.
|
|
26909
|
+
*
|
|
26900
26910
|
* @param channel - Channel number (0-based)
|
|
26901
|
-
* @param options - Optional timeout
|
|
26911
|
+
* @param options - Optional timeout and doorbell context hint
|
|
26902
26912
|
* @returns true if autotracking is supported, false otherwise
|
|
26903
26913
|
*/
|
|
26904
26914
|
async probeAutotrackingSupport(channel, options) {
|
|
@@ -26908,6 +26918,14 @@ ${xml}`
|
|
|
26908
26918
|
const xml = await this.sendXml({ cmdId: 299, channel: ch, timeoutMs });
|
|
26909
26919
|
const smartTrackModeRaw = getXmlText(xml, "smartTrackMode");
|
|
26910
26920
|
const smartTrackMode = Number(smartTrackModeRaw ?? 0);
|
|
26921
|
+
const smartTrackModeAbilityRaw = getXmlText(
|
|
26922
|
+
xml,
|
|
26923
|
+
"smartTrackModeAbility"
|
|
26924
|
+
);
|
|
26925
|
+
const smartTrackModeAbility = smartTrackModeAbilityRaw === void 0 ? void 0 : Number(smartTrackModeAbilityRaw);
|
|
26926
|
+
if (options?.isDoorbell && Number.isFinite(smartTrackModeAbility) && smartTrackModeAbility === 0) {
|
|
26927
|
+
return false;
|
|
26928
|
+
}
|
|
26911
26929
|
return smartTrackMode > 0;
|
|
26912
26930
|
} catch {
|
|
26913
26931
|
return false;
|
|
@@ -27000,7 +27018,8 @@ ${xml}`
|
|
|
27000
27018
|
const features = this.parseFeaturesFromSupport(support);
|
|
27001
27019
|
const objects = await this.getAiDetectTypes(ch, { timeoutMs: 1500 });
|
|
27002
27020
|
const autotrackingProbed = await this.probeAutotrackingSupport(ch, {
|
|
27003
|
-
timeoutMs: 1500
|
|
27021
|
+
timeoutMs: 1500,
|
|
27022
|
+
isDoorbell: capabilities.isDoorbell === true
|
|
27004
27023
|
});
|
|
27005
27024
|
capabilities.hasAutotracking = autotrackingProbed;
|
|
27006
27025
|
let presets;
|