Fix missing method from SPI HAL

Fixes: https://github.com/espressif/arduino-esp32/issues/640
This commit is contained in:
me-no-dev 2017-09-18 12:14:41 +08:00
parent 79ee46ead2
commit ab0ea2f6da

View File

@ -680,6 +680,16 @@ void spiTransferBytes(spi_t * spi, uint8_t * data, uint8_t * out, uint32_t size)
SPI_MUTEX_UNLOCK();
}
void spiTransferBits(spi_t * spi, uint32_t data, uint32_t * out, uint8_t bits)
{
if(!spi) {
return;
}
SPI_MUTEX_LOCK();
spiTransferBitsNL(spi, data, out, bits);
SPI_MUTEX_UNLOCK();
}
/*
* Manual Lock Management
* */