projects
/
fw
/
altos
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
b8d8b23
)
altos/avr: Use ISR_BLOCK to disable interrupts during slave ISR
author
Keith Packard
<keithp@keithp.com>
Wed, 17 Oct 2012 04:08:58 +0000
(21:08 -0700)
committer
Keith Packard
<keithp@keithp.com>
Wed, 17 Oct 2012 04:08:58 +0000
(21:08 -0700)
This avoids enabling and then immediatly disabling them
Signed-off-by: Keith Packard <keithp@keithp.com>
src/avr/ao_spi_slave.c
patch
|
blob
|
history
diff --git
a/src/avr/ao_spi_slave.c
b/src/avr/ao_spi_slave.c
index b742d29aa6de10b73bb6d1ce8e60f756c0d7fc3f..a400b8a0a929f0485b8d8da894f43c17ec098f79 100644
(file)
--- a/
src/avr/ao_spi_slave.c
+++ b/
src/avr/ao_spi_slave.c
@@
-44,9
+44,8
@@
ao_spi_slave_send(uint8_t *buf, uint8_t len)
static uint8_t ao_spi_slave_running;
-ISR(PCINT0_vect)
+ISR(PCINT0_vect
, ISR_BLOCK
)
{
- cli();
#if SPI_SLAVE_PIN_0_3
if ((PINB & (1 << PORTB0)) == 0)
#endif
@@
-61,7
+60,6
@@
ISR(PCINT0_vect)
} else {
ao_spi_slave_running = 0;
}
- sei();
}
void