AP_DroneCAN: prevent saturation of CPU with DroneCAN thread

This commit is contained in:
Andrew Tridgell 2024-09-24 20:51:11 +10:00 committed by Randy Mackay
parent 06e3b2051d
commit 4e008d942c
1 changed files with 4 additions and 0 deletions

View File

@ -506,6 +506,10 @@ void AP_DroneCAN::loop(void)
continue;
}
// ensure that the DroneCAN thread cannot completely saturate
// the CPU, preventing low priority threads from running
hal.scheduler->delay_microseconds(100);
canard_iface.process(1);
safety_state_send();