Skip to content

Commit 3806c45

Browse files
committed
fix bmi fifo ths
1 parent efc8f2f commit 3806c45

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/sensor/imu/BMI270.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,6 +378,7 @@ float bmi_temp_read(void)
378378
uint8_t bmi_setup_DRDY(uint16_t threshold)
379379
{
380380
uint8_t buf[2];
381+
threshold *= PACKET_SIZE; // byte threshold
381382
buf[0] = threshold & 0xFF;
382383
buf[1] = (threshold >> 8) & 0x1F;
383384
int err = ssi_burst_write(SENSOR_INTERFACE_DEV_IMU, BMI270_FIFO_WTM_0, buf, 2);
@@ -578,7 +579,7 @@ const sensor_imu_t sensor_imu_bmi270 = {
578579

579580
*bmi_setup_DRDY,
580581
*bmi_setup_WOM,
581-
582+
582583
*imu_none_ext_setup,
583584
*imu_none_ext_passthrough
584585
};

0 commit comments

Comments
 (0)