Page 1 of 1
app_main and APP_CPU
Posted: Fri Sep 29, 2017 3:33 pm
by JoaoLopesF
Hi,
I have a question:
How to change app_main and all app code to run in APP_CPU (without FreeRTOS task), instead the default PRO_CPU,
if ESP32 is dual core ?
Its is possible, or have any reason to app_main stay in PRO_CPU ?
Regards
Joao Lopes
Re: app_main and APP_CPU
Posted: Fri Sep 29, 2017 9:51 pm
by WiFive
app_main is already inside freertos task so not sure why you want to avoid a new task pinned to cpu1
Re: app_main and APP_CPU
Posted: Sat Sep 30, 2017 4:42 pm
by JoaoLopesF
WiFive wrote:app_main is already inside freertos task so not sure why you want to avoid a new task pinned to cpu1
Hi WiFive, I agree that, and after I post it, I migrate all code in app_main to an task in CPU 1, and works very well
but a question still in the air, what app_main is not in cpu 1, the APP_CPU ?
I think for novices, including me, it is confuse.
Thanks for response
Regards
Joao Lopes
Re: app_main and APP_CPU
Posted: Sun Oct 01, 2017 2:08 am
by ESP_Sprite
This is because effectively, APP_CPU and PRO_CPU are legacy names, from back when the ESP32 was envisioned as an AMP processor (a processor which runs two entirely separate programs, with only limited interaction between the two). When we switched to SMP, the processors effectively became interchangable, but because the nomenclature already was in everything (register sets, startup code, ...) we decided it was easier to just keep it.
Re: app_main and APP_CPU
Posted: Mon Oct 02, 2017 2:54 pm
by JoaoLopesF
Hi ESP_Sprite,
Thanks for this response
Regards
Joao Lopes