ZWAVE Door Lock Logging Records
Door Lock Logging Records
QQ:380939960
对于ZWAVE门锁来说,它可以支持纪录一定数量的操作纪录,以供用户查阅。但是并不是所有的锁都支持纪录查询;因此ZWAVE定义了一系列对应的命令来支持相关的操作。
Door Lock Logging Records Supported Get Command
The Door Lock LoggingRecords Supported Get Command is used to request the number of records that theaudit trail supports.
7 |
6 |
5 |
4 |
3 |
2 |
1 |
0 |
Command Class = COMMAND_CLASS_DOOR_LOCK_LOGGING |
|||||||
Command = DOOR_LOCK_LOGGING_RECORDS_SUPPORTED_GET |
首先,可以通过这个命令来查询一个锁是否支持历史操作纪录查询;在sigma design的SDK中对应的是ZWAVE_DoorLockLoggingRecordsSupportedGet这个函数;
Door Lock Logging Records Supported Report Command
The Door Lock LoggingRecords Supported Report Command is used to report the maximum number ofreports the audit trail supports. The Door Lock Logging Records SupportedReport Command can be requested by the Door Lock Logging Records Supported GetCommand.
7 |
6 |
5 |
4 |
3 |
2 |
1 |
0 |
Command Class = COMMAND_CLASS_DOOR_LOCK_LOGGING |
|||||||
Command = DOOR_LOCK_LOGGING_RECORDS_SUPPORTED_REPORT |
|||||||
Max records stored |
当我们通过ZWAVE_DoorLockLoggingRecordsSupportedGet函数下发给doorlock命令DOOR_LOCK_LOGGING_RECORDS_SUPPORTED_GET后,door lock会回应DOOR_LOCK_LOGGING_RECORDS_SUPPORTED_REPORT; 在该命令中给出支持的最多可供查询的“历史操作纪录”;
门锁 |
最多可供查询的“历史操作纪录”数量 |
kwikset door lock |
0 |
SCHLAGE door lock |
0 |
Vision door lock |
50 |
Door Lock Logging Record Get Command
The Door Lock LoggingRecord Get Command is used to request the audit trail.
7 |
6 |
5 |
4 |
3 |
2 |
1 |
0 |
Command Class = COMMAND_CLASS_DOOR_LOCK_LOGGING |
|||||||
Command = RECORD_GET |
|||||||
Record number |
Record number (8bit)
The Record numberfield indicates the record to be requested.
A value 0 – Maxrecords stored is acceptable with a value of 0 being the most recent entry.When requesting with a value of 0, the report will contain the record number sothe latest record is known.
通过sigma Design SDK中的ZWAVE_RecordGet(BYTE nodeId,BYTErecordNumber)函数可以触发该命令。如果recordNumber为0,则表示获取最近的一次操作纪录;
Door lock record report
在ZWAVE协议中对于door lock record report的描述如下,当用户查询record纪录时,锁会通过这个命令返回对应的查询结果;
The Door LockLogging Record Report Command returns records from the audit trail. The DoorLock Logging Record Report Command can be send unsolicited or as a result ofreceiving a Door Lock Logging Record Get Command. To provide flexibility theuser associated with the record can be identified by one of two methods. Theuser identifier field or the user code entered MUST be filled into the reportwhen needed as dictated by the access status field.
7 |
6 |
5 |
4 |
3 |
2 |
1 |
0 |
Command Class = COMMAND_CLASS_DOOR_LOCK_LOGGING |
|||||||
Command = RECORD_REPORT |
|||||||
Record number |
|||||||
Timestamp - Year 1 |
|||||||
Timestamp - Year 2 |
|||||||
Timestamp – Month |
|||||||
Timestamp – Day |
|||||||
Record status |
Timestamp - Hour Local Time |
||||||
Timestamp - Minute Local Time |
|||||||
Timestamp - Second Local Time |
|||||||
Event Type |
|||||||
User Identifier |
|||||||
User Code Length |
|||||||
USER_CODE1 |
|||||||
.. |
|||||||
USER_CODEn |
recordNumber = 36 year1 = 0x07 year2 = 0xe0 month = 10 day = 31 recordStatus = 0x01 hourLocalTime = 10 minuteLocalTime = 51 secondLocalTime = 12 eventType = 14 userIdentifier = 0 userCodeLength = 0 |
下面结合实例进行叙述
Record number (8bit)
Record numberrequested (1- 255). 在我们的例子中,这个record ID是36;
Timestamp - Year1..2 (16 bit)
Specify the year inthe usual Gregorian calendar. The first byte (Year 1) is the most significantbyte. 例子中0x07e0对应的十进制数是2016,也就是2016年;
Timestamp - Month(8 bit)
Specify the month ofthe year between 01 (January) and 12 (December). 例子中是10月;
Timestamp - Day (8bit)
Specify the day ofthe month between 01 and 31. 例子中是31日;
Record status(3-bits)
The record statusfield is used to indicate whether legal data is stored in the record.
Record State |
Description |
0 |
Requested record is empty. |
1 |
Requested record holds legal data. |
在我们的例子中该值为1,说明该纪录是有效的纪录;
Timestamp - HourLocal Time (8 bit)
Specify the number ofcomplete hours that have passed since midnight (00-23) in local time. 在例子中是10点
Timestamp - MinuteLocal Time (8 bit)
Specify the number ofcomplete minutes that have passed since the start of the hour (00-59) in localtime. 在例子中是51分;
Timestamp - SecondLocal Time (8 bit)
Specify the numberof complete seconds since the start of the minute (00-59) in local time. Thevalue 60 used to keep UTC from wandering away is not supported.在例子中是12秒
Event Type (8 bit)
Following Events aresupported:
Event type |
Description |
1 |
Lock Command: Keypad access code verified lock command |
2 |
Unlock Command: Keypad access code verified unlock command |
3 |
Lock Command: Keypad lock button pressed |
4 |
Unlock command: Keypad unlock button pressed |
5 |
Lock Command: Keypad access code out of schedule |
6 |
Unlock Command: Keypad access code out of schedule |
7 |
Keypad illegal access code entered |
8 |
Key or latch operation locked (manual) |
9 |
Key or latch operation unlocked (manual) |
10 |
Auto lock operation |
11 |
Auto unlock operation |
12 |
Lock Command: Z-Wave access code verified |
13 |
Unlock Command: Z-Wave access code verified |
14 |
Lock Command: Z-Wave (no code) |
15 |
Unlock Command: Z-Wave (no code) |
16 |
Lock Command: Z-Wave access code out of schedule |
17 |
Unlock Command Z-Wave access code out of schedule |
18 |
Z-Wave illegal access code entered |
19 |
Key or latch operation locked (manual) |
20 |
Key or latch operation unlocked (manual) |
21 |
Lock secured |
22 |
Lock unsecured |
23 |
User code added |
24 |
User code deleted |
25 |
All user codes deleted |
26 |
Master code changed |
27 |
User code changed |
28 |
Lock reset |
29 |
Configuration changed |
30 |
Low battery |
31 |
New Battery installed |
在我们的例子中Event type是13,也就是“Lock Command: Z-Wave (no code)”
User Identifier (8bits)
The User Identifieris used to recognize the user identity. A valid User Identifier MUST be a valuestarting from 1 to the maximum number of users supported by the device; referto the User Code Command Class. A User Identifier of 0 is acceptable when therecord does not need to identify a user or if the User Code is provided in thisreport.
在我们的实例中,该值为0,所以没有用户ID的。由于触发这条纪录是通过APP下发一条“锁门”的命令,不对应任何用户的,所以user ID是空;
User Code Length(8 bit)
The User CodeLength field indicates the number of bytes used to hold the User Code. A lengthof 0 is acceptable
在我们的实例中,该值为0,所以没有用户ID的。由于触发这条纪录是通过APP下发一条“锁门”的命令,不对应任何用户的,所以user ID是空;
综上所述,lock返回给我们的第36条纪录,对应的时间是2016-10-31 10:51:12通过ZWAVE命令下发的一条Lock命令;这条命令没有给出“用户密码”,所以User ID和user code length都是0;
再看几条纪录的例子
recordNumber = 37 year1 = 0x07 year2 = 0xe0 month = 10 day = 31 recordStatus = 0x01 hourLocalTime = 11 minuteLocalTime = 28 secondLocalTime = 43 eventType = 7 userIdentifier = 0 userCodeLength = 0 userCode1 = 0x9B userCode2 = 0x1F userCode3 = 0x4B userCode4 = 0xB9 userCode5 = 0x88 userCode6 = 0x00 userCode7 = 0x00 userCode8 = 0x88 userCode9 = 0x2B userCode10 = 0x48 2016-10-31 11:28:43,有用户在门锁通过按键输入错误的开锁密码开锁。Keypad illegal access code entered recordNumber = 38 year1 = 0x07 year2 = 0xe0 month = 10 day = 31 recordStatus = 0x01 hourLocalTime = 11 minuteLocalTime = 28 secondLocalTime = 50 eventType = 7 userIdentifier = 0 userCodeLength = 0 userCode1 = 0x73 userCode2 = 0xEA userCode3 = 0xC2 userCode4 = 0x74 userCode5 = 0xF7 userCode6 = 0x00 userCode7 = 0x00 userCode8 = 0x88 userCode9 = 0x2B userCode10 = 0x48 2016-10-31 11:28:50,有用户在门锁通过按键输入错误的开锁密码开锁。Keypad illegal access code entered recordNumber = 39 year1 = 0x07 year2 = 0xe0 month = 10 day = 31 recordStatus = 0x01 hourLocalTime = 11 minuteLocalTime = 28 secondLocalTime = 59 eventType = 9 userIdentifier = 0 userCodeLength = 0 userCode1 = 0x7B userCode2 = 0x39 userCode3 = 0x5C userCode4 = 0x79 userCode5 = 0x1A userCode6 = 0x00 userCode7 = 0x00 userCode8 = 0x88 userCode9 = 0x2B userCode10 = 0x48 2016-10-31 11:28:59,有用户使用钥匙或者通过操作门锁上的旋钮开锁。Key or latch operation unlocked (manual); 实际上这次是通过旋转锁上的旋钮开锁的。 |
ZWAVE Door Lock Logging Records相关推荐
- ZWAVE Door Lock Configuration Set
Door Lock Configuration Set The Door LockConfiguration Set Command used to set the configuration of ...
- c专家编程/c陷阱_编程中的进取陷阱
c专家编程/c陷阱 "Gumption traps" are a term introduced by Robert M. Pirsig in Chapter 26 of Zen ...
- Z-Wave Door Locks最佳实践
介绍 门锁对家庭的安全至关重要,因此通信必须可靠和快速.本文档汇集了许多门锁存在的问题,并指导开发人员实现最健壮和可互操作的门锁应用.这些大多是建议,而不是要求,并不能保证Z-Wave认证.Z-Wav ...
- logging模块详细使用
啄木鸟社区里的Pythonic八荣八耻有一条: 以打印日志为荣 , 以单步跟踪为耻; 很多程序都有记录日志的需求,并且日志中包含的信息既有正常的程序访问日志,还可能有错误.警告等信息输出,python ...
- python之 logging模块详细使用【转载】
很多程序都有记录日志的需求,并且日志中包含的信息既有正常的程序访问日志,还可能有错误.警告等信息输出,python的logging模块提供了标准的日志接口,你可以通过它存储各种格式的日志,主要用于输出 ...
- Django项目日志概述
Django项目日志概述 本文环境python3.5.2,Django版本1.10.2 Django项目中日志的实现 Django项目中使用的日志,使用了Python标准库中的logging模块进行实 ...
- 最方便最好看最好用的python日志。
这个日志没有依赖自己的其他包,复制即可运行,也可以从pypi网站上下载或者pip来安装这个日志. 1.日志内置了7种模板,其中模版4和模板5,可以实现点击日志跳转到指定文件指定行数的功能,史无前例的实 ...
- Android APIs (Class Index - Android SDK)(一)
这些是Android API(API level: 19)类 类名 描述 A AbortableHttpRequest Interface representing an HTTP request t ...
- 第2章 包装外观(Wrapper Facade):用于在类中封装函数的结构型模式
2.1 介绍 本论文描述包装外观模式.该模式的意图是通过面向对象( OO)类接口来封装低级函数和数据结构.常见的包装外观模式的例子是像 MFC. ACE和 AWT这样的类库,它们封装本地的 OS C ...
最新文章
- 5G最完整的PPT,朋友圈超火
- You must restart adb and Eclipse问题的解决
- tomcat1.8,tomcat-users.xml文件中如下修改才可以使用app manager登录,其中的roles有哪些枚举需要确认
- 去掉字符串里特殊字符的正则表达式方求
- 肖邦夜曲21_原装进口 | 肖邦夜曲全集 鲁宾斯坦 钢琴经典 2CD
- [云炬Python学习笔记] Python读取指定文件夹下的文件
- android自定义dialog不显示,Android 自定义的dialog显示不正常呢,怎么回事???
- JavaScript执行bat文件清理浏览器缓存
- Mysql删除重复数据并解决You can't specify target table 'xx' for update in FROM clause 报错与 query interrupted报错
- 如何在windows server 2008上配置NLB群集
- JavaScript学习(三十五)—拖动元素
- iOS UIButton没了交互事件
- cass有坐标文件生成里程文件_请问在CASS7.0中怎样生成坐标文件和里程文件,请尽量详细...
- torch/utils/cpp_extension.py raise RuntimeError(message) from e
- 电脑桌面有计算机和回收站怎么办,电脑回收站不见了怎么办 电脑回收站找回的4种方法...
- 批处理文件(bat)装逼 之全彩滚动我爱你 绘制五彩爱心 绘制3D球体
- vscode+markdown+pandoc写论文
- 微信开发必备工具:利用cpolar在公网上测试本地Web网站或移动应用程序
- bootrom的类型
- 查询mysql索引信息_数据查询优化之mysql索引
热门文章
- c语言snprintf,snprintf()函数使用总结
- JS实现记录用户在网站的停留时间
- Oracle dbwr 什么意思,Oracle 过程之DBWR运行原理
- Samba服务器在高校网络管理中的应用
- 女主计算机学霸 爸爸是考古学家,强推5本校园“女主学霸文”初见你时,你是那么的楚楚动人...
- 腾讯视频QLV格式转换成mp4格式,只需这样做!
- Lua--初学--new,inherit总结
- Arcengine的工具中实现Snapping(捕捉)
- 搞搞 Prometheus: Alertmanager
- OEM,ODM,OBM是什么??