mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-21 05:07:36 +08:00
consume all available queued vehicle_commands
This commit is contained in:
@@ -2415,7 +2415,7 @@ Commander::run()
|
||||
}
|
||||
|
||||
/* handle commands last, as the system needs to be updated to handle them */
|
||||
if (_cmd_sub.updated()) {
|
||||
while (_cmd_sub.updated()) {
|
||||
/* got command */
|
||||
const unsigned last_generation = _cmd_sub.get_last_generation();
|
||||
vehicle_command_s cmd;
|
||||
|
||||
Reference in New Issue
Block a user