Skip to content

Commit 6e3e684

Browse files
xn365dagar
authored andcommitted
Fix srf05 driver.
1 parent b35dd86 commit 6e3e684

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/drivers/distance_sensor/srf05/SRF05.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ SRF05::measure()
152152
const hrt_abstime timestamp_sample = hrt_absolute_time();
153153
const hrt_abstime dt = _falling_edge_time - _rising_edge_time;
154154

155-
const float current_distance = dt * 343.0f / 10e6f / 2.0f;
155+
const float current_distance = dt * 343.0f / 1e6f / 2.0f;
156156

157157
if (dt > HXSRX0X_CONVERSION_TIMEOUT) {
158158
perf_count(_comms_errors);

0 commit comments

Comments
 (0)