refactor dcd API, drop edpt_hdl_t in favor of endpoint address for easy port

This commit is contained in:
hathach
2018-03-11 15:20:27 +07:00
parent fd250b92cb
commit cfdc7999f6
7 changed files with 70 additions and 77 deletions

View File

@@ -155,7 +155,7 @@
#define ASSERT_1ARGS(cond) do { if (!(cond)) { tusb_hal_dbg_breakpoint(); _ASSERT_MESS() return false; } } while(0)
#define ASSERT_2ARGS(cond, _error) do { if (!(cond)) { tusb_hal_dbg_breakpoint(); _ASSERT_MESS() return _error;} } while(0)
#define ASSERT_(...) GET_3RD_ARG(__VA_ARGS__, ASSERT_2ARGS, ASSERT_1ARGS)(__VA_ARGS__)
#define TU_ASSERT(...) GET_3RD_ARG(__VA_ARGS__, ASSERT_2ARGS, ASSERT_1ARGS)(__VA_ARGS__)
#ifdef __cplusplus
}