Simple 2 Tasks Program Crash Core1 Panic
Posted: Sat Dec 16, 2017 10:20 pm
Hi Every body,
After succesfully installed eclipse and run few examples "by hand" , i'm starting a simple program.
I started from blinck exemple, and add a second tasks.
Led connected to pin5 blinks well. My second tasks executed each 1 second a printf("hello"):
my main.c really simple:
But esp32 doesnt like it , and i can see in uart console rebooting and making this error:
When i disable the printf , no more error.
I don't really see what i did wrong here. i found freertos really nice, at the moment ... on paper
Thanls a lot for your help.
After succesfully installed eclipse and run few examples "by hand" , i'm starting a simple program.
I started from blinck exemple, and add a second tasks.
Led connected to pin5 blinks well. My second tasks executed each 1 second a printf("hello"):
Code: Select all
void my_task2(void *pvParameter)
{
while (1){
printf("task in loop\n\r");
vTaskDelay(1000 / portTICK_PERIOD_MS);
} // end while
// vTaskDelete(NULL);
}
Code: Select all
void app_main()
{
printf("app main\n\r");
// xTaskCreate(&blink_task, "blink_task", configMINIMAL_STACK_SIZE, NULL, 5, NULL);
xTaskCreate(&my_task2,"task2",1000,NULL, 4, NULL);
// vTaskStartScheduler (); // Start the real time kernel with preemption.
// Will not get here unless a task calls vTaskEndScheduler ()
}
Code: Select all
Error: Core 1 panic'ed (StoreProhibited). Exception was unhandled.
I don't really see what i did wrong here. i found freertos really nice, at the moment ... on paper
Thanls a lot for your help.