Copy project
This commit is contained in:
parent
ce7a467af7
commit
26a0fd884f
173 changed files with 157458 additions and 1 deletions
17
ad_astra/AdAstra/src/hardware_access/spi/spi.h
Normal file
17
ad_astra/AdAstra/src/hardware_access/spi/spi.h
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
#ifndef SPI_H
|
||||
#define SPI_H
|
||||
|
||||
#include <avr/io.h>
|
||||
#include "bitwise.h"
|
||||
|
||||
|
||||
#define DO_PIN PB1
|
||||
#define USCK_PIN PB2
|
||||
|
||||
inline void initializeSPI() {
|
||||
DDRB |= BV(DO_PIN) | BV(USCK_PIN); // set pin directions for MOSI and SCK
|
||||
}
|
||||
|
||||
void sendByteOnSPI(uint8_t byte);
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue