| 数据搜索系统,热门电子元器件搜索 |
|
PC87373 数据表(PDF) 127 Page - National Semiconductor (TI) |
|
|
|
|||||||||||||||||||||||||||||
PC87373 数据表(HTML) 127 Page - National Semiconductor (TI) |
|
127 / 174 page ![]() 10.0 Game Port (GMP) (Continued) 127 www.national.com Revision 1.1 A simple push-button mechanism is typically used to implement the game device buttons. The status of each button is sensed by the Game Port via the JOYnBTN0,1 pins as either high or low, and reflected by the GMPST register. It is the responsibility of the software to determine the actual status of the buttons according to their polarity, which depends on the specific implementation of the system and the game device. 10.2.4 Game Port Operation The Game Port monitors the game device position and button status indicators by polling their status at a specific moment via the Game Port Status register (GMPST, see Section 10.3.2). The process of reading the position status of the game device(s) is initiated by performing a write access to the GMPST register. This write access causes the Game Port to release the JOYnX,Y pins. When a JOYnX,Y pin is released, the cor- responding bit in the GMPST register is set to 1. To capture the position indicated by the game device, the software should poll the GMPST register and measure the time it takes for the JOYnX,Y to go high. This measurement should be performed by measuring the time during which an axis bit is 1. Reading the status of the buttons of the game device is done by polling the GMPST register and looking for changes in the bits reflecting the status of the JOYnBTN0,1 pins. Optional debouncers for the button status pins can be enabled by setting the DBNC_EN bit of the Game Port Configuration register to 1. The Game Port Configuration register is located at Index F0h in the Game Port’s logical device configuration space (see Section 3.16.2 on page 70). These debouncers can be used to ensure that the status of a button pin is reflected by the associated GMPST bit only after that pin has been stable for at least 16 ms. If the debouncers are not enabled (de- fault), it is the responsibility of the software to implement the debounce for the button status pins, if necessary. |
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |