Information

Universal Serial Bus Interface
MPC8308 PowerQUICC II Pro Processor Reference Manual, Rev. 1
13-144 Freescale Semiconductor
The device queue head (dQH) points to the linked list of transfer tasks, each depicted by the device
Transfer Descriptor (dTD). An area of memory pointed to by ENDPOINTLISTADDR contains a group of
all dQHs in a sequential list as shown in Figure 13-64. The even elements in the list of dQH’s are used for
receive endpoints (OUT/SETUP) and the odd elements are used for transmit endpoints (IN/INTERRUPT).
Device transfer descriptors are linked head to tail starting at the queue head and ending at a terminate bit.
Once the dTD has been retired, it will no longer be part of the linked list from the queue head. Therefore,
software is required to track all transfer descriptors since pointers will no longer exist within the queue
head once the dTD is retired (see Section 13.8.5.1, “Software Link Pointers”).
In addition to the current and next pointers and the dTD overlay, the dQH also contains the following
parameters for the associated endpoint: Multipler, Maximum Packet Length, Interrupt On Setup. The
complete initialization of the dQH including these fields is demonstrated in the next section.
13.8.4.1 Queue Head Initialization
One pair of device queue heads must be initialized for each active endpoint. To initialize a device queue
head:
Write the MaxPacketSize field as required by the USB Chapter 9 or application specific protocol.
Write the multiplier field to 0 for control, bulk, and interrupt endpoints. For ISO endpoints, set the
multiplier to 1, 2, or 3 as required bandwidth an in conjunction with the USB Chapter 9 protocol.
Note that in FS mode, the multiplier field can only be 1 for ISO endpoints.
Write the next dTD Terminate bit field to ‘1.’
Write the Active bit in the status field to ‘0.’
Write the Halt bit in the status field to ‘0.’
NOTE
The DCD must only modify dQH if the associated endpoint is not primed
and there are no outstanding dTDs.
13.8.4.2 Operational Model for Setup Transfers
As discussed in Section 13.8.3.5, “Control Endpoint Operation Model,” setup transfer requires special
treatment by the DCD. A setup transfer does not use a dTD but instead stores the incoming data from a
setup packet in an 8-byte buffer within the dQH.
Upon receiving notification of the setup packet, the DCD should handle the setup transfer as demonstrated
here:
1. Copy setup buffer contents from dQH - RX to software buffer.
2. Acknowledge setup backup by writing a ‘1’ to the corresponding bit in ENDPTSETUPSTAT.
NOTE
The acknowledge must occur before continuing to process the setup packet.