Skip to content
The Chat Archive
mixtral-8x7b-instruct-v0.1· Mistral AI Arena Human Preference 55K

on which core of esp32 microcontroller runs what when using arduino?

  1. User

    on which core of esp32 microcontroller runs what when using arduino?

  2. Assistant

    When using the Arduino environment to program an ESP32 microcontroller, the user's code is executed on the user-programmable Xtensa dual-core 32-bit LX6 microprocessor core (Core 0 or Core 1), while the second core (Core 1 or Core 0, depending on the configuration) is used by the ESP-IDF (Espressif IoT Development Framework) for various background tasks such as WiFi and Bluetooth connectivity, tasks scheduling, and other system functions.

    The Arduino core libraries and the user's code are built and executed on top of the ESP-IDF, which provides a set of APIs for accessing the ESP32's hardware resources, such as peripherals, communication interfaces, and security features. The Arduino core libraries map the familiar Arduino functions (e.g., digitalWrite, analogRead) to the corresponding ESP-IDF APIs, allowing users to write code for the ESP32 using the same functions and syntax as for other Arduino-compatible boards.

    In summary, when using Arduino on ESP32, the user's code runs on one of the two LX6 cores, while the other core is used by the ESP-IDF for system tasks. The user can choose which core to use for their code by setting the CORE_NUM define in the Makefile or in the platform.txt file (if using the Arduino IDE). By default, the user's code runs on Core 0.

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.