Fixed EVENT_USB_CDC_ControLineStateChanged() event not taking the CDC interface struc...
[pub/USBasp.git] / Bootloaders / CDC / BootloaderCDC.h
index dce84a5..da75593 100644 (file)
 \r
                #include <LUFA/Drivers/USB/USB.h>                // USB Functionality\r
 \r
+       /* Preprocessor Checks: */\r
+               #if !defined(SIGNATURE_0) || !defined(SIGNATURE_1) || !defined(SIGNATURE_2)\r
+                       #error Device signature byte constants are not defined due to outdated avr-libc version. See demo documentation.\r
+               #endif\r
+\r
        /* Macros: */\r
                /** CDC Class Specific request to get the line encoding on a CDC-ACM virtual serial port, including the\r
                 *  baud rate, parity, stop bits and data bits.\r
                #define BOOTLOADER_HWVERSION_MINOR   0x00\r
 \r
                /** Eight character bootloader firmware identifier reported to the host when requested */\r
-               #define SOFTWARE_IDENTIFIER          "LUFA-CDC"\r
-\r
-       /* Event Handlers: */\r
-               /** Indicates that this module will catch the USB_Disconnect event when thrown by the library. */\r
-               HANDLES_EVENT(USB_Disconnect);\r
-\r
-               /** Indicates that this module will catch the USB_ConfigurationChanged event when thrown by the library. */\r
-               HANDLES_EVENT(USB_ConfigurationChanged);\r
-\r
-               /** Indicates that this module will catch the USB_UnhandledControlPacket event when thrown by the library. */\r
-               HANDLES_EVENT(USB_UnhandledControlPacket);\r
+               #define SOFTWARE_IDENTIFIER          "LUFACDC"\r
                \r
        /* Type Defines: */\r
                /** Type define for a non-returning pointer to the start of the loaded application in flash memory. */\r
                TASK(CDC_Task);\r
 \r
        /* Function Prototypes: */\r
+               void EVENT_USB_Disconnect(void);\r
+               void EVENT_USB_ConfigurationChanged(void);\r
+               void EVENT_USB_UnhandledControlPacket(void);\r
+\r
                #if defined(INCLUDE_FROM_BOOTLOADERCDC_C) || defined(__DOXYGEN__)\r
                        static void    ReadWriteMemoryBlock(const uint8_t Command);\r
                        static uint8_t FetchNextCommandByte(void);\r