5 data transmit function, 1 overview of transmit processing, 2 tx buffer configuration – NEC Network Controller uPD98502 User Manual

Page 334: D ata s egm ent

Advertising
background image

CHAPTER 6 USB CONTROLLER

334

Preliminary User’s Manual S15543EJ1V0UM

6.5 Data Transmit Function

This section explains USB Controller's data transmit function.

6.5.1 Overview of transmit processing

USB Controller divides the data segments in system memory, into USB packets, then transmits them to the Host

PC. The V

R

4120A sets the size of USB packet in the MAXP field of the EP0 Control Register, the EP1-2 Control

Register, the EP3-4 Control Register, and the EP5-6 Control Register (in the example shown below, a value of 64

bytes has been set).

Figure 6-4. Division of Data into USB Packets

D ata S egm ent

U SB

Packet

U SB

Packet

U SB

Packet

U SB

Packet

U SB

Packet

64 Byte s

64 Byte s

64 Byte s

64 Byte s 40 Byte s

Last USB packet in a data segment will be smaller than the value set in the MAXP field (40 bytes in the example

shown above). As a result, the Host PC can identify the boundary between data segments. When the last USB packet

size is equal to the value in the MAXP field, a zero-length USB packet will be transmitted after the last item of the

divided data in transmit SZLP Mode. In transmit NZLP Mode, a zero-length USB packet is not transmitted. For an

explanation of the transmit modes, see Section 6.5.3 Data transmit modes.

After all the data segments have been transferred, USB Controller writes the "transmit indication" which has

transmit status information into the MailBox in system memory.

For an explanation of the transmit indication, see Section 6.5.6 Tx indication.

Data segments transmission time at a given EndPoint can be scheduled upon the issue of the corresponding

transmit command. The current transmit status can be determined by reading the contents of the USB Tx EndPoint

Status Register (Address: 1000_1048H).

For an explanation of how to issue the transmit command, see Section 6.5.4 V

R

4120A processing at data

transmitting.

6.5.2 Tx buffer configuration

The V

R

4120A creates a Tx buffer in system memory, then informs USB Controller to transmit data to the Host PC.

The configuration of the Tx buffer is as shown below.

Advertising