summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--esp8266/common-hal/nativeio/SPI.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/esp8266/common-hal/nativeio/SPI.c b/esp8266/common-hal/nativeio/SPI.c
index 27774dcab..5c00e5843 100644
--- a/esp8266/common-hal/nativeio/SPI.c
+++ b/esp8266/common-hal/nativeio/SPI.c
@@ -122,6 +122,7 @@ bool common_hal_nativeio_spi_write(nativeio_spi_obj_t *self,
spi_tx8fast(HSPI, data[i]);
++i;
}
+ while (spi_busy(HSPI)) {}; // Wait for SPI to finish the last byte.
return true;
}