Page 1 of 1

Running FreeRTOS on both cores

Posted: Sat Apr 28, 2018 1:59 pm
by PawelJalocha
In my application, I have enabled running the FreeRTOS on both cores and then I observed like memory overwrites, at least on the console output. My application would as well become unstable: it would run for an hour or two and then simply stop, not even restarted.

Is there anything to consider when running two cores with FreeRTOS, are there any additional rules to follow ?

When running on a single core is the other core simply unused or does is still do some useful job ?

Re: Running FreeRTOS on both cores

Posted: Sun Apr 29, 2018 3:33 am
by ESP_Sprite
It depends: if you use all the FreeRTOS primitives (muxes, queues, etc) for moderating access to resources and multi-tasking correctly, running your code on two cores should need no change in your code. If you don't... well, race conditions can effectively be triggered way more easily in a multicore environment. So it depends more-or-less on how your code is written, I'd say.

Re: Running FreeRTOS on both cores

Posted: Sun Apr 29, 2018 1:34 pm
by PawelJalocha
Thank you, thus from the programmer point of view the RTOS runs as if there was a single core as long as all the resources are properly protected by the semaphores ?

Is given task run always by the same core or it can be switched between cores ?

Re: Running FreeRTOS on both cores

Posted: Sun Apr 29, 2018 8:38 pm
by WiFive