mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-06-07 08:52:46 +00:00
Add architecture guards to all architecture-specific files, so that they can be bulk-added to existing IDE projects without having to exclude unused architecture files.
This commit is contained in:
parent
d4b45e8502
commit
8f4f48d963
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_SERIAL_C
|
#define __INCLUDE_FROM_SERIAL_C
|
||||||
#include "../Serial.h"
|
#include "../Serial.h"
|
||||||
|
|
||||||
@ -112,3 +115,5 @@ void Serial_CreateBlockingStream(FILE* Stream)
|
|||||||
|
|
||||||
*Stream = (FILE)FDEV_SETUP_STREAM(Serial_putchar, Serial_getchar_Blocking, _FDEV_SETUP_RW);
|
*Stream = (FILE)FDEV_SETUP_STREAM(Serial_putchar, Serial_getchar_Blocking, _FDEV_SETUP_RW);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_TWI_C
|
#define __INCLUDE_FROM_TWI_C
|
||||||
#include "../TWI.h"
|
#include "../TWI.h"
|
||||||
|
|
||||||
@ -201,3 +204,4 @@ uint8_t TWI_WritePacket(const uint8_t SlaveAddress,
|
|||||||
return ErrorCode;
|
return ErrorCode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_SERIAL_C
|
#define __INCLUDE_FROM_SERIAL_C
|
||||||
#include "../Serial.h"
|
#include "../Serial.h"
|
||||||
|
|
||||||
@ -115,3 +118,5 @@ void Serial_CreateBlockingStream(FILE* Stream)
|
|||||||
|
|
||||||
*Stream = (FILE)FDEV_SETUP_STREAM(Serial_putchar, Serial_getchar_Blocking, _FDEV_SETUP_RW);
|
*Stream = (FILE)FDEV_SETUP_STREAM(Serial_putchar, Serial_getchar_Blocking, _FDEV_SETUP_RW);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -51,3 +54,4 @@ void USB_Device_SendRemoteWakeup(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -269,3 +272,4 @@ uint8_t Endpoint_Null_Stream(uint16_t Length,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -180,3 +183,4 @@ uint8_t Endpoint_WaitUntilReady(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -292,3 +295,4 @@ static void USB_Host_ResetDevice(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -214,3 +217,5 @@ uint8_t Pipe_Null_Stream(uint16_t Length,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -179,3 +182,4 @@ uint8_t Pipe_WaitUntilReady(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
||||||
#include "../USBController.h"
|
#include "../USBController.h"
|
||||||
@ -260,3 +263,4 @@ static void USB_Init_Host(void)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_AVR8)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBInterrupt.h"
|
#include "../USBInterrupt.h"
|
||||||
|
|
||||||
@ -273,3 +276,5 @@ ISR(USB_COM_vect, ISR_BLOCK)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -45,3 +48,4 @@ void USB_Device_SendRemoteWakeup(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -229,3 +232,4 @@ uint8_t Endpoint_Null_Stream(uint16_t Length,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -173,3 +176,4 @@ uint8_t Endpoint_WaitUntilReady(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -292,3 +295,4 @@ static void USB_Host_ResetDevice(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -160,3 +163,4 @@ uint8_t Pipe_Null_Stream(uint16_t Length,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -178,3 +181,4 @@ uint8_t Pipe_WaitUntilReady(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
||||||
#include "../USBController.h"
|
#include "../USBController.h"
|
||||||
@ -217,3 +220,4 @@ static void USB_Init_Host(void)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBInterrupt.h"
|
#include "../USBInterrupt.h"
|
||||||
|
|
||||||
@ -223,3 +226,4 @@ ISR(USB_COM_vect)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -42,3 +45,5 @@ void USB_Device_SendRemoteWakeup(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -269,3 +272,4 @@ uint8_t Endpoint_Null_Stream(uint16_t Length,
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -145,3 +148,5 @@ uint8_t Endpoint_WaitUntilReady(void)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -35,3 +38,4 @@
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBMode.h"
|
#include "../USBMode.h"
|
||||||
|
|
||||||
@ -35,3 +38,4 @@
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
#define __INCLUDE_FROM_USB_CONTROLLER_C
|
||||||
#include "../USBController.h"
|
#include "../USBController.h"
|
||||||
@ -178,3 +181,4 @@ static void USB_Init_Device(void)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_XMEGA)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_USB_DRIVER
|
#define __INCLUDE_FROM_USB_DRIVER
|
||||||
#include "../USBInterrupt.h"
|
#include "../USBInterrupt.h"
|
||||||
|
|
||||||
@ -101,3 +104,4 @@ ISR(USB_BUSEVENT_vect)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,7 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#if defined(__AVR32__)
|
||||||
#include <avr32/io.h>
|
#include <avr32/io.h>
|
||||||
|
|
||||||
.section .exception_handlers, "ax", @progbits
|
.section .exception_handlers, "ax", @progbits
|
||||||
@ -123,3 +124,5 @@ Autovector_Table:
|
|||||||
.word ((AVR32_INTC_INT0 + \Level) << AVR32_INTC_IPR_INTLEVEL_OFFSET) | (Exception_INT\Level - EVBA_Table)
|
.word ((AVR32_INTC_INT0 + \Level) << AVR32_INTC_IPR_INTLEVEL_OFFSET) | (Exception_INT\Level - EVBA_Table)
|
||||||
.endr
|
.endr
|
||||||
// === END OF GENERAL INTERRUPT HANDLER OFFSET TABLE ===
|
// === END OF GENERAL INTERRUPT HANDLER OFFSET TABLE ===
|
||||||
|
|
||||||
|
#endif
|
||||||
|
@ -28,6 +28,9 @@
|
|||||||
this software.
|
this software.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#include "../../Common/Common.h"
|
||||||
|
#if (ARCH == ARCH_UC3)
|
||||||
|
|
||||||
#define __INCLUDE_FROM_INTMANAGEMENT_C
|
#define __INCLUDE_FROM_INTMANAGEMENT_C
|
||||||
#include "InterruptManagement.h"
|
#include "InterruptManagement.h"
|
||||||
|
|
||||||
@ -62,3 +65,4 @@ void INTC_Init(void)
|
|||||||
__builtin_mtsr(AVR32_EVBA, (uintptr_t)&EVBA_Table);
|
__builtin_mtsr(AVR32_EVBA, (uintptr_t)&EVBA_Table);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user