aboutsummaryrefslogtreecommitdiff
path: root/src/modules/bottle_drop/bottle_drop.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/bottle_drop/bottle_drop.cpp')
-rw-r--r--src/modules/bottle_drop/bottle_drop.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/modules/bottle_drop/bottle_drop.cpp b/src/modules/bottle_drop/bottle_drop.cpp
index a899cbe60..6a501d97c 100644
--- a/src/modules/bottle_drop/bottle_drop.cpp
+++ b/src/modules/bottle_drop/bottle_drop.cpp
@@ -497,6 +497,10 @@ BottleDrop::task_main()
float groundspeed_body = sqrtf(_global_pos.vel_n * _global_pos.vel_n + _global_pos.vel_e * _global_pos.vel_e);
distance_real = fabsf(get_distance_to_next_waypoint(_global_pos.lat, _global_pos.lon, _drop_position.lat, _drop_position.lon));
+ if (counter % 90 == 0) {
+ mavlink_log_info(_mavlink_fd, "#audio: drop distance %.2f", (double)distance_real);
+ }
+
//warnx("absolut wind speed = %.4f", vr); //////////////////////////////////////////////////////////////////// DEBUGGING
@@ -636,10 +640,6 @@ BottleDrop::task_main()
onboard_mission_pub = orb_advertise(ORB_ID(onboard_mission), &onboard_mission);
}
- if (counter % 90 == 0) {
- mavlink_log_info(_mavlink_fd, "#audio: drop distance %.2f", (double)distance_real);
- }
-
// We're close enough - open the bay
distance_open_door = math::max(3.0f, fabsf(t_door * groundspeed_body));