STM32F103 VS MKI194V1(LSM6DSR)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-11-02 9:46 AM
Hi,
I'm currently using the STM32F103 SPI to read the MKI194V1, but I've noticed that the ID I'm reading is always 0x4A. Could you please help me check if there's an issue, or provide any sample code?
I also take a photo of the MKI194V1. The marking on the surface I think is SR 934
- Labels:
-
SPI
-
STM32CubeMX
-
STM32F1 Series
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-11-02 10:24 AM
The WHO_AM_I register should be 0x6B
I'd probably use the Transmit_Receive methods to ensure that the chip-select doesn't go high too early.
ACCELERO_IO_Read https://github.com/STMicroelectronics/STM32CubeF4/blob/master/Drivers/BSP/STM32F4-Discovery/stm32f4_discovery.c#L575
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-11-09 9:42 PM
Thanks for your help.
I found that sometimes I can receive the correct value (0x6B) and sometimes I can't. I suspect it might be a timing issue, but I haven't found a solution yet.
