2021-05-26 03:34 PM
Hello, I am attempting to communicate using SPI with an H3LIS331 accelerometer. The H3LIS331 is on a custom board that originally had a LIS3DSH on it. The LIS3DSH had been working without a problem, but we were looking to expand the acceleration scale.
No matter what register I attempt to access, the MISO line puts out one byte of 0xFF and one byte of 0x00. See the attached logic analyzer screenshot, which shows writing to 3 CTRL registers and then attempting to read the WHO_AM_I register. The SPI traffic in the screenshot is the first to occur after powering the board on.
Additional information:
I did notice that the MISO line has an unusual "long tail" after the low byte; see the attached oscilloscope capture which also shows the SPI clock. That might be a symptom of some fundamental problem, but isn't a problem in itself.
Can you see anything I'm missing, or do you have suggestions of what to check next? Thanks!
2021-05-27 03:45 AM
Hi @MRigg.1 ,
the H3LIS331(DL) and the LIS3DSH are pin-to-pin (and voltage) compatible, so in principle there should be no difference. The suggested electrical connections are the same too.
So I believe there could be two reason for the malfunction:
Another point to test is to check the timings you can find in the p.11 of the datasheet:
Can you confirm they are fulfilled?
-Eleon
2021-05-27 10:53 AM
Hello Eleon,
Thanks for the fast response!
All of the timing parameters are met except for t_dis(SO), which is very out of spec at ~650 ns (compared to the maximum 50 ns spec). See the attached screenshot. This may point to damage to the H3LIS331, I'm not sure. I don't have access to the pads themselves, only the traces as they leave the chip footprint. I have applied pressure on the chip to try and force contact, but I didn't see a change in behavior.
Regarding parasitics, I slowed the SCLK down to 1.9 MHz to test this, but the behavior is the same as described in my initial post.
At this point, I'm going to get another H3LIS331 swapped in and hope for different behavior. If you have other suggestions to try, I would appreciate them.
Thanks again!
-Matt
2022-02-04 08:33 AM
Me too, no solutions