---
name: "matrix_keypad_build_keymap"
section: "9"
platform: "linux"
package: "linux-manual-3.2"
version: "3.2.78-1"
release: "Debian 7 (Wheezy)"
platforms: ["linux"]
url: "https://new.carta.tech/matrix_keypad_build_keymap"
---

# matrix\_keypad\_build\_keymap(9)

convert platform keymap into matrix keymap

## NAME

matrix\_keypad\_build\_keymap - convert platform keymap into matrix keymap

## SYNOPSIS

**void matrix\_keypad\_build\_keymap(const struct matrix\_keymap\_data \*** *keymap\_data***, unsigned int** *row\_shift***, unsigned short \*** *keymap***, unsigned long \*** *keybit***);**

## ARGUMENTS

*keymap\_data*

keymap supplied by the platform code

*row\_shift*

number of bits to shift row value by to advance to the next line in the keymap

*keymap*

expanded version of keymap that is suitable for use by matrix keyboad driver

*keybit*

pointer to bitmap of keys supported by input device

## DESCRIPTION

This function converts platform keymap (encoded with **KEY** macro) into an array of keycodes that is suitable for using in a standard matrix keyboard driver that uses row and col as indices.

## COPYRIGHT
