forked from mirrors/qmk_userspace
Begin to carve out platform/protocol API - Migrate keyboard_* calls (#14888)
This commit is contained in:
parent
c3c562cbb6
commit
2ec268bd21
5 changed files with 27 additions and 35 deletions
|
@ -20,7 +20,18 @@ void platform_setup(void);
|
|||
|
||||
void protocol_setup(void);
|
||||
void protocol_init(void);
|
||||
void protocol_task(void);
|
||||
void protocol_pre_task(void);
|
||||
void protocol_post_task(void);
|
||||
|
||||
// Bodge as refactoring vusb sucks....
|
||||
void protocol_task(void) __attribute__((weak));
|
||||
void protocol_task(void) {
|
||||
protocol_pre_task();
|
||||
|
||||
keyboard_task();
|
||||
|
||||
protocol_post_task();
|
||||
}
|
||||
|
||||
/** \brief Main
|
||||
*
|
||||
|
@ -30,8 +41,10 @@ int main(void) __attribute__((weak));
|
|||
int main(void) {
|
||||
platform_setup();
|
||||
protocol_setup();
|
||||
keyboard_setup();
|
||||
|
||||
protocol_init();
|
||||
keyboard_init();
|
||||
|
||||
/* Main loop */
|
||||
while (true) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue