Skip to content

Commit

Permalink
fix(sensors): correctly correct the past sensor readings
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanthecoder committed Jul 12, 2024
1 parent 89e20a8 commit 2c3ae54
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions include/sensors/core/tasks/pressure_driver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -359,9 +359,8 @@ class MMR920 {
// data is in the same format as later samples, don't apply
// the current_pressure_baseline_pa since it has already
// been applied
sensor_buffer->at(sensor_buffer_index) =
sensor_buffer->at(sensor_buffer_index) -
current_moving_pressure_baseline_pa;
sensor_buffer->at(i) =
sensor_buffer->at(i) - current_moving_pressure_baseline_pa;
}
}

Expand Down

0 comments on commit 2c3ae54

Please sign in to comment.