sys/arduino: Bug and style fixes in SPI
- set is_transaction before releasing the SPI bus (and the mutex) to avoid data races - adapt switch indent to coding convention
This commit is contained in:
parent
dd0c13d227
commit
45ed8bc330
@ -90,8 +90,8 @@ void SPIClass::beginTransaction(SPISettings settings)
|
||||
|
||||
void SPIClass::endTransaction()
|
||||
{
|
||||
spi_release(spi_dev);
|
||||
is_transaction = false;
|
||||
spi_release(spi_dev);
|
||||
rmutex_unlock(&mut);
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user