增加最后一次激活时间的显示
This commit is contained in:
parent
20c2953a97
commit
5c4fff393d
@ -57,6 +57,17 @@ public class D3F0SelfCheckMessage extends BaseMessage {
|
||||
" blVer:"+src.readUnsignedByte() +
|
||||
" reboot:"+src.readUnsignedShort();
|
||||
}
|
||||
if(src.readableBytes()>=8){
|
||||
long lastActiveDate = src.readUnsignedInt();
|
||||
long lastActiveTime = src.readUnsignedInt();
|
||||
short year = (short) ((lastActiveDate>>16)&0xFF);
|
||||
short month = (short) ((lastActiveDate>>8)&0xFF);
|
||||
short day = (short) (lastActiveDate&0xFF);
|
||||
byte hour = (byte) (lastActiveTime/3600);
|
||||
byte munite = (byte) (lastActiveTime/60 - hour*60);
|
||||
auxInfo = auxInfo + " last active time:"+
|
||||
year+"-"+month+"-"+day+" "+hour+":"+munite;
|
||||
}
|
||||
|
||||
// read 会移动 bytebuf 的指针,所以保存原始码流需要将此指针挑拨回开始处
|
||||
src.readerIndex(0);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user