FreeRTOS priority and its effect on Thread
Don't use HAL_Delay which is an active busy loop of which the RTOS is not aware. vTaskDelay is the RTOS function that suspends the task until enough time has passed.