STM32CubeH7 icon indicating copy to clipboard operation
STM32CubeH7 copied to clipboard

SPI45 PCLK clock source macros are mislabeled.

Open iabdalkader opened this issue 3 years ago • 1 comments

Describe the bug SPI45 does Not have a PCLK1 clock source, it should PCLK2 (and D2PCLK2). You can see that in CubeMX, the first clock source in the MUX is PCLK2:

image

And also in any H7 reference manual (for example dm00176879 section 9.5.8 Figure 57) you can see SPI45 the only PCLK source available is PCLK2:

image

So RCC_SPI4CLKSOURCE_D2PCLK1 should be renamed to RCC_SPI4CLKSOURCE_D2PCLK2 and RCC_SPI45CLKSOURCE_PCLK1 to RCC_SPI45CLKSOURCE_PCLK2

I can send a PR to fix that, but not sure if you want to avoid breaking existing code, alternatively for backwards compatibility you might want to consider adding:

#define RCC_SPI45CLKSOURCE_PCLK2        RCC_SPI45CLKSOURCE_D2PCLK1

iabdalkader avatar May 26 '22 07:05 iabdalkader

ST Internal Reference: 130353

ASELSTM avatar Jun 15 '22 15:06 ASELSTM

Hi @iabdalkader,

The issue you reported has been fixed in the frame of version v1.11.0 of the STM32CubeH7 published on GitHub.

Thank you again for having reported.

With regards,

ASELSTM avatar Feb 17 '23 15:02 ASELSTM