More safe read data on SPI

pull/130/head
DiSlord 6 years ago
parent 8c131098f0
commit fb258a9201

@ -223,7 +223,7 @@ static void spi_TxBuffer(uint8_t *buffer, uint16_t len) {
static uint8_t spi_RxByte(void) {
// Start RX clock (by sending data)
SPI_WRITE_8BIT(LCD_SPI, 0xFF);
while (SPI_RX_IS_EMPTY(LCD_SPI));
while (SPI_RX_IS_EMPTY(LCD_SPI)||SPI_IS_BUSY(LCD_SPI));
return SPI_READ_8BIT(LCD_SPI);
}

Loading…
Cancel
Save

Powered by TurnKey Linux.