aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/dox/usb.dox
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-06-14 16:45:57 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-06-14 16:45:57 +0000
commit2b1173e29246cbc82f45490d0b1b1443d7bf897a (patch)
tree43a43b5de70a4463ae050560f6ebde75f502b0b7 /os/hal/dox/usb.dox
parent18cab5548c02bd6c52af77be2a737a8a8fd47070 (diff)
downloadChibiOS-2b1173e29246cbc82f45490d0b1b1443d7bf897a.tar.gz
ChibiOS-2b1173e29246cbc82f45490d0b1b1443d7bf897a.tar.bz2
ChibiOS-2b1173e29246cbc82f45490d0b1b1443d7bf897a.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4276 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/dox/usb.dox')
-rw-r--r--os/hal/dox/usb.dox79
1 files changed, 10 insertions, 69 deletions
diff --git a/os/hal/dox/usb.dox b/os/hal/dox/usb.dox
index 7298e191d..748e41afe 100644
--- a/os/hal/dox/usb.dox
+++ b/os/hal/dox/usb.dox
@@ -86,7 +86,7 @@
selected -> selected [label="\nSUSPEND/WAKEUP\n>event_cb<\n\nValid EP0 Message\n>requests_hook_cb<\n\nGET DESCRIPTOR\n>get_descriptor_cb<"];
selected -> configured [label="\nSET_CONF(n)\n>event_cb<"];
configured -> selected [label="\nSET_CONF(0)\n>event_cb<"];
- configured -> configured [label="\nSUSPEND/WAKEUP\n>event_cb<\n\nValid EP0 Message\n>requests_hook_cb<\n\nGET DESCRIPTOR\n>get_descriptor_cb<\n\nEndpoints Activity\n >in_cb< or >out_cb<"];
+ configured -> configured [label="\nSUSPEND/WAKEUP\n>event_cb<\n\nValid EP0 Message\n>requests_hook_cb<\n\nGET DESCRIPTOR\n>get_descriptor_cb<\n\nEndpoints Activity\n >in_cb< >out_cb< >setup_cb<"];
configured -> ready [label="\nUSB RESET\n>event_cb<"];
}
* @enddot
@@ -115,57 +115,9 @@
* - <b>OUT</b> endpoints are used by the application to receive data from
* the host.
* .
- * In ChibiOS/RT the endpoints can be configured in two distinct ways:
- * - <b>Packet Mode</b>. In this mode the driver invokes a callback each
- * time a packet has been received or transmitted. This mode is especially
- * suited for those applications handling continuous streams of data.
- * <br><br>
- * States diagram for OUT endpoints in packet mode:
- * @dot
- digraph example {
- rankdir="LR";
- node [shape=circle, fontname=Helvetica, fontsize=8, fixedsize="true",
- width="0.9", height="0.9"];
- edge [fontname=Helvetica, fontsize=8];
-
- disabled [label="EP_DISABLED\nDisabled", style="bold"];
- receiving [label="EP_BUSY\nReceiving Packet"];
- idle [label="EP_IDLE\nPacket in Buffer"];
-
- disabled -> receiving [label="\nusbInitEndpointI()"];
- receiving -> idle [label="\npacket received\n>out_cb<"];
- idle -> receiving [label="\nusbReadPacketBuffer()\nusbStartReceiveI()"];
- receiving -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
- idle -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
- }
- * @enddot
- * <br><br>
- * States diagram for IN endpoints in packet mode:
- * @dot
- digraph example {
- rankdir="LR";
- node [shape=circle, fontname=Helvetica, fontsize=8, fixedsize="true",
- width="0.9", height="0.9"];
- edge [fontname=Helvetica, fontsize=8];
-
- disabled [label="EP_DISABLED\nDisabled", style="bold"];
- transmitting [label="EP_BUSY\nSending Packet"];
- idle [label="EP_IDLE\nBuffer Empty"];
-
- disabled -> idle [label="\nusbInitEndpointI()"];
- idle -> transmitting [label="\nusbWritePacketBuffer()\nusbStartTransmitI()"];
- transmitting -> idle [label="\npacket sent\n>in_cb<"];
- transmitting -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
- idle -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
- }
- * @enddot
- * <br><br>
- * - <b>Transaction Mode</b>. In this mode the driver invokes a callback
- * only after a large, potentially multi-packet, transfer has been
- * completed, a callback is invoked only at the end of the transfer.
- * <br><br>
- * States diagram for OUT endpoints in transaction mode:
- * @dot
+ * The driver invokes a callback after finishing an IN or OUT transaction.
+ * States diagram for OUT endpoints in transaction mode:
+ * @dot
digraph example {
rankdir="LR";
node [shape=circle, fontname=Helvetica, fontsize=8, fixedsize="true",
@@ -183,10 +135,10 @@
receiving -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
idle -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
}
- * @enddot
- * <br><br>
- * States diagram for IN endpoints in transaction mode:
- * @dot
+ * @enddot
+ * <br><br>
+ * States diagram for IN endpoints in transaction mode:
+ * @dot
digraph example {
rankdir="LR";
node [shape=circle, fontname=Helvetica, fontsize=8, fixedsize="true",
@@ -204,19 +156,8 @@
transmitting -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
idle -> disabled [label="\nUSB RESET\nusbDisableEndpointsI()"];
}
- * @enddot
- * <br><br>
- * .
- * @subsection usb_2_3 USB Packet Buffers
- * An important difference between packet and transaction modes is that there
- * is a dedicated endpoint buffer in packet mode while in transaction mode
- * the application has to specify its own buffer for duration of the whole
- * transfer.<br>
- * Packet buffers cannot be accessed directly by the application because those
- * could not be necessarily memory mapped, a buffer could be a FIFO or some
- * other kind of memory accessible in a special way depending on the
- * underlying hardware architecture, the functions @p usbReadPacketI() and
- * @p usbWritePacketI() allow to access packet buffers in an abstract way.
+ * @enddot
+ * <br><br>
*
* @subsection usb_2_4 USB Callbacks
* The USB driver uses callbacks in order to interact with the application.