Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
USB System Architecture (USB 2.0).pdf
Скачиваний:
172
Добавлен:
03.05.2015
Размер:
7.03 Mб
Скачать

USB System Architecture

Association Between Data Endpoint and Feedback Endpoint

The specification defines the association between isochronous data endpoints and the corresponding endpoint that provides the feedback service. This association is based on endpoint number matching. This is possible because the data endpoint and the feedback endpoint always transfer data in opposite directions. For example a device with an adaptive data endpoint (number 2) that is sourcing data (IN) to an asynchronous endpoint within another device (via the host), would receive explicit feedback from the host on endpoint number 2 (OUT).

When multiple data endpoints share feedback information from the same endpoint, the data endpoints must have endpoint numbers in ascending order from the feedback endpoint. In this way a given data endpoint can always search for the first endpoint that transfers data in the opposite direction and that has an endpoint number that is the same or smaller than its own endpoint number.

Interrupt Transfers

Interrupt transfers are used to poll devices to determine if they have data that needs to be transferred (i.e., if they have an interrupt request pending). If a device does not currently have data to send (i.e., no interrupt is pending), then the device returns no acknowledge, indicating that no data is available to send at this time.

Interrupt transfers are also used to send data to a device on a scheduled basis. If the device is no ready for the data it returns a no acknowledge (NAK) packet indicating the device’s current status.

Service Period

Interrupt transfers are scheduled periodically based on the requirements of the device so that overrun conditions do not occur. Full-speed interrupt transfers can occur as often as every frame or as infrequently as every 255th frame. Lowspeed transfers can occur at a maximum rate of every 10ms or as seldom as every 255ms. The polling interval required by a given device is specified within the interrupt endpoint descriptor. Table 6-5 on page 135 shows the portion of an endpoint descriptor that defines the type and interrupt polling interval. Note that offset 6 defines the polling interval in 1ms increments.

134

Chapter 6: LS/FS Transfer Types & Scheduling

Table 6-5: Endpoint Descriptor’s Interrupt Polling Interval Definition

Offset

Field

Size

Value

Description

 

 

 

 

 

 

 

 

 

 

6

Polling Interval

1

Number

Interval for polling endpoint for data trans-

 

 

 

 

fers. Expressed in milliseconds.

 

 

 

 

This field is ignored for bulk and control

 

 

 

 

endpoints. For isochronous endpoints, this

 

 

 

 

field must be set to 1. For interrupt end-

 

 

 

 

points, this field may range from 1 to 255.

 

 

 

 

 

Bus Bandwidth Allocation

During each frame the maximum data payload supported by interrupt transfers is 64 bytes for full-speed devices. Transfers must always occur at the maximum packet size specified by the endpoint descriptor except for the last transfer. A data packet less than maximum size is viewed as the last transfer.

Like isochronous endpoints, an interrupt pipe requires guaranteed delivery of data within the specified polling interval. Failure to access the endpoint within the polling interval may result in data loss due to buffer overflow. If the available bandwidth cannot support the interrupt pipe, the device is not configured.

Error Recovery

Error recovery for interrupt transfers is supported. If an error is detected during a transfer, it is attempted again during the next service interval. See Chapter 8, entitled "Error Recovery," on page 167 for details regarding error detection and retry.

135

Соседние файлы в предмете [НЕСОРТИРОВАННОЕ]