Author Topic: .  (Read 1536 times)

0 Members and 1 Guest are viewing this topic.

Offline fullmoon6661Topic starter

  • Newbie
  • Posts: 6
  • Country: 00
.
« on: July 02, 2022, 01:27:22 am »
.
« Last Edit: July 19, 2024, 07:30:12 pm by fullmoon6661 »
 

Offline dmendesf

  • Frequent Contributor
  • **
  • Posts: 339
  • Country: br
Re: STM32: Dual simultaneous SPI data input on STM32F1?
« Reply #1 on: July 02, 2022, 04:00:45 am »
Use 2 SPIs, one as master and other as a slave. Connect clock and CS together. Use master SPI to drive adc and get one datastream. Slave SPI gets the other datastream automagically.
 
The following users thanked this post: fullmoon6661

Offline pcprogrammer

  • Super Contributor
  • ***
  • Posts: 4346
  • Country: nl
Re: STM32: Dual simultaneous SPI data input on STM32F1?
« Reply #2 on: July 02, 2022, 05:53:16 am »
The 2 spi setup dmendesf gave is the way to go, but have you thought about what you are going to do with 2 times 16bit 1Msps of data coming into the STM32F103?

You need DMA to get the samples into the memory to not burden the CPU, but there is not a lot of memory to store the samples.

And even though it is a quick MCU then do processing on the samples and spit them out to some other system is also a bit of a load. Sure it can be done but not with sustained data.

With USB I managed to get a single channel of sustained 16bit 100Ksps to stream to a PC. Needed to write my own USB driver under linux to make it work.


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf