borgware-2d/src/config.h

39 lines
729 B
C
Raw Normal View History

#ifndef CONFIG_H_
#define CONFIG_H_
#include "autoconf.h"
#ifdef CAN_SUPPORT
#define BORG_CAN
2011-10-28 21:52:17 +00:00
// spi.[ch] defines
//spi port default config
#if SPI_PORTIDX == 0
2011-10-28 21:52:17 +00:00
#define SPI_PORT PORTA
#define SPI_DDR DDRA
#define SPI_PIN PINA
#elif SPI_PORTIDX == 1
2011-10-28 21:52:17 +00:00
#define SPI_PORT PORTB
#define SPI_DDR DDRB
#define SPI_PIN PINB
#elif SPI_PORTIDX == 2
2011-10-28 21:52:17 +00:00
#define SPI_PORT PORTC
#define SPI_DDR DDRC
#define SPI_PIN PINC
#elif SPI_PORTIDX == 3
2011-10-28 21:52:17 +00:00
#define SPI_PORT PORTD
#define SPI_DDR DDRD
#define SPI_PIN PIND
#endif
// can.[ch] defines
#define CAN_RX_BUFFER_SIZE 2 //only used for Interrupt
#define CAN_TX_BUFFER_SIZE 2 //only used for Interrupt
#endif
#define INIT_EEPROM
//#define UART_BAUD_RATE 115200L
#endif /* CONFIG_H_ */