How to get an 8MHz sine wave HSE output on pin MCO1 (PA8) and should it be in phase with the original crystal signal?
I have been told i need to sync 2 STM32 MCU's together (on the same PCB) to stop an intermittent I2C bus failure between them. At the moment they are operating on separate 8Mhz crystals. I have used the following command to configure and output the 8MHz clock on MCO1 (PA8) but it is a square wave and 180 degrees out of phase.
HAL_RCC_MCOConfig(RCC_MCO1, RCC_MCO1SOURCE_HSE, RCC_MCODIV_1);
I am compiling in Atollic.
What have i not done to get an in phase sine wave?
Any help would be appreciated.