mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-23 14:47:44 +08:00
[df_ms5607_wrapper] convert to mbar, fix error_count, device_id
This commit is contained in:
committed by
Beat Küng
parent
5cb6753572
commit
05fc506a56
@@ -151,8 +151,10 @@ int DfMS5607Wrapper::_publish(struct baro_sensor_data &data)
|
||||
baro_report baro_report;
|
||||
baro_report.timestamp = hrt_absolute_time();
|
||||
|
||||
baro_report.pressure = data.pressure_pa;
|
||||
baro_report.pressure = data.pressure_pa / 100.0f; // convert to mbar
|
||||
baro_report.temperature = data.temperature_c;
|
||||
baro_report.error_count = data.error_counter;
|
||||
baro_report.device_id = m_id.dev_id;
|
||||
|
||||
// TODO: when is this ever blocked?
|
||||
if (!(m_pub_blocked)) {
|
||||
|
||||
Reference in New Issue
Block a user