2024-02-08 06:10 AM
Hi
I am using the LIS2MDL Magnetometer, which is connected to i2c0 on my custom board. I have enabled the respective kernel configuration for the magnetometer.
CONFIG_IIO_ST_SENSORS_I2C=y
CONFIG_IIO_ST_SENSORS_SPI=y
CONFIG_IIO_ST_SENSORS_CORE=y
CONFIG_IIO_ST_MAGN_3AXIS=y
CONFIG_IIO_ST_MAGN_I2C_3AXIS=y
CONFIG_IIO_ST_MAGN_SPI_3AXIS=y
The implemented device tree is provided below.
\{
regulator_1: regulator-1 {
compatible = "regulator-fixed";
regulator-name = "regulator.1";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};
};
&i2c0 {
status = "okay";
lis2mdl: lis2mdl@1e {
compatible = "st,lis2mdl";
reg = <0x1e>;
vdd-supply = <®ulator_1>;
vddio-supply = <®ulator_1>;
};
};
When my board booted up, I checked whether the driver was probed or not. However, it did not get probed. I have attached my dmesg log below.
[ 4.624377] st-magn-i2c 0-001e: supply vdd not found, using dummy regulator
[ 4.631410] st-magn-i2c 0-001e: supply vddio not found, using dummy regulator
[ 4.638715] iio iio:device3: DRDY on pdata not valid.
[ 4.643880] st-magn-i2c: probe of 0-001e failed with error -22
[ 4.649725] cdns-i2c ff020000.i2c: 400 kHz mmio ff020000 irq 38
The hardware connections that we checked are fine, but I don't know why this error is happening. Can anyone kindly assist me in debugging this issue?
Solved! Go to Solution.
2024-02-09 05:53 AM
Hi @Perumalsamy ,
Can you try to use our official drivers and let me know if the problem persists?
2024-02-09 05:53 AM
Hi @Perumalsamy ,
Can you try to use our official drivers and let me know if the problem persists?
2024-02-09 06:00 AM
Thank You @Federica Bossi