This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
resources:tools-software:linux-drivers:input-misc:adxl345 [16 Jan 2013 16:09] – [Example platform device initialization] Michael Hennerich | resources:tools-software:linux-drivers:input-misc:adxl345 [07 Sep 2018 08:41] (current) – [Description] add adx375 link to ADI product page Alexandru Ardelean | ||
---|---|---|---|
Line 5: | Line 5: | ||
* [[adi> | * [[adi> | ||
* [[adi> | * [[adi> | ||
+ | * [[adi> | ||
Line 13: | Line 14: | ||
===== Evaluation Boards ===== | ===== Evaluation Boards ===== | ||
- | * [[adi> | + | |
- | * [[adi> | + | |
+ | * [[adi> | ||
+ | * [[adi> | ||
===== Description ===== | ===== Description ===== | ||
Line 30: | Line 33: | ||
[[adi> | [[adi> | ||
[[adi> | [[adi> | ||
+ | [[adi> | ||
+ | |||
{{youtube> | {{youtube> | ||
Line 96: | Line 101: | ||
===== Status ===== | ===== Status ===== | ||
- | ^ Source | + | ^ Source ^ Mainlined? ^ |
- | | [[git.linux.org> | + | | [[git.linux.org> |
Line 627: | Line 632: | ||
</ | </ | ||
+ | ===== Devicetree ===== | ||
+ | |||
+ | Required devicetree properties: | ||
+ | * compatible: Needs to be " | ||
+ | * reg: The chipselect number used for the device | ||
+ | * spi-max-frequency: | ||
+ | * spi-cpha: Needs to be set for the correct SPI mode | ||
+ | * spi-cpol: Needs to be set for the correct SPI mode | ||
+ | * interrupt-parent: | ||
+ | * interrupts: The interrupt associated with the INT2 pin | ||
+ | |||
+ | < | ||
+ | | ||
+ | # | ||
+ | # | ||
+ | | ||
+ | ... | ||
+ | |||
+ | | ||
+ | | ||
+ | reg = <0>; | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | }; | ||
+ | }; | ||
+ | </ | ||
===== Example Platform / Board file (I2C Interface Option) ===== | ===== Example Platform / Board file (I2C Interface Option) ===== | ||
Line 659: | Line 693: | ||
arch_initcall(board_init); | arch_initcall(board_init); | ||
</ | </ | ||
+ | |||
+ | ===== Devicetree ===== | ||
+ | |||
+ | Required devicetree properties: | ||
+ | * compatible: Needs to be " | ||
+ | * reg: The slave address of the device | ||
+ | * interrupt-parent: | ||
+ | * interrupts: The interrupt associated with the INT2 pin | ||
+ | |||
+ | < | ||
+ | | ||
+ | # | ||
+ | # | ||
+ | | ||
+ | ... | ||
+ | |||
+ | | ||
+ | | ||
+ | reg = < | ||
+ | | ||
+ | | ||
+ | }; | ||
+ | }; | ||
+ | </ | ||
+ | |||
====== Adding Linux driver support ====== | ====== Adding Linux driver support ====== | ||
Line 765: | Line 824: | ||
</ | </ | ||
- | ===== Use the event_test | + | ===== Use the evtest |
< | < | ||
- | root:/> | + | root:/> |
Input driver version is 1.0.0 | Input driver version is 1.0.0 | ||
Input device ID: bus 0x18 vendor 0x0 product 0x159 version 0x0 | Input device ID: bus 0x18 vendor 0x0 product 0x159 version 0x0 |