@onbright/hardware-suit
Advanced tools
Comparing version 1.10.2 to 1.10.3
@@ -15,12 +15,11 @@ "use strict"; | ||
this.isCheck = ''; | ||
this.type = status.slice(0, 2); | ||
this.gear = status.slice(2, 4); | ||
this.evenType = status.slice(4, 6); | ||
this.time = status.slice(6, 8); | ||
this.motion = status.slice(8, 10); | ||
this.isNear = status.slice(12, 14); | ||
this.isCheck = status.slice(14, 16); | ||
this.type = status.slice(2, 4); | ||
this.gear = status.slice(0, 2); | ||
this.time = status.slice(4, 6); | ||
this.motion = status.slice(6, 8); | ||
this.isNear = status.slice(10, 12); | ||
this.isCheck = status.slice(12, 14); | ||
} | ||
} | ||
exports.SensorHumanBeingStatus = SensorHumanBeingStatus; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiU2Vuc29ySHVtYW5CZWluZy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uL3NyYy9lbnRpdHkvU2Vuc29ySHVtYW5CZWluZy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSxxQ0FBa0M7QUFFbEMsTUFBYSxzQkFBdUIsU0FBUSxlQUFNO0lBUWhELFlBQVksTUFBYztRQUN4QixLQUFLLENBQUMsTUFBTSxDQUFDLENBQUM7UUFSVCxTQUFJLEdBQVcsRUFBRSxDQUFDO1FBQ2xCLFNBQUksR0FBVyxFQUFFLENBQUM7UUFDbEIsYUFBUSxHQUFXLEVBQUUsQ0FBQztRQUN0QixTQUFJLEdBQVcsRUFBRSxDQUFDO1FBQ2xCLFdBQU0sR0FBVyxFQUFFLENBQUM7UUFDcEIsV0FBTSxHQUFXLEVBQUUsQ0FBQztRQUNwQixZQUFPLEdBQVcsRUFBRSxDQUFDO1FBRzFCLElBQUksQ0FBQyxJQUFJLEdBQUcsTUFBTSxDQUFDLEtBQUssQ0FBQyxDQUFDLEVBQUUsQ0FBQyxDQUFDLENBQUE7UUFDOUIsS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QVcsRUFBRSxDQUFDO1FBQ2xCLFdBQU0sR0FBVyxFQUFFLENBQUM7UUFDcEIsV0FBTSxHQUFXLEVBQUUsQ0FBQztRQUNwQixZQUFPLEdBQVcsRUFBRSxDQUFDO1FBRzFCLElBQUksQ0FBQyxJQUFJLEdBQUcsTUFBTSxDQUFDLEtBQUssQ0FBQyxDQUFDLEVBQUUsQ0FBQyxDQUFDLENBQUE7UUFDOUIsSUFBSSxDQUFDLElBQUksR0FBRyxNQUFNLENBQUMsS0FBSyxDQUFDLENBQUMsRUFBRSxDQUFDLENBQUMsQ0FBQTtRQUM5QixJQUFJLENBQUMsSUFBSSxHQUFHLE1BQU0sQ0FBQyxLQUFLLENBQUMsQ0FBQyxFQUFFLENBQUMsQ0FBQyxDQUFBO1FBQzlCLElBQUksQ0FBQyxNQUFNLEdBQUcsTUFBTSxDQUFDLEtBQUssQ0FBQyxDQUFDLEVBQUUsQ0FBQyxDQUFDLENBQUE7UUFDaEMsSUFBSSxDQUFDLE1BQU0sR0FBRyxNQUFNLENBQUMsS0FBSyxDQUFDLEVBQUUsRUFBRSxFQUFFLENBQUMsQ0FBQTtRQUNsQyxJQUFJLENBQUMsT0FBTyxHQUFHLE1BQU0sQ0FBQyxLQUFLLENBQUMsRUFBRSxFQUFFLEVBQUUsQ0FBQyxDQUFBO0lBQ3JDLENBQUM7Q0FDRjtBQWpCRCx3REFpQkMifQ== |
@@ -22,3 +22,3 @@ "use strict"; | ||
const nearMap = { | ||
'0': '不接近也不愿理', | ||
'0': '不接近也不远离', | ||
'1': '接近', | ||
@@ -64,3 +64,3 @@ '2': '远离' | ||
getStatusDescriptor() { | ||
const eventCode = converter_1.fillLength(converter_1.toBinary(this.SensorHumanBeingStatus.evenType, 16), 8); | ||
const eventCode = converter_1.fillLength(converter_1.toBinary(this.SensorHumanBeingStatus.type, 16), 8); | ||
const gearNumber = converter_1.toDecimal(this.SensorHumanBeingStatus.gear, 16); | ||
@@ -70,6 +70,7 @@ const isMotion = Number(converter_1.toDecimal(this.SensorHumanBeingStatus.motion, 16)); | ||
const checkNum = Number(converter_1.toDecimal(this.SensorHumanBeingStatus.isCheck, 16)); | ||
return `${evnetMap[eventCode[7]]}${eventCode[6] === '1' ? ' | 定时上报' : ''}${eventCode[5] === '1' ? ' | 按键上报' : ''}| ${Number(gearNumber)}档 | 上报时间:${this.getTime()} | ${motionMap[isMotion]} | ${nearMap[near]} | 检查开关:${checkMap[checkNum]}`; | ||
debugger; | ||
return `档位:${Number(gearNumber)}档 | 事件类似:${evnetMap[eventCode[7]] || ''}${eventCode[6] === '1' ? ',定时上报' : ''}${eventCode[5] === '1' ? ',按键上报' : ''} | 上报时间:${this.getTime() || '-'} | 运动/静止:${motionMap[isMotion] || '-'} | 接近/远离:${nearMap[near] || '-'} | 状态检查开关:${checkMap[checkNum] || '-'}`; | ||
} | ||
} | ||
exports.SensorHumanBeingEquip = SensorHumanBeingEquip; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiU2Vuc29ySHVtYW5CZWluZ0VxdWlwLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL21vZHVsZXMvU2Vuc29ySHVtYW5CZWluZ0VxdWlwLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBOzs7OztHQUtHO0FBQ0gsMkNBQXdDO0FBQ3hDLGlFQUFvRTtBQUNwRSxrREFBb0U7QUFFcEUsTUFBTSxRQUFRLEdBQVE7SUFDcEIsR0FBRyxFQUFFLElBQUk7SUFDVCxHQUFHLEVBQUUsSUFBSTtDQUNWLENBQUE7QUFDRCxNQUFNLFNBQVMsR0FBUTtJQUNyQixHQUFHLEVBQUUsSUFBSTtJQUNULEdBQUcsRUFBRSxJQUFJO0NBQ1YsQ0FBQTtBQUNELE1BQU0sT0FBTyxHQUFRO0lBQ25CLEdBQUcsRUFBRSxTQUFTO0lBQ2QsR0FBRyxFQUFFLElBQ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YSxRQUFRLENBQUMsUUFBUSxDQUFDLElBQUksR0FBRyxFQUFFLENBQUE7SUFDaFMsQ0FBQztDQUNGO0FBM0NELHNEQTJDQyJ9 |
@@ -0,1 +1,8 @@ | ||
### [1.10.3](http://git.on-bright.com:8081/iweb/hardware-suit/compare/v1.10.2...v1.10.3) (2022-03-03) | ||
### Bug Fixes | ||
* 人体存在状态更改 ([c926751](http://git.on-bright.com:8081/iweb/hardware-suit/commit/c9267516c2f7676ab2104a891f886e2aa523b5dd)) | ||
### [1.10.2](http://git.on-bright.com:8081/iweb/hardware-suit/compare/v1.10.1...v1.10.2) (2022-03-02) | ||
@@ -2,0 +9,0 @@ |
{ | ||
"name": "@onbright/hardware-suit", | ||
"version": "1.10.2", | ||
"version": "1.10.3", | ||
"description": "hardware-suit javascript library", | ||
@@ -5,0 +5,0 @@ "main": "dist/hardware-suit.js", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2397436
25572