mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-01 10:31:35 +08:00
oneshot:trigger exit early in no chan in oneshot
This commit is contained in:
committed by
Lorenz Meier
parent
d21b6655d2
commit
b885fd97f6
@@ -478,6 +478,8 @@ static inline void io_timer_set_PWM_mode(unsigned timer)
|
|||||||
void io_timer_trigger(void)
|
void io_timer_trigger(void)
|
||||||
{
|
{
|
||||||
int oneshots = io_timer_get_mode_channels(IOTimerChanMode_OneShot);
|
int oneshots = io_timer_get_mode_channels(IOTimerChanMode_OneShot);
|
||||||
|
|
||||||
|
if (oneshots != 0) {
|
||||||
uint32_t action_cache[MAX_IO_TIMERS] = {0};
|
uint32_t action_cache[MAX_IO_TIMERS] = {0};
|
||||||
int actions = 0;
|
int actions = 0;
|
||||||
|
|
||||||
@@ -503,6 +505,7 @@ void io_timer_trigger(void)
|
|||||||
|
|
||||||
px4_leave_critical_section(flags);
|
px4_leave_critical_section(flags);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int io_timer_init_timer(unsigned timer)
|
int io_timer_init_timer(unsigned timer)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user