xvsdk
3.2.0
|
A class to handle device status event stream. More...
#include <xv-sdk.h>
Public Types | |
using | Data = std::vector< unsigned char > const & |
Public Member Functions | |
virtual bool | start ()=0 |
start streaming. | |
virtual bool | stop ()=0 |
stop streaming. | |
virtual int | registerCallback (std::function< void(std::vector< unsigned char > const &)>)=0 |
Register callback to receive data. | |
virtual bool | unregisterCallback (int callbackId)=0 |
Unregister callback. | |
A class to handle device status event stream.
DataStructure Data structure of device status data:
Header:
Bytes index: 0
Bytes length: 2
Const value: 0x01, 0xaf
Sensor type:
Bytes index: 2
Bytes length: 1
Const value: 0x62
Timestamp:
Bytes index: 3
Bytes length: 8
Sensor tempreture:
Bytes index: 11
Bytes length: 6
Comments: Two bytes for each sensor, factor is 0.0625, unit is centigrade. For example: if the value is 0x02c0, the tempreture value will be 704*0.0625 = 44.0 centigrade
CPU tempreture:
Bytes index: 17
Bytes length: 1
Comments: factor is 1, unit is centigrade.
Current fan speed:
Bytes index: 18
Bytes length: 2
Average fan speed:
Bytes index: 20
Bytes length: 2
Fan speed change:
Bytes index: 22
Bytes length: 2
Previous fan speed:
Bytes index: 24
Bytes length: 2
Curent fan duty cycle:
Bytes index: 26
Bytes length: 1
Fan duty cycle change:
Bytes index: 27
Bytes length: 1
Previous fan duty cycle:
Bytes index: 28
Bytes length: 1
Soft reset:
Bytes index: 29
Bytes length: 1
Comment: 0x80-soft reset unsupported, 0x81-soft reset supported
Frequency:
Bytes index: 30
Bytes length: 4
RGB switch:
Bytes index: 34
Bytes length: 1
Comment: 0x0-offline, 0x01-online
Fisheye switch:
Bytes index: 35
Bytes length: 1
Comment: 0x00-offline, 0x01-online. The upper four bits are status of four cameras, bit7-sen_right2, bit6-sen_left2, bit5-sen_right, bit4-sen_left
TOF switch:
Bytes index: 36
Bytes length: 1
Comment: 0x00-offline, 0x01-online
UAC speaker switch:
Bytes index: 37
Bytes length: 1
Comment: 0x00-offline, 0x01-online with normal streaming, 0x02-online with interrupted streaming
UAC mic switch:
Bytes index: 38
Bytes length: 1
Comment: 0x00-offline, 0x01-online with normal streaming, 0x02-online with interrupted streaming
Audio speaker switch:
Bytes index: 39
Bytes length: 1
Comment: 0x00-offline, 0x01-online
Audio mic switch:
Bytes index: 40
Bytes length: 1
Comment: 0x00-offline, 0x01-online
DP switch:
Bytes index: 41
Bytes length: 1
Comment: 0x00-offline, 0x01-online
Panel switch:
Bytes index: 42
Bytes length: 1
Comment: 0x00-offline, 0x01-online
USB status:
Bytes index: 43
Bytes length: 1
Comment: 0x00-interface up, 0x01-interface down, 0x02-suspend, 0x03-resume, 0x04-reset
USB reset flag:
Bytes index: 44
Bytes length: 1
Comment: 0x00-normal, 0x01-reset
DataStructure of handle controller data:
Header:
Bytes index: 0
Bytes length: 2
Const value: 0x01, 0xaf
Sensor type:
Bytes index: 2
Bytes length: 1
Const value: 0x71
Handle controller type:
Bytes index: 3
Bytes length: 1
Const value: 0x22-left handle controller, 0x23-right handle controller
Timestamp:
Bytes index: 4
Bytes length: 2
Const value: 0x22-left handle controller, 0x23-right handle controller
Acc x:
Bytes index: 4
Bytes length: 2
Acc y:
Bytes index: 4
Bytes length: 2
Acc z:
Bytes index: 4
Bytes length: 2
Gyro x:
Bytes index: 4
Bytes length: 2
Gyro y:
Bytes index: 4
Bytes length: 2
Gyro z:
Bytes index: 4
Bytes length: 2
DataStructure of handle controller key eventdata:
Header:
Bytes index: 0
Bytes length: 2
Const value: 0x01, 0xaf
Sensor type:
Bytes index: 2
Bytes length: 1
Const value: 0x71
Handle controller type:
Bytes index: 3
Bytes length: 1
Const value: 0x32-left handle controller, 0x33-right handle controller
Trigger:
Bytes index: 4
Bytes length: 1
Side trigger:
Bytes index: 5
Bytes length: 1
Rocker x:
Bytes index: 6
Bytes length: 2
Rocker y:
Bytes index: 8
Bytes length: 2
Key:
Bytes index: 10
Bytes length: 1
Battery:
Bytes index: 11
Bytes length: 2