Associate
November 29, 2021
Question
Custom SPI Datasize
- November 29, 2021
- 3 replies
- 3408 views
Hello,
I am trying to interface to an external ADC via SPI. I amusing the STM32Cube IDE with a Nucleo-144 STM32L552.
The issue I am having is that the ADC requires an unusual number of clock pulses (18 as per data sheet - see attached screenshot). Note, in this situation the ADC is the slave, the Nucelo the master providing the sclk pulses.
From what I can gather, there is no way to set a custom number of clock pluses in in the Cube IDE, rather you are limited to 2, 4, 8, 16 etc. number of data bits and the clock pulse parodies these values (as to be expected).
My question, is there any easy way to get 18 clock pulses using the existing cube IDE and HAL functions?
Regards,
Sam