EasyManua.ls Logo

NXP Semiconductors MKL25Z128VLK4 - USB Transaction

NXP Semiconductors MKL25Z128VLK4
807 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...
Table 35-4. Buffer descriptor fields (continued)
Field Description
TOK_PID[n] Bits [5:2] can also represent the current token PID. The current token PID is written back in to the
BD by the USB-FS when a transfer completes. The values written back are the token PID values
from the USB specification:
0x1h for an OUT token.
0x9h for an IN token.
0xDh for a SETUP token.
In host mode, this field is used to report the last returned PID or a transfer status indication. The
possible values returned are:
0x3h DATA0
0xBh DATA1
0x2h ACK
0xEh STALL
0xAh NAK
0x0h Bus Timeout
0xFh Data Error
1–0
Reserved
Reserved, should read as zeroes.
ADDR[31:0] Address
Represents the 32-bit buffer address in system memory. These bits are unchanged by the USB-
FS.
35.3.5 USB transaction
When the USB-FS transmits or receives data, it computes the BDT address using the
address generation shown in "Addressing Buffer Descriptor Entries" table.
If OWN =1, the following process occurs:
1. The USB-FS reads the BDT.
2. The SIE transfers the data via the DMA to or from the buffer pointed to by the
ADDR field of the BD.
3. When the TOKEN is complete, the USB-FS updates the BDT and, if KEEP=0,
changes the OWN bit to 0.
4. The STAT register is updated and the TOK_DNE interrupt is set.
5. When the processor processes the TOK_DNE interrupt, it reads from the status
register all the information needed to process the endpoint.
6. At this point, the processor allocates a new BD so that additional USB data can be
transmitted or received for that endpoint, and then processes the last BD.
The following figure shows a timeline of how a typical USB token is processed after the
BDT is read and OWN=1.
Chapter 35 Universal Serial Bus OTG Controller (USBOTG)
KL25 Sub-Family Reference Manual, Rev. 3, September 2012
Freescale Semiconductor, Inc. 619

Table of Contents

Related product manuals