LIS3MDLTR Compass not getting detected


hwdef.txt (4.7 KB)

Hello Everyone!
I am trying to integrate ICM-20948 IMU with LIS3MDLTR compass.
so the micro-controller used here is STM32-H7, I have shown block diagram for the reference.

so IMU and magnetometer both are connected to same spi pins of h7
PE5 - MISO
PE6 - MOSI
PE2 - SCK

And two chip select pins for the IC’s
PE4 - FOR IMU
PC15 - FOR LIS3MDLTR

I have attached hwdef file for your reference, so the LIS3MD is not getting detected but ICM-20948
is working fine. the internal compass which IMU has it is also working.

but only LIS3MD is not getting detected ???
I am confused what’s going wrong?