WiFiClient has higher priority than hw_timer since core 2.x?

tomtobback
Posts: 1
Joined: Tue Nov 29, 2022 8:32 am

WiFiClient has higher priority than hw_timer since core 2.x?

Postby tomtobback » Tue Nov 29, 2022 9:45 am

Hi, i've been working on an LED matrix application with an ESP32-WROVER module:
  • I use a hw_timer_t to run an IRAM_ATTR ISR every 10us to update the matrix shift register,
  • and have a TCP server (WiFiServer) to receive instructions, checking for new clients in the loop().
This all worked well on ESP32-Arduino core 1.0.4, but when i switched to core 2.0.5 recently, it seems the TCP server has a higher priority than before, upsetting the timing of the matrix update, resulting in bright flashes when data is received.
I have looked through the core release notes but cannot find anything timer/wifi related, except maybe https://github.com/espressif/arduino-es ... t/954df2fc but i don't know how that could help me.
I have tried to add portENTER_CRITICAL_ISR and EXIT in the ISR but that does not help.
I thought of using RTOS tasks but that would get complicated, and i hope there is another fix to make it work again as before.
(I know there are DMA libraries for LED matrix too, i'm using one with another type of matrix and the issue does not occur with DMA. Unfortunately i cannot make the DMA library work with the above matrix)
Any advice much appreciated, thanks.

Who is online

Users browsing this forum: No registered users and 58 guests