@startuml scale max 900*520 skinparam backgroundColor transparent skinparam shadowing false skinparam defaultFontName "DejaVu Sans Mono" skinparam defaultFontSize 12 skinparam rectangleBorderColor #2b6f8e skinparam rectangleBackgroundColor #edf6fa skinparam ArrowColor #8295a0 top to bottom direction title A3 DISPATCH — external vector, saved context and FromISR switch rectangle "01 isr_external_irq" as Vector rectangle "02 freertos_risc_v_trap_handler\nsave full task context" as Trap rectangle "03 xISRStack\nmcause = 0x8000000b" as Stack rectangle "04 application_interrupt_handler" as App rectangle "05 xSemaphoreGiveFromISR\nxHPW = pdTRUE" as Give rectangle "06 portYIELD_FROM_ISR\nvTaskSwitchContext" as Yield rectangle "07 restore selected task context" as Restore Vector --> Trap Trap --> Stack Stack --> App App --> Give Give --> Yield Yield --> Restore @enduml