RenierM26 / ha-ezviz

Ezviz component for HASSIO, testing latest additions to official integration. (The few I work on at least)
GNU General Public License v3.0
44 stars 21 forks source link

Alarm Type #91

Open pbvdven opened 2 years ago

pbvdven commented 2 years ago

Hi,

Could you please if possible add a field that shows the last triggerd alarm type number it would be very usefull.

if you look at last_alarm_pic field in home assistant there a link that llinks also has the alarm number. if posible please add that number to your field list but the number in the link does not always change so mabey there is another field or something that shows the last triggerd alarm type.

https://ieu.ezvizlife.com/v3/alarms/pic/get?fileId=20211009191407-E37024487-1-**10000**-2-1&deviceSerialNo=E37024487&cn=1&ct=5&lc=7&bn=5_alarm.eu&isDevVideo=0

https://ieu.ezvizlife.com/v3/alarms/pic/get?fileId=20211009194848-E50593717-1-**10002**-2-1&deviceSerialNo=E50593717&cn=1&ct=5&lc=7&bn=5_alarm.eu&isDevVideo=0

10000:PIR Event 10001:Emergency Button Event 10002:Motion Detection Alarm 10003:Baby Cry Alarm 10004:Magnetic Contact Alarm 10005:Smoke Alarm 10006:Combustible Gas Alarm 10008:Water Leak Alarm 10009:Emergency Button Alarm 10010:PIR Alarm 10011:Video Tempering Alarm 10012:Video Loss 10013:Line Crossing 10014:Intrusion 10015:Face Detection Event 40001:Third-party Capture 40002:Connectivity 10016:Door Bell Ring Alarm 10018:Curtain Alarm 10019:Open-close Detector Alarm 10020:Scene Change Detection 10021:Defocus Detection 10022:Audio Exception Detection 10023:Unattended Baggage Detection 10024:Object Removal Detection 10025:Illegal Parking Detection 10026:People Gathering Detection 10027:Lotering Detection 10028:Fast Moving Detection 10029:Region Entrance Detection 10030:Region Exiting Detection 10031:Magnetic Disturbance Alarm 10032:Low Batter Alarm 10033:Intrusion Alarm 10035:Baby Motion Detection 10036:Switch Power Supply Alarm 10100:IO Alarm 10101:IO-1 Alarm 10102:IO-2 Alarm 10103:IO-3 Alarm 10104:IO-4 Alarm 10105:IO-5 Alarm 10106:IO-6 Alarm 10107:IO-7 Alarm 10108:IO-8 Alarm 10109:IO-9 Alarm 10110:IO-10 Alarm 10111:IO-11 Alarm 10112:IO-12 Alarm 10113:IO-13 Alarm 10114:IO-14Alarm 10115:IO-15 Alarm 10116:IO-16 Alarm 12000:Motion Detection Alarm 12001:Video Loss 12002:Video Tampering Alarm 12003:Instant Zone Alarm 12004:Instant Zone Alarm Recovered 12005:24-hour Voiced Zone Alarm 12006:24-hour Voiced Zone Alarm Recovered 12007:Delay Zone Alarm 12008:Delay Zone Alarm Recovered 12009:Internal Delayed Alarm 12010:Internal Delayed Alarm Recovered 12011:Fire Alarm Arming Zone Alarm 12012:Fire Alarm Arming Zone Alarm Recovered 12013:Behavior Analysis Alarm 12014:Behavior Analysis Alarm Recovered 12015:24 Hour Non-voiced Zone Alarm 12016:24 Hour Non-voiced Zone Alarm Recovered 12017:24 Hour Aux Zone Alarm 12018:24 Hour Aux Zone Alarm Recovered 12019:24 Hour Shock Zone Alarm 12020:24 Hour Shock Zone Alarm Recovered 12021:Sensor Tampered 12022:Sensor Tamper Recovered 12023:Soft Zone Emergency Alarm 12024:Soft Zone Fire Alarm 12025:Soft Zone Bandit Alarm 12026:Duress Report 12027:Device Tampering Alarm 12028:Device Tampering Alarm Recovered 12029:AC Power Off 12030:AC Power On 12031:Low Battery Voltage 12032:Battery Voltage Recovery 12033:Telephone Disconnected 12034:Telephone Connected 12035:Expansion Bus Module Offline 12036:Expansion Bus Module Online 12037:Keyboard Offline. 12038:Keyboard Recovered 12039:KBUS Trigger Disconnection 12040:KBUS Trigger Recovered 12041:Auto Arming/Disarming Failed 12042:Auto Disarming Failed 12043:Wireless Network Exception 12044:Wireless Network Recovery 12045:SIM Card Exception 12046:SIM Card Recovery 12047:Control Panel Reset 12048:Disarm 12049:Arm 12050:Auto Disarm 12051:Auto Arm 12052:Clear Alarm 12053:Instant Arm 12054:Key Region Disarming 12055:Key Region Arming 12056:Stay Arm 12057:Forced Arm 12058:Bypass 12059:Bypass Recovery 12060:Partition Group Bypass 12061:Partition Group Bypass Recovered 12062:Manual Test Report 12063:Scheduled Test Report 12064:Single-Zone Disarming 12065:Single-Zone Arming 12066:Keypad Locked 12067:Keypad Unlocked 12068:Printer Disconnected 12069:Printer Connected 12070:Instant Disarming 12071:Stay Disarming 12072:Scheduled to Enable the Trigger 12073:Scheduled to Disable the Trigger 12074:Failed to enable the trigger according to the schedule. 12075:Failed to disable the trigger according to the schedule. 12076:Enter Programming 12077:Exit Programming 12078:KBUS GP/K Disconnection 12079:KBUS GP/K Connection 12080:KBUS MN/K Disconnection 12081:KBUS MN/K Connected 12082:IP Conflicted 12083:Normal IP 12084:Network Disconnected 12085:Normal Network 12086:Motion Detection Alarm Stopped 12087:Video Tampering Detection Stopped 12088:Video Signal Recovered 12089:Input/Output Video Standard Mismatch 12090:Input/Output Video Format Recovered 12091:Video Input Exception 12092:Video Input Recovered 12093:HDD Full 12094:Free HDD 12095:HDD Error 12096:HDD Recovered 12097:Uploading Picture Failed 12098:Detector Offline 12099:Detector Online 12100:Detector Battery Low 12101:Detector Battery OK 12102:Zone Add Detector 12103:Zone Delete Detector 12104:Wi-Fi Exception :Wi-Fi Recovered 12106:RF Exception 12107:RF Recovered 10037:Over_Temperature Alarm 10038:Low_Temperature Alarm 10039:Over_Humidity Alarm 10040:Low_Humidity Alarm 12108:Host Anti-tamper Alarm 12109:Host Anti-tamper Alarm Recovered 12110:Card Reader Anti-Tamper Alarm 12111:Card Reader Anti-Tamper Alarm Recovered 12112:Event Input Alarm 12113:Event Input Alarm Recovery 12114:Door Control Security Anti-Tamper Alarm 12115:Door Control Security Anti-Tamper Alarm Recovered 12116:Network Disconnected 12117:Network Connected 12118:Device Power On 12119:Device Power Off 12120:Door Abnormally Open

RenierM26 commented 2 years ago

Hi @pbvdven,

Excellent idea! I have added this to the latest release. Would you mind trying? The Alarm api provides the code as well as the "name string".,

pbvdven commented 2 years ago

Sorry for the late answer. @RenierM26 i have tested it it works like expected for my cameras. its shows the last alarm type i have different ezviz cameras with and without AI so on the C3x i got 10131 - AI Human-Shape and Vehicle-Shape Detection and the other C3n 10079 Intelligent Detection Alarm C3w 10002 Motion Detection Alarm and on the doorbell DB1 10000 PIR Event but the actual button press is not resulting in an alarm like 10016:Door Bell Ring Alarm. that's very disappointing but for everything else it works like a charm. thanks

RenierM26 commented 2 years ago

Hi @pbvdven,

Do you see any notifications of doorbell button presses in the Ezviz app under library?

pbvdven commented 2 years ago

No in the library you only find the pir event. If you click on the doorbell camera there is a separated call list see pictures 88DBAD5F-BC42-4F03-A9E0-3C4838C6D1B2

C4ED0B18-422B-449C-BFB3-085DE07CA107 B4CC6BEC-A17B-467C-ADBD-FC41ED886B7D