2025-08-17 4:49 PM
I write six 32-bit floats to RAM every 10 µs (100 kHz) via DMA. I batch and flush every 10 ms → 1000 samples × 24 B = 24 kB per block → 2.4 MB/s average.
RAM buffers: planning double/triple buffering (48–72 kB) in SRAM1/2 (CCM isn’t DMA-accessible).SPI SD card path:
• Is ~2.4 MB/s sustained feasible over SPI-mode SD on F407?
• Proven settings welcome: SPI clock, DMA, FatFs multi-block writes, file pre-allocation, 4–32 kB write chunks, f_sync cadence, and buffer size to ride out SD write stalls.
• (I know SDIO 4-bit is safer; I’m asking specifically about SPI-mode viability.)USB path:
• USB FS (12 Mb/s) can’t sustain 2.4 MB/s payload.
• With USB HS (480 Mb/s + external ULPI PHY) it should be easy: 24 kB every 10 ms is ~4.5% bus.
• Any working configs for CDC vs raw Bulk, 512-B packets, TX FIFO sizing, DMA double-buffering, and host side (WinUSB/libusb/Matlab) readers?Fallbacks:
• Quantize to Q15 (int16) → 12 kB/10 ms = 1.2 MB/s; FS becomes borderline/possible with careful buffering, or keep floats and reduce sample rate.Any real-world numbers, scope captures, or code snippets would be greatly appreciated.