1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2024-12-22 19:34:14 +02:00

flashi/spi: Use tabs instead of spaces.

Purely cosmetic. No idea when this sneaked in here.
This commit is contained in:
Stefan Schmidt 2015-06-07 00:34:14 +02:00
parent 37a4f00e41
commit 15b15b9524
2 changed files with 6 additions and 6 deletions

View File

@ -39,7 +39,7 @@ static bool flash_can_write(uint16_t size)
static void flash_write(const uint8_t *buf, uint16_t size)
{
static uint8_t last;
const uint8_t *p;
const uint8_t *p;
for (p = buf; p != buf+size; p++) {
if (!(payload & (SPM_PAGESIZE-1))) {
@ -57,7 +57,7 @@ static void flash_write(const uint8_t *buf, uint16_t size)
boot_page_write(payload-SPM_PAGESIZE);
boot_spm_busy_wait();
}
}
}
}

View File

@ -34,9 +34,9 @@ void spi_begin(void)
uint8_t spi_io(uint8_t v)
{
// while (!(UCSR1A & 1 << UDRE1));
UDR1 = v;
while (!(UCSR1A & 1 << RXC1));
return UDR1;
UDR1 = v;
while (!(UCSR1A & 1 << RXC1));
return UDR1;
}
@ -51,7 +51,7 @@ void spi_recv_block(uint8_t *buf, uint8_t n)
{
if (!n)
return;
UDR1 = 0;
UDR1 = 0;
while (--n) {
while (!(UCSR1A & 1 << RXC1));
*buf++ = UDR1;