Hi guys, I just want to know if there's a way for the above and how if yes.
Hi guys, I just want to know if there's a way for the above and how if yes.
Hi,
Recently I tried to read some data from icm20602 sensor by spi. But I had some trouble, it seemed that code can't read the right data from the sensor, such as sensor's default device ID(0x12). I'm confused about it. If you have some suggentions? Or do you have any examples?
Thanks a lot
Jerry
Hi Jerry,
That could be a problem with SPI PHASE and POLARITY.
Kindly check all the 4 cases with those.
Warm Regards,
Kumar
Hi Jerry,
That could be a problem with SPI PHASE and POLARITY.
Kindly check all the 4 cases with those.
Warm Regards,
Kumar
Hi,Kumar
I had think about that and I've tried to check all the 4 cases. But, strangely, the device ID returned was always 0x00 in the 4 cases.....
nrf_drv_spi_transfer() returned NRF_SUCCESS, seemed that there's no problem in transmission. But the returned value 0x00 showed that read_data function wasn't work.......
Have you read and write icm successfully by spi?Can you show me your code for a example?
thanks a lot.
Jerry
Hi Jerry,
Should there be a command delay between the write, read functions?
Or try a different function for reading from SPI DRIVER instead of spi_transfer one. HAL_SPI DRIVER functions are better if we have.
Also, make sure that MISO and MOSI are properly connected, just in case.
No, I couldn't work on that sensor as I moved to a ST one