mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-21 09:22:18 +00:00
px4_shutdown_request() was called from the power button IRQ callback, which invoked a work queue callback. But on NuttX, the work queue uses a semaphore, and thus it cannot be called from IRQ context. This patch switches to publishing an uORB msg instead, which is handled in the commander main thread. To increase failure resistance, we could subscribe to the same topic in another module for redundancy, in case commander runs wild.
459 B
459 B