AnsweredAssumed Answered

SensorTile Drivers and Implementation

Question asked by Dylan144GT on Mar 20, 2018
Latest reply on Apr 18, 2018 by Davide G

Hello All,

 

I am having a a bit of an issue working with my SensorTile kit. I am able to get the demo apps working and so on, but I now want to start on my own project.

 

For the moment I have just tried to set the MCU up using CubeMX and I am trying to use the StdC Libs from ST's GitHub and I am only concentrating on the LSM6DSM. From what I understand all one has to do is write a function for SPI TX and RX and the rest should be taken care of by the driver. I have tried to emulate what the provided example does, but when I try to test communication by reading the WHO_AM_I register, I get no response. Attached is my main.c file and a screen shot of how I set SPI2 up in half duplex master mode. I have also attached the SPI.c that is generated by CubeMX.

 

If anyone can see anything I am doing incorrectly, please don't hesitate to point it out. Or Is it perhaps worth moving to the drivers in the x-cube-mems1 drivers.

 

Thanks,

 

Dylan

Attachments

Outcomes