One of our product is using bare metal coding written in C language for Ti MSP432E401Y. Now we are going to migrate it to FreeRTOS. Whether only application code need to be divided in to tasks? Drivers and middleware code can be kept as it is?
Also please let me the migration steps if ther is any?
In my experiance, the bulk of the application code can stay as is, only the parts that control how one piece talks to another change. Drivers are what typically change first, changing ‘busy waits’ into using interrupts and FreeRTOS syncronization primatives.
Often you can start with just those changes, to get a ‘single task’ application that mostly works just as before but runs under FreeRTOS. You can then start to break up the application into pieces.
If you don’t change the drivers from using busy waits to using blocking on syncronization primatives, you tend to loose any help that FreeRTOS would provide, as they busy waits will eat up your processor cycles.
In my experiance, the bulk of the application code can stay as is, only
the parts that control how one piece talks to another change. Drivers are
what typically change first, changing ‘busy waits’ into using interrupts
and FreeRTOS syncronization primatives.
Often you can start with just those changes, to get a ‘single task’
application that mostly works just as before but runs under FreeRTOS. You
can then start to break up the application into pieces.
If you don’t change the drivers from using busy waits to using blocking on
syncronization primatives, you tend to loose any help that FreeRTOS would
provide, as they busy waits will eat up your processor cycles.