//! The SPI mutex.static xSemaphoreHandle xSPIMutex;spi_status_t spi_selectChip(volatile avr32_spi_t *spi, unsigned char chip){ while (pdFALSE == xSemaphoreTake(xSPIMutex, 20));// ..... lalalalal return SPI_OK;}