android buttons definition

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

android buttons definition

Jump to solution
753 Views
jfsimon
Contributor III

Hi,

I understand android buttons can be hooked to any PAD on the i.mx6 CPUs.

For example on the sabrelite,  i can see android buttons are defined in u-boot like the followoing:

board/freescale/mx6qsabrelite/mx6qsabrelite.c:

........

static struct button_key const buttons[] = {

        {"back",        IMX_GPIO_NR(2, 2),      'B'},

        {"home",        IMX_GPIO_NR(2, 4),      'H'},

        {"menu",        IMX_GPIO_NR(2, 1),      'M'},

        {"search",      IMX_GPIO_NR(2, 3),      'S'},

        {"volup",       IMX_GPIO_NR(7, 13),     'V'},

        {"voldown",     IMX_GPIO_NR(4, 5),      'v'},

};

........

My question is how android is made aware of this PAD to buttons mapping?

Thanks a lot

-jfs

Labels (2)
0 Kudos
1 Solution
538 Views
daiane_angolini
NXP Employee
NXP Employee

Take a look on kernel image, on board file

it should be something like:

<kernel>/arch/arm/mach-mx6/board-imx6sabrelite.c

You will see kernel defines buttons as well

View solution in original post

0 Kudos
1 Reply
539 Views
daiane_angolini
NXP Employee
NXP Employee

Take a look on kernel image, on board file

it should be something like:

<kernel>/arch/arm/mach-mx6/board-imx6sabrelite.c

You will see kernel defines buttons as well

0 Kudos