Use this forum to chat about hardware specific topics for the ESP8266 (peripherals, memory, clocks, JTAG, programming)

User avatar
By mculibrk
#14603 Hi there!
I'm working with the (H)SPI module and using the SPi generated interrupts to "recharge/restart" the SPI transfers.
The interrupt handler is attached using the API function ETS_SPI_INTR_ATTACH()

My interrupt handler takes around 200 cycles to complete (approx 2500 nS) and at the end it starts a new SPI transfer of ~480 bits.

Checking at the scope there is a gap of approx 8000 nS between successive SPI transmissions (see picture).

Is that 5uS latency "normal behavior"? What is the interrupt latency of the ESP/xtensa MCU?

If this latency is caused by the ESP library/API is there any option to use HW interrupts/vectors directly, bypassing any "slow library"?

Regards,
mculibrk
You do not have the required permissions to view the files attached to this post.