2017-02-26 02:32 PM
Hello.
I´m having problems on SPI reading WHO_AM_I register of a LSM9DS1 mounted on STEVAL-MKI159V1 : the correct answer is 0x68 but very often I got 0x28. The suspect that the level of bit 6 was not correctly set is confirmed by some traces of the oscilloscope but I need to say that:
1) Attaching probes fixes the problem : for some reasons the loads of probes solve the problem.
2) I got the two attached pictures during the initialization of the board or shaking a little bit cables of a second circuit on a breadboard.
Summarizing the situation : in normal condition I got very often the incorrect value 0x28 but when I connect probes the problem disappears and I have always the correct value 0x68. Only in some conditions - initialization phase in the first 10 seconds or shaking a little bit some connection cables of a breadboard - I got the two attached pictures. I read a post of an user with a similar problem but the conclusion of the story was a suspected damage of the component during the soldering : in my case I bought two STEVAL-MKI159V1 and both have the same problem ...
Let me close adding that I connected STEVAL to a Pic18F25K80 with a SPI clock at 4 MHz.
Thank you and best regards,
Scianni Vincenzo
2017-03-01 05:09 PM
Hello.
Thanks to my colleague Laurent, I found the problem : for a wrong configuration of the pin connected to CS_M - the chip select of magnometer - this pin was always driven low so Magnometer and Accelerometer/Gyroscope were addressed at the same time and, because SDO_A/G and SDO_M share the same MISO line, then the problem.
Regards,
Scianni Vincenzo