refractor hid device driver

This commit is contained in:
hathach
2013-12-02 14:17:51 +07:00
parent 2c8b8ea529
commit 1ad78f104e
9 changed files with 172 additions and 199 deletions

View File

@@ -59,6 +59,16 @@ static uint8_t keyboardd_report_count; // number of reports sent each mounted
//--------------------------------------------------------------------+
// tinyusb Callbacks
//--------------------------------------------------------------------+
void tusbd_hid_keyboard_mounted_cb(uint8_t coreid)
{
keyboardd_report_count = 0;
}
void tusbd_hid_keyboard_unmounted_cb(uint8_t coreid)
{
}
void tusbd_hid_keyboard_cb(uint8_t coreid, tusb_event_t event, uint32_t xferred_bytes)
{
switch(event)
@@ -70,11 +80,6 @@ void tusbd_hid_keyboard_cb(uint8_t coreid, tusb_event_t event, uint32_t xferred_
}
}
void tusbd_hid_keyboard_mounted_cb(uint8_t coreid)
{
keyboardd_report_count = 0;
}
//--------------------------------------------------------------------+
// APPLICATION CODE
//--------------------------------------------------------------------+