aboutsummaryrefslogtreecommitdiff
path: root/tk-attiny.h
diff options
context:
space:
mode:
authorSelene ToyKeeper2018-12-18 14:43:52 -0700
committerSelene ToyKeeper2018-12-18 14:43:52 -0700
commitc401894ebea3ed1f9313448324e897b2bf37b8e4 (patch)
treec7d13f8bd51387fb6d02a82faaf06270fe55d95e /tk-attiny.h
parentUpdated Anduril text file, mostly. (diff)
downloadanduril-c401894ebea3ed1f9313448324e897b2bf37b8e4.tar.gz
anduril-c401894ebea3ed1f9313448324e897b2bf37b8e4.tar.bz2
anduril-c401894ebea3ed1f9313448324e897b2bf37b8e4.zip
Reworked the config file include system so it'll include the #defined value
instead of having to hard-code a bunch of specific recognized values.
Diffstat (limited to 'tk-attiny.h')
-rw-r--r--tk-attiny.h43
1 files changed, 8 insertions, 35 deletions
diff --git a/tk-attiny.h b/tk-attiny.h
index 54856bf..3c985f2 100644
--- a/tk-attiny.h
+++ b/tk-attiny.h
@@ -61,6 +61,11 @@
#include <avr/interrupt.h>
/******************** I/O pin and register layout ************************/
+#ifdef HWDEFFILE
+#include "tk.h"
+#include incfile(HWDEFFILE)
+#endif
+
#if 0 // placeholder
#elif defined(NANJG_LAYOUT)
@@ -75,42 +80,10 @@
#elif defined(FERRERO_ROCHER_LAYOUT)
#include "hwdef-Ferrero_Rocher.h"
-#elif defined(FSM_BLF_GT_DRIVER)
-#include "hwdef-BLF_GT.h"
-
-#elif defined(FSM_BLF_GT_MINI_DRIVER)
-#include "hwdef-BLF_GT_Mini.h"
-
-#elif defined(FSM_BLF_Q8_DRIVER)
-#include "hwdef-BLF_Q8.h"
-
-#elif defined(FSM_EMISAR_D4_DRIVER)
-#include "hwdef-Emisar_D4.h"
-
-#elif defined(FSM_EMISAR_D4S_DRIVER)
-#include "hwdef-Emisar_D4S.h"
-
-#elif defined(FSM_EMISAR_D1_DRIVER)
-#include "hwdef-Emisar_D1.h"
-
-#elif defined(FSM_EMISAR_D1S_DRIVER)
-#include "hwdef-Emisar_D1S.h"
-
-#elif defined(FSM_FF_PL47_DRIVER)
-#include "hwdef-FF_PL47.h"
-
-#elif defined(FSM_FF_ROT66_DRIVER)
-#include "hwdef-FF_ROT66.h"
-
-#elif defined(FSM_FW3A_DRIVER)
-#include "hwdef-FW3A.h"
-
-#elif defined(FSM_TKSABER_DRIVER)
-#include "hwdef-TK_Saber.h"
+#endif // no more recognized driver types
-#else
+#ifndef LAYOUT_DEFINED
#error Hey, you need to define an I/O pin layout.
-
-#endif // no more recognized driver types
+#endif
#endif // TK_ATTINY_H