2019-11-17 11:33 AM
Solved! Go to Solution.
2019-11-18 03:23 AM
Hi @JVerb , well for a full synchronization (nano-second level) you should use an application processor with 20 independent SPI or I2C peripherals... However, please consider that sensors are limited in terms of output data rate (ODR), which is directly related to the internal processing of the sensor electronics, and to the data available at the digital output. For example, a pressure sensor or a temperature sensor monitors environmental parameters, so they can slowly vary without significant changes, and the max ODR for these kinds of sensors in ST portfolio is below 100Hz; a magnetometer has a max 1kHz ODR; a motion sensor such as an accelerometer or a gyroscope runs max at 6kHz; finally, a microphone sensor is more "problematic" than the previous ones, and you should use a dedicated interface because the master-clock can run up to 3MHz.
For all these reasons, you can use the same SPI for a group of sensors (3 or 4), for example at 4MHz speed, driving only the CS separately with a microcontroller. I suggest you to use an MCU with a proper number of interfaces / peripherals, such as an STM32F4 or STM32H7 family MCU, which has 6 SPI interfaces for motion sensors, 4 I2C for temperature/humidity/pressure, 3 I2S for microphones etc. To get a full parallelism you will set properly the interfaces in your FW, but the MCU runs at 480MHz so I think you should be able to get a satisfactory parallelism. For STM32F4 you can find examples of lot of different sensors acquisition in the online available FP-SNS-ALLMEMS1 package. Regards
2019-11-18 03:23 AM
Hi @JVerb , well for a full synchronization (nano-second level) you should use an application processor with 20 independent SPI or I2C peripherals... However, please consider that sensors are limited in terms of output data rate (ODR), which is directly related to the internal processing of the sensor electronics, and to the data available at the digital output. For example, a pressure sensor or a temperature sensor monitors environmental parameters, so they can slowly vary without significant changes, and the max ODR for these kinds of sensors in ST portfolio is below 100Hz; a magnetometer has a max 1kHz ODR; a motion sensor such as an accelerometer or a gyroscope runs max at 6kHz; finally, a microphone sensor is more "problematic" than the previous ones, and you should use a dedicated interface because the master-clock can run up to 3MHz.
For all these reasons, you can use the same SPI for a group of sensors (3 or 4), for example at 4MHz speed, driving only the CS separately with a microcontroller. I suggest you to use an MCU with a proper number of interfaces / peripherals, such as an STM32F4 or STM32H7 family MCU, which has 6 SPI interfaces for motion sensors, 4 I2C for temperature/humidity/pressure, 3 I2S for microphones etc. To get a full parallelism you will set properly the interfaces in your FW, but the MCU runs at 480MHz so I think you should be able to get a satisfactory parallelism. For STM32F4 you can find examples of lot of different sensors acquisition in the online available FP-SNS-ALLMEMS1 package. Regards
2019-11-18 03:56 AM
>... and you need to read the value of each sensor exact at the same time ...
Define "exact the same time".
Ambient characteristics as temperature and pressure have very small rates of change, a once-per-second sampling rate would be more then sufficient.