Javert
Member level 2
Due to the graphics library I will have to switch from super loop to RTOS, probably FreeRTOS.
Unfortunately, the examples and books I found contain a more comprehensive view, ie an example of some real application only, simple flashing LEDs and the like.
Can you advise where I could see a more complex treasure or book that would solve the use of RTOS on real applications?
Or otherwise.
I have an application something like hot air heating
- the rotary encoder for entering the required temperature is read in the interrupt handler,
- display to show the desired and actual temperature
- SSR for switching heating
- thermometer for measuring the temperature of the intake air
- SSR for fan control for simplicity only one speed
in super loop
1 Read real temperature
2. if is diferebnce (cold) switch fan ON
3. PID (compare set and real temperature, and set SSR)
4. Display set and real temperture
5. Goto 1
How to best convert it to FreeRTOS?
ie divide into tasks and which method to run tasks to choose? For example, PID should, in my opinion, be performed every 100ms
Unfortunately, the examples and books I found contain a more comprehensive view, ie an example of some real application only, simple flashing LEDs and the like.
Can you advise where I could see a more complex treasure or book that would solve the use of RTOS on real applications?
Or otherwise.
I have an application something like hot air heating
- the rotary encoder for entering the required temperature is read in the interrupt handler,
- display to show the desired and actual temperature
- SSR for switching heating
- thermometer for measuring the temperature of the intake air
- SSR for fan control for simplicity only one speed
in super loop
1 Read real temperature
2. if is diferebnce (cold) switch fan ON
3. PID (compare set and real temperature, and set SSR)
4. Display set and real temperture
5. Goto 1
How to best convert it to FreeRTOS?
ie divide into tasks and which method to run tasks to choose? For example, PID should, in my opinion, be performed every 100ms