JiriBilek / WiFiSpi

SPI library for Arduino AVR and STM32F1 to connect to ESP8266
GNU Lesser General Public License v3.0
62 stars 13 forks source link

Added support for any SPI interface #7

Closed posse-spin closed 6 years ago

posse-spin commented 6 years ago

Changed the initialization list as to not break old code. Also added the yield() function to waitForSlaveTxReady() and waitForSlaveRxReady(), as it was holding the entire sketch for the timeout duration.

posse-spin commented 6 years ago

I'm having a lot of timeouts on waitForSlaveRxReady, which cause a tcp disconnect. I'm initializing WiFiSpi with 10MHz max speed, setting up a server, opening a client and then requesting the number of bytes available for read every 10ms. Any reason why I should be hitting the 3s timeout?

(should this be moved to an issue?)

JiriBilek commented 6 years ago

Please try the development version of this library and if it doesn't help, open a nwe issue. In development branch I tuned SPI timeouts because I saw rejected messages time to time. This happened only on STM32F1, not on ATMega.

JiriBilek commented 6 years ago

The changes are ok, thanks. I'll test it and merge ASAP. J.

JiriBilek commented 6 years ago

Reopening to be able to merge :)