Is there any way to get around the ~125 microsecond delay when doing Pin toggle for CS before and after an SPI transaction?
For use cases with a single SPI device and one master, it seems advantageous to access the hardware CS.
https://github.com/micropython/micropyt ... spi.c#L102 seems to indicate there was some thought at one time to set up the ESP GPIO from HSPICS at the hardware level. Is there any way to call PIN_FUNC_SELECT() from Python?
There is also an open issue for this on Github: https://github.com/micropython/micropython/issues/2509
Using HSPICS on GPIO15
Re: Using HSPICS on GPIO15
We talked about this a few days ago on https://github.com/micropython/micropyt ... 1161176125 although the pin toggle delay wasn't discussed there.
Re: Using HSPICS on GPIO15
Interesting approach taken by Owen.
The decision makes sense, and I understand the reasoning behind it.
That said, hiding a hardware feature of the ESP device seems like a disadvantage.
Here is an example of the delay:
Is there anything to be done to tighten up the CS toggle around the SPI transaction, or is this simply a limitation of the Python abstraction?
The decision makes sense, and I understand the reasoning behind it.
That said, hiding a hardware feature of the ESP device seems like a disadvantage.
Here is an example of the delay:
Code: Select all
cs.value(0)
spi.write(b'\xac')
cs.value(1)
Re: Using HSPICS on GPIO15
It is marginally faster to write
cs(0)
rather than
cs.value(0)
as it avoids the lookup of the value function but yeah right now this is a limitation.