EasyManua.ls Logo

Motorola MPC823e - Page 810

Motorola MPC823e
1353 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Communication Processor Module
16-356 MPC823e REFERENCE MANUAL MOTOROLA
USB
COMMUNICATION
16
PROCESSOR MODULE
16.10.4.1 OUT TOKEN. When the USB controller receives an OUT token, data reception
begins. The USB controller fetches the next buffer descriptor associated with the endpoint
and if it is empty, it starts transferring the incoming packet to the buffer descriptor’s
associated data buffer. When the data buffer has been filled, the USB controller clears the
E bit in the RX buffer descriptor and generates an interrupt if the I bit in the buffer descriptor
is set. If the incoming packet exceeds the length of the data buffer, the USB controller
fetches the next buffer descriptor in the table and, if it is empty, continues transferring the
rest of the packet to this buffer descriptor’s associated buffer. Otherwise, if it is full, an error
occurs. The entire data packet, including the DATA0/DATA1 packet ID (PID), is written to
the receive buffers and the PID is reflected in the PID field of the receive buffer descriptor.
It is your responsibility to program the driver software to check data packet synchronization
by monitoring the DATA0/DATA1 PID sequence toggle.
If the packet was received error-free (no CRC errors and no bit stuff error), depending on
the endpoint transfer mode configuration, an ACK handshake will be transmitted to the host.
If a reception error occurred, no handshake packet is returned, and the error status bits will
be set in the last buffer descriptor associated with this packet. If the RHS field in the
endpoint’s configuration register is programmed to respond with NAK, a NAK handshake is
returned instead of ACK. If the RHS field is programmed to respond with STALL, a STALL
handshake is returned. In both cases, the buffer will receive the data packet if the buffer
descriptors are available.
Table 16-32. USB Out Token Reception
DATA PACKET
CORRUPTED
USEP
x
RHS FIELD
HANDSHAKE
SENT TO HOST
Yes N/A None (Data Discarded)
No 00 (Normal) ACK
No 01 (Ignore) None
No 10 (NAK) NAK
No 11 (STALL) STALL

Table of Contents

Related product manuals