IRQ SPEED

All ESP32 boards running MicroPython.
Target audience: MicroPython users with an ESP32 board.
Post Reply
georges
Posts: 1
Joined: Sat Jun 22, 2019 6:36 pm

IRQ SPEED

Post by georges » Sat Jun 22, 2019 6:46 pm

Hi,
I am new to micropython.
I plan to use an ESP32 board to control a little robot.
It is a simple mobile platform with two wheels and a few sensors.
It use two DC motors with encoders.
The encoders generate pulse at about 5 Khz each.

Do we have experience if the External IRQ is able to follow these frequency ?
My function is very short : only increment a counter.

Does anybody have any experiences about it ?

Best regards
Georges

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: IRQ SPEED

Post by Roberthh » Sat Jun 22, 2019 7:37 pm

Using ESP32 for that purpose will be no joy. The esp32 has bad IRQ latency between 20 and 400 µs. That is caused mainly by the code being stored in serial flash and cached in to the address space. On a cache miss, you will have a large latency. Better use the PyBoard.

OutoftheBOTS_
Posts: 847
Joined: Mon Nov 20, 2017 10:18 am

Re: IRQ SPEED

Post by OutoftheBOTS_ » Sat Jun 22, 2019 10:10 pm

The STM32 MCUs of the PYBoard also have hardware encoder counters on their timers.

Post Reply