Browse Source

DfBmp280Wrapper: initialise baro report

Signed-off-by: Roman <bapstroman@gmail.com>
sbg
Roman 7 years ago committed by Daniel Agar
parent
commit
f3c12bc7c7
  1. 2
      src/platforms/posix/drivers/df_bmp280_wrapper/df_bmp280_wrapper.cpp

2
src/platforms/posix/drivers/df_bmp280_wrapper/df_bmp280_wrapper.cpp

@ -150,7 +150,7 @@ int DfBmp280Wrapper::_publish(struct baro_sensor_data &data) @@ -150,7 +150,7 @@ int DfBmp280Wrapper::_publish(struct baro_sensor_data &data)
{
perf_begin(_baro_sample_perf);
baro_report baro_report;
baro_report baro_report = {};
baro_report.timestamp = hrt_absolute_time();
baro_report.pressure = data.pressure_pa / 100.0f; // to mbar

Loading…
Cancel
Save