Aug 2, 2024
Create New STM32 Project
option in CubeIDEmain.c
file under user code sectionsHAL_Delay
for timingHAL_GPIO_WritePin(GPIOA, GPIO_PIN_5, GPIO_PIN_SET);
HAL_Delay(1000);
HAL_GPIO_WritePin(GPIOA, GPIO_PIN_5, GPIO_PIN_RESET);
HAL_Delay(1000);
HAL_UART_Transmit
to send data to PCchar *message = "Hello World!";
HAL_UART_Transmit(&huart2, (uint8_t*)message, strlen(message), timeout);