Skip to main content
Evelina CAMILLERI
ST Employee
June 20, 2022
Solved

How do I enable MLC code in LSM6DSOX driver in Linux 5.10, is there any example?

  • June 20, 2022
  • 1 reply
  • 1070 views

..

    This topic has been closed for replies.
    Best answer by Evelina CAMILLERI

    The LSM6DSOX driver for linux IIO:

    https://github.com/STMicroelectronics/STMems_Linux_IIO_drivers/tree/linux-4.19.y-gh/drivers/iio/imu/st_lsm6dsox

    embeds a sample code that configures the MLC / FSM for "6D position recognition", this creates an IIO device for generating events when detected the 6D position once enabled through the sysfs by writing 1 in the file:

    /sys/bus/iio/devices/iio:device<x>/events/in_activity0_thresh_rising_en

    where x represents the IIO index for this MLC/FSM device that depends on the already available IIO devices registered in the board.

    The sample code embedded in the IIO LDD can be customized by using the already available application examples for MLC: https://github.com/STMicroelectronics/STMems_Machine_Learning_Core/tree/master/application_examples

    1 reply

    Evelina CAMILLERI
    Evelina CAMILLERIAuthorBest answer
    ST Employee
    June 20, 2022

    The LSM6DSOX driver for linux IIO:

    https://github.com/STMicroelectronics/STMems_Linux_IIO_drivers/tree/linux-4.19.y-gh/drivers/iio/imu/st_lsm6dsox

    embeds a sample code that configures the MLC / FSM for "6D position recognition", this creates an IIO device for generating events when detected the 6D position once enabled through the sysfs by writing 1 in the file:

    /sys/bus/iio/devices/iio:device<x>/events/in_activity0_thresh_rising_en

    where x represents the IIO index for this MLC/FSM device that depends on the already available IIO devices registered in the board.

    The sample code embedded in the IIO LDD can be customized by using the already available application examples for MLC: https://github.com/STMicroelectronics/STMems_Machine_Learning_Core/tree/master/application_examples