summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorNathan Conrad <[email protected]>2020-04-12 21:07:17 -0400
committerNathan Conrad <[email protected]>2020-04-12 21:27:27 -0400
commit0eeaccaf46c28444cc0830895559652cf5638c60 (patch)
tree2a31a54dd03a0ff7a413427e3cee6a9036bd85e4 /docs
parent2ff3f765db7e62201d0491093111b0d649446046 (diff)
Skeleton, and initial stm32fsdev implementation (that leaks memory)
Diffstat (limited to 'docs')
-rw-r--r--docs/porting.md7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/porting.md b/docs/porting.md
index ccafa7999..de300c080 100644
--- a/docs/porting.md
+++ b/docs/porting.md
@@ -119,6 +119,13 @@ Opening an endpoint is done for all non-control endpoints once the host picks a
Also make sure to enable endpoint specific interrupts.
+##### dcd_edpt_close
+
+Close an endpoint. After calling this, the device should not respond to any packets directed towards this endpoint. Implementation is optional, and is to be called from USBD in a non-interrupt context.
+This function is used for implementing alternate settings.
+
+When called, this function need to abort any transfers in progress through this endpoint, before returning.
+
##### dcd_edpt_xfer
`dcd_edpt_xfer` is responsible for configuring the peripheral to send or receive data from the host. "xfer" is short for "transfer". **This is one of the core methods you must implement for TinyUSB to work (one other is the interrupt handler).** Data from the host is the OUT direction and data to the host is IN. It is used for all endpoints including the control endpoint 0. Make sure to handle the zero-length packet STATUS packet on endpoint 0 correctly. It may be a special transaction to the peripheral.