Comments (7)
Please post the XML you receive from:
http://XXX.XXX.XXX.XXX/ISAPI/Event/triggers
Your namespace url is not one i've seen before, so I assume this is a rebranded Hikvision NVR you are using?
from pyhik.
Hi John,
It's a Chinese unit with English firmware.
I've posted the out put for the URL above.
Rob
from pyhik.
Based on the triggers XML you provided it doesn't look like you have any of your events set to “Notify the surveillance center” as a trigger in your NVR setup. To avoid having all events show up this library only searches for events that have that flag set.
from pyhik.
<?xml version="1.0" encoding="UTF-8"?>
<EventTriggerList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-1</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>1</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-2</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>2</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>record-1</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>1</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-2</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>2</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-3</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>3</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-4</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>4</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-5</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>5</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-6</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>6</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-3</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>3</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>record-1</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>1</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-2</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>2</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-3</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>3</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-4</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>4</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-5</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>5</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-6</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>6</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-4</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>4</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>record-1</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>1</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-2</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>2</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-3</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>3</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-4</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>4</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-5</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>5</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-6</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>6</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-5</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>5</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>record-1</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>1</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-2</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>2</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-3</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>3</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-4</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>4</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-5</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>5</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-6</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>6</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>VMD-6</id>
<eventType>VMD</eventType>
<dynVideoInputChannelID>6</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>record-1</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>1</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>record-6</id>
<notificationMethod>record</notificationMethod>
<dynVideoInputID>6</dynVideoInputID>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-1</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>1</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-2</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>2</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-3</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>3</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-4</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>4</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-5</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>5</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>videoloss-6</id>
<eventType>videoloss</eventType>
<dynVideoInputChannelID>6</dynVideoInputChannelID>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>diskfull</id>
<eventType>diskfull</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>email</id>
<notificationMethod>email</notificationMethod>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>diskerror</id>
<eventType>diskerror</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>email</id>
<notificationMethod>email</notificationMethod>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>nicbroken</id>
<eventType>nicbroken</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>email</id>
<notificationMethod>email</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>ipconflict</id>
<eventType>ipconflict</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0"> </EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>illaccess</id>
<eventType>illaccess</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
<EventTrigger xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<id>recordingfailure</id>
<eventType>recordingfailure</eventType>
<EventTriggerNotificationList xmlns="http://www.isapi.org/ver20/XMLSchema" version="1.0">
<EventTriggerNotification>
<id>email</id>
<notificationMethod>email</notificationMethod>
</EventTriggerNotification>
<EventTriggerNotification>
<id>center</id>
<notificationMethod>center</notificationMethod>
</EventTriggerNotification>
</EventTriggerNotificationList>
</EventTrigger>
</EventTriggerList>
from pyhik.
Setting the events to notify center, got the binary_sensors discovered, but something isn't right with the NVR. The /ISAPI/Event/notification/alertStream always results in 404. I guess it's due to the hacked firmware. Nothing to do with the library, so I'll close this.
Only contribution is an error about not liking the "recordingfailure" event type.
Anyway thanks for the tips. I've ordered another NVR which will hopefully address this issue.
from pyhik.
You should give the /Event/notification/alertStream
endpoint a try as well if you haven't already. The library should already try that path automatically if the ISAPI path fails, but you never know.
from pyhik.
I get a slightly different error
/ISAPI/Event/notification/alertStream - No XML just
Can't locate the url
/Event/notification/alertStream
<!DOCTYPE html>
<html><head><title>Document Error: Not Found</title></head>
<body><h2>Access Error: 404 -- Not Found</h2>
<p>Can't open document: /Event/notification/alertStream</p>
</body>
</html>
from pyhik.
Related Issues (20)
- There was a problem: 'NoneType' object has no attribute 'text' HOT 6
- Track events not shown in triggers XML endpoint HOT 7
- hikvision.py reference api document HOT 2
- Control PTZ
- Accessing Alarm trigger of camera in python code HOT 1
- /ISAPI/Event/triggers returning device error HOT 1
- Multiple detection stopped working in HA
- HomeAssistant 'Problem finding attribute: 'duration'' in logging HOT 3
- Request: Features for video Intercom HOT 1
- faceSnap sensor support HOT 11
- TypeError: int() argument must be a string, a bytes-like object or a number, not 'NoneType' HOT 20
- Delay is receiving Events HOT 2
- Only usable with `admin` username HOT 1
- What about streaming through the NVR HOT 1
- Home Assistant 2022.12.0B0 HOT 16
- Trigger Light strobe / Alarm. Is it possible? HOT 1
- ANPR DS-2CD4A26FWD-IZS HOT 10
- binary sensor not created HOT 2
- etchannel_num = int(etchannel.text) - TypeError: int() argument must be a string, a bytes-like object or a real number, not 'NoneType' HOT 21
- Video Tampering Detection event not properly detected because of XML namespace problem
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyhik.