fixed some PCB_rev-define-Stuff

This commit is contained in:
Marcel Peterkau 2023-03-02 17:38:57 +01:00
parent a563182f3e
commit 50208e4a1a
2 changed files with 14 additions and 8 deletions

View File

@ -4,16 +4,22 @@
#define Q(x) #x
#define QUOTE(x) Q(x)
#if PCB_REV == 2
#if PCB_REV == 1
#define GPIO_BUTTON D7
#define GPIO_LED D8
#define GPIO_TRIGGER D6
#define GPIO_PUMP D5
#elif PCB_REV == 1 || PCB_REV == 3
#define GPIO_BUTTON D5
#define GPIO_LED D6
#define GPIO_TRIGGER D4
#define GPIO_PUMP D3
#elif PCB_REV == 2
#define GPIO_BUTTON D7
#define GPIO_LED D8
#define GPIO_TRIGGER D6
#define GPIO_PUMP D5
#elif PCB_REV == 3
#define GPIO_BUTTON D4
#define GPIO_LED D3
#define GPIO_TRIGGER D6
#define GPIO_PUMP D0
#define GPIO_CS_CAN D8
#elif PCB_REV == 4
#define GPIO_BUTTON D4
#define GPIO_LED D3

View File

@ -8,11 +8,11 @@
#error "Unsupported PCB-Revision"
#endif
#if PCB_REV < 4 && defined(FEATURE_ENABLE_CAN)
#if PCB_REV < 3 && defined(FEATURE_ENABLE_CAN)
#error "CAN-Feature unsupported with this PCB-Rev"
#endif
#if PCB_REV < 4 && defined(DFEATURE_ENABLE_GPS)
#error "CAN-Feature unsupported with this PCB-Rev"
#error "GPS-Feature unsupported with this PCB-Rev"
#endif
#endif