-extern inline void spi_enable() { bset((void*)&_io_ports[M6811_SPCR], M6811_SPE); }
-extern inline void spi_disable() { bclr((void*)&_io_ports[M6811_SPCR], M6811_SPE); }
+extern volatile u8 _switch_input;
+#define switch_input _switch_input
+extern volatile u8 _misc_input;
+#define misc_input _misc_input
+extern volatile u8 _home_sensors;
+#define home_sensors _home_sensors
+
+#define is_standalone() (misc_input & 0x01) /* DIP sw 1 */
+#define must_verify() (misc_input & 0x02) /* DIP sw 2 */
+
+extern u16 _stack;