-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathupnp_ipcamera.js
40 lines (35 loc) · 1.01 KB
/
upnp_ipcamera.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/* global module */
"use strict";
/*
UPNPManager: msearch = UpnpMsearchHeader {
device_id: "uuid:ae67e622-7a66-465e-bab0-28107b2df980",
device_type: "",
service_type: "urn:cellvision:service:Null:1",
service_ver: "",
location: "http://10.252.120.202:8592/rootdesc.xml",
os: "Cellvision UPnP/1.0",
date: "",
ext: "",
expires: 1800,
alive: true
}
*/
const upnpServer = require('./upnpserver_base.js');
class IpCameraUpnpServer extends upnpServer {
constructor(ip, udn) {
var ipcam_config = {
location: 'http://' + ip + ':8100',
udn: udn,
description: 'ipcam_config description',
adInterval: 180000 // once every 3 minutes
};
super(ipcam_config);
this._server.addUSN('urn:cellvision:service:Null:1');
//console.log("im constructed", ip, udn);
}
startServer (label) {
console.log(label, 'started');
super.startServer(label);
}
}
module.exports = IpCameraUpnpServer;