The DSP has general-purpose and dedicated registers in each of its functional blocks, страница 34

Table B-43. USB SETUP Token Data Register

Byte        7                                             0

Data 0

Data 1

Data 2

Data 3

Data 4

Data 5

Data 6

Data 7

0

1

2

3

4

5

6

7

USB SETUP C ounter Re g ister

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

X

X

X

X

X

X

X

X

X

X

X

X

C3

C2

C1

C0

Figure B-15. USB SETUP Counter Register

Provides information as to the total size of the SETUP transaction data stage. This register is read/write by the MCU only.

C[3:0]       Counter bits.

The counter hardware is a modulo 4 bit down counter used for tallying data bytes in both the IN and OUT data stages of SETUP transactions. As such, the count value stored has different meanings.

IN Transfers:

The MCU loads the counter with the number of bytes to transfer (must be 8 or less since the USB Setup Token Data Register file is 8 bytes maximum). The USB interface then decrements the count value after each byte is transferred to the host.

OUT Transfers:

Starting from a cleared value of 0, the counter is decremented with each byte received from the host, including the two CRC bytes. For example, if 8 bytes are received, the count value progresses from 15, 14, 13, etc. to a value of 6 (inclusive is the 2 CRC bytes). The MCU reads the value and subtracts it from 14 to determine the actual number of data bytes in the USB Setup Token Register file (14 - 6 = 8 bytes).

USB Register I/O Address Register

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

A15

A14

A13

A12

A11

A10

A9

A8

A7

A6

A5

A4

A3

A2

A1

A0

Figure B-16. USB Register I/O Address Register

Contains the address of the ADSP-2192 register that is to be read/written. This register is read/write by the MCU only.

Table B-44. USB Register I/O Address Register

A[15]

MCU sets to 1 to notify the PDC Register Interface block to start ADSP-2192 read/write cycle. PDC Register Interface block clears to 0 to notify MCU the read/write cycle has completed.

A[14]

1 = WRITE, 0 = READ

A[13:0]

ADSP-2192 address to read/write

USB Register I/O Data Register

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

D15

D14

D13

D12

D11

D10

D9

D8

D7

D6

D5

D4

D3

D2

D1

D0

Figure B-17. USB Register I/O Data Register

Contains the data of the ADSP-2192 register which has been read or is to be written. This register is read/write by the MCU only.

Table B-45. USB Register I/O Data Register

D[15:0]

During READ this register contains the data read from the ADSP-2192, during WRITE this register is the data to be written to the ADSP-2192


USB Control Register