[Sensor] Add user-commands range limitation

This commit is contained in:
luhuadong
2020-03-16 11:03:32 +08:00
parent 815d231f4a
commit 7c4e70b3b3
2 changed files with 11 additions and 2 deletions

View File

@@ -111,6 +111,8 @@ extern "C" {
#define RT_SENSOR_CTRL_SET_POWER (5) /* Set power mode. args type of sensor power mode. ex. RT_SENSOR_POWER_DOWN,RT_SENSOR_POWER_NORMAL */
#define RT_SENSOR_CTRL_SELF_TEST (6) /* Take a self test */
#define RT_SENSOR_CTRL_USER_CMD_START 0x100 /* User commands should be greater than 0x100 */
struct rt_sensor_info
{
rt_uint8_t type; /* The sensor type */