CHAPTER 6 USB CONTROLLER
Preliminary User’s Manual S15543EJ1V0UM 339
(1) First, the VR4120A prepares the data to be transmitted in system memory.
(2) The VR4120A reads the USB Command Register.
(3) The VR4120A checks whether the Busy bit of the USB Command Register is set. If the Busy bit is set, it
indicates that USB Controller is still executing the previous command. Thus the VR4120A can not issue a
new command.
(4) The VR4120A reads the USB Tx EndPoint Status Register.
(5) The VR4120A checks whether the EndPoint that is to perform transmission next is in the Busy status. If the
EndPoint is Busy, the VR4120A repeats the processing from the reading of the USB Tx EndPoint Status
Register.
(6) The VR4120A issues the Tx command.
(7) The VR4120A reads the USB General Status Registers 1.
(8) The VR4120A checks whether transmission has completed.
(9) The VR4120A reads the contents of the USB Tx Mailbox Read Address Register.
(10) The VR4120A reads the transmit Indication.
(11) The VR4120A updates the contents of the USB Tx MailBox Read Address Register.
By issuing a transmit command, the transmission of a data segment can be scheduled.
A transmit command is issued by writing a value into the registers listed below. When writing, it is necessary to
write first to the USB Command Extension Register, then the USB Command Register.
If data size field of USB Command Register is “0”, USB Controller transmits Zero-Length Packet.
The size of data set by the transmission command and the total size of data buffer to be transmitted have to be the
same value.
Figure 6-8. Transmit Command Issue
313029282726252423222120191817161514131211109876543210
ReservedCommand Data SizeReserved
31 16 15 0
Address
write start address of Tx data
segment
Specifies EndPoint Number
000: EndPoint0 (Control)
001: EndPoint1 (Isochronous)
010: EndPoint3 (Bulk)
011: EndPoint5 (Interrupt)
USB Command Register (40H)
USB Command Extension Register (44H)
For a given EndPoint, it is possible to schedule the transmitting of up to two data items. Once two data have been
scheduled, even if the VR4120A writes a transmit command into the USB Command Register to transmit a third data,
that command cannot be accepted until the first scheduled data is transmitted.
The number of data items that are scheduled for transmission can be determined by reading the USB Tx EndPoint
Status Register.