node-red-contrib-hik-media-buffer 1.1.26 → 1.1.28

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.
@@ -48,7 +48,7 @@ module.exports = function(RED) {
48
48
  const res = await camAuth.request({
49
49
  method: 'GET',
50
50
  url: `${node.protocol}://${cam.ip}:${node.port}/ISAPI/System/Video/inputs/channels/${cam.channel}/overlays/channelNameOverlay`,
51
- timeout: 5000,
51
+ timeout: 3000,
52
52
  httpsAgent: node.protocol === "https" ? httpsAgent : undefined
53
53
  });
54
54
 
@@ -75,7 +75,7 @@ module.exports = function(RED) {
75
75
  await camAuth.request({
76
76
  method: 'GET',
77
77
  url: `${node.protocol}://${cam.ip}:${node.port}/ISAPI/System/deviceInfo`,
78
- timeout: 5000,
78
+ timeout: 3000,
79
79
  httpsAgent: node.protocol === "https" ? httpsAgent : undefined
80
80
  });
81
81
  if (statoCamera[cam.ip] === false) {
@@ -106,7 +106,7 @@ module.exports = function(RED) {
106
106
  }
107
107
  }
108
108
 
109
- const heartbeatInterval = setInterval(checkCameras, 15000);
109
+ const heartbeatInterval = setInterval(checkCameras, 10000);
110
110
 
111
111
  // --- DOWNLOAD, SALVATAGGIO, CONVERSIONE E RIMOZIONE DOPO 2 MINUTI ---
112
112
  async function downloadMedia(evento, channelID) {
@@ -248,14 +248,14 @@ module.exports = function(RED) {
248
248
  }
249
249
  });
250
250
  response.data.on('error', () => handleNvrError());
251
- response.data.on('end', () => !isClosing && setTimeout(startAlertStream, 1000));
251
+ response.data.on('end', () => !isClosing && setTimeout(startAlertStream, 5000));
252
252
  }).catch(() => handleNvrError());
253
253
  }
254
254
 
255
255
  function handleNvrError() {
256
256
  if (nvrOnline) { node.send({ payload: { tipo_messaggio: "status", stato_telecamera: "offline", ip: node.host, msg: "NVR Offline", nome_cliente: node.name } }); nvrOnline = false; }
257
257
  updateNodeStatus();
258
- if (!isClosing) setTimeout(startAlertStream, 3000);
258
+ if (!isClosing) setTimeout(startAlertStream, 10000);
259
259
  }
260
260
 
261
261
  startAlertStream();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-red-contrib-hik-media-buffer",
3
- "version": "1.1.26",
3
+ "version": "1.1.28",
4
4
  "description": "Ottiene buffer video e immagine da camere Hikvision via ISAPI",
5
5
  "keywords": [
6
6
  "node-red",