Changes between Version 3 and Version 4 of Android/OSDevelopment
- Timestamp:
- 08/26/2020 08:19:59 PM (5 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Android/OSDevelopment
v3 v4 44 44 [=#gsc-pushbutton] 45 45 ==== GSC User Pushbutton ==== 46 The [wiki:gsc Gateworks System Controller] functions as a pushbutton controller for the front-panel user pushbutton available on most Ventana boards. This particular button is available as gpio-240 on Ventana boards however there is a [wiki:gsc#inputdriver gsc-input driver]that converts GSC related interrupts, such as push-button press-and-release to Linux Input events.46 The [wiki:gsc Gateworks System Controller] functions as a pushbutton controller for the front-panel user pushbutton available on most Ventana boards. This particular button is available as gpio-240 on Ventana boards however there is a gsc-input driver that converts GSC related interrupts, such as push-button press-and-release to Linux Input events. 47 47 48 48 By default note that the GSC is configured such that the user pushbutton is a hard reset. To configure it instead to be software controlled you need to set GSC CTRL_0 accordingly depending on the actions you wish to catch. For example: … … 53 53 }}} 54 54 55 The [wiki:gsc#inputdriver gsc-input driver]will catch all enabled GSC interrupts and emit a Linux Input event with a key-code cooresponding to a button (defined in Linux input.h). For example the GSC_IRQ_PB (pushbutton press-and-release) interrupt is mapped to BTN_0 which is defined as 0x100 (decimal 256) in [https://lxr.missinglinkelectronics.com/linux/include/uapi/linux/input.h#L481 input.h].55 The gsc-input driver will catch all enabled GSC interrupts and emit a Linux Input event with a key-code cooresponding to a button (defined in Linux input.h). For example the GSC_IRQ_PB (pushbutton press-and-release) interrupt is mapped to BTN_0 which is defined as 0x100 (decimal 256) in [https://lxr.missinglinkelectronics.com/linux/include/uapi/linux/input.h#L481 input.h]. 56 56 57 57 There exists a key layout file that maps the Linux input event keycodes to Android key events in /system/usr/keylayout/gsc_input.kl: … … 76 76 For more information see: 77 77 * [wiki:gsc#pushbutton GSC pushbutton] 78 * [wiki:gsc#inputdriver gsc-input kernel driver]79 78 * [wiki:gsc#gsc_ctrl_0 GSC_CTRL_0 register] 80 79 * [wiki:gsc#gsc_interrupt_status GSC_INTERRUPT_STATUS register]