Keyboard

done to optimize the packet size based on the fact that the most common report has only one non- zero scan code without a modifier. The full Standard 101 Keys report format is shown in Table 4-5.

Table 4-5. Standard 101 Keys Report Format

Byte

Name

2

Scan Code 1

(< 0xFC)

 

3Modifier Keys

4Scan Code 2

5Scan Code 3

6Scan Code 4

7Scan Code 5

8Scan Code 6

Example

The following reports is sent if a user presses an ‘a’ on the keyboard. The down key packet sent from the keyboard to the bridge is shown in Table 4-6.

Table 4-6. Example ‘a’ Down Key Standard 101 Keys Report

Byte 2

Scan Code 1

0x04

The bridge then adds the trailing zeros, inserts the reserved byte, rearranges the modifier and scans code 1 bytes and removes the packet header to produce the USB report shown in Table 4-7.

Table 4-7. Example USB Report for the ‘a’ Down Key

Modifier

Reserved

Scan Code

Scan Code

Scan Code

Scan Code

Scan Code

Scan Code

Keys

1

2

3

4

5

6

 

0x00

0x00

0x04

0x00

0x00

0x00

0x00

0x00

The up key packet sent from the keyboard to the bridge (all data bytes are zero) is shown in Table 4-8.

Table 4-8. Example Up Key Standard 101 Keys Report

Byte 2

Scan Code 1

0x00

The bridge then adds the trailing zeros, inserts the reserved byte, and removes the packet header to produce the USB report shown in Table 4-9.

Table 4-9. Example USB Report for a Standard 101 Key Null Packet Report

Modifier

Reserved

Scan Code

Scan Code

Scan Code

Scan Code

Scan Code

Scan Code

Keys

1

2

3

4

5

6

 

0x00

0x00

0x00

0x00

0x00

0x00

0x00

0x00

CY4672 Reference Design Guide, Document # 001-16968 Revision **

67

[+] Feedback

Page 67
Image 67
Cypress CY4672 manual Byte Name, 0xFC, Modifier Reserved Scan Code Keys 0x00 0x04