UART doesn't work on STM32F407G-DISC1
I am a beginner, and this is my first time trying to use UART to send data from MCU to PC.I try to follow the deep blue embedded tutorial (STM32 Serial Print & Monitor (UART Data Debug), however the console does not receive anything when I connect to it.
This is my main function code
int main(void)
{
/* USER CODE BEGIN 1 */
//USART vs UART
//synchronous generates data on clock and sends it to
//the receiver which works accordingly in synchronized manner
//asynchronous generates data clock internally
/* USER CODE END 1 */
/* MCU Configuration--------------------------------------------------------*/
/* Reset of all peripherals, Initializes the Flash interface and the Systick. */
HAL_Init();
/* USER CODE BEGIN Init */
/* USER CODE END Init */
/* Configure the system clock */
SystemClock_Config();
/* USER CODE BEGIN SysInit */
/* USER CODE END SysInit */
/* Initialize all configured peripherals */
MX_GPIO_Init();
MX_DMA_Init();
MX_I2C1_Init();
MX_I2S3_Init();
MX_SPI1_Init();
MX_USB_HOST_Init();
MX_USART2_UART_Init();
/* USER CODE BEGIN 2 */
//uint8_t UART2rxBuffer[12] = {0};
//HAL_UART_Transmit(&huart2, UART2rxBuffer, sizeof(UART2rxBuffer), 5000);
//HAL_UART_Transmit(&huart2, UART2rxBuffer, sizeof(UART2rxBuffer), 100);
uint8_t MSG[35] = {'\0'};
uint8_t X = 0;
/* USER CODE END 2 */
/* Infinite loop */
/* USER CODE BEGIN WHILE */
uint8_t hello_world[13] = "Hello World\n";
HAL_UART_Transmit(&huart2, hello_world, sizeof(hello_world), 500);
while (1)
{
/* USER CODE END WHILE */
MX_USB_HOST_Process();
/* USER CODE BEGIN 3 */
//sprintf(MSG, "Hello Dudes! Tracing X = %d\r\n", X);
//HAL_UART_Transmit(&huart2, MSG, sizeof(MSG), 500); //timeout time
HAL_UART_Transmit(&huart2, hello_world, sizeof(hello_world), 500);
HAL_Delay(500); //wait half a second
X++;
}
/* USER CODE END 3 */
}These are my UART2 settings.

These are my pins.

This is my clock configuration.

What should I change so that UART sends the data correctly?
