boards: Set devicetree alias for ST IIS2DLPC nodes

Set accel0 alias for all boards with the IIS2DLPC accelerometer
to use by the accel_polling sample.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
This commit is contained in:
TOKITA Hiroshi 2022-07-22 08:09:41 +09:00 committed by Maureen Helm
parent 342f74a792
commit 2432555b54
2 changed files with 14 additions and 2 deletions

View file

@ -13,9 +13,15 @@
* ISM330DHCX, IIS2MDC and IIS2DLPC sensors are accessible from the main board mcu. * ISM330DHCX, IIS2MDC and IIS2DLPC sensors are accessible from the main board mcu.
*/ */
/ {
aliases {
accel0 = &iis2dlpc;
};
};
&arduino_i2c { &arduino_i2c {
iis2dlpc@19 { iis2dlpc: iis2dlpc@19 {
compatible = "st,iis2dlpc"; compatible = "st,iis2dlpc";
reg = <0x19>; reg = <0x19>;
drdy-gpios = <&arduino_header 4 GPIO_ACTIVE_HIGH>; /* A4 - INT2 */ drdy-gpios = <&arduino_header 4 GPIO_ACTIVE_HIGH>; /* A4 - INT2 */

View file

@ -15,9 +15,15 @@
* declared in DTS file. * declared in DTS file.
*/ */
/ {
aliases {
accel0 = &iis2dlpc;
};
};
&arduino_i2c { &arduino_i2c {
iis2dlpc@19 { iis2dlpc: iis2dlpc@19 {
compatible = "st,iis2dlpc"; compatible = "st,iis2dlpc";
reg = <0x19>; reg = <0x19>;
drdy-gpios = <&arduino_header 4 GPIO_ACTIVE_HIGH>; /* A4 - INT2 */ drdy-gpios = <&arduino_header 4 GPIO_ACTIVE_HIGH>; /* A4 - INT2 */