在哪里可以找到允许我从SensorStudio块访问数据的功能列表?
例如game_rotation_vector_data_event()
答案 0 :(得分:0)
设备可以支持的可用传感器数据事件回调列表是从CustomSensorDesigner块的默认实现源代码中预编写的(作为注释)。这些函数在取消注释后即可实现。
有关信息,如果给定的CustomSensorDesigner块没有很好地附加到回调函数的相应传感器,则该函数不会产生任何影响。
此清单示例(ICM-30670):
static void accelerometer_data_event(uint32_t timestamp, void* data, uint16_tlen) {
VSensorDataAccelerometer* in = (VSensorDataAccelerometer*) data;
/* implement here */
}
static void magnetometer_data_event(uint32_t timestamp, void* data, uint16_tlen) {
VSensorDataMagnetometer* in = (VSensorDataMagnetometer*) data;
/* implement here */
}
static void orientation_data_event(uint32_t timestamp, void* data, uint16_tlen) {
VSensorDataOrientation* in = (VSensorDataOrientation*) data;
/* implement here */
}
static void gyroscope_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataGyroscope* in = (VSensorDataGyroscope*) data;
/* implement here */
}
static void pressure_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataPressure* in = (VSensorDataPressure*) data;
/* implement here */
}
static void proximity_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataProximity* in = (VSensorDataProximity*) data;
/* implement here */
}
static void gravity_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataGravity* in = (VSensorDataGravity*) data;
/* implement here */
}
static void linear_acceleration_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataLinearAcc* in = (VSensorDataLinearAcc*) data;
/* implement here */
}
static void rotation_vector_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataQuaternion* in = (VSensorDataQuaternion*) data;
/* implement here */
}
static void ambient_temperature_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataTemperature* in = (VSensorDataTemperature*) data;
/* implement here */
}
static void uncal_magnetometer_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataMagnetometerUncal* in = (VSensorDataMagnetometerUncal*) data;
/* implement here */
}
static void game_rotation_vector_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataQuaternion* in = (VSensorDataQuaternion*) data;
/* implement here */
}
static void uncal_gyroscope_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataGyroscopeUncal* in = (VSensorDataGyroscopeUncal*) data;
/* implement here */
}
static void smd_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}
static void step_detector_data_event(uint32_t timestamp, void* data, uint16_tlen) {
/* implement here */
}
static void step_counter_data_event(uint32_t timestamp, void* data, uint16_tlen) {
VSensorDataStepCount* in = (VSensorDataStepCount*) data;
/* implement here */
}
static void geomag_rotation_vector_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataQuaternion* in = (VSensorDataQuaternion*) data;
/* implement here */
}
static void tilt_detector_data_event(uint32_t timestamp, void* data, uint16_tlen) {
/* implement here */
}
static void pick_up_gesture_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}
static void bac_data_event(uint32_t timestamp, void* data, uint16_t len) {
VSensorDataBAC* in = (VSensorDataBAC*) data;
/* implement here */
}
static void custom0_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}
static void custom1_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}
static void custom2_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}
static void custom3_data_event(uint32_t timestamp, void* data, uint16_t len) {
/* implement here */
}