From 36d123e9c5a9ce0e29b9bc22ef87661bf479e299 Mon Sep 17 00:00:00 2001 From: Nick Brassel Date: Tue, 16 Nov 2021 05:21:09 +1100 Subject: Add support for deferred executors. (#14859) * Add support for deferred executors. * More docs. * Include from quantum.h * Cleanup. * Parameter checks * Comments. * qmk format-c * I accidentally a few words. * API name change. * Apply suggestions from code review Co-authored-by: Sergey Vlasov * Review comments. * qmk format-c * Review comments. Co-authored-by: Sergey Vlasov --- tmk_core/protocol/arm_atsam/main_arm_atsam.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'tmk_core') diff --git a/tmk_core/protocol/arm_atsam/main_arm_atsam.c b/tmk_core/protocol/arm_atsam/main_arm_atsam.c index 1df5112ed8..de12821a74 100644 --- a/tmk_core/protocol/arm_atsam/main_arm_atsam.c +++ b/tmk_core/protocol/arm_atsam/main_arm_atsam.c @@ -40,6 +40,10 @@ void send_mouse(report_mouse_t *report); void send_system(uint16_t data); void send_consumer(uint16_t data); +#ifdef DEFERRED_EXEC_ENABLE +void deferred_exec_task(void); +#endif // DEFERRED_EXEC_ENABLE + host_driver_t arm_atsam_driver = {keyboard_leds, send_keyboard, send_mouse, send_system, send_consumer}; uint8_t led_states; @@ -360,6 +364,11 @@ int main(void) { } #endif // CONSOLE_ENABLE +#ifdef DEFERRED_EXEC_ENABLE + // Run deferred executions + deferred_exec_task(); +#endif // DEFERRED_EXEC_ENABLE + // Run housekeeping housekeeping_task(); } -- cgit v1.2.1