move scheduling to its own file (#1842)
* move scheduling to its own file * header * protip don't include a cpp file
This commit is contained in:
parent
a05b06f5f0
commit
c8b4fac456
|
@ -607,17 +607,3 @@ void doScheduleStopEngine(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
||||||
//backupRamFlush();
|
//backupRamFlush();
|
||||||
#endif // EFI_PROD_CODE
|
#endif // EFI_PROD_CODE
|
||||||
}
|
}
|
||||||
|
|
||||||
void action_s::execute() {
|
|
||||||
efiAssertVoid(CUSTOM_ERR_ASSERT, callback != NULL, "callback==null1");
|
|
||||||
callback(param);
|
|
||||||
}
|
|
||||||
|
|
||||||
schfunc_t action_s::getCallback() const {
|
|
||||||
return callback;
|
|
||||||
}
|
|
||||||
|
|
||||||
void * action_s::getArgument() const {
|
|
||||||
return param;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
|
@ -5,5 +5,4 @@ SYSTEMSRC_CPP = \
|
||||||
$(PROJECT_DIR)/controllers/system/efi_gpio.cpp \
|
$(PROJECT_DIR)/controllers/system/efi_gpio.cpp \
|
||||||
$(PROJECT_DIR)/controllers/system/periodic_task.cpp \
|
$(PROJECT_DIR)/controllers/system/periodic_task.cpp \
|
||||||
$(PROJECT_DIR)/controllers/system/dc_motor.cpp \
|
$(PROJECT_DIR)/controllers/system/dc_motor.cpp \
|
||||||
|
$(PROJECT_DIR)/controllers/system/timer/scheduler.cpp \
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
/**
|
||||||
|
* @file scheduler.h
|
||||||
|
*
|
||||||
|
* @date October 1, 2020
|
||||||
|
*/
|
||||||
|
#include "scheduler.h"
|
||||||
|
|
||||||
|
void action_s::execute() {
|
||||||
|
efiAssertVoid(CUSTOM_ERR_ASSERT, callback != NULL, "callback==null1");
|
||||||
|
callback(param);
|
||||||
|
}
|
||||||
|
|
||||||
|
schfunc_t action_s::getCallback() const {
|
||||||
|
return callback;
|
||||||
|
}
|
||||||
|
|
||||||
|
void * action_s::getArgument() const {
|
||||||
|
return param;
|
||||||
|
}
|
Loading…
Reference in New Issue