Unable to run Task on Core 1

DutchOrange
Posts: 74
Joined: Fri Dec 04, 2020 4:23 pm

Unable to run Task on Core 1

Postby DutchOrange » Sun Apr 11, 2021 3:21 pm

Good day,
I wanted to try to do multi tasking usigng the duel core system on the ESP32, Iam able to make it run on Core 0 but not core 1.
This is on windows. ESP-IDF (/MDF but I dont think this is a MDF related question).
Must you change any settings in menuconfig ? Or Must you add any code so you can use core 1 ?

Here is my code:

Code: Select all

// Copyright 2017 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at

//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

#include "mdf_common.h"
#include "mwifi.h"
#include <stdio.h>

// #define MEMORY_DEBUG

static const char *TAG = "get_started";

//Varables I added - - - - - - - - - - - - - -
int node_level = 111; 
// static const BaseType_t app_cpu = 1;
void hello_world_task(void *parameters){
    while (1)
    {
    printf(" \nHello wrold I should be on core 1 \n  On core : %d  \n ", xPortGetCoreID());
    vTaskDelay(1000 / portTICK_PERIOD_MS);
    }
    
    
}
// - - - - - - - - - - - - - - - - - 

static void root_task(void *arg)
{
    mdf_err_t ret                    = MDF_OK;
    char *data                       = MDF_MALLOC(MWIFI_PAYLOAD_LEN);
    size_t size                      = MWIFI_PAYLOAD_LEN;
    uint8_t src_addr[MWIFI_ADDR_LEN] = {0x0};
    mwifi_data_type_t data_type      = {0};

    MDF_LOGI("Root is running");

    for (int i = 0;; ++i) {
        if (!mwifi_is_started()) {
            vTaskDelay(500 / portTICK_RATE_MS);
            continue;
        }

        size = MWIFI_PAYLOAD_LEN;
        memset(data, 0, MWIFI_PAYLOAD_LEN);
        ret = mwifi_root_read(src_addr, &data_type, data, &size, portMAX_DELAY);
        MDF_ERROR_CONTINUE(ret != MDF_OK, "<%s> mwifi_root_read", mdf_err_to_name(ret));
        MDF_LOGI("Root receive, addr: " MACSTR ", size: %d, data: %s", MAC2STR(src_addr), size, data);

        size = sprintf(data, "(%d) Hello node!", i);
        ret = mwifi_root_write(src_addr, 1, &data_type, data, size, true);
        MDF_ERROR_CONTINUE(ret != MDF_OK, "mwifi_root_recv, ret: %x", ret);
        MDF_LOGI("Root send, addr: " MACSTR ", size: %d, data: %s", MAC2STR(src_addr), size, data);
    }

    MDF_LOGW("Root is exit");

    MDF_FREE(data);
    vTaskDelete(NULL);
}

static void node_read_task(void *arg)           // Node read taks
{
    mdf_err_t ret = MDF_OK;
    char *data    = MDF_MALLOC(MWIFI_PAYLOAD_LEN);
    size_t size   = MWIFI_PAYLOAD_LEN;
    mwifi_data_type_t data_type      = {0x0};
    uint8_t src_addr[MWIFI_ADDR_LEN] = {0x0};

    MDF_LOGI("Note read task is running");

    for (;;) {
        if (!mwifi_is_connected()) {
            vTaskDelay(500 / portTICK_RATE_MS);
            continue;
        }

        size = MWIFI_PAYLOAD_LEN;
        memset(data, 0, MWIFI_PAYLOAD_LEN);
        ret = mwifi_read(src_addr, &data_type, data, &size, portMAX_DELAY);
        MDF_ERROR_CONTINUE(ret != MDF_OK, "mwifi_read, ret: %x", ret);
        MDF_LOGI("Node receive, addr: " MACSTR ", size: %d, data: %s", MAC2STR(src_addr), size, data);

        printf("node read task is running on core :  %d and the heap size is = %d  and the Layer Number = : %d!\n", xPortGetCoreID(), uxTaskGetStackHighWaterMark(NULL),esp_mesh_get_layer());
        node_level = esp_mesh_get_layer(); 
        vTaskDelay(100 / portTICK_PERIOD_MS);
    }

    MDF_LOGW("Note read task is exit");
    MDF_FREE(data);
    vTaskDelete(NULL);
}

void node_write_task(void *arg)
{
    mdf_err_t ret = MDF_OK;
    int count     = 0;
    size_t size   = 0;
    char *data    = MDF_MALLOC(MWIFI_PAYLOAD_LEN);
    mwifi_data_type_t data_type = {0x0};

    MDF_LOGI("Node write task is running");

    for (;;) {
        if (!mwifi_is_connected()) {
            vTaskDelay(500 / portTICK_RATE_MS);
            continue;
        }

        size = sprintf(data, "(%d) Hello root!", count++);
        ret = mwifi_write(NULL, &data_type, data, size, true);
        MDF_ERROR_CONTINUE(ret != MDF_OK, "mwifi_write, ret: %x", ret);

        vTaskDelay(1000 / portTICK_RATE_MS);
         printf("THIS IS THE WRITING TASK \n node read task is running on core :  %d and the heap size is = %d  and the Layer Number = : %d!\n", xPortGetCoreID(), uxTaskGetStackHighWaterMark(NULL),esp_mesh_get_layer());
    }

    MDF_LOGW("Node write task is exit");

    MDF_FREE(data);
    vTaskDelete(NULL);
}

/**
 * @brief Timed printing system information
 */
static void print_system_info_timercb(void *timer)
{
    uint8_t primary                 = 0;
    wifi_second_chan_t second       = 0;
    mesh_addr_t parent_bssid        = {0};
    uint8_t sta_mac[MWIFI_ADDR_LEN] = {0};
    wifi_sta_list_t wifi_sta_list   = {0x0};

    esp_wifi_get_mac(ESP_IF_WIFI_STA, sta_mac);
    esp_wifi_ap_get_sta_list(&wifi_sta_list);
    esp_wifi_get_channel(&primary, &second);
    esp_mesh_get_parent_bssid(&parent_bssid);

    MDF_LOGI("System information, channel: %d, layer: %d, self mac: " MACSTR ", parent bssid: " MACSTR
             ", parent rssi: %d, node num: %d, free heap: %u", primary,
             esp_mesh_get_layer(), MAC2STR(sta_mac), MAC2STR(parent_bssid.addr),
             mwifi_get_parent_rssi(), esp_mesh_get_total_node_num(), esp_get_free_heap_size());

    for (int i = 0; i < wifi_sta_list.num; i++) {
        MDF_LOGI("Child mac: " MACSTR, MAC2STR(wifi_sta_list.sta[i].mac));
    }

#ifdef MEMORY_DEBUG

    if (!heap_caps_check_integrity_all(true)) {
        MDF_LOGE("At least one heap is corrupt");
    }

    mdf_mem_print_heap();
    mdf_mem_print_record();
    mdf_mem_print_task();
#endif /**< MEMORY_DEBUG */
}

static mdf_err_t wifi_init()
{
    mdf_err_t ret          = nvs_flash_init();
    wifi_init_config_t cfg = WIFI_INIT_CONFIG_DEFAULT();

    if (ret == ESP_ERR_NVS_NO_FREE_PAGES || ret == ESP_ERR_NVS_NEW_VERSION_FOUND) {
        MDF_ERROR_ASSERT(nvs_flash_erase());
        ret = nvs_flash_init();
    }

    MDF_ERROR_ASSERT(ret);

    MDF_ERROR_ASSERT(esp_netif_init());
    MDF_ERROR_ASSERT(esp_event_loop_create_default());
    MDF_ERROR_ASSERT(esp_wifi_init(&cfg));
    MDF_ERROR_ASSERT(esp_wifi_set_storage(WIFI_STORAGE_FLASH));
    MDF_ERROR_ASSERT(esp_wifi_set_mode(WIFI_MODE_STA));
    MDF_ERROR_ASSERT(esp_wifi_set_ps(WIFI_PS_NONE));
    MDF_ERROR_ASSERT(esp_mesh_set_6m_rate(false));
    MDF_ERROR_ASSERT(esp_wifi_start());

    return MDF_OK;
}

/**
 * @brief All module events will be sent to this task in esp-mdf
 *
 * @Note:
 *     1. Do not block or lengthy operations in the callback function.
 *     2. Do not consume a lot of memory in the callback function.
 *        The task memory of the callback function is only 4KB.
 */
static mdf_err_t event_loop_cb(mdf_event_loop_t event, void *ctx)
{
    MDF_LOGI("event_loop_cb, event: %d", event);

    switch (event) {
        case MDF_EVENT_MWIFI_STARTED:
            MDF_LOGI("MESH is started");
            break;

        case MDF_EVENT_MWIFI_PARENT_CONNECTED:
            MDF_LOGI("Parent is connected on station interface");
            break;

        case MDF_EVENT_MWIFI_PARENT_DISCONNECTED:
            MDF_LOGI("Parent is disconnected on station interface");
            break;

        default:
            break;
    }

    return MDF_OK;
}

void app_main()
{
    mwifi_init_config_t cfg = MWIFI_INIT_CONFIG_DEFAULT();
    mwifi_config_t config   = {
        .channel   = CONFIG_MESH_CHANNEL,
        .mesh_id   = CONFIG_MESH_ID,
        .mesh_type = CONFIG_DEVICE_TYPE,
    };

    /**
     * @brief Set the log level for serial port printing.
     */
    esp_log_level_set("*", ESP_LOG_INFO);
    esp_log_level_set(TAG, ESP_LOG_DEBUG);

    /**
     * @brief Initialize wifi mesh.
     */
    MDF_ERROR_ASSERT(mdf_event_loop_init(event_loop_cb));
    MDF_ERROR_ASSERT(wifi_init());
    MDF_ERROR_ASSERT(mwifi_init(&cfg));
    MDF_ERROR_ASSERT(mwifi_set_config(&config));
    MDF_ERROR_ASSERT(mwifi_start());

    /**
     * @brief Data transfer between wifi mesh devices
     */
    if (config.mesh_type == MESH_ROOT) {
        xTaskCreate(root_task, "root_task", 4 * 1024,
                    NULL, CONFIG_MDF_TASK_DEFAULT_PRIOTY, NULL);
    } else {

xTaskCreatePinnedToCore(node_write_task,
                        "Node write task",
                        4 * 1024,
                        NULL,
                        2,
                        NULL,
                        0); 

xTaskCreatePinnedToCore(node_read_task,
                        "Node Write Task", 
                         4 * 1024,
                        NULL,
                        2,
                        NULL,
                        0); 


        /*
        xTaskCreate(node_write_task,
                     "node_write_task",
                     4 * 1024,
                     NULL,
                     CONFIG_MDF_TASK_DEFAULT_PRIOTY,  // = 6
                      NULL);    //Was NULL
        xTaskCreate(node_read_task,
                      "node_read_task",
                      4 * 1024,
                      NULL,
                      CONFIG_MDF_TASK_DEFAULT_PRIOTY,   // = 6 
                      NULL);    //Was NULL
                      */
// I added ===============================================================
//xTaskCreatePinnedToCore
//xTaskCreateStaticPinnedToCore

         xTaskCreatePinnedToCore(hello_world_task, 
                         "hello world task",
                         2 * 1024,
                         NULL,
                         6,     //Was 1
                         NULL,
                          1); // tskNO_AFFINITY , APP_CPU    , PRO_CPU 

              /*
                
                //This works, also automaticaly puts on core 0 
                 xTaskCreate(hello_world_task, 
                         "hello world task",
                         2 * 1024,
                         NULL,
                         CONFIG_MDF_TASK_DEFAULT_PRIOTY,     //Was 1
                         NULL); 
              */

//=========================================================================
    }

    TimerHandle_t timer = xTimerCreate("print_system_info", 10000 / portTICK_RATE_MS,
                                       true, NULL, print_system_info_timercb);
    xTimerStart(timer, 0);
}
(Just to cut to it, here is how i called the task:

Code: Select all

xTaskCreatePinnedToCore(hello_world_task, 
                         "hello world task",
                         2 * 1024,
                         NULL,
                         6,     //Was 1
                         NULL,
                          1); // tskNO_AFFINITY , APP_CPU    , PRO_CPU

Thanks, any help is appreciated.

chegewara
Posts: 2207
Joined: Wed Jun 14, 2017 9:00 pm

Re: Unable to run Task on Core 1

Postby chegewara » Sun Apr 11, 2021 4:38 pm

You are doing printf in task, in that case task stack is at least 3 * 1024.

DutchOrange
Posts: 74
Joined: Fri Dec 04, 2020 4:23 pm

Re: Unable to run Task on Core 1

Postby DutchOrange » Sun Apr 11, 2021 5:56 pm

Thanks for the reply,
I increased it to 3 then 4 and changed the core:

Code: Select all

xTaskCreatePinnedToCore(hello_world_task, 
                         "hello world task",
                         4 * 1024,
                         NULL,
                         5,     //Was 1
                         NULL,
                          1);
Yet It still crashes.
Here is the error code (If it helps):

Code: Select all

Writing at 0x0009c000... (100 %)
Wrote 926496 bytes (588188 compressed) at 0x00010000 in 13.7 seconds (effective 542.1 kbit/s)...
Hash of data verified.

Leaving...
Hard resetting via RTS pin...
Executing action: monitor
Running idf_monitor in directory e:\desktop\mdf-projects\get-started
Executing "C:\Users\Brandon\.espressif\python_env\idf4.2_py3.8_env\Scripts\python.exe E:\Desktop\esp-idf\tools/idf_monitor.py -p COM3 -b 115200 --toolchain-prefix xtensa-esp32-elf- e:\desktop\mdf-projects\get-started\build\get_started.elf -m 'C:\Users\Brandon\.espressif\python_env\idf4.2_py3.8_env\Scripts\python.exe' 'E:\Desktop\esp-idf\tools\idf.py' '-p' 'COM3'"...
--- WARNING: GDB cannot open serial ports accessed as COMx
--- Using \\.\COM3 instead...
--- idf_monitor on \\.\COM3 115200 ---
--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---
ets Jun  8 2016 00:22:57

rst:0x1 (POWERON_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:4
load:0x3fff0034,len:7040
ho 0 tail 12 room 4
load:0x40078000,len:13212
load:0x40080400,len:4568
0x40080400: _init at ??:?

entry 0x400806f4
I (30) boot: ESP-IDF v4.2 2nd stage bootloader
I (31) boot: compile time 19:51:44
I (31) boot: chip revision: 1
I (33) boot_comm: chip revision: 1, min. bootloader chip revision: 0
I (40) boot.esp32: SPI Speed      : 40MHz
I (45) boot.esp32: SPI Mode       : DIO
I (49) boot.esp32: SPI Flash Size : 4MB
I (54) boot: Enabling RNG early entropy source...
I (59) boot: Partition Table:
I (63) boot: ## Label            Usage          Type ST Offset   Length
I (70) boot:  0 nvs              WiFi data        01 02 00009000 00004000
I (78) boot:  1 otadata          OTA data         01 00 0000d000 00002000
I (85) boot:  2 phy_init         RF data          01 01 0000f000 00001000
I (93) boot:  3 ota_0            OTA app          00 10 00010000 001e0000
I (100) boot:  4 ota_1            OTA app          00 11 001f0000 001e0000
I (108) boot:  5 coredump         Unknown data     01 03 003d0000 00010000
I (115) boot:  6 reserved         Unknown data     01 fe 003e0000 00020000
I (123) boot: End of partition table
I (127) boot: No factory image, trying OTA 0
I (132) boot_comm: chip revision: 1, min. application chip revision: 0
I (139) esp_image: segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x23f14 (147220) map
I (204) esp_image: segment 1: paddr=0x00033f3c vaddr=0x3ffb0000 size=0x04054 ( 16468) load
I (211) esp_image: segment 2: paddr=0x00037f98 vaddr=0x40080000 size=0x00404 (  1028) load
0x40080000: _WindowOverflow4 at E:/Desktop/esp-mdf/esp-idf/components/freertos/xtensa/xtensa_vectors.S:1730

I (212) esp_image: segment 3: paddr=0x000383a4 vaddr=0x40080404 size=0x07c74 ( 31860) load
I (234) esp_image: segment 4: paddr=0x00040020 vaddr=0x400d0020 size=0xa55f0 (677360) map
0x400d0020: _stext at ??:?

I (492) esp_image: segment 5: paddr=0x000e5618 vaddr=0x40088078 size=0x0cce0 ( 52448) load
0x40088078: vTaskPlaceOnEventList at E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:2914

I (527) boot: Loaded app from partition at offset 0x10000
I (589) boot: Set actual ota_seq=1 in otadata[0]
I (589) boot: Disabling RNG early entropy source...
I (590) cpu_start: Pro cpu up.
I (593) cpu_start: Application information:
I (598) cpu_start: Project name:     get_started
I (603) cpu_start: App version:      1
I (607) cpu_start: Compile time:     Apr 11 2021 19:35:02
I (613) cpu_start: ELF file SHA256:  c00afa464adc9601...
I (619) cpu_start: ESP-IDF:          v4.2-326-gaf8bc4c43
I (625) cpu_start: Single core mode
I (630) heap_init: Initializing. RAM available for dynamic allocation:
I (637) heap_init: At 3FF80000 len 00002000 (8 KiB): RTCRAM
I (643) heap_init: At 3FFAE6E0 len 00001920 (6 KiB): DRAM
I (649) heap_init: At 3FFB9D70 len 00026290 (152 KiB): DRAM
I (655) heap_init: At 3FFE0440 len 0001FBC0 (126 KiB): D/IRAM
I (662) heap_init: At 40078000 len 00008000 (32 KiB): IRAM
I (668) heap_init: At 40094D58 len 0000B2A8 (44 KiB): IRAM
I (674) cpu_start: Pro cpu start user code
I (692) spi_flash: detected chip: generic
I (692) spi_flash: flash io: dio
I (692) esp_core_dump_flash: Init core dump to flash
I (696) esp_core_dump_flash: Found partition 'coredump' @ 3d0000 65536 bytes
I (709) esp_core_dump_flash: Found core dump 25084 bytes in flash @ 0x3d0000
I (711) cpu_start: Starting scheduler on PRO CPU.
I (738) wifi:wifi driver task: 3ffc0290, prio:23, stack:6656, core=0
I (739) system_api: Base MAC address is not set
I (739) system_api: read default base MAC address from EFUSE
I (752) wifi:wifi firmware version: 25f230e
I (752) wifi:wifi certification version: v7.0
I (753) wifi:config NVS flash: enabled
I (756) wifi:config nano formating: disabled
I (761) wifi:Init data frame dynamic rx buffer num: 32
I (765) wifi:Init management frame dynamic rx buffer num: 32
I (771) wifi:Init management short buffer num: 32
I (775) wifi:Init dynamic tx buffer num: 32
I (779) wifi:Init static rx buffer size: 1600
I (783) wifi:Init static rx buffer num: 10
I (787) wifi:Init dynamic rx buffer num: 32
I (791) wifi_init: tcpip mbox: 32
I (795) wifi_init: udp mbox: 6
I (799) wifi_init: tcp mbox: 6
I (802) wifi_init: tcp tx win: 5744
I (806) wifi_init: tcp rx win: 5744
I (811) wifi_init: tcp mss: 1440
I (815) wifi_init: WiFi IRAM OP enabled
I (819) wifi_init: WiFi RX IRAM OP enabled
I (825) wifi:Set ps type: 0

I (915) phy: phy_version: 4500, 0cd6843, Sep 17 2020, 15:37:07, 0, 0
I (917) wifi:mode : sta (24:0a:c4:58:7e:d8)
I (919) [mwifi, 297]: esp-mdf version: v1.0-129-g4555f06-dirty
I (923) wifi:mode : sta (24:0a:c4:58:7e:d8) + softAP (24:0a:c4:58:7e:d9)
I (930) wifi:Total power save buffer number: 16
I (932) wifi:Init max length of beacon: 752/752
I (937) wifi:Init max length of beacon: 752/752
I (942) mesh: <nvs>read layer:0, err:0x1102
I (945) mesh: <nvs>read assoc:0, err:0x1102
I (950) mesh: [CONFIG]invalid router settings, ssid_len:0, ssid:, bssid:00:00:00:00:00:00
I (1561) [mwifi, 223]: MESH is started
I (1562) [get_started, 207]: event_loop_cb, event: 0
I (1562) [get_started, 211]: MESH is started
I (1566) [get_started, 114]: Node write task is running
I (1571) [get_started, 82]: Note read task is running
E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:1070 (prvAddNewTaskToReadyList)- assert failed!

abort() was called at PC 0x400879de on core 0
0x400879de: prvAddNewTaskToReadyList at E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:1070 (discriminator 1)


Backtrace:0x40086a2b:0x3ffaf430 0x40087099:0x3ffaf450 0x4008db2a:0x3ffaf470 0x400879de:0x3ffaf4e0 0x40087b4b:0x3ffaf500 0x400d677f:0x3ffaf540 0x400d4923:0x3ffaf640 0x400870a1:0x3ffaf670
0x40086a2b: panic_abort at E:/Desktop/esp-mdf/esp-idf/components/esp_system/panic.c:330

0x40087099: esp_system_abort at E:/Desktop/esp-mdf/esp-idf/components/esp_system/system_api.c:106

0x4008db2a: abort at E:/Desktop/esp-mdf/esp-idf/components/newlib/abort.c:46

0x400879de: prvAddNewTaskToReadyList at E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:1070 (discriminator 1)

0x40087b4b: xTaskCreatePinnedToCore at E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:843

0x400d677f: app_main at e:\desktop\mdf-projects\get-started\build/../main/get_started.c:296

0x400d4923: main_task at E:/Desktop/esp-mdf/esp-idf/components/esp32/cpu_start.c:600 (discriminator 2)

0x400870a1: vPortTaskWrapper at E:/Desktop/esp-mdf/esp-idf/components/freertos/xtensa/port.c:143



ELF file SHA256: c00afa464adc9601

I (1601) esp_core_dump_flash: Save core dump to flash...
I (1607) esp_core_dump_elf: Found tasks: 15
I (1613) esp_core_dump_flash: Erase flash 28672 bytes @ 0x3d0000
I (1963) esp_core_dump_flash: Write end offset 0x61fc, check sum length 4
I (1963) esp_core_dump_flash: Core dump has been saved to flash.
Rebooting...
ets Jun  8 2016 00:22:57

rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0030,len:4
load:0x3fff0034,len:7040
ho 0 tail 12 room 4
load:0x40078000,len:13212
load:0x40080400,len:4568
0x40080400: _init at ??:?

entry 0x400806f4
I (31) boot: ESP-IDF v4.2 2nd stage bootloader
I (31) boot: compile time 19:51:44
I (31) boot: chip revision: 1
I (33) boot_comm: chip revision: 1, min. bootloader chip revision: 0
I (41) boot.esp32: SPI Speed      : 40MHz
I (45) boot.esp32: SPI Mode       : DIO
I (50) boot.esp32: SPI Flash Size : 4MB
I (54) boot: Enabling RNG early entropy source...
I (60) boot: Partition Table:
I (63) boot: ## Label            Usage          Type ST Offset   Length
I (71) boot:  0 nvs              WiFi data        01 02 00009000 00004000
I (78) boot:  1 otadata          OTA data         01 00 0000d000 00002000
I (85) boot:  2 phy_init         RF data          01 01 0000f000 00001000
I (93) boot:  3 ota_0            OTA app          00 10 00010000 001e0000
I (100) boot:  4 ota_1            OTA app          00 11 001f0000 001e0000
I (108) boot:  5 coredump         Unknown data     01 03 003d0000 00010000
I (116) boot:  6 reserved         Unknown data     01 fe 003e0000 00020000
I (123) boot: End of partition table
I (127) boot_comm: chip revision: 1, min. application chip revision: 0
I (135) esp_image: segment 0: paddr=0x00010020 vaddr=0x3f400020 size=0x23f14 (147220) map
I (200) esp_image: segment 1: paddr=0x00033f3c vaddr=0x3ffb0000 size=0x04054 ( 16468) load
I (207) esp_image: segment 2: paddr=0x00037f98 vaddr=0x40080000 size=0x00404 (  1028) load
0x40080000: _WindowOverflow4 at E:/Desktop/esp-mdf/esp-idf/components/freertos/xtensa/xtensa_vectors.S:1730

I (208) esp_image: segment 3: paddr=0x000383a4 vaddr=0x40080404 size=0x07c74 ( 31860) load
I (229) esp_image: segment 4: paddr=0x00040020 vaddr=0x400d0020 size=0xa55f0 (677360) map
0x400d0020: _stext at ??:?

I (488) esp_image: segment 5: paddr=0x000e5618 vaddr=0x40088078 size=0x0cce0 ( 52448) load
0x40088078: vTaskPlaceOnEventList at E:/Desktop/esp-mdf/esp-idf/components/freertos/tasks.c:2914

chegewara
Posts: 2207
Joined: Wed Jun 14, 2017 9:00 pm

Re: Unable to run Task on Core 1

Postby chegewara » Sun Apr 11, 2021 6:04 pm

You didnt post logs earlier so it was my guess looking at code. Now from logs it is most likely you have enabled "FreeRTOS->Run FreeRTOS only on first core" in menuconfig.

DutchOrange
Posts: 74
Joined: Fri Dec 04, 2020 4:23 pm

Re: Unable to run Task on Core 1

Postby DutchOrange » Sun Apr 11, 2021 6:12 pm

Thanks so much for the help, worked perfectly.
Now I just got to get the libraries working.

Thanks again.

Who is online

Users browsing this forum: Konstantin, Majestic-12 [Bot] and 137 guests