Universal Serial Bus InterfaceMCF5253 Reference Manual, Rev. 124-146 Freescale Semiconductor24.11.5.5 Flushing/De-Priming an EndpointIt is necessary for the DCD to flush to de-prime one more endpoints on a USB device reset or during abroken control transfer. There may also be application specific requirements to stop transfers in progress.The following procedure can be used by the DCD to stop a transfer in progress:1. Write a '1' to the corresponding bit(s) in ENDPTFLUSH.2. Wait until all bits in ENDPTFLUSH are '0'.3. Software note: this operation may take a large amount of time depending on the USB bus activity.It is not desirable to have this wait loop within an interrupt service routine.4. Read ENDPTSTATUS to ensure that for all endpoints commanded to be flushed, that thecorresponding bits are now '0'. If the corresponding bits are '1' after step #2 has finished, then theflush failed as described in the following:Explanation: In very rare cases, a packet is in progress to the particular endpoint when commandedflush using ENDPTFLUSH. A safeguard is in place to refuse the flush to ensure that the packet inprogress completes successfully. The DCD may need to repeatedly flush any endpoints that fail toflush be repeating steps 1-3 until each endpoint is successfully flushed.24.11.5.6 Device Error MatrixTable 24-88 summarizes packet errors that are not automatically handled by the USB_DR.Notice that the device controller handles all errors on Bulk/Control/Interrupt Endpoints except for a databuffer overflow. However, for ISO endpoints, errors packets are not retried and errors are tagged asindicated.Table 24-88. Device Error MatrixError Direction PacketTypeData BufferError BitTransactionError BitOverflow ** RX Any 1 0ISO Packet Error RX ISO 0 1ISO Fulfillment Error Both ISO 0 1Table 24-89. Error DescriptionsError DescriptionOverflow Number of bytes received exceeded max. packet size or total buffer length.** This error will also set the Halt bit in the dQH and if there are dTDs remaining in the linked list for theendpoint, then those will not be executed.ISO Packet Error CRC Error on received ISO packet. Contents not guaranteed to be correct.ISO Fulfillment Error Host failed to complete the number of packets defined in the dQH mult field within the given(micro)frame. For scheduled data delivery the DCD may need to readjust the data queue because afulfillment error will cause Device Controller to cease data transfers on the pipe for one (micro)frame.During the ‘dead’(micro)frame, the Device Controller reports error on the pipe and primes for thefollowing frame.