Question
Periodical data transmit configuration
Hello,
I am using STM32L0 MCU and trying to write a code which would include:
- Periodically transmitting data1 to UART.
- Constantly waiting for data2 (period value) from UART.
- If data2 (period value) is received from UART, change value of data1 transmission period to data2.
The problem is that if I use HAL_Delay function for periodical transmission of data1, then program is blocked from constant waiting for data2.
Now I am using timer for periodical transmission every second but I do not know how to change timer period value to other which is received from UART.
I would like to have opportunity to change time periods to 1, 5, 10 or 30 minutes.
Maybe you have some thoughts how such program could be implemented?
