Skip to content

Commit

Permalink
Merge branch 'docs/update_interrupt_number_esp32h2' into 'master'
Browse files Browse the repository at this point in the history
docs: update the number of interrupts for esp32h2

See merge request espressif/esp-idf!24081
  • Loading branch information
Lindazhxy committed Jun 9, 2023
2 parents 3cabd18 + b7a6655 commit 3d11043
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions docs/en/api-reference/system/intr_alloc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,14 @@ Overview

The {IDF_TARGET_NAME} has two cores, with 32 interrupts. Each interrupt has a certain priority level, most (but not all) interrupts are connected to the interrupt mux.

.. only:: esp32c2 or esp32c3 or esp32c6 or esp32h2
.. only:: esp32c2 or esp32c3

The {IDF_TARGET_NAME} has one core, with 31 interrupts. Each interrupt has a programmable priority level.

.. only:: esp32c6 or esp32h2

The {IDF_TARGET_NAME} has one core, with 28 external asynchronous interrupts. Each interrupt has a programmable priority level. In addition, there are also 4 core local interrupt sources (CLINT). See *{IDF_TARGET_NAME} Technical Reference Manual* [`PDF <{IDF_TARGET_TRM_EN_URL}#riscvcpu>`__] for more details.

Because there are more interrupt sources than interrupts, sometimes it makes sense to share an interrupt in multiple drivers. The :cpp:func:`esp_intr_alloc` abstraction exists to hide all these implementation details.

A driver can allocate an interrupt for a certain peripheral by calling :cpp:func:`esp_intr_alloc` (or :cpp:func:`esp_intr_alloc_intrstatus`). It can use the flags passed to this function to set the type of interrupt allocated, specifying a particular level or trigger method. The interrupt allocation code will then find an applicable interrupt, use the interrupt mux to hook it up to the peripheral, and install the given interrupt handler and ISR to it.
Expand Down Expand Up @@ -96,5 +100,3 @@ API Reference
-------------

.. include-build-file:: inc/esp_intr_alloc.inc


0 comments on commit 3d11043

Please sign in to comment.