&i2c0 {
status = "ok";
#address-cells = <0x1>;
#size-cells = <0x0>;
lsm6dsm@6b {
compatible = "st,lsm6dsm";
reg = <0x6b>;
interrupt-parent = <&gpio>;
interrupts = <26 IRQ_TYPE_LEVEL_HIGH>;
};
7. Kernel configuration
Configure kernel with *make menuconfig*
> Device Drivers --->
> <M> Industrial I/O support --->
> Inertial measurement units --->
> <M> STMicroelectronics LSM6DSM/LSM6DSL sensor --->
8. Built the driver as module st-lsm6dsm.ko into the kernel and rebuilt the iso successfully.
9. But still i'm not able to see the device enumerated like below /dev/iio:device*
/sys/devices/iio:device*
(this is because kernel do not know that which I2C port to use after loading the appropriate driver module)