mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-24 07:09:48 +08:00
VtolLandDetector require vehicle_status timestamp
This commit is contained in:
@@ -70,7 +70,7 @@ void VtolLandDetector::_update_topics()
|
||||
bool VtolLandDetector::_get_maybe_landed_state()
|
||||
{
|
||||
// Only trigger in RW mode
|
||||
if (!_vehicle_status.is_rotary_wing) {
|
||||
if ((_vehicle_status.timestamp != 0) && !_vehicle_status.is_rotary_wing) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -80,7 +80,7 @@ bool VtolLandDetector::_get_maybe_landed_state()
|
||||
bool VtolLandDetector::_get_landed_state()
|
||||
{
|
||||
// Only trigger in RW mode
|
||||
if (!_vehicle_status.is_rotary_wing) {
|
||||
if ((_vehicle_status.timestamp != 0) && !_vehicle_status.is_rotary_wing) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user