1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2c66ec88fSEmmanuel Vadot%YAML 1.2 3c66ec88fSEmmanuel Vadot--- 4c66ec88fSEmmanuel Vadot$id: http://devicetree.org/schemas/input/matrix-keymap.yaml# 5c66ec88fSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml# 6c66ec88fSEmmanuel Vadot 78bab661aSEmmanuel Vadottitle: Common Key Matrices on Matrix-connected Key Boards 8c66ec88fSEmmanuel Vadot 9c66ec88fSEmmanuel Vadotmaintainers: 10c66ec88fSEmmanuel Vadot - Olof Johansson <olof@lixom.net> 11c66ec88fSEmmanuel Vadot 12c66ec88fSEmmanuel Vadotdescription: | 13c66ec88fSEmmanuel Vadot A simple common binding for matrix-connected key boards. Currently targeted at 14c66ec88fSEmmanuel Vadot defining the keys in the scope of linux key codes since that is a stable and 15c66ec88fSEmmanuel Vadot standardized interface at this time. 16c66ec88fSEmmanuel Vadot 17c66ec88fSEmmanuel Vadot Some users of this binding might choose to specify secondary keymaps for 18c66ec88fSEmmanuel Vadot cases where there is a modifier key such as a Fn key. Proposed names 19c66ec88fSEmmanuel Vadot for said properties are "linux,fn-keymap" or with another descriptive 20c66ec88fSEmmanuel Vadot word for the modifier other from "Fn". 21c66ec88fSEmmanuel Vadot 22c66ec88fSEmmanuel Vadotproperties: 23c66ec88fSEmmanuel Vadot linux,keymap: 24*fac71e4eSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32-array 25c66ec88fSEmmanuel Vadot description: | 26c66ec88fSEmmanuel Vadot An array of packed 1-cell entries containing the equivalent of row, 27c66ec88fSEmmanuel Vadot column and linux key-code. The 32-bit big endian cell is packed as: 28c66ec88fSEmmanuel Vadot row << 24 | column << 16 | key-code 29c66ec88fSEmmanuel Vadot 30c66ec88fSEmmanuel Vadot keypad,num-rows: 31c66ec88fSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 32c66ec88fSEmmanuel Vadot description: Number of row lines connected to the keypad controller. 33c66ec88fSEmmanuel Vadot 34c66ec88fSEmmanuel Vadot keypad,num-columns: 35c66ec88fSEmmanuel Vadot $ref: /schemas/types.yaml#/definitions/uint32 36c66ec88fSEmmanuel Vadot description: Number of column lines connected to the keypad controller. 37c66ec88fSEmmanuel Vadot 386be33864SEmmanuel VadotadditionalProperties: true 396be33864SEmmanuel Vadot 40c66ec88fSEmmanuel Vadotexamples: 41c66ec88fSEmmanuel Vadot - | 42c66ec88fSEmmanuel Vadot keypad { 43c66ec88fSEmmanuel Vadot /* ... */ 44c66ec88fSEmmanuel Vadot linux,keymap = < 0x00030012 45c66ec88fSEmmanuel Vadot 0x0102003a >; 46c66ec88fSEmmanuel Vadot keypad,num-rows = <2>; 47c66ec88fSEmmanuel Vadot keypad,num-columns = <8>; 48c66ec88fSEmmanuel Vadot }; 49