2021-09-23 11:57 AM
Have been struggling to get SPI to work. I have been working in the engineering boot mode to try and trouble shoot my issues.
I have configured PLL3 to run the MCU at 48MHz and the SPI peripheral kernel clk to run at 108MHz and selected the clock sources in the RCC regs accordingly, I have implemented the procedure for configuring SPI in the related section in the reference manual. The GPIO have been configured to their appropriate modes and alternate functions. I have enabled the peripheral bus in RCC.
I am able to confirm the register setting via the debugger.
However, when I try to send data, I see nothing on the GPIO. I also don't see any flags reported when attempting to overfill the TXFIFO to elicit a response from the peripheral.
I am not using the HAL library directly, though I have looked through it to see what I may have missed to no avail.
Can anyone let me know if there is another enable bit, power bit or otherwise that I may be overlooking?
Solved! Go to Solution.
2021-09-23 02:50 PM
Simple questions have stupid simple answers. Was simply missing that MODF was being set due to a config error when using software nss.
2021-09-23 02:50 PM
Simple questions have stupid simple answers. Was simply missing that MODF was being set due to a config error when using software nss.
2021-09-23 11:39 PM
Hi,
Please confirm you are using an STM32MP15x ?
Glad to see you solved your issue.
Usually trying generating code using CubeMX and do side-by-side comparisons will help.
Examples provided on CubeMP1 in Projects\STM32MP157C-DK2\Examples\SPI folder could also help you.
Regards.