aboutsummaryrefslogtreecommitdiff
path: root/src/spi.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/spi.c')
-rw-r--r--src/spi.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/spi.c b/src/spi.c
index 69012fa..adf858d 100644
--- a/src/spi.c
+++ b/src/spi.c
@@ -8,11 +8,9 @@ volatile Mutex spi_mutex;
void (*spi_receive) (uint8_t data) = 0;
ISR(SPI_STC_vect, ISR_BLOCK) {
- void (*spir_w) (uint8_t data) = spi_receive;
_spi_busy = 0;
- while (spir_w != NULL) {
+ if (spi_receive != NULL) {
spir_w(SPDR);
- spir_w++;
}
}