
UM10375
All information provided in this document is subject to legal disclaimers.
© NXP B.V. 2011. All rights reserved.
User manual
Rev. 3 — 14 June 2011
151 of 368
NXP Semiconductors
UM10375
Chapter 10: LPC13xx USB device controller
10.10.3.4 USB Transmit Packet Length register (USBTxPLen - 0x4002 0024)
This indicates the number of bytes still to be transferred from the processor to the RAM.
The processor has to program this register with the byte length of the packet to be sent,
before writing to the Transmit Data Register. The processor can read this register to
determine the number of bytes it has transferred to the memory.
Remark:
To transfer an empty packet, this register has to be set to 0x00 and a single write
operation has to be performed on the Transmit Data Register.
10.10.3.5 USB Control register (USBCtrl - 0x4002 0028)
This register controls the data transfer operation of the USB device. It selects the endpoint
buffer that is accessed by the USBRxData and USBTxData registers and enables reading
and writing them. USBCtrl is a read/write register.
Table 171. USB Receive Packet Length register (USBRxPLen - address 0x4002 0020) bit
description
Bit
Symbol
Value
Description
Reset
value
9:0
PKT_LNGTH -
The remaining number of bytes to be read from the
currently selected endpoint’s buffer. When this field
decrements to 0, the RxENDPKT bit will be set in
USBDevIntSt.
0
10
DV
Data valid. This bit is useful for isochronous endpoints.
Non-isochronous endpoints do not raise an interrupt when
an erroneous data packet is received. But invalid data
packet can be produced with a bus reset. For isochronous
endpoints, data transfer will happen even if an erroneous
packet is received. In this case DV bit will not be set for the
packet.
0
0
Data is invalid.
1
Data is valid.
31:11 -
-
Reserved, user software should not write ones to reserved
bits. The value read from a reserved bit is not defined.
NA
Table 172. USB Transmit Packet Length register (USBTxPLen - address 0x4002 0024) bit
description
Bit
Symbol
Description
Reset
value
9:0
PKT_LNGTH The remaining number of bytes to be written to the selected
endpoint buffer. This field is decremented by 4 by hardware after
each write to USBTxData. When this field decrements to 0, the
TxENDPKT bit will be set in USBDevIntSt.
0
31:10 -
Reserved, user software should not write ones to reserved bits.
The value read from a reserved bit is not defined.
-