add tuh_edpt_close() API, it will abort any pending transfer
implement hcd_edpt_close() for pio-usb and max3421e, also move max3421e api into its own header.
This commit is contained in:
@@ -33,6 +33,10 @@
|
||||
|
||||
#include "common/tusb_common.h"
|
||||
|
||||
#if CFG_TUH_MAX3421
|
||||
#include "portable/analog/max3421/hcd_max3421.h"
|
||||
#endif
|
||||
|
||||
//--------------------------------------------------------------------+
|
||||
// MACRO CONSTANT TYPEDEF
|
||||
//--------------------------------------------------------------------+
|
||||
@@ -227,6 +231,9 @@ bool tuh_edpt_xfer(tuh_xfer_t* xfer);
|
||||
// Open a non-control endpoint
|
||||
bool tuh_edpt_open(uint8_t daddr, tusb_desc_endpoint_t const * desc_ep);
|
||||
|
||||
// Close a non-control endpoint, it will abort any pending transfer
|
||||
bool tuh_edpt_close(uint8_t daddr, uint8_t ep_addr);
|
||||
|
||||
// Abort a queued transfer. Note: it can only abort transfer that has not been started
|
||||
// Return true if a queued transfer is aborted, false if there is no transfer to abort
|
||||
bool tuh_edpt_abort_xfer(uint8_t daddr, uint8_t ep_addr);
|
||||
|
Reference in New Issue
Block a user