Add branch for the conversion of demos to use standard C header files for configurati...
authorDean Camera <dean@fourwalledcubicle.com>
Thu, 10 May 2012 19:24:58 +0000 (19:24 +0000)
committerDean Camera <dean@fourwalledcubicle.com>
Thu, 10 May 2012 19:24:58 +0000 (19:24 +0000)
395 files changed:
Bootloaders/CDC/BootloaderCDC.c
Bootloaders/CDC/BootloaderCDC.h
Bootloaders/CDC/BootloaderCDC.txt
Bootloaders/CDC/Config/AppConfig.h [new file with mode: 0644]
Bootloaders/CDC/Config/LUFAConfig.h [new file with mode: 0644]
Bootloaders/CDC/Descriptors.c
Bootloaders/CDC/Descriptors.h
Bootloaders/CDC/makefile
Bootloaders/DFU/BootloaderDFU.c
Bootloaders/DFU/BootloaderDFU.h
Bootloaders/DFU/BootloaderDFU.txt
Bootloaders/DFU/Descriptors.c
Bootloaders/DFU/makefile
Bootloaders/HID/BootloaderHID.c
Bootloaders/HID/BootloaderHID.h
Bootloaders/HID/BootloaderHID.txt
Bootloaders/HID/Descriptors.c
Bootloaders/HID/Descriptors.h
Bootloaders/HID/HostLoaderApp/hid_bootloader_cli.c
Bootloaders/HID/makefile
BuildTests/BoardDriverTest/Board/Buttons.h [new file with mode: 0644]
BuildTests/BoardDriverTest/Board/Dataflash.h [new file with mode: 0644]
BuildTests/BoardDriverTest/Board/Joystick.h [new file with mode: 0644]
BuildTests/BoardDriverTest/Board/LEDs.h [new file with mode: 0644]
BuildTests/BoardDriverTest/BoardDeviceMap.cfg [new file with mode: 0644]
BuildTests/BoardDriverTest/Test.c [new file with mode: 0644]
BuildTests/BoardDriverTest/makefile [new file with mode: 0644]
BuildTests/BoardDriverTest/makefile.avr8 [new file with mode: 0644]
BuildTests/BoardDriverTest/makefile.uc3 [new file with mode: 0644]
BuildTests/BoardDriverTest/makefile.xmega [new file with mode: 0644]
BuildTests/ModuleTest/makefile
BuildTests/SingleUSBModeTest/makefile
BuildTests/StaticAnalysisTest/makefile
BuildTests/makefile
Demos/Device/ClassDriver/AudioInput/AudioInput.c
Demos/Device/ClassDriver/AudioInput/Descriptors.c
Demos/Device/ClassDriver/AudioInput/Descriptors.h
Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
Demos/Device/ClassDriver/AudioOutput/Descriptors.c
Demos/Device/ClassDriver/AudioOutput/Descriptors.h
Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.c
Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.h
Demos/Device/ClassDriver/DualVirtualSerial/DualVirtualSerial.c
Demos/Device/ClassDriver/GenericHID/Descriptors.c
Demos/Device/ClassDriver/GenericHID/Descriptors.h
Demos/Device/ClassDriver/GenericHID/GenericHID.c
Demos/Device/ClassDriver/Joystick/Descriptors.c
Demos/Device/ClassDriver/Joystick/Descriptors.h
Demos/Device/ClassDriver/Joystick/Joystick.c
Demos/Device/ClassDriver/Keyboard/Descriptors.c
Demos/Device/ClassDriver/Keyboard/Descriptors.h
Demos/Device/ClassDriver/Keyboard/Keyboard.c
Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c
Demos/Device/ClassDriver/KeyboardMouse/Descriptors.h
Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.c
Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.h
Demos/Device/ClassDriver/KeyboardMouseMultiReport/KeyboardMouseMultiReport.c
Demos/Device/ClassDriver/MIDI/Descriptors.c
Demos/Device/ClassDriver/MIDI/Descriptors.h
Demos/Device/ClassDriver/MIDI/MIDI.c
Demos/Device/ClassDriver/MassStorage/Descriptors.c
Demos/Device/ClassDriver/MassStorage/Descriptors.h
Demos/Device/ClassDriver/MassStorage/MassStorage.c
Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.c
Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.h
Demos/Device/ClassDriver/MassStorageKeyboard/MassStorageKeyboard.c
Demos/Device/ClassDriver/Mouse/Descriptors.c
Demos/Device/ClassDriver/Mouse/Descriptors.h
Demos/Device/ClassDriver/Mouse/Mouse.c
Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c
Demos/Device/ClassDriver/RNDISEthernet/Descriptors.h
Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
Demos/Device/ClassDriver/VirtualSerial/Descriptors.c
Demos/Device/ClassDriver/VirtualSerial/Descriptors.h
Demos/Device/ClassDriver/VirtualSerial/VirtualSerial.c
Demos/Device/ClassDriver/VirtualSerialMassStorage/Descriptors.c
Demos/Device/ClassDriver/VirtualSerialMassStorage/Descriptors.h
Demos/Device/ClassDriver/VirtualSerialMassStorage/VirtualSerialMassStorage.c
Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.c
Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.h
Demos/Device/ClassDriver/VirtualSerialMouse/VirtualSerialMouse.c
Demos/Device/Incomplete/Sideshow/Descriptors.c
Demos/Device/Incomplete/Sideshow/Descriptors.h
Demos/Device/Incomplete/Sideshow/Lib/SideshowCommands.c
Demos/Device/Incomplete/Sideshow/Sideshow.c
Demos/Device/Incomplete/TestAndMeasurement/Descriptors.c
Demos/Device/Incomplete/TestAndMeasurement/Descriptors.h
Demos/Device/Incomplete/TestAndMeasurement/TestAndMeasurement.c
Demos/Device/LowLevel/AudioInput/AudioInput.c
Demos/Device/LowLevel/AudioInput/Descriptors.c
Demos/Device/LowLevel/AudioInput/Descriptors.h
Demos/Device/LowLevel/AudioOutput/AudioOutput.c
Demos/Device/LowLevel/AudioOutput/Descriptors.c
Demos/Device/LowLevel/AudioOutput/Descriptors.h
Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c
Demos/Device/LowLevel/DualVirtualSerial/Descriptors.h
Demos/Device/LowLevel/DualVirtualSerial/DualVirtualSerial.c
Demos/Device/LowLevel/GenericHID/Descriptors.c
Demos/Device/LowLevel/GenericHID/Descriptors.h
Demos/Device/LowLevel/GenericHID/GenericHID.c
Demos/Device/LowLevel/Joystick/Descriptors.c
Demos/Device/LowLevel/Joystick/Descriptors.h
Demos/Device/LowLevel/Joystick/Joystick.c
Demos/Device/LowLevel/Keyboard/Descriptors.c
Demos/Device/LowLevel/Keyboard/Descriptors.h
Demos/Device/LowLevel/Keyboard/Keyboard.c
Demos/Device/LowLevel/KeyboardMouse/Descriptors.c
Demos/Device/LowLevel/KeyboardMouse/Descriptors.h
Demos/Device/LowLevel/KeyboardMouse/KeyboardMouse.c
Demos/Device/LowLevel/MIDI/Descriptors.c
Demos/Device/LowLevel/MIDI/Descriptors.h
Demos/Device/LowLevel/MIDI/MIDI.c
Demos/Device/LowLevel/MassStorage/Descriptors.c
Demos/Device/LowLevel/MassStorage/Descriptors.h
Demos/Device/LowLevel/MassStorage/MassStorage.c
Demos/Device/LowLevel/Mouse/Descriptors.c
Demos/Device/LowLevel/Mouse/Descriptors.h
Demos/Device/LowLevel/Mouse/Mouse.c
Demos/Device/LowLevel/RNDISEthernet/Descriptors.c
Demos/Device/LowLevel/RNDISEthernet/Descriptors.h
Demos/Device/LowLevel/RNDISEthernet/RNDISEthernet.c
Demos/Device/LowLevel/VirtualSerial/Descriptors.c
Demos/Device/LowLevel/VirtualSerial/Descriptors.h
Demos/Device/LowLevel/VirtualSerial/VirtualSerial.c
Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.c
Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.h
Demos/DualRole/ClassDriver/MouseHostDevice/DeviceFunctions.c
Demos/DualRole/ClassDriver/MouseHostDevice/HostFunctions.c
Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.c
Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.c
Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.c
Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c
Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c
Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c
Demos/Host/ClassDriver/MIDIHost/MIDIHost.c
Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c
Demos/Host/ClassDriver/MouseHost/MouseHost.c
Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c
Demos/Host/ClassDriver/PrinterHost/PrinterHost.c
Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c
Demos/Host/ClassDriver/StillImageHost/StillImageHost.c
Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c
Demos/Host/Incomplete/BluetoothHost/ConfigDescriptor.c
Demos/Host/Incomplete/BluetoothHost/ConfigDescriptor.h
Demos/Host/LowLevel/AndroidAccessoryHost/ConfigDescriptor.c
Demos/Host/LowLevel/AndroidAccessoryHost/ConfigDescriptor.h
Demos/Host/LowLevel/AudioInputHost/ConfigDescriptor.c
Demos/Host/LowLevel/AudioInputHost/ConfigDescriptor.h
Demos/Host/LowLevel/AudioInputHost/Doxygen.conf
Demos/Host/LowLevel/AudioOutputHost/ConfigDescriptor.c
Demos/Host/LowLevel/AudioOutputHost/ConfigDescriptor.h
Demos/Host/LowLevel/AudioOutputHost/Doxygen.conf
Demos/Host/LowLevel/GenericHIDHost/ConfigDescriptor.c
Demos/Host/LowLevel/GenericHIDHost/ConfigDescriptor.h
Demos/Host/LowLevel/JoystickHostWithParser/ConfigDescriptor.c
Demos/Host/LowLevel/JoystickHostWithParser/ConfigDescriptor.h
Demos/Host/LowLevel/JoystickHostWithParser/Doxygen.conf
Demos/Host/LowLevel/KeyboardHost/ConfigDescriptor.c
Demos/Host/LowLevel/KeyboardHost/ConfigDescriptor.h
Demos/Host/LowLevel/KeyboardHostWithParser/ConfigDescriptor.c
Demos/Host/LowLevel/KeyboardHostWithParser/ConfigDescriptor.h
Demos/Host/LowLevel/KeyboardHostWithParser/Doxygen.conf
Demos/Host/LowLevel/MIDIHost/ConfigDescriptor.c
Demos/Host/LowLevel/MIDIHost/ConfigDescriptor.h
Demos/Host/LowLevel/MIDIHost/MIDIHost.c
Demos/Host/LowLevel/MassStorageHost/ConfigDescriptor.c
Demos/Host/LowLevel/MassStorageHost/ConfigDescriptor.h
Demos/Host/LowLevel/MouseHost/ConfigDescriptor.c
Demos/Host/LowLevel/MouseHost/ConfigDescriptor.h
Demos/Host/LowLevel/MouseHostWithParser/ConfigDescriptor.c
Demos/Host/LowLevel/MouseHostWithParser/ConfigDescriptor.h
Demos/Host/LowLevel/MouseHostWithParser/Doxygen.conf
Demos/Host/LowLevel/PrinterHost/ConfigDescriptor.c
Demos/Host/LowLevel/PrinterHost/ConfigDescriptor.h
Demos/Host/LowLevel/RNDISEthernetHost/ConfigDescriptor.c
Demos/Host/LowLevel/RNDISEthernetHost/ConfigDescriptor.h
Demos/Host/LowLevel/StillImageHost/ConfigDescriptor.c
Demos/Host/LowLevel/StillImageHost/ConfigDescriptor.h
Demos/Host/LowLevel/VirtualSerialHost/ConfigDescriptor.c
Demos/Host/LowLevel/VirtualSerialHost/ConfigDescriptor.h
LUFA.pnproj
LUFA/CodeTemplates/LUFAConfig.h
LUFA/Common/ArchitectureSpecific.h
LUFA/Common/BoardTypes.h
LUFA/DoxygenPages/ChangeLog.txt
LUFA/DoxygenPages/DeviceSupport.txt
LUFA/DoxygenPages/FutureChanges.txt
LUFA/DoxygenPages/KnownIssues.txt [new file with mode: 0644]
LUFA/DoxygenPages/LUFAPoweredProjects.txt
LUFA/DoxygenPages/LibraryResources.txt
LUFA/DoxygenPages/MainPage.txt
LUFA/DoxygenPages/MigrationInformation.txt
LUFA/Drivers/Board/AVR8/ADAFRUITU4/LEDs.h
LUFA/Drivers/Board/AVR8/ATAVRUSBRF01/Buttons.h
LUFA/Drivers/Board/AVR8/ATAVRUSBRF01/LEDs.h
LUFA/Drivers/Board/AVR8/BENITO/Buttons.h
LUFA/Drivers/Board/AVR8/BENITO/LEDs.h
LUFA/Drivers/Board/AVR8/BIGMULTIO/LEDs.h
LUFA/Drivers/Board/AVR8/BLACKCAT/LEDs.h
LUFA/Drivers/Board/AVR8/BUI/LEDs.h
LUFA/Drivers/Board/AVR8/BUMBLEB/Buttons.h
LUFA/Drivers/Board/AVR8/BUMBLEB/Joystick.h
LUFA/Drivers/Board/AVR8/BUMBLEB/LEDs.h
LUFA/Drivers/Board/AVR8/CULV3/Buttons.h
LUFA/Drivers/Board/AVR8/CULV3/LEDs.h
LUFA/Drivers/Board/AVR8/DUCE/LEDs.h [new file with mode: 0644]
LUFA/Drivers/Board/AVR8/EVK527/Buttons.h
LUFA/Drivers/Board/AVR8/EVK527/Dataflash.h
LUFA/Drivers/Board/AVR8/EVK527/Joystick.h
LUFA/Drivers/Board/AVR8/EVK527/LEDs.h
LUFA/Drivers/Board/AVR8/JMDBU2/Buttons.h
LUFA/Drivers/Board/AVR8/JMDBU2/LEDs.h
LUFA/Drivers/Board/AVR8/MAXIMUS/LEDs.h
LUFA/Drivers/Board/AVR8/MICROPENDOUS/Buttons.h
LUFA/Drivers/Board/AVR8/MICROPENDOUS/LEDs.h
LUFA/Drivers/Board/AVR8/MICROSIN162/Buttons.h
LUFA/Drivers/Board/AVR8/MICROSIN162/LEDs.h
LUFA/Drivers/Board/AVR8/MINIMUS/Buttons.h
LUFA/Drivers/Board/AVR8/MINIMUS/LEDs.h
LUFA/Drivers/Board/AVR8/MULTIO/LEDs.h
LUFA/Drivers/Board/AVR8/OLIMEX162/Buttons.h
LUFA/Drivers/Board/AVR8/OLIMEX162/LEDs.h
LUFA/Drivers/Board/AVR8/OLIMEX32U4/Buttons.h [new file with mode: 0644]
LUFA/Drivers/Board/AVR8/OLIMEX32U4/LEDs.h [new file with mode: 0644]
LUFA/Drivers/Board/AVR8/OLIMEXT32U4/Buttons.h [new file with mode: 0644]
LUFA/Drivers/Board/AVR8/OLIMEXT32U4/LEDs.h [new file with mode: 0644]
LUFA/Drivers/Board/AVR8/RZUSBSTICK/LEDs.h
LUFA/Drivers/Board/AVR8/SPARKFUN8U2/LEDs.h
LUFA/Drivers/Board/AVR8/STK525/Buttons.h
LUFA/Drivers/Board/AVR8/STK525/Dataflash.h
LUFA/Drivers/Board/AVR8/STK525/Joystick.h
LUFA/Drivers/Board/AVR8/STK525/LEDs.h
LUFA/Drivers/Board/AVR8/STK526/Buttons.h
LUFA/Drivers/Board/AVR8/STK526/Dataflash.h
LUFA/Drivers/Board/AVR8/STK526/Joystick.h
LUFA/Drivers/Board/AVR8/STK526/LEDs.h
LUFA/Drivers/Board/AVR8/TEENSY/LEDs.h
LUFA/Drivers/Board/AVR8/TUL/Buttons.h
LUFA/Drivers/Board/AVR8/TUL/LEDs.h
LUFA/Drivers/Board/AVR8/UDIP/Buttons.h
LUFA/Drivers/Board/AVR8/UDIP/LEDs.h
LUFA/Drivers/Board/AVR8/UNO/LEDs.h
LUFA/Drivers/Board/AVR8/USB2AX/Buttons.h
LUFA/Drivers/Board/AVR8/USB2AX/LEDs.h
LUFA/Drivers/Board/AVR8/USBFOO/Buttons.h
LUFA/Drivers/Board/AVR8/USBFOO/LEDs.h
LUFA/Drivers/Board/AVR8/USBKEY/Buttons.h
LUFA/Drivers/Board/AVR8/USBKEY/Dataflash.h
LUFA/Drivers/Board/AVR8/USBKEY/Joystick.h
LUFA/Drivers/Board/AVR8/USBKEY/LEDs.h
LUFA/Drivers/Board/AVR8/USBTINYMKII/Buttons.h
LUFA/Drivers/Board/AVR8/USBTINYMKII/LEDs.h
LUFA/Drivers/Board/AVR8/XPLAIN/Dataflash.h
LUFA/Drivers/Board/AVR8/XPLAIN/LEDs.h
LUFA/Drivers/Board/Buttons.h
LUFA/Drivers/Board/LEDs.h
LUFA/Drivers/Board/UC3/EVK1100/Buttons.h
LUFA/Drivers/Board/UC3/EVK1100/Joystick.h
LUFA/Drivers/Board/UC3/EVK1100/LEDs.h
LUFA/Drivers/Board/UC3/EVK1101/Buttons.h
LUFA/Drivers/Board/UC3/EVK1101/Joystick.h
LUFA/Drivers/Board/UC3/EVK1101/LEDs.h
LUFA/Drivers/Board/UC3/EVK1104/Buttons.h
LUFA/Drivers/Board/UC3/EVK1104/LEDs.h
LUFA/Drivers/Board/XMEGA/A3BU_XPLAINED/Buttons.h
LUFA/Drivers/Board/XMEGA/A3BU_XPLAINED/Dataflash.h
LUFA/Drivers/Board/XMEGA/A3BU_XPLAINED/LEDs.h
LUFA/Drivers/Board/XMEGA/B1_XPLAINED/Buttons.h
LUFA/Drivers/Board/XMEGA/B1_XPLAINED/Dataflash.h
LUFA/Drivers/Board/XMEGA/B1_XPLAINED/LEDs.h
LUFA/Drivers/Peripheral/AVR8/SerialSPI_AVR8.h
LUFA/Drivers/Peripheral/XMEGA/SerialSPI_XMEGA.h
LUFA/Drivers/USB/Class/Common/MIDIClassCommon.h
LUFA/Drivers/USB/Class/Device/AudioClassDevice.c
LUFA/Drivers/USB/Class/Device/AudioClassDevice.h
LUFA/Drivers/USB/Class/Device/CDCClassDevice.c
LUFA/Drivers/USB/Class/Device/CDCClassDevice.h
LUFA/Drivers/USB/Class/Device/HIDClassDevice.c
LUFA/Drivers/USB/Class/Device/HIDClassDevice.h
LUFA/Drivers/USB/Class/Device/MIDIClassDevice.c
LUFA/Drivers/USB/Class/Device/MIDIClassDevice.h
LUFA/Drivers/USB/Class/Device/MassStorageClassDevice.c
LUFA/Drivers/USB/Class/Device/MassStorageClassDevice.h
LUFA/Drivers/USB/Class/Device/RNDISClassDevice.c
LUFA/Drivers/USB/Class/Device/RNDISClassDevice.h
LUFA/Drivers/USB/Class/Host/AndroidAccessoryClassHost.c
LUFA/Drivers/USB/Class/Host/AndroidAccessoryClassHost.h
LUFA/Drivers/USB/Class/Host/AudioClassHost.c
LUFA/Drivers/USB/Class/Host/AudioClassHost.h
LUFA/Drivers/USB/Class/Host/CDCClassHost.c
LUFA/Drivers/USB/Class/Host/CDCClassHost.h
LUFA/Drivers/USB/Class/Host/HIDClassHost.c
LUFA/Drivers/USB/Class/Host/HIDClassHost.h
LUFA/Drivers/USB/Class/Host/MIDIClassHost.c
LUFA/Drivers/USB/Class/Host/MIDIClassHost.h
LUFA/Drivers/USB/Class/Host/MassStorageClassHost.c
LUFA/Drivers/USB/Class/Host/MassStorageClassHost.h
LUFA/Drivers/USB/Class/Host/PrinterClassHost.c
LUFA/Drivers/USB/Class/Host/PrinterClassHost.h
LUFA/Drivers/USB/Class/Host/RNDISClassHost.c
LUFA/Drivers/USB/Class/Host/RNDISClassHost.h
LUFA/Drivers/USB/Class/Host/StillImageClassHost.c
LUFA/Drivers/USB/Class/Host/StillImageClassHost.h
LUFA/Drivers/USB/Core/AVR8/Endpoint_AVR8.c
LUFA/Drivers/USB/Core/AVR8/Endpoint_AVR8.h
LUFA/Drivers/USB/Core/AVR8/Host_AVR8.c
LUFA/Drivers/USB/Core/AVR8/Pipe_AVR8.c
LUFA/Drivers/USB/Core/AVR8/Pipe_AVR8.h
LUFA/Drivers/USB/Core/AVR8/USBController_AVR8.c
LUFA/Drivers/USB/Core/AVR8/USBInterrupt_AVR8.c
LUFA/Drivers/USB/Core/DeviceStandardReq.c
LUFA/Drivers/USB/Core/Endpoint.h
LUFA/Drivers/USB/Core/Pipe.h
LUFA/Drivers/USB/Core/StdDescriptors.h
LUFA/Drivers/USB/Core/UC3/Endpoint_UC3.c
LUFA/Drivers/USB/Core/UC3/Endpoint_UC3.h
LUFA/Drivers/USB/Core/UC3/Host_UC3.c
LUFA/Drivers/USB/Core/UC3/Pipe_UC3.c
LUFA/Drivers/USB/Core/UC3/Pipe_UC3.h
LUFA/Drivers/USB/Core/UC3/USBController_UC3.c
LUFA/Drivers/USB/Core/UC3/USBInterrupt_UC3.c
LUFA/Drivers/USB/Core/USBController.h
LUFA/Drivers/USB/Core/USBMode.h
LUFA/Drivers/USB/Core/XMEGA/Device_XMEGA.h
LUFA/Drivers/USB/Core/XMEGA/Endpoint_XMEGA.c
LUFA/Drivers/USB/Core/XMEGA/Endpoint_XMEGA.h
LUFA/Drivers/USB/Core/XMEGA/USBController_XMEGA.c
LUFA/Drivers/USB/Core/XMEGA/USBController_XMEGA.h
LUFA/Drivers/USB/Core/XMEGA/USBInterrupt_XMEGA.c
LUFA/Drivers/USB/USB.h
LUFA/Platform/XMEGA/ClockManagement.h
Maintenance/makefile
Projects/AVRISP-MKII/AVRISP-MKII.c
Projects/AVRISP-MKII/Descriptors.c
Projects/AVRISP-MKII/Descriptors.h
Projects/AVRISP-MKII/Lib/ISP/ISPProtocol.c
Projects/AVRISP-MKII/Lib/V2Protocol.c
Projects/AVRISP-MKII/Lib/V2ProtocolParams.c
Projects/AVRISP-MKII/Lib/XPROG/XMEGANVM.c
Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.c
Projects/AVRISP-MKII/Lib/XPROG/XPROGProtocol.h
Projects/AVRISP-MKII/Lib/XPROG/XPROGTarget.c
Projects/Benito/Benito.c
Projects/Benito/Descriptors.c
Projects/Benito/Descriptors.h
Projects/HIDReportViewer/HIDReportViewer.c
Projects/Incomplete/StandaloneProgrammer/Descriptors.c
Projects/Incomplete/StandaloneProgrammer/Descriptors.h
Projects/Incomplete/StandaloneProgrammer/DiskDevice.c
Projects/Incomplete/StandaloneProgrammer/DiskHost.c
Projects/Incomplete/StandaloneProgrammer/Lib/PetiteFATFs/diskio.c
Projects/LEDNotifier/Descriptors.c
Projects/LEDNotifier/Descriptors.h
Projects/LEDNotifier/LEDNotifier.c
Projects/MIDIToneGenerator/Descriptors.c
Projects/MIDIToneGenerator/Descriptors.h
Projects/MIDIToneGenerator/MIDIToneGenerator.c
Projects/Magstripe/Descriptors.c
Projects/Magstripe/Descriptors.h
Projects/Magstripe/Magstripe.c
Projects/MediaController/Descriptors.c
Projects/MediaController/Descriptors.h
Projects/MediaController/MediaController.c
Projects/MissileLauncher/ConfigDescriptor.c
Projects/MissileLauncher/ConfigDescriptor.h
Projects/RelayBoard/Doxygen.conf
Projects/SerialToLCD/Descriptors.c [new file with mode: 0644]
Projects/SerialToLCD/Descriptors.h [new file with mode: 0644]
Projects/SerialToLCD/Doxygen.conf [new file with mode: 0644]
Projects/SerialToLCD/Lib/HD44780.c [new file with mode: 0644]
Projects/SerialToLCD/Lib/HD44780.h [new file with mode: 0644]
Projects/SerialToLCD/SerialToLCD.c [new file with mode: 0644]
Projects/SerialToLCD/SerialToLCD.h [new file with mode: 0644]
Projects/SerialToLCD/SerialToLCD.txt [new file with mode: 0644]
Projects/SerialToLCD/makefile [new file with mode: 0644]
Projects/TempDataLogger/Descriptors.c
Projects/TempDataLogger/Descriptors.h
Projects/TempDataLogger/TempDataLogger.c
Projects/USBtoSerial/Descriptors.c
Projects/USBtoSerial/Descriptors.h
Projects/USBtoSerial/USBtoSerial.c
Projects/Webserver/Descriptors.c
Projects/Webserver/Descriptors.h
Projects/Webserver/USBDeviceMode.c
Projects/Webserver/USBHostMode.c
Projects/XPLAINBridge/AVRISPDescriptors.c
Projects/XPLAINBridge/AVRISPDescriptors.h
Projects/XPLAINBridge/Doxygen.conf
Projects/XPLAINBridge/USARTDescriptors.c
Projects/XPLAINBridge/USARTDescriptors.h
Projects/XPLAINBridge/XPLAINBridge.c
Projects/XPLAINBridge/XPLAINBridge.h
Projects/XPLAINBridge/XPLAINBridge.txt
Projects/makefile

index e9ea8ae..211b054 100644 (file)
@@ -56,6 +56,28 @@ static uint32_t CurrAddress;
  */
 static bool RunBootloader = true;
 
+/** Magic lock for forced application start. If the HWBE fuse is programmed and BOOTRST is unprogrammed, the bootloader
+ *  will start if the /HWB line of the AVR is held low and the system is reset. However, if the /HWB line is still held
+ *  low when the application attempts to start via a watchdog reset, the bootloader will re-start. If set to the value
+ *  \ref MAGIC_BOOT_KEY the special init function \ref Application_Jump_Check() will force the application to start.
+ */
+uint32_t MagicBootKey ATTR_NO_INIT;
+
+
+/** Special startup routine to check if the bootloader was started via a watchdog reset, and if the magic application
+ *  start key has been loaded into \ref MagicBootKey. If the bootloader started via the watchdog and the key is valid,
+ *  this will force the user application to start via a software jump.
+ */
+void Application_Jump_Check(void)
+{
+       /* If the reset source was the bootloader and the key is correct, clear it and jump to the application */
+       if ((MCUSR & (1 << WDRF)) && (MagicBootKey == MAGIC_BOOT_KEY))
+       {
+               MagicBootKey = 0;
+               // cppcheck-suppress constStatement
+               ((void (*)(void))0x0000)();
+       }
+}
 
 /** Main program entry point. This routine configures the hardware required by the bootloader, then continuously
  *  runs the bootloader processing routine until instructed to soft-exit, or hard-reset via the watchdog to start
@@ -80,6 +102,9 @@ int main(void)
 
        /* Disconnect from the host - USB interface will be reset later along with the AVR */
        USB_Detach();
+       
+       /* Unlock the forced application start mode of the bootloader if it is restarted */
+       MagicBootKey = MAGIC_BOOT_KEY;
 
        /* Enable the watchdog and force a timeout to reset the AVR */
        wdt_enable(WDTO_250MS);
@@ -122,17 +147,12 @@ ISR(TIMER1_OVF_vect, ISR_BLOCK)
 void EVENT_USB_Device_ConfigurationChanged(void)
 {
        /* Setup CDC Notification, Rx and Tx Endpoints */
-       Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT,
-                                  ENDPOINT_DIR_IN, CDC_NOTIFICATION_EPSIZE,
-                                  ENDPOINT_BANK_SINGLE);
+       Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT,
+                                  CDC_NOTIFICATION_EPSIZE, 1);
 
-       Endpoint_ConfigureEndpoint(CDC_TX_EPNUM, EP_TYPE_BULK,
-                                  ENDPOINT_DIR_IN, CDC_TXRX_EPSIZE,
-                                  ENDPOINT_BANK_SINGLE);
+       Endpoint_ConfigureEndpoint(CDC_TX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
 
-       Endpoint_ConfigureEndpoint(CDC_RX_EPNUM, EP_TYPE_BULK,
-                                  ENDPOINT_DIR_OUT, CDC_TXRX_EPSIZE,
-                                  ENDPOINT_BANK_SINGLE);
+       Endpoint_ConfigureEndpoint(CDC_RX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
 }
 
 /** Event handler for the USB_ControlRequest event. This is used to catch and process control requests sent to
@@ -303,7 +323,7 @@ static void ReadWriteMemoryBlock(const uint8_t Command)
 static uint8_t FetchNextCommandByte(void)
 {
        /* Select the OUT endpoint so that the next data byte can be read */
-       Endpoint_SelectEndpoint(CDC_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_RX_EPADDR);
 
        /* If OUT endpoint empty, clear it and wait for the next packet from the host */
        while (!(Endpoint_IsReadWriteAllowed()))
@@ -329,7 +349,7 @@ static uint8_t FetchNextCommandByte(void)
 static void WriteNextResponseByte(const uint8_t Response)
 {
        /* Select the IN endpoint so that the next data byte can be written */
-       Endpoint_SelectEndpoint(CDC_TX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_TX_EPADDR);
 
        /* If IN endpoint full, clear it and wait until ready for the next packet to the host */
        if (!(Endpoint_IsReadWriteAllowed()))
@@ -353,7 +373,7 @@ static void WriteNextResponseByte(const uint8_t Response)
 static void CDC_Task(void)
 {
        /* Select the OUT endpoint */
-       Endpoint_SelectEndpoint(CDC_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_RX_EPADDR);
 
        /* Check if endpoint has a command in it sent from the host */
        if (!(Endpoint_IsOUTReceived()))
@@ -549,7 +569,7 @@ static void CDC_Task(void)
        }
 
        /* Select the IN endpoint */
-       Endpoint_SelectEndpoint(CDC_TX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_TX_EPADDR);
 
        /* Remember if the endpoint is completely full before clearing it */
        bool IsEndpointFull = !(Endpoint_IsReadWriteAllowed());
@@ -577,7 +597,7 @@ static void CDC_Task(void)
        }
 
        /* Select the OUT endpoint */
-       Endpoint_SelectEndpoint(CDC_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_RX_EPADDR);
 
        /* Acknowledge the command from the host */
        Endpoint_ClearOUT();
index 4b9e7d6..257e884 100644 (file)
@@ -67,6 +67,9 @@
                /** Eight character bootloader firmware identifier reported to the host when requested */
                #define SOFTWARE_IDENTIFIER          "LUFACDC"
 
+               /** Magic bootloader key to unlock forced application start mode. */
+               #define MAGIC_BOOT_KEY            0xDC42CACA
+               
        /* Type Defines: */
                /** Type define for a non-returning pointer to the start of the loaded application in flash memory. */
                typedef void (*AppPtr_t)(void) ATTR_NO_RETURN;
@@ -75,6 +78,8 @@
                static void CDC_Task(void);
                static void SetupHardware(void);
 
+               void Application_Jump_Check(void) ATTR_INIT_SECTION(3);
+
                void EVENT_USB_Device_ConfigurationChanged(void);
 
                #if defined(INCLUDE_FROM_BOOTLOADERCDC_C) || defined(__DOXYGEN__)
index d6ab945..618b95d 100644 (file)
@@ -47,9 +47,9 @@
  *  This bootloader enumerates to the host as a CDC Class device (virtual serial port), allowing for AVR109
  *  protocol compatible programming software to load firmware onto the AVR.
  *
- *  Out of the box this bootloader builds for the USB1287, and will fit into 4KB of bootloader space. If
- *  you wish to enlarge this space and/or change the AVR model, you will need to edit the BOOT_START and MCU
- *  values in the accompanying makefile.
+ *  Out of the box this bootloader builds for the AT90USB1287 with an 8KB bootloader section size, and will fit
+ *  into 4KB of bootloader space. If you wish to alter this size and/or change the AVR model, you will need to
+ *  edit the MCU, FLASH_SIZE_KB and BOOT_SECTION_SIZE_KB values in the accompanying makefile.
  *
  *  When the bootloader is running, the board's LED(s) will flash at regular intervals to distinguish the
  *  bootloader from the normal user application.
diff --git a/Bootloaders/CDC/Config/AppConfig.h b/Bootloaders/CDC/Config/AppConfig.h
new file mode 100644 (file)
index 0000000..ae3e50e
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Library Configuration Header File
+ *
+ *  This is a header file which is be used to configure LUFA's
+ *  compile time options, as an alternative to the compile time
+ *  constants supplied through a makefile.
+ *
+ *  For information on what each token does, refer to the LUFA
+ *  manual section "Summary of Compile Tokens".
+ */
+
+#ifndef _APP_CONFIG_H_
+#define _APP_CONFIG_H_
+
+       #define NO_BLOCK_SUPPORT
+       #define NO_EEPROM_BYTE_SUPPORT
+       #define NO_FLASH_BYTE_SUPPORT
+       #define NO_LOCK_BYTE_WRITE_SUPPORT
+
+#endif
\ No newline at end of file
diff --git a/Bootloaders/CDC/Config/LUFAConfig.h b/Bootloaders/CDC/Config/LUFAConfig.h
new file mode 100644 (file)
index 0000000..c5a01c2
--- /dev/null
@@ -0,0 +1,93 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Library Configuration Header File
+ *
+ *  This is a header file which is be used to configure LUFA's
+ *  compile time options, as an alternative to the compile time
+ *  constants supplied through a makefile.
+ *
+ *  For information on what each token does, refer to the LUFA
+ *  manual section "Summary of Compile Tokens".
+ */
+
+#ifndef _LUFA_CONFIG_H_
+#define _LUFA_CONFIG_H_
+
+       #if (ARCH == ARCH_AVR8)
+
+               /* Non-USB Related Configuration Tokens: */
+//             #define DISABLE_TERMINAL_CODES
+
+               /* USB Class Driver Related Tokens: */
+//             #define HID_HOST_BOOT_PROTOCOL_ONLY
+//             #define HID_STATETABLE_STACK_DEPTH       {Insert Value Here}
+//             #define HID_USAGE_STACK_DEPTH            {Insert Value Here}
+//             #define HID_MAX_COLLECTIONS              {Insert Value Here}
+//             #define HID_MAX_REPORTITEMS              {Insert Value Here}
+//             #define HID_MAX_REPORT_IDS               {Insert Value Here}
+//             #define NO_CLASS_DRIVER_AUTOFLUSH
+
+               /* General USB Driver Related Tokens: */
+               #define ORDERED_EP_CONFIG
+               #define USE_STATIC_OPTIONS               (USB_DEVICE_OPT_FULLSPEED | USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)
+               #define USB_DEVICE_ONLY
+//             #define USB_HOST_ONLY
+//             #define USB_STREAM_TIMEOUT_MS            {Insert Value Here}
+//             #define NO_LIMITED_CONTROLLER_CONNECT
+               #define NO_SOF_EVENTS
+
+               /* USB Device Mode Driver Related Tokens: */
+               #define USE_RAM_DESCRIPTORS
+//             #define USE_FLASH_DESCRIPTORS
+//             #define USE_EEPROM_DESCRIPTORS
+               #define NO_INTERNAL_SERIAL
+               #define FIXED_CONTROL_ENDPOINT_SIZE      8
+               #define DEVICE_STATE_AS_GPIOR            0
+               #define FIXED_NUM_CONFIGURATIONS         1
+//             #define CONTROL_ONLY_DEVICE
+//             #define INTERRUPT_CONTROL_ENDPOINT
+               #define NO_DEVICE_REMOTE_WAKEUP
+               #define NO_DEVICE_SELF_POWER
+
+               /* USB Host Mode Driver Related Tokens: */
+//             #define HOST_STATE_AS_GPIOR              {Insert Value Here}
+//             #define USB_HOST_TIMEOUT_MS              {Insert Value Here}
+//             #define HOST_DEVICE_SETTLE_DELAY_MS          {Insert Value Here}
+//      #define NO_AUTO_VBUS_MANAGEMENT
+//      #define INVERTED_VBUS_ENABLE_LINE
+
+       #else
+
+               #error Unsupported architecture for this LUFA configuration file.
+
+       #endif
+#endif
index 4bf3ece..9c892f8 100644 (file)
@@ -131,7 +131,7 @@ const USB_Descriptor_Configuration_t ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -157,20 +157,20 @@ const USB_Descriptor_Configuration_t ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index e5ef641..0010fc6 100644 (file)
                        #error The selected AVR part is not currently supported by this bootloader.
                #endif
 
-               /** Endpoint number for the CDC control interface event notification endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address for the CDC control interface event notification endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN | 2)
 
-               /** Endpoint number for the CDC data interface TX (data IN) endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address for the CDC data interface TX (data IN) endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN | 3)
 
-               /** Endpoint number for the CDC data interface RX (data OUT) endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address for the CDC data interface RX (data OUT) endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size of the CDC data interface TX and RX data endpoint banks, in bytes. */
                #define CDC_TXRX_EPSIZE                16
index 066fb88..b449ff0 100644 (file)
@@ -95,7 +95,7 @@ F_USB = $(F_CPU)
 # Note that the bootloader size and start address given in AVRStudio is in words and not
 # bytes, and so will need to be doubled to obtain the byte address needed by AVR-GCC.
 FLASH_SIZE_KB        = 128
-BOOT_SECTION_SIZE_KB = 4
+BOOT_SECTION_SIZE_KB = 8
 
 
 # Formulas used to calculate the starting address of the Bootloader section, and the User Application
@@ -124,22 +124,7 @@ LUFA_PATH = ../..
 
 
 # LUFA library compile-time options and predefined tokens
-LUFA_OPTS  = -D USB_DEVICE_ONLY
-LUFA_OPTS += -D DEVICE_STATE_AS_GPIOR=0
-LUFA_OPTS += -D ORDERED_EP_CONFIG
-LUFA_OPTS += -D FIXED_CONTROL_ENDPOINT_SIZE=8
-LUFA_OPTS += -D FIXED_NUM_CONFIGURATIONS=1
-LUFA_OPTS += -D USE_RAM_DESCRIPTORS
-LUFA_OPTS += -D USE_STATIC_OPTIONS="(USB_DEVICE_OPT_FULLSPEED | USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"
-LUFA_OPTS += -D NO_INTERNAL_SERIAL
-LUFA_OPTS += -D NO_DEVICE_SELF_POWER
-LUFA_OPTS += -D NO_DEVICE_REMOTE_WAKEUP
-LUFA_OPTS += -D NO_SOF_EVENTS
-
-#LUFA_OPTS += -D NO_BLOCK_SUPPORT
-#LUFA_OPTS += -D NO_EEPROM_BYTE_SUPPORT
-#LUFA_OPTS += -D NO_FLASH_BYTE_SUPPORT
-#LUFA_OPTS += -D NO_LOCK_BYTE_WRITE_SUPPORT
+LUFA_OPTS  = -D USE_LUFA_CONFIG_HEADER
 
 
 # Create the LUFA source path variables by including the LUFA root makefile
@@ -184,7 +169,7 @@ DEBUG = dwarf-2
 #     Each directory must be seperated by a space.
 #     Use forward slashes for directory separators.
 #     For a directory that has spaces, enclose it in quotes.
-EXTRAINCDIRS = $(LUFA_PATH)/
+EXTRAINCDIRS = $(LUFA_PATH)/ Config/
 
 
 # Compiler flag to set the C Standard level.
index 3ce2a62..233e145 100644 (file)
@@ -92,6 +92,27 @@ static uint16_t StartAddr = 0x0000;
  */
 static uint16_t EndAddr = 0x0000;
 
+/** Magic lock for forced application start. If the HWBE fuse is programmed and BOOTRST is unprogrammed, the bootloader
+ *  will start if the /HWB line of the AVR is held low and the system is reset. However, if the /HWB line is still held
+ *  low when the application attempts to start via a watchdog reset, the bootloader will re-start. If set to the value
+ *  \ref MAGIC_BOOT_KEY the special init function \ref Application_Jump_Check() will force the application to start.
+ */
+uint32_t MagicBootKey ATTR_NO_INIT;
+
+
+/** Special startup routine to check if the bootloader was started via a watchdog reset, and if the magic application
+ *  start key has been loaded into \ref MagicBootKey. If the bootloader started via the watchdog and the key is valid,
+ *  this will force the user application to start via a software jump.
+ */
+void Application_Jump_Check(void)
+{
+       // If the reset source was the bootloader and the key is correct, clear it and jump to the application
+       if ((MCUSR & (1 << WDRF)) && (MagicBootKey == MAGIC_BOOT_KEY))
+       {
+               MagicBootKey = 0;
+               AppStartPtr();
+       }
+}
 
 /** Main program entry point. This routine configures the hardware required by the bootloader, then continuously
  *  runs the bootloader processing routine until instructed to soft-exit, or hard-reset via the watchdog to start
@@ -695,6 +716,9 @@ static void ProcessWriteCommand(void)
                {
                        if (SentCommand.Data[1] == 0x00)                                   // Start via watchdog
                        {
+                               /* Unlock the forced application start mode of the bootloader if it is restarted */
+                               MagicBootKey = MAGIC_BOOT_KEY;
+
                                /* Start the watchdog to reset the AVR once the communications are finalized */
                                wdt_enable(WDTO_250MS);
                        }
index a807753..46b70c0 100644 (file)
@@ -66,6 +66,9 @@
 
                /** Minor bootloader version number. */
                #define BOOTLOADER_VERSION_REV   0
+               
+               /** Magic bootloader key to unlock forced application start mode. */
+               #define MAGIC_BOOT_KEY            0xDC42CACA
 
                /** Complete bootloader version number expressed as a packed byte, constructed from the
                 *  two individual bootloader version macros.
                        static void ProcessWriteCommand(void);
                        static void ProcessReadCommand(void);
                #endif
+               
+               void Application_Jump_Check(void) ATTR_INIT_SECTION(3);
 
 #endif
 
index d0811b2..2c9eaf1 100644 (file)
@@ -47,9 +47,9 @@
  *  This bootloader enumerates to the host as a DFU Class device, allowing for DFU-compatible programming
  *  software to load firmware onto the AVR.
  *
- *  Out of the box this bootloader builds for the USB1287, and should fit into 4KB of bootloader space. If
- *  you wish to enlarge this space and/or change the AVR model, you will need to edit the BOOT_START and MCU
- *  values in the accompanying makefile.
+ *  Out of the box this bootloader builds for the AT90USB1287 with an 8KB bootloader section size, and will fit
+ *  into 4KB of bootloader space. If you wish to alter this size and/or change the AVR model, you will need to
+ *  edit the MCU, FLASH_SIZE_KB and BOOT_SECTION_SIZE_KB values in the accompanying makefile.
  *
  *  When the bootloader is running, the board's LED(s) will flash at regular intervals to distinguish the
  *  bootloader from the normal user application.
index d551590..ff33b6b 100644 (file)
@@ -111,7 +111,7 @@ const USB_Descriptor_Configuration_t ConfigurationDescriptor =
                        .DetachTimeout          = 0x0000,
                        .TransferSize           = 0x0C00,
 
-                       .DFUSpecification       = VERSION_BCD(01.01)
+                       .DFUSpecification       = VERSION_BCD(01.10)
                }
 };
 
index 608564e..f78ceb2 100644 (file)
@@ -95,7 +95,7 @@ F_USB = $(F_CPU)
 # Note that the bootloader size and start address given in AVRStudio is in words and not
 # bytes, and so will need to be doubled to obtain the byte address needed by AVR-GCC.
 FLASH_SIZE_KB        = 128
-BOOT_SECTION_SIZE_KB = 4
+BOOT_SECTION_SIZE_KB = 8
 
 
 # Formulas used to calculate the starting address of the Bootloader section, and the User Application
index 928000f..acc351a 100644 (file)
  */
 static bool RunBootloader = true;
 
+/** Magic lock for forced application start. If the HWBE fuse is programmed and BOOTRST is unprogrammed, the bootloader
+ *  will start if the /HWB line of the AVR is held low and the system is reset. However, if the /HWB line is still held
+ *  low when the application attempts to start via a watchdog reset, the bootloader will re-start. If set to the value
+ *  \ref MAGIC_BOOT_KEY the special init function \ref Application_Jump_Check() will force the application to start.
+ */
+uint32_t MagicBootKey ATTR_NO_INIT;
+
+
+/** Special startup routine to check if the bootloader was started via a watchdog reset, and if the magic application
+ *  start key has been loaded into \ref MagicBootKey. If the bootloader started via the watchdog and the key is valid,
+ *  this will force the user application to start via a software jump.
+ */
+void Application_Jump_Check(void)
+{
+       /* If the reset source was the bootloader and the key is correct, clear it and jump to the application */
+       if ((MCUSR & (1 << WDRF)) && (MagicBootKey == MAGIC_BOOT_KEY))
+       {
+               MagicBootKey = 0;
+               // cppcheck-suppress constStatement
+               ((void (*)(void))0x0000)();
+       }
+}
+
 /** Main program entry point. This routine configures the hardware required by the bootloader, then continuously
  *  runs the bootloader processing routine until instructed to soft-exit.
  */
@@ -58,6 +81,9 @@ int main(void)
        /* Disconnect from the host - USB interface will be reset later along with the AVR */
        USB_Detach();
 
+       /* Unlock the forced application start mode of the bootloader if it is restarted */
+       MagicBootKey = MAGIC_BOOT_KEY;
+
        /* Enable the watchdog and force a timeout to reset the AVR */
        wdt_enable(WDTO_250MS);
 
@@ -85,9 +111,7 @@ static void SetupHardware(void)
 void EVENT_USB_Device_ConfigurationChanged(void)
 {
        /* Setup HID Report Endpoint */
-       Endpoint_ConfigureEndpoint(HID_IN_EPNUM, EP_TYPE_INTERRUPT,
-                                      ENDPOINT_DIR_IN, HID_IN_EPSIZE,
-                                  ENDPOINT_BANK_SINGLE);
+       Endpoint_ConfigureEndpoint(HID_IN_EPADDR, EP_TYPE_INTERRUPT, HID_IN_EPSIZE, 1);
 }
 
 /** Event handler for the USB_ControlRequest event. This is used to catch and process control requests sent to
index ab5752d..af2812a 100644 (file)
                /** Bootloader special address to start the user application */
                #define COMMAND_STARTAPPLICATION   0xFFFF
 
+               /** Magic bootloader key to unlock forced application start mode. */
+               #define MAGIC_BOOT_KEY            0xDC42CACA
+               
        /* Function Prototypes: */
                static void SetupHardware(void);
 
+               void Application_Jump_Check(void) ATTR_INIT_SECTION(3);
+               
                void EVENT_USB_Device_ConfigurationChanged(void);
                void EVENT_USB_Device_UnhandledControlRequest(void);
 
index a774ab4..f6c084d 100644 (file)
  *  from PJRC (used with permission). This bootloader is deliberatley non-compatible with the properietary PJRC
  *  HalfKay bootloader GUI; only the command line interface software accompanying this bootloader will work with it.
  *  
- *  Out of the box this bootloader builds for the USB1287, and will fit into 2KB of bootloader space for the
- *  Series 2 USB AVRs (ATMEGAxxU2, AT90USBxx2) or 4KB of bootloader space for all other models. If you wish to
- *  enlarge this space and/or change the AVR model, you will need to edit the BOOT_START and MCU values in the
- *  accompanying makefile.
+ *  Out of the box this bootloader builds for the AT90USB1287 with an 8KB bootloader section size, and will fit
+ *  into 2KB of bootloader space for the Series 2 USB AVRs (ATMEGAxxU2, AT90USBxx2) or 4KB of bootloader space for
+ *  all other models. If you wish to alter this size and/or change the AVR model, you will need to edit the MCU,
+ *  FLASH_SIZE_KB and BOOT_SECTION_SIZE_KB values in the accompanying makefile.
  *
  *  \section Sec_Installation Driver Installation
  *
index 5d4271e..c1ea8e3 100644 (file)
@@ -137,10 +137,10 @@ const USB_Descriptor_Configuration_t ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | HID_IN_EPNUM),
+                       .EndpointAddress        = HID_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_IN_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index 41c4ee4..ad21603 100644 (file)
@@ -55,8 +55,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the HID data IN endpoint. */
-               #define HID_IN_EPNUM                 1
+               /** Endpoint address of the HID data IN endpoint. */
+               #define HID_IN_EPADDR                (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the HID reporting IN endpoint. */
                #define HID_IN_EPSIZE                64
index 6063e19..c86b0da 100644 (file)
@@ -970,13 +970,9 @@ void parse_options(int argc, char **argv)
                        } else if (strncmp(arg, "-mmcu=", 6) == 0) {
                                arg += 6;
 
-                               uint8_t valid_prefix = 0;
-
                                if (strncmp(arg, "at90usb", 7) == 0) {
-                                       valid_prefix = 1;
                                        arg += 7;
                                } else if (strncmp(arg, "atmega", 6) == 0) {
-                                       valid_prefix = 1;
                                        arg += 6;
                                } else {
                                        die("Unknown MCU type\n");
index efbb6a6..bfefbf6 100644 (file)
@@ -95,7 +95,7 @@ F_USB = $(F_CPU)
 # Note that the bootloader size and start address given in AVRStudio is in words and not
 # bytes, and so will need to be doubled to obtain the byte address needed by AVR-GCC.
 FLASH_SIZE_KB        = 128
-BOOT_SECTION_SIZE_KB = 4
+BOOT_SECTION_SIZE_KB = 8
 
 
 # Formulas used to calculate the starting address of the Bootloader section. These formulas
diff --git a/BuildTests/BoardDriverTest/Board/Buttons.h b/BuildTests/BoardDriverTest/Board/Buttons.h
new file mode 100644 (file)
index 0000000..8754721
--- /dev/null
@@ -0,0 +1,90 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Custom Board Button Hardware Driver (Template)
+ *
+ *  This is a stub driver header file, for implementing custom board
+ *  layout hardware with compatible LUFA board specific drivers. If
+ *  the library is configured to use the BOARD_USER board mode, this
+ *  driver file should be completed and copied into the "/Board/" folder
+ *  inside the application's folder.
+ *
+ *  This stub is for the board-specific component of the LUFA Buttons driver,
+ *  for the control of physical board-mounted GPIO pushbuttons.
+ */
+
+#ifndef __BUTTONS_USER_H__
+#define __BUTTONS_USER_H__
+
+       /* Includes: */
+               // TODO: Add any required includes here
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_BUTTONS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/Buttons.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** Button mask for the first button on the board. */
+                       #define BUTTONS_BUTTON1          (1 << 0)
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void Buttons_Init(void)
+                       {
+
+                       }
+
+                       static inline void Buttons_Disable(void)
+                       {
+
+                       }
+
+                       static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Buttons_GetStatus(void)
+                       {
+                               return 0;
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
diff --git a/BuildTests/BoardDriverTest/Board/Dataflash.h b/BuildTests/BoardDriverTest/Board/Dataflash.h
new file mode 100644 (file)
index 0000000..72561e5
--- /dev/null
@@ -0,0 +1,195 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Custom Board Dataflash Hardware Driver (Template)
+ *
+ *  This is a stub driver header file, for implementing custom board
+ *  layout hardware with compatible LUFA board specific drivers. If
+ *  the library is configured to use the BOARD_USER board mode, this
+ *  driver file should be completed and copied into the "/Board/" folder
+ *  inside the application's folder.
+ *
+ *  This stub is for the board-specific component of the LUFA Dataflash
+ *  driver.
+*/
+
+#ifndef __DATAFLASH_USER_H__
+#define __DATAFLASH_USER_H__
+
+       /* Includes: */
+               // TODO: Add any required includes here
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_DATAFLASH_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/Dataflash.h instead.
+               #endif
+
+       /* Private Interface - For use in library only: */
+       #if !defined(__DOXYGEN__)
+               /* Macros: */
+                       #define DATAFLASH_CHIPCS_MASK                // TODO: Replace this with a mask of all the /CS pins of all Dataflashes
+                       #define DATAFLASH_CHIPCS_DDR                 // TODO: Replace with the DDR register name for the board's Dataflash ICs
+                       #define DATAFLASH_CHIPCS_PORT                // TODO: Replace with the PORT register name for the board's Dataflash ICs
+       #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** Constant indicating the total number of dataflash ICs mounted on the selected board. */
+                       #define DATAFLASH_TOTALCHIPS                 1 // TODO: Replace with the number of Dataflashes on the board, max 2
+
+                       /** Mask for no dataflash chip selected. */
+                       #define DATAFLASH_NO_CHIP                    DATAFLASH_CHIPCS_MASK
+
+                       /** Mask for the first dataflash chip selected. */
+                       #define DATAFLASH_CHIP1                      // TODO: Replace with mask to hold /CS of first Dataflash low, and all others high
+
+                       /** Mask for the second dataflash chip selected. */
+                       #define DATAFLASH_CHIP2                      // TODO: Replace with mask to hold /CS of second Dataflash low, and all others high
+
+                       /** Internal main memory page size for the board's dataflash ICs. */
+                       #define DATAFLASH_PAGE_SIZE                  // TODO: Replace with the page size for the Dataflash ICs
+
+                       /** Total number of pages inside each of the board's dataflash ICs. */
+                       #define DATAFLASH_PAGES                      // TODO: Replace with the total number of pages inside one of the Dataflash ICs
+
+               /* Inline Functions: */
+                       /** Initializes the dataflash driver so that commands and data may be sent to an attached dataflash IC.
+                        *  The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
+                        */
+                       static inline void Dataflash_Init(void)
+                       {
+
+                       }
+
+                       /** Sends a byte to the currently selected dataflash IC, and returns a byte from the dataflash.
+                        *
+                        *  \param[in] Byte  Byte of data to send to the dataflash
+                        *
+                        *  \return Last response byte from the dataflash
+                        */
+                       static inline uint8_t Dataflash_TransferByte(const uint8_t Byte) ATTR_ALWAYS_INLINE;
+                       static inline uint8_t Dataflash_TransferByte(const uint8_t Byte)
+                       {
+                               return 0;
+                       }
+
+                       /** Sends a byte to the currently selected dataflash IC, and ignores the next byte from the dataflash.
+                        *
+                        *  \param[in] Byte  Byte of data to send to the dataflash
+                        */
+                       static inline void Dataflash_SendByte(const uint8_t Byte) ATTR_ALWAYS_INLINE;
+                       static inline void Dataflash_SendByte(const uint8_t Byte)
+                       {
+
+                       }
+
+                       /** Sends a dummy byte to the currently selected dataflash IC, and returns the next byte from the dataflash.
+                        *
+                        *  \return Last response byte from the dataflash
+                        */
+                       static inline uint8_t Dataflash_ReceiveByte(void) ATTR_ALWAYS_INLINE ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Dataflash_ReceiveByte(void)
+                       {
+                               return 0;
+                       }
+
+                       /** Determines the currently selected dataflash chip.
+                        *
+                        *  \return Mask of the currently selected Dataflash chip, either \ref DATAFLASH_NO_CHIP if no chip is selected
+                        *          or a DATAFLASH_CHIPn mask (where n is the chip number).
+                        */
+                       static inline uint8_t Dataflash_GetSelectedChip(void) ATTR_ALWAYS_INLINE ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Dataflash_GetSelectedChip(void)
+                       {
+                               return 0;
+                       }
+
+                       /** Selects the given dataflash chip.
+                        *
+                        *  \param[in]  ChipMask  Mask of the Dataflash IC to select, in the form of DATAFLASH_CHIPn mask (where n is
+                        *              the chip number).
+                        */
+                       static inline void Dataflash_SelectChip(const uint8_t ChipMask) ATTR_ALWAYS_INLINE;
+                       static inline void Dataflash_SelectChip(const uint8_t ChipMask)
+                       {
+                               
+                       }
+
+                       /** Deselects the current dataflash chip, so that no dataflash is selected. */
+                       static inline void Dataflash_DeselectChip(void) ATTR_ALWAYS_INLINE;
+                       static inline void Dataflash_DeselectChip(void)
+                       {
+                               
+                       }
+
+                       /** Selects a dataflash IC from the given page number, which should range from 0 to
+                        *  ((DATAFLASH_PAGES * DATAFLASH_TOTALCHIPS) - 1). For boards containing only one
+                        *  dataflash IC, this will select DATAFLASH_CHIP1. If the given page number is outside
+                        *  the total number of pages contained in the boards dataflash ICs, all dataflash ICs
+                        *  are deselected.
+                        *
+                        *  \param[in] PageAddress  Address of the page to manipulate, ranging from
+                        *                          0 to ((DATAFLASH_PAGES * DATAFLASH_TOTALCHIPS) - 1).
+                        */
+                       static inline void Dataflash_SelectChipFromPage(const uint16_t PageAddress)
+                       {
+                               
+                       }
+
+                       /** Toggles the select line of the currently selected dataflash IC, so that it is ready to receive
+                        *  a new command.
+                        */
+                       static inline void Dataflash_ToggleSelectedChipCS(void)
+                       {
+                               
+                       }
+
+                       /** Spin-loops while the currently selected dataflash is busy executing a command, such as a main
+                        *  memory page program or main memory to buffer transfer.
+                        */
+                       static inline void Dataflash_WaitWhileBusy(void)
+                       {
+                               
+                       }
+
+                       /** Sends a set of page and buffer address bytes to the currently selected dataflash IC, for use with
+                        *  dataflash commands which require a complete 24-bit address.
+                        *
+                        *  \param[in] PageAddress  Page address within the selected dataflash IC
+                        *  \param[in] BufferByte   Address within the dataflash's buffer
+                        */
+                       static inline void Dataflash_SendAddressBytes(uint16_t PageAddress, const uint16_t BufferByte)
+                       {
+                               
+                       }
+
+#endif
+
diff --git a/BuildTests/BoardDriverTest/Board/Joystick.h b/BuildTests/BoardDriverTest/Board/Joystick.h
new file mode 100644 (file)
index 0000000..f432838
--- /dev/null
@@ -0,0 +1,102 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Custom Board Joystick Hardware Driver (Template)
+ *
+ *  This is a stub driver header file, for implementing custom board
+ *  layout hardware with compatible LUFA board specific drivers. If
+ *  the library is configured to use the BOARD_USER board mode, this
+ *  driver file should be completed and copied into the "/Board/" folder
+ *  inside the application's folder.
+ *
+ *  This stub is for the board-specific component of the LUFA Joystick
+ *  driver, for a digital four-way (plus button) joystick.
+*/
+
+#ifndef __JOYSTICK_USER_H__
+#define __JOYSTICK_USER_H__
+
+       /* Includes: */
+               // TODO: Add any required includes here
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_JOYSTICK_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/Joystick.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** Mask for the joystick being pushed in the left direction. */
+                       #define JOY_LEFT                  // TODO: Add mask to indicate joystick left position here
+
+                       /** Mask for the joystick being pushed in the right direction. */
+                       #define JOY_RIGHT                 // TODO: Add mask to indicate joystick right position here
+
+                       /** Mask for the joystick being pushed in the upward direction. */
+                       #define JOY_UP                    // TODO: Add mask to indicate joystick up position here
+
+                       /** Mask for the joystick being pushed in the downward direction. */
+                       #define JOY_DOWN                  // TODO: Add mask to indicate joystick down position here
+
+                       /** Mask for the joystick being pushed inward. */
+                       #define JOY_PRESS                 // TODO: Add mask to indicate joystick pressed position here
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void Joystick_Init(void)
+                       {
+                               
+                       }
+
+                       static inline void Joystick_Disable(void)
+                       {
+                               
+                       }
+
+                       static inline uint8_t Joystick_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Joystick_GetStatus(void)
+                       {
+                               return 0;
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
diff --git a/BuildTests/BoardDriverTest/Board/LEDs.h b/BuildTests/BoardDriverTest/Board/LEDs.h
new file mode 100644 (file)
index 0000000..a0346b2
--- /dev/null
@@ -0,0 +1,130 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief LUFA Custom Board LED Hardware Driver (Template)
+ *
+ *  This is a stub driver header file, for implementing custom board
+ *  layout hardware with compatible LUFA board specific drivers. If
+ *  the library is configured to use the BOARD_USER board mode, this
+ *  driver file should be completed and copied into the "/Board/" folder
+ *  inside the application's folder.
+ *
+ *  This stub is for the board-specific component of the LUFA LEDs driver,
+ *  for the LEDs (up to four) mounted on most development boards.
+*/
+
+#ifndef __LEDS_USER_H__
+#define __LEDS_USER_H__
+
+       /* Includes: */
+               // TODO: Add any required includes here
+
+/* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_LEDS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/LEDS.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** LED mask for the first LED on the board. */
+                       #define LEDS_LED1        (1 << 0)
+                       
+                       /** LED mask for the second LED on the board. */
+                       #define LEDS_LED2        (1 << 1)
+
+                       /** LED mask for the third LED on the board. */
+                       #define LEDS_LED3        (1 << 2)
+                       
+                       /** LED mask for the fourth LED on the board. */
+                       #define LEDS_LED4        (1 << 3)
+
+                       /** LED mask for all the LEDs on the board. */
+                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2 | LEDS_LED3 | LEDS_LED4)
+
+                       /** LED mask for none of the board LEDs. */
+                       #define LEDS_NO_LEDS     0
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void LEDs_Init(void)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_Disable(void)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_TurnOffLEDs(const uint8_t LEDMask)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_SetAllLEDs(const uint8_t LEDMask)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_ChangeLEDs(const uint8_t LEDMask, const uint8_t ActiveMask)
+                       {
+                               
+                       }
+
+                       static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
+                       {
+                               
+                       }
+
+                       static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t LEDs_GetLEDs(void)
+                       {
+                               return 0;
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
diff --git a/BuildTests/BoardDriverTest/BoardDeviceMap.cfg b/BuildTests/BoardDriverTest/BoardDeviceMap.cfg
new file mode 100644 (file)
index 0000000..683b181
--- /dev/null
@@ -0,0 +1,51 @@
+# BOARD DEFINE = {ARCH} : {MCU} :\r
+BOARD_USER = avr8 : at90usb1287 :\r
+BOARD_NONE = avr8 : at90usb1287 :\r
+BOARD_USBKEY = avr8 : at90usb1287 :\r
+BOARD_STK525 = avr8 : at90usb647 :\r
+BOARD_STK526 = avr8 : at90usb162 :\r
+BOARD_RZUSBSTICK = avr8 : at90usb1287 :\r
+BOARD_ATAVRUSBRF01 = avr8 : at90usb1287 :\r
+BOARD_BUMBLEB = avr8 : at90usb162 :\r
+BOARD_XPLAIN = avr8 : at90usb1287 :\r
+BOARD_XPLAIN_REV1 = avr8 : at90usb1287 :\r
+BOARD_EVK527 = avr8 : atmega32u4 :\r
+BOARD_TEENSY = avr8 : at90usb162 :\r
+BOARD_USBTINYMKII = avr8 : at90usb162 :\r
+BOARD_BENITO = avr8 : at90usb162 :\r
+BOARD_JMDBU2 = avr8 : atmega32u2 :\r
+BOARD_OLIMEX162 = avr8 : at90usb162 :\r
+BOARD_UDIP = avr8 : atmega32u2 :\r
+BOARD_BUI = avr8 : at90usb646 :\r
+BOARD_UNO = avr8 : atmega8u2 :\r
+BOARD_CULV3 = avr8 : atmega32u4 :\r
+BOARD_BLACKCAT = avr8 : at90usb162 :\r
+BOARD_MAXIMUS = avr8 : at90usb162 :\r
+BOARD_MINIMUS = avr8 : atmega32u2 :\r
+BOARD_ADAFRUITU4 = avr8 : atmega32u4 :\r
+BOARD_MICROSIN162 = avr8 : atmega162 :\r
+BOARD_USBFOO = avr8 : atmega162 :\r
+BOARD_SPARKFUN8U2 = avr8 : atmega8u2 :\r
+BOARD_EVK1101 = uc3 : uc3b0256 :\r
+BOARD_TUL = avr8 : atmega32u4 :\r
+BOARD_EVK1100 = uc3 : uc3a0512 :\r
+BOARD_EVK1104 = uc3 : uc3a3256 :\r
+BOARD_A3BU_XPLAINED = xmega : atxmega256a3bu :\r
+BOARD_TEENSY2 = avr8 : at90usb646 :\r
+BOARD_USB2AX = avr8 : atmega32u4 :\r
+BOARD_USB2AX_V3 = avr8 : atmega32u4 :\r
+BOARD_MICROPENDOUS_32U2 = avr8 : atmega32u2 :\r
+BOARD_MICROPENDOUS_A = avr8 : at90usb1287 :\r
+BOARD_MICROPENDOUS_1 = avr8 : at90usb162 :\r
+BOARD_MICROPENDOUS_2 = avr8 : atmega32u4 :\r
+BOARD_MICROPENDOUS_3 = avr8 : at90usb1287 :\r
+BOARD_MICROPENDOUS_4 = avr8 : at90usb1287 :\r
+BOARD_MICROPENDOUS_DIP = avr8 : at90usb1287 :\r
+BOARD_MICROPENDOUS_REV1 = avr8 : at90usb1287 :\r
+BOARD_MICROPENDOUS_REV2 = avr8 : at90usb1287 :\r
+BOARD_B1_XPLAINED = xmega : atxmega128b1 :\r
+BOARD_MULTIO = avr8 : at90usb162 :\r
+BOARD_BIGMULTIO = avr8 : atmega32u4 :\r
+BOARD_DUCE = avr8 : atmega32u2 :\r
+BOARD_OLIMEX32U4 = avr8 : atmega32u4 :\r
+BOARD_OLIMEXT32U4 = avr8 : atmega32u4 :
\ No newline at end of file
diff --git a/BuildTests/BoardDriverTest/Test.c b/BuildTests/BoardDriverTest/Test.c
new file mode 100644 (file)
index 0000000..2d908cb
--- /dev/null
@@ -0,0 +1,77 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+#include <LUFA/Common/Common.h>
+#include <LUFA/Drivers/Board/Buttons.h>
+#include <LUFA/Drivers/Board/Dataflash.h>
+#include <LUFA/Drivers/Board/LEDs.h>
+#include <LUFA/Drivers/Board/Joystick.h>
+
+int main(void)
+{
+       uint_reg_t Dummy;
+       
+       /* Buttons Compile Check */
+       Buttons_Init();
+       Dummy = Buttons_GetStatus();
+       Buttons_Disable();
+       
+       /* Dataflash Compile Check */
+       Dataflash_Init();
+       Dataflash_TransferByte(0);
+       Dataflash_SendByte(0);
+       Dummy = Dataflash_ReceiveByte();
+       Dummy = Dataflash_GetSelectedChip();
+       Dataflash_SelectChip(0);
+       Dataflash_DeselectChip();
+       Dataflash_SelectChipFromPage(0);
+       Dataflash_ToggleSelectedChipCS();
+       Dataflash_WaitWhileBusy();
+       Dataflash_SendAddressBytes(0, 0);
+
+       /* LEDs Compile Check */
+       LEDs_Init();
+       LEDs_TurnOnLEDs(LEDS_ALL_LEDS);
+       LEDs_TurnOffLEDs(LEDS_ALL_LEDS);
+       LEDs_SetAllLEDs(LEDS_ALL_LEDS);
+       LEDs_ChangeLEDs(LEDS_ALL_LEDS, LEDS_NO_LEDS);
+       LEDs_ToggleLEDs(LEDS_ALL_LEDS);
+       Dummy = LEDs_GetLEDs();
+       LEDs_Disable();
+       
+       /* Joystick Compile Check */
+       Joystick_Init();
+       Dummy = Joystick_GetStatus();
+       Joystick_Disable();
+       
+       (void)Dummy;
+}
+
+
diff --git a/BuildTests/BoardDriverTest/makefile b/BuildTests/BoardDriverTest/makefile
new file mode 100644 (file)
index 0000000..598d953
--- /dev/null
@@ -0,0 +1,63 @@
+#\r
+#             LUFA Library\r
+#     Copyright (C) Dean Camera, 2011.\r
+#\r
+#  dean [at] fourwalledcubicle [dot] com\r
+#           www.lufa-lib.org\r
+#\r
+\r
+# Makefile for the board driver build test. This\r
+# test attempts to build a dummy project with all\r
+# possible board targets using their respective\r
+# compiler.\r
+\r
+# Path to the root of the LUFA tree to scan\r
+LUFA_ROOT_PATH    = ../..\r
+\r
+\r
+all: begin makeboardlist testboards clean end\r
+\r
+begin:\r
+       @echo Executing build test "BoardDriverTest".\r
+       @echo\r
+\r
+end:\r
+       @echo Build test "BoardDriverTest" complete.\r
+       @echo\r
+\r
+makeboardlist:\r
+       @grep "BOARD_" $(LUFA_ROOT_PATH)/LUFA/Common/BoardTypes.h | cut -d'#' -f2 | cut -d' ' -f2 | grep "BOARD_" > BoardList.txt\r
+       \r
+testboards:\r
+       echo "buildtest:" > BuildMakefile\r
+       \r
+       @while read line; \\r
+        do \\r
+          build_cfg=`grep "$$line " BoardDeviceMap.cfg | sed 's/ //g' | cut -d'=' -f2-`; \\r
+          \\r
+          build_board=$$line; \\r
+          build_arch=`echo $$build_cfg | cut -d':' -f1`; \\r
+          build_mcu=`echo $$build_cfg | cut -d':' -f2`; \\r
+          \\r
+          if ( test -z "$$build_cfg" ); then \\r
+            echo "No matching information set for board $$build_board"; \\r
+          else \\r
+            echo "Found board configuration for $$build_board - $$build_arch, $$build_mcu"; \\r
+                \\r
+                printf "\t@echo Building dummy project for $$build_board...\n" >> BuildMakefile; \\r
+                printf "\tmake -s -f makefile.%s clean\n" $$build_arch >> BuildMakefile; \\r
+                printf "\tmake -s -f makefile.%s MCU=%s BOARD=%s elf\n\n" $$build_arch $$build_mcu $$build_board >> BuildMakefile; \\r
+          fi; \\r
+        done < BoardList.txt\r
+        \r
+        $(MAKE) -f BuildMakefile buildtest\r
+\r
+clean:\r
+       rm -f BuildMakefile\r
+       rm -f BoardList.txt\r
+       $(MAKE) -f makefile.avr8 clean\r
+       $(MAKE) -f makefile.xmega clean\r
+       $(MAKE) -f makefile.uc3 clean\r
+\r
+%:\r
+       
\ No newline at end of file
diff --git a/BuildTests/BoardDriverTest/makefile.avr8 b/BuildTests/BoardDriverTest/makefile.avr8
new file mode 100644 (file)
index 0000000..1f0d759
--- /dev/null
@@ -0,0 +1,722 @@
+# Hey Emacs, this is a -*- makefile -*-\r
+#----------------------------------------------------------------------------\r
+# WinAVR Makefile Template written by Eric B. Weddington, Jörg Wunsch, et al.\r
+#  >> Modified for use with the LUFA project. <<\r
+#\r
+# Released to the Public Domain\r
+#\r
+# Additional material for this makefile was written by:\r
+# Peter Fleury\r
+# Tim Henigan\r
+# Colin O'Flynn\r
+# Reiner Patommel\r
+# Markus Pfaff\r
+# Sander Pool\r
+# Frederik Rouleau\r
+# Carlos Lamas\r
+# Dean Camera\r
+# Opendous Inc.\r
+# Denver Gingerich\r
+#\r
+#----------------------------------------------------------------------------\r
+# On command line:\r
+#\r
+# make all = Make software.\r
+#\r
+# make clean = Clean out built project files.\r
+#\r
+# make coff = Convert ELF to AVR COFF.\r
+#\r
+# make extcoff = Convert ELF to AVR Extended COFF.\r
+#\r
+# make program = Download the hex file to the device, using avrdude.\r
+#                Please customize the avrdude settings below first!\r
+#\r
+# make dfu = Download the hex file to the device, using dfu-programmer (must\r
+#            have dfu-programmer installed).\r
+#\r
+# make flip = Download the hex file to the device, using Atmel FLIP (must\r
+#             have Atmel FLIP installed).\r
+#\r
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer\r
+#               (must have dfu-programmer installed).\r
+#\r
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP\r
+#                (must have Atmel FLIP installed).\r
+#\r
+# make doxygen = Generate DoxyGen documentation for the project (must have\r
+#                DoxyGen installed)\r
+#\r
+# make debug = Start either simulavr or avarice as specified for debugging,\r
+#              with avr-gdb or avr-insight as the front end for debugging.\r
+#\r
+# make filename.s = Just compile filename.c into the assembler code only.\r
+#\r
+# make filename.i = Create a preprocessed source file for use in submitting\r
+#                   bug reports to the GCC project.\r
+#\r
+# To rebuild project do "make clean" then "make all".\r
+#----------------------------------------------------------------------------\r
+\r
+\r
+# MCU name\r
+MCU = at90usb1287\r
+\r
+\r
+# Target architecture (see library "Board Types" documentation).\r
+ARCH = AVR8\r
+\r
+\r
+# Target board (see library "Board Types" documentation, NONE for projects not requiring\r
+# LUFA board drivers). If USER is selected, put custom board drivers in a directory called\r
+# "Board" inside the application directory.\r
+BOARD = NONE\r
+\r
+\r
+# Processor frequency.\r
+#     This will define a symbol, F_CPU, in all source code files equal to the\r
+#     processor frequency in Hz. You can then use this symbol in your source code to\r
+#     calculate timings. Do NOT tack on a 'UL' at the end, this will be done\r
+#     automatically to create a 32-bit value in your source code.\r
+#\r
+#     This will be an integer division of F_USB below, as it is sourced by\r
+#     F_USB after it has run through any CPU prescalers. Note that this value\r
+#     does not *change* the processor frequency - it should merely be updated to\r
+#     reflect the processor speed set externally so that the code can use accurate\r
+#     software delays.\r
+F_CPU = 16000000\r
+\r
+\r
+# Input clock frequency.\r
+#     This will define a symbol, F_USB, in all source code files equal to the\r
+#     input clock frequency (before any prescaling is performed) in Hz. This value may\r
+#     differ from F_CPU if prescaling is used on the latter, and is required as the\r
+#     raw input clock is fed directly to the PLL sections of the AVR for high speed\r
+#     clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'\r
+#     at the end, this will be done automatically to create a 32-bit value in your\r
+#     source code.\r
+#\r
+#     If no clock division is performed on the input clock inside the AVR (via the\r
+#     CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.\r
+F_USB = $(F_CPU)\r
+\r
+\r
+# Output format. (can be srec, ihex, binary)\r
+FORMAT = ihex\r
+\r
+\r
+# Target file name (without extension).\r
+TARGET = Test\r
+\r
+\r
+# Object files directory\r
+#     To put object files in current directory, use a dot (.), do NOT make\r
+#     this an empty or blank macro!\r
+OBJDIR = .\r
+\r
+\r
+# Path to the LUFA library\r
+LUFA_PATH = ../..\r
+\r
+\r
+# LUFA library compile-time options and predefined tokens\r
+LUFA_OPTS  = \r
+\r
+\r
+# Create the LUFA source path variables by including the LUFA root makefile\r
+include $(LUFA_PATH)/LUFA/makefile\r
+\r
+\r
+# List C source files here. (C dependencies are automatically generated.)\r
+SRC = Test.c\r
+\r
+\r
+\r
+# List C++ source files here. (C dependencies are automatically generated.)\r
+CPPSRC = \r
+\r
+\r
+# List Assembler source files here.\r
+#     Make them always end in a capital .S.  Files ending in a lowercase .s\r
+#     will not be considered source files but generated files (assembler\r
+#     output from the compiler), and will be deleted upon "make clean"!\r
+#     Even though the DOS/Win* filesystem matches both .s and .S the same,\r
+#     it will preserve the spelling of the filenames, and gcc itself does\r
+#     care about how the name is spelled on its command-line.\r
+ASRC = \r
+\r
+\r
+# Optimization level, can be [0, 1, 2, 3, s].\r
+#     0 = turn off optimization. s = optimize for size.\r
+#     (Note: 3 is not always the best optimization level. See avr-libc FAQ.)\r
+OPT = s\r
+\r
+\r
+# Debugging format.\r
+#     Native formats for AVR-GCC's -g are dwarf-2 [default] or stabs.\r
+#     AVR Studio 4.10 requires dwarf-2.\r
+#     AVR [Extended] COFF format requires stabs, plus an avr-objcopy run.\r
+DEBUG = dwarf-2\r
+\r
+\r
+# List any extra directories to look for include files here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRAINCDIRS = $(LUFA_PATH)/\r
+\r
+\r
+# Compiler flag to set the C Standard level.\r
+#     c89   = "ANSI" C\r
+#     gnu89 = c89 plus GCC extensions\r
+#     c99   = ISO C99 standard (not yet fully implemented)\r
+#     gnu99 = c99 plus GCC extensions\r
+CSTANDARD = -std=c99\r
+\r
+\r
+# Place -D or -U options here for C sources\r
+CDEFS  = -DF_CPU=$(F_CPU)UL\r
+CDEFS += -DF_USB=$(F_USB)UL\r
+CDEFS += -DBOARD=BOARD_$(BOARD) -DARCH=ARCH_$(ARCH)\r
+CDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Place -D or -U options here for ASM sources\r
+ADEFS  = -DF_CPU=$(F_CPU)\r
+ADEFS += -DF_USB=$(F_USB)UL\r
+ADEFS += -DBOARD=BOARD_$(BOARD)\r
+ADEFS += $(LUFA_OPTS)\r
+\r
+# Place -D or -U options here for C++ sources\r
+CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
+CPPDEFS += -DF_USB=$(F_USB)UL\r
+CPPDEFS += -DBOARD=BOARD_$(BOARD)\r
+CPPDEFS += $(LUFA_OPTS)\r
+#CPPDEFS += -D__STDC_LIMIT_MACROS\r
+#CPPDEFS += -D__STDC_CONSTANT_MACROS\r
+\r
+\r
+\r
+#---------------- Compiler Options C ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CFLAGS = -g$(DEBUG)\r
+CFLAGS += $(CDEFS)\r
+CFLAGS += -O$(OPT)\r
+CFLAGS += -funsigned-char\r
+CFLAGS += -funsigned-bitfields\r
+CFLAGS += -ffunction-sections\r
+CFLAGS += -fno-inline-small-functions\r
+CFLAGS += -fpack-struct\r
+CFLAGS += -fshort-enums\r
+CFLAGS += -fno-strict-aliasing\r
+CFLAGS += -fno-split-wide-types\r
+CFLAGS += -Wall\r
+CFLAGS += -Wstrict-prototypes\r
+#CFLAGS += -mshort-calls\r
+#CFLAGS += -fno-unit-at-a-time\r
+#CFLAGS += -Wundef\r
+#CFLAGS += -Wunreachable-code\r
+#CFLAGS += -Wsign-compare\r
+CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)\r
+CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+CFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Compiler Options C++ ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CPPFLAGS = -g$(DEBUG)\r
+CPPFLAGS += $(CPPDEFS)\r
+CPPFLAGS += -O$(OPT)\r
+CPPFLAGS += -funsigned-char\r
+CPPFLAGS += -funsigned-bitfields\r
+CPPFLAGS += -fpack-struct\r
+CPPFLAGS += -fshort-enums\r
+CPPFLAGS += -fno-exceptions\r
+CPPFLAGS += -Wall\r
+CPPFLAGS += -Wundef\r
+#CPPFLAGS += -mshort-calls\r
+#CPPFLAGS += -fno-unit-at-a-time\r
+#CPPFLAGS += -Wstrict-prototypes\r
+#CPPFLAGS += -Wunreachable-code\r
+#CPPFLAGS += -Wsign-compare\r
+CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)\r
+CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+#CPPFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Assembler Options ----------------\r
+#  -Wa,...:   tell GCC to pass this to the assembler.\r
+#  -adhlns:   create listing\r
+#  -gstabs:   have the assembler create line number information; note that\r
+#             for use in COFF files, additional information about filenames\r
+#             and function names needs to be present in the assembler source\r
+#             files -- see avr-libc docs [FIXME: not yet described there]\r
+#  -listing-cont-lines: Sets the maximum number of continuation lines of hex\r
+#       dump that will be displayed for a given single line of source input.\r
+ASFLAGS = $(ADEFS) -Wa,-adhlns=$(<:%.S=$(OBJDIR)/%.lst),-gstabs,--listing-cont-lines=100\r
+\r
+\r
+#---------------- Library Options ----------------\r
+# Minimalistic printf version\r
+PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min\r
+\r
+# Floating point printf version (requires MATH_LIB = -lm below)\r
+PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt\r
+\r
+# If this is left blank, then it will use the Standard printf version.\r
+PRINTF_LIB =\r
+#PRINTF_LIB = $(PRINTF_LIB_MIN)\r
+#PRINTF_LIB = $(PRINTF_LIB_FLOAT)\r
+\r
+\r
+# Minimalistic scanf version\r
+SCANF_LIB_MIN = -Wl,-u,vfscanf -lscanf_min\r
+\r
+# Floating point + %[ scanf version (requires MATH_LIB = -lm below)\r
+SCANF_LIB_FLOAT = -Wl,-u,vfscanf -lscanf_flt\r
+\r
+# If this is left blank, then it will use the Standard scanf version.\r
+SCANF_LIB =\r
+#SCANF_LIB = $(SCANF_LIB_MIN)\r
+#SCANF_LIB = $(SCANF_LIB_FLOAT)\r
+\r
+\r
+MATH_LIB = -lm\r
+\r
+\r
+# List any extra directories to look for libraries here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRALIBDIRS =\r
+\r
+\r
+\r
+#---------------- External Memory Options ----------------\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# used for variables (.data/.bss) and heap (malloc()).\r
+#EXTMEMOPTS = -Wl,-Tdata=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# only used for heap (malloc()).\r
+#EXTMEMOPTS = -Wl,--section-start,.data=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+EXTMEMOPTS =\r
+\r
+\r
+\r
+#---------------- Linker Options ----------------\r
+#  -Wl,...:     tell GCC to pass this to linker.\r
+#    -Map:      create map file\r
+#    --cref:    add cross reference to  map file\r
+LDFLAGS  = -Wl,-Map=$(TARGET).map,--cref\r
+LDFLAGS += -Wl,--relax\r
+LDFLAGS += -Wl,--gc-sections\r
+LDFLAGS += $(EXTMEMOPTS)\r
+LDFLAGS += $(patsubst %,-L%,$(EXTRALIBDIRS))\r
+LDFLAGS += $(PRINTF_LIB) $(SCANF_LIB) $(MATH_LIB)\r
+#LDFLAGS += -T linker_script.x\r
+\r
+\r
+\r
+#---------------- Programming Options (avrdude) ----------------\r
+\r
+# Programming hardware\r
+# Type: avrdude -c ?\r
+# to get a full listing.\r
+#\r
+AVRDUDE_PROGRAMMER = jtagmkII\r
+\r
+# com1 = serial port. Use lpt1 to connect to parallel port.\r
+AVRDUDE_PORT = usb\r
+\r
+AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex\r
+#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep\r
+\r
+\r
+# Uncomment the following if you want avrdude's erase cycle counter.\r
+# Note that this counter needs to be initialized first using -Yn,\r
+# see avrdude manual.\r
+#AVRDUDE_ERASE_COUNTER = -y\r
+\r
+# Uncomment the following if you do /not/ wish a verification to be\r
+# performed after programming the device.\r
+#AVRDUDE_NO_VERIFY = -V\r
+\r
+# Increase verbosity level.  Please use this when submitting bug\r
+# reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude>\r
+# to submit bug reports.\r
+#AVRDUDE_VERBOSE = -v -v\r
+\r
+AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER)\r
+AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)\r
+AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)\r
+AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)\r
+\r
+\r
+\r
+#---------------- Debugging Options ----------------\r
+\r
+# For simulavr only - target MCU frequency.\r
+DEBUG_MFREQ = $(F_CPU)\r
+\r
+# Set the DEBUG_UI to either gdb or insight.\r
+# DEBUG_UI = gdb\r
+DEBUG_UI = insight\r
+\r
+# Set the debugging back-end to either avarice, simulavr.\r
+DEBUG_BACKEND = avarice\r
+#DEBUG_BACKEND = simulavr\r
+\r
+# GDB Init Filename.\r
+GDBINIT_FILE = __avr_gdbinit\r
+\r
+# When using avarice settings for the JTAG\r
+JTAG_DEV = /dev/com1\r
+\r
+# Debugging port used to communicate between GDB / avarice / simulavr.\r
+DEBUG_PORT = 4242\r
+\r
+# Debugging host used to communicate between GDB / avarice / simulavr, normally\r
+#     just set to localhost unless doing some sort of crazy debugging when\r
+#     avarice is running on a different computer.\r
+DEBUG_HOST = localhost\r
+\r
+\r
+\r
+#============================================================================\r
+\r
+\r
+# Define programs and commands.\r
+SHELL = sh\r
+CC = avr-gcc\r
+OBJCOPY = avr-objcopy\r
+OBJDUMP = avr-objdump\r
+SIZE = avr-size\r
+AR = avr-ar rcs\r
+NM = avr-nm\r
+AVRDUDE = avrdude\r
+REMOVE = rm -f\r
+REMOVEDIR = rm -rf\r
+COPY = cp\r
+WINSHELL = cmd\r
+\r
+\r
+# Define Messages\r
+# English\r
+MSG_ERRORS_NONE = Errors: none\r
+MSG_BEGIN = -------- begin --------\r
+MSG_END = --------  end  --------\r
+MSG_SIZE_BEFORE = Size before:\r
+MSG_SIZE_AFTER = Size after:\r
+MSG_COFF = Converting to AVR COFF:\r
+MSG_EXTENDED_COFF = Converting to AVR Extended COFF:\r
+MSG_FLASH = Creating load file for Flash:\r
+MSG_EEPROM = Creating load file for EEPROM:\r
+MSG_EXTENDED_LISTING = Creating Extended Listing:\r
+MSG_SYMBOL_TABLE = Creating Symbol Table:\r
+MSG_LINKING = Linking:\r
+MSG_COMPILING = Compiling C:\r
+MSG_COMPILING_CPP = Compiling C++:\r
+MSG_ASSEMBLING = Assembling:\r
+MSG_CLEANING = Cleaning project:\r
+MSG_CREATING_LIBRARY = Creating library:\r
+\r
+\r
+\r
+\r
+# Define all object files.\r
+OBJ = $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+\r
+# Define all listing files.\r
+LST = $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+\r
+\r
+# Compiler flags to generate dependency files.\r
+GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d\r
+\r
+\r
+# Combine all necessary flags and optional flags.\r
+# Add target processor to flags.\r
+ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS)\r
+ALL_CPPFLAGS = -mmcu=$(MCU) -I. -x c++ $(CPPFLAGS) $(GENDEPFLAGS)\r
+ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS)\r
+\r
+\r
+\r
+\r
+\r
+# Default target.\r
+all: begin gccversion sizebefore build sizeafter end\r
+\r
+# Change the build target to build a HEX file or a library.\r
+build: elf hex eep lss sym\r
+#build: lib\r
+\r
+\r
+elf: $(TARGET).elf\r
+hex: $(TARGET).hex\r
+eep: $(TARGET).eep\r
+lss: $(TARGET).lss\r
+sym: $(TARGET).sym\r
+LIBNAME=lib$(TARGET).a\r
+lib: $(LIBNAME)\r
+\r
+\r
+\r
+# Eye candy.\r
+# AVR Studio 3.x does not check make's exit code but relies on\r
+# the following magic strings to be generated by the compile job.\r
+begin:\r
+       @echo\r
+       @echo $(MSG_BEGIN)\r
+\r
+end:\r
+       @echo $(MSG_END)\r
+       @echo\r
+\r
+\r
+# Display size of file.\r
+HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex\r
+ELFSIZE = $(SIZE) $(MCU_FLAG) $(FORMAT_FLAG) $(TARGET).elf\r
+MCU_FLAG = $(shell $(SIZE) --help | grep -- --mcu > /dev/null && echo --mcu=$(MCU) )\r
+FORMAT_FLAG = $(shell $(SIZE) --help | grep -- --format=.*avr > /dev/null && echo --format=avr )\r
+\r
+\r
+sizebefore:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+sizeafter:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+\r
+\r
+# Display compiler version information.\r
+gccversion :\r
+       @$(CC) --version\r
+\r
+\r
+# Program the device.\r
+program: $(TARGET).hex $(TARGET).eep\r
+       $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM)\r
+\r
+flip: $(TARGET).hex\r
+       batchisp -hardware usb -device $(MCU) -operation erase f\r
+       batchisp -hardware usb -device $(MCU) -operation loadbuffer $(TARGET).hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+\r
+dfu: $(TARGET).hex\r
+       dfu-programmer $(MCU) erase\r
+       dfu-programmer $(MCU) flash $(TARGET).hex\r
+       dfu-programmer $(MCU) reset\r
+\r
+flip-ee: $(TARGET).hex $(TARGET).eep\r
+       $(COPY) $(TARGET).eep $(TARGET)eep.hex\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM erase\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM loadbuffer $(TARGET)eep.hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+       $(REMOVE) $(TARGET)eep.hex\r
+\r
+dfu-ee: $(TARGET).hex $(TARGET).eep\r
+       dfu-programmer $(MCU) eeprom-flash $(TARGET).eep\r
+       dfu-programmer $(MCU) reset\r
+\r
+\r
+# Generate avr-gdb config/init file which does the following:\r
+#     define the reset signal, load the target file, connect to target, and set\r
+#     a breakpoint at main().\r
+gdb-config:\r
+       @$(REMOVE) $(GDBINIT_FILE)\r
+       @echo define reset >> $(GDBINIT_FILE)\r
+       @echo SIGNAL SIGHUP >> $(GDBINIT_FILE)\r
+       @echo end >> $(GDBINIT_FILE)\r
+       @echo file $(TARGET).elf >> $(GDBINIT_FILE)\r
+       @echo target remote $(DEBUG_HOST):$(DEBUG_PORT)  >> $(GDBINIT_FILE)\r
+ifeq ($(DEBUG_BACKEND),simulavr)\r
+       @echo load  >> $(GDBINIT_FILE)\r
+endif\r
+       @echo break main >> $(GDBINIT_FILE)\r
+\r
+debug: gdb-config $(TARGET).elf\r
+ifeq ($(DEBUG_BACKEND), avarice)\r
+       @echo Starting AVaRICE - Press enter when "waiting to connect" message displays.\r
+       @$(WINSHELL) /c start avarice --jtag $(JTAG_DEV) --erase --program --file \\r
+       $(TARGET).elf $(DEBUG_HOST):$(DEBUG_PORT)\r
+       @$(WINSHELL) /c pause\r
+\r
+else\r
+       @$(WINSHELL) /c start simulavr --gdbserver --device $(MCU) --clock-freq \\r
+       $(DEBUG_MFREQ) --port $(DEBUG_PORT)\r
+endif\r
+       @$(WINSHELL) /c start avr-$(DEBUG_UI) --command=$(GDBINIT_FILE)\r
+\r
+\r
+\r
+\r
+# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB.\r
+COFFCONVERT = $(OBJCOPY) --debugging\r
+COFFCONVERT += --change-section-address .data-0x800000\r
+COFFCONVERT += --change-section-address .bss-0x800000\r
+COFFCONVERT += --change-section-address .noinit-0x800000\r
+COFFCONVERT += --change-section-address .eeprom-0x810000\r
+\r
+\r
+\r
+coff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-avr $< $(TARGET).cof\r
+\r
+\r
+extcoff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof\r
+\r
+\r
+\r
+# Create final output files (.hex, .eep) from ELF output file.\r
+%.hex: %.elf\r
+       @echo\r
+       @echo $(MSG_FLASH) $@\r
+       $(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock $< $@\r
+\r
+%.eep: %.elf\r
+       @echo\r
+       @echo $(MSG_EEPROM) $@\r
+       -$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \\r
+       --change-section-lma .eeprom=0 --no-change-warnings -O $(FORMAT) $< $@ || exit 0\r
+\r
+# Create extended listing file from ELF output file.\r
+%.lss: %.elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_LISTING) $@\r
+       $(OBJDUMP) -h -S -z $< > $@\r
+\r
+# Create a symbol table from ELF output file.\r
+%.sym: %.elf\r
+       @echo\r
+       @echo $(MSG_SYMBOL_TABLE) $@\r
+       $(NM) -n $< > $@\r
+\r
+\r
+\r
+# Create library from object files.\r
+.SECONDARY : $(TARGET).a\r
+.PRECIOUS : $(OBJ)\r
+%.a: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_CREATING_LIBRARY) $@\r
+       $(AR) $@ $(OBJ)\r
+\r
+\r
+# Link: create ELF output file from object files.\r
+.SECONDARY : $(TARGET).elf\r
+.PRECIOUS : $(OBJ)\r
+%.elf: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_LINKING) $@\r
+       $(CC) $(ALL_CFLAGS) $^ --output $@ $(LDFLAGS)\r
+\r
+\r
+# Compile: create object files from C source files.\r
+$(OBJDIR)/%.o : %.c\r
+       @echo\r
+       @echo $(MSG_COMPILING) $<\r
+       $(CC) -c $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create object files from C++ source files.\r
+$(OBJDIR)/%.o : %.cpp\r
+       @echo\r
+       @echo $(MSG_COMPILING_CPP) $<\r
+       $(CC) -c $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C source files.\r
+%.s : %.c\r
+       $(CC) -S $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C++ source files.\r
+%.s : %.cpp\r
+       $(CC) -S $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Assemble: create object files from assembler source files.\r
+$(OBJDIR)/%.o : %.S\r
+       @echo\r
+       @echo $(MSG_ASSEMBLING) $<\r
+       $(CC) -c $(ALL_ASFLAGS) $< -o $@\r
+\r
+\r
+# Create preprocessed source for use in sending a bug report.\r
+%.i : %.c\r
+       $(CC) -E -mmcu=$(MCU) -I. $(CFLAGS) $< -o $@\r
+\r
+\r
+# Target: clean project.\r
+clean: begin clean_list end\r
+\r
+clean_list :\r
+       @echo\r
+       @echo $(MSG_CLEANING)\r
+       $(REMOVE) $(TARGET).hex\r
+       $(REMOVE) $(TARGET).eep\r
+       $(REMOVE) $(TARGET).cof\r
+       $(REMOVE) $(TARGET).elf\r
+       $(REMOVE) $(TARGET).map\r
+       $(REMOVE) $(TARGET).sym\r
+       $(REMOVE) $(TARGET).lss\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+       $(REMOVE) $(SRC:.c=.s)\r
+       $(REMOVE) $(SRC:.c=.d)\r
+       $(REMOVE) $(SRC:.c=.i)\r
+       $(REMOVEDIR) .dep\r
+\r
+doxygen:\r
+       @echo Generating Project Documentation \($(TARGET)\)...\r
+       @if ( doxygen Doxygen.conf 2>&1 | grep -v "warning: ignoring unsupported tag" ;); then \\r
+         exit 1; \\r
+       fi;\r
+       @echo Documentation Generation Complete.\r
+\r
+clean_doxygen:\r
+       rm -rf Documentation\r
+\r
+checksource:\r
+       @for f in $(SRC) $(CPPSRC) $(ASRC); do \\r
+               if [ -f $$f ]; then \\r
+                       echo "Found Source File: $$f" ; \\r
+               else \\r
+                       echo "Source File Not Found: $$f" ; \\r
+               fi; done \r
+\r
+\r
+# Create object files directory\r
+$(shell mkdir $(OBJDIR) 2>/dev/null)\r
+\r
+\r
+# Include the dependency files.\r
+-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*)\r
+\r
+\r
+# Listing of phony targets.\r
+.PHONY : all begin finish end sizebefore sizeafter gccversion \\r
+build elf hex eep lss sym coff extcoff doxygen clean          \\r
+clean_list clean_doxygen program dfu flip flip-ee dfu-ee      \\r
+debug gdb-config checksource\r
diff --git a/BuildTests/BoardDriverTest/makefile.uc3 b/BuildTests/BoardDriverTest/makefile.uc3
new file mode 100644 (file)
index 0000000..7e75b54
--- /dev/null
@@ -0,0 +1,485 @@
+# Hey Emacs, this is a -*- makefile -*-\r
+#----------------------------------------------------------------------------\r
+# WinAVR Makefile Template written by Eric B. Weddington, Jörg Wunsch, et al.\r
+#  >> Modified for use with the LUFA project. <<\r
+#\r
+# Released to the Public Domain\r
+#\r
+# Additional material for this makefile was written by:\r
+# Peter Fleury\r
+# Tim Henigan\r
+# Colin O'Flynn\r
+# Reiner Patommel\r
+# Markus Pfaff\r
+# Sander Pool\r
+# Frederik Rouleau\r
+# Carlos Lamas\r
+# Dean Camera\r
+# Opendous Inc.\r
+# Denver Gingerich\r
+#\r
+#----------------------------------------------------------------------------\r
+# On command line:\r
+#\r
+# make all = Make software.\r
+#\r
+# make clean = Clean out built project files.\r
+#\r
+# make dfu = Download the hex file to the device, using dfu-programmer (must\r
+#            have dfu-programmer installed).\r
+#\r
+# make flip = Download the hex file to the device, using Atmel FLIP (must\r
+#             have Atmel FLIP installed).\r
+#\r
+# make doxygen = Generate DoxyGen documentation for the project (must have\r
+#                DoxyGen installed)\r
+#\r
+# make filename.s = Just compile filename.c into the assembler code only.\r
+#\r
+# make filename.i = Create a preprocessed source file for use in submitting\r
+#                   bug reports to the GCC project.\r
+#\r
+# To rebuild project do "make clean" then "make all".\r
+#----------------------------------------------------------------------------\r
+\r
+\r
+# MCU name\r
+MCU = uc3a3256\r
+\r
+\r
+# Targeted chip architecture (see library "Architectures" documentation)\r
+ARCH = UC3\r
+\r
+\r
+# Target board (see library "Board Types" documentation, NONE for projects not requiring\r
+# LUFA board drivers). If USER is selected, put custom board drivers in a directory called \r
+# "Board" inside the application directory.\r
+BOARD = NONE\r
+\r
+\r
+# Processor frequency.\r
+#     This will define a symbol, F_CPU, in all source code files equal to the\r
+#     processor frequency in Hz. You can then use this symbol in your source code to\r
+#     calculate timings. Do NOT tack on a 'UL' at the end, this will be done\r
+#     automatically to create a 32-bit value in your source code.\r
+#\r
+#     This should be the frequency the system core runs at, after the system clock\r
+#     has been set up correctly and started.\r
+F_CPU = 12000000\r
+\r
+\r
+# USB controller master clock frequency.\r
+#     This will define a symbol, F_USB, in all source code files equal to the\r
+#     input clock frequency of the USB controller's clock generator in Hz.\r
+#\r
+#     For the UC3 chips, this should be equal to 48MHz or 96MHz.\r
+F_USB = 48000000\r
+\r
+\r
+# Output format. (can be srec, ihex, binary)\r
+FORMAT = ihex\r
+\r
+\r
+# Target file name (without extension).\r
+TARGET = Test\r
+\r
+\r
+# Object files directory\r
+#     To put object files in current directory, use a dot (.), do NOT make\r
+#     this an empty or blank macro!\r
+OBJDIR = .\r
+\r
+\r
+# Path to the LUFA library\r
+LUFA_PATH = ../..\r
+\r
+\r
+# LUFA library compile-time options and predefined tokens (add '-D' before each token)\r
+LUFA_OPTS = \r
+\r
+\r
+# Create the LUFA source path variables by including the LUFA root makefile\r
+include $(LUFA_PATH)/LUFA/makefile\r
+\r
+\r
+# List C source files here. (C dependencies are automatically generated.)\r
+SRC = Test.c\r
+\r
+\r
+# List C++ source files here. (C dependencies are automatically generated.)\r
+CPPSRC = \r
+\r
+\r
+# List Assembler source files here.\r
+#     Make them always end in a capital .S.  Files ending in a lowercase .s\r
+#     will not be considered source files but generated files (assembler\r
+#     output from the compiler), and will be deleted upon "make clean"!\r
+#     Even though the DOS/Win* filesystem matches both .s and .S the same,\r
+#     it will preserve the spelling of the filenames, and gcc itself does\r
+#     care about how the name is spelled on its command-line.\r
+ASRC = \r
+\r
+\r
+# Optimization level, can be [0, 1, 2, 3, s]. \r
+#     0 = turn off optimization. s = optimize for size.\r
+#     (Note: 3 is not always the best optimization level. See avr-libc FAQ.)\r
+OPT = s\r
+\r
+\r
+# List any extra directories to look for include files here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRAINCDIRS = $(LUFA_PATH)/\r
+\r
+\r
+# Compiler flag to set the C Standard level.\r
+#     c89   = "ANSI" C\r
+#     gnu89 = c89 plus GCC extensions\r
+#     c99   = ISO C99 standard (not yet fully implemented)\r
+#     gnu99 = c99 plus GCC extensions\r
+CSTANDARD = -std=gnu99\r
+\r
+\r
+# Place -D or -U options here for C sources\r
+CDEFS  = -DF_CPU=$(F_CPU)UL\r
+CDEFS += -DF_USB=$(F_USB)UL\r
+CDEFS += -DBOARD=BOARD_$(BOARD)\r
+CDEFS += -DARCH=ARCH_$(ARCH)\r
+CDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Place -D or -U options here for ASM sources\r
+ADEFS  = -DF_CPU=$(F_CPU)\r
+ADEFS += -DF_USB=$(F_USB)UL\r
+ADEFS += -DBOARD=BOARD_$(BOARD)\r
+ADEFS += -DARCH=ARCH_$(ARCH)\r
+ADEFS += $(LUFA_OPTS)\r
+\r
+# Place -D or -U options here for C++ sources\r
+CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
+CPPDEFS += -DF_USB=$(F_USB)UL\r
+CPPDEFS += -DBOARD=BOARD_$(BOARD)\r
+CPPDEFS += -DARCH=ARCH_$(ARCH)\r
+CPPDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Debugging level.\r
+DEBUG = 3\r
+\r
+\r
+#---------------- Compiler Options C ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CFLAGS = -g$(DEBUG)\r
+CFLAGS += $(CDEFS)\r
+CFLAGS += -O$(OPT)\r
+CFLAGS += -funsigned-char\r
+CFLAGS += -funsigned-bitfields\r
+CFLAGS += -ffunction-sections\r
+CFLAGS += -fno-strict-aliasing\r
+CFLAGS += -Wall\r
+CFLAGS += -Wstrict-prototypes\r
+CFLAGS += -masm-addr-pseudos\r
+CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)\r
+CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+CFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Compiler Options C++ ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CPPFLAGS = -g$(DEBUG)\r
+CPPFLAGS += $(CPPDEFS)\r
+CPPFLAGS += -O$(OPT)\r
+CPPFLAGS += -funsigned-char\r
+CPPFLAGS += -funsigned-bitfields\r
+CPPFLAGS += -ffunction-sections\r
+CPPFLAGS += -fno-strict-aliasing\r
+CPPFLAGS += -fno-exceptions\r
+CPPFLAGS += -masm-addr-pseudos\r
+CPPFLAGS += -Wall\r
+CPPFLAGS += -Wundef\r
+CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)\r
+CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+#CPPFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Assembler Options ----------------\r
+#  -Wa,...:   tell GCC to pass this to the assembler.\r
+#  -adhlns:   create listing\r
+#  -gstabs:   have the assembler create line number information; note that\r
+#             for use in COFF files, additional information about filenames\r
+#             and function names needs to be present in the assembler source\r
+#             files -- see avr-libc docs [FIXME: not yet described there]\r
+#  -listing-cont-lines: Sets the maximum number of continuation lines of hex \r
+#       dump that will be displayed for a given single line of source input.\r
+ASFLAGS = $(ADEFS) -Wa,-adhlns=$(<:%.S=$(OBJDIR)/%.lst),-gstabs,--listing-cont-lines=100\r
+\r
+\r
+#---------------- Linker Options ----------------\r
+#  -Wl,...:     tell GCC to pass this to linker.\r
+#    -Map:      create map file\r
+#    --cref:    add cross reference to  map file\r
+LDFLAGS  = -Wl,-Map=$(TARGET).map,--cref\r
+LDFLAGS += -Wl,--gc-sections --rodata-writable\r
+LDFLAGS += -Wl,--direct-data\r
+#LDFLAGS += -T linker_script.x\r
+\r
+\r
+#============================================================================\r
+\r
+\r
+# Define programs and commands.\r
+SHELL = sh\r
+CC = avr32-gcc\r
+OBJCOPY = avr32-objcopy\r
+OBJDUMP = avr32-objdump\r
+SIZE = avr32-size\r
+AR = avr32-ar rcs\r
+NM = avr32-nm\r
+REMOVE = rm -f\r
+REMOVEDIR = rm -rf\r
+COPY = cp\r
+WINSHELL = cmd\r
+\r
+\r
+# Define Messages\r
+# English\r
+MSG_ERRORS_NONE = Errors: none\r
+MSG_BEGIN = -------- begin --------\r
+MSG_END = --------  end  --------\r
+MSG_SIZE_BEFORE = Size before: \r
+MSG_SIZE_AFTER = Size after:\r
+MSG_COFF = Converting to AVR COFF:\r
+MSG_FLASH = Creating load file for Flash:\r
+MSG_EEPROM = Creating load file for EEPROM:\r
+MSG_EXTENDED_LISTING = Creating Extended Listing:\r
+MSG_SYMBOL_TABLE = Creating Symbol Table:\r
+MSG_LINKING = Linking:\r
+MSG_COMPILING = Compiling C:\r
+MSG_COMPILING_CPP = Compiling C++:\r
+MSG_ASSEMBLING = Assembling:\r
+MSG_CLEANING = Cleaning project:\r
+MSG_CREATING_LIBRARY = Creating library:\r
+\r
+\r
+\r
+\r
+# Define all object files.\r
+OBJ = $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o) \r
+\r
+# Define all listing files.\r
+LST = $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst) \r
+\r
+\r
+# Compiler flags to generate dependency files.\r
+GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d\r
+\r
+\r
+# Combine all necessary flags and optional flags.\r
+# Add target processor to flags.\r
+ALL_CFLAGS = -mpart=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS)\r
+ALL_CPPFLAGS = -mpart=$(MCU) -I. -x c++ $(CPPFLAGS) $(GENDEPFLAGS)\r
+ALL_ASFLAGS = -mpart=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS)\r
+\r
+\r
+\r
+\r
+\r
+# Default target.\r
+all: begin gccversion sizebefore build sizeafter end\r
+\r
+# Change the build target to build a HEX file or a library.\r
+build: elf hex lss sym\r
+#build: lib\r
+\r
+\r
+elf: $(TARGET).elf\r
+hex: $(TARGET).hex\r
+lss: $(TARGET).lss\r
+sym: $(TARGET).sym\r
+LIBNAME=lib$(TARGET).a\r
+lib: $(LIBNAME)\r
+\r
+\r
+\r
+# Eye candy.\r
+# AVR Studio 3.x does not check make's exit code but relies on\r
+# the following magic strings to be generated by the compile job.\r
+begin:\r
+       @echo\r
+       @echo $(MSG_BEGIN)\r
+\r
+end:\r
+       @echo $(MSG_END)\r
+       @echo\r
+\r
+\r
+# Display size of file.\r
+HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex\r
+ELFSIZE = $(SIZE) $(MCU_FLAG) $(FORMAT_FLAG) $(TARGET).elf\r
+MCU_FLAG = $(shell $(SIZE) --help | grep -- --mcu > /dev/null && echo --mcu=$(MCU) )\r
+FORMAT_FLAG = $(shell $(SIZE) --help | grep -- --format=.*avr > /dev/null && echo --format=avr )\r
+\r
+\r
+sizebefore:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+sizeafter:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+\r
+\r
+# Display compiler version information.\r
+gccversion : \r
+       @$(CC) --version\r
+\r
+\r
+# Program the device.  \r
+flip: $(TARGET).hex\r
+       batchisp -hardware usb -device $(MCU) -operation erase f\r
+       batchisp -hardware usb -device $(MCU) -operation loadbuffer $(TARGET).hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+\r
+dfu: $(TARGET).hex\r
+       dfu-programmer $(MCU) erase\r
+       dfu-programmer $(MCU) flash $(TARGET).hex\r
+       dfu-programmer $(MCU) reset\r
+\r
+\r
+# Create final output files (.hex, .eep) from ELF output file.\r
+%.hex: %.elf\r
+       @echo\r
+       @echo $(MSG_FLASH) $@\r
+       $(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock -R .signature $< $@\r
+\r
+# Create extended listing file from ELF output file.\r
+%.lss: %.elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_LISTING) $@\r
+       $(OBJDUMP) -h -S -z $< > $@\r
+\r
+# Create a symbol table from ELF output file.\r
+%.sym: %.elf\r
+       @echo\r
+       @echo $(MSG_SYMBOL_TABLE) $@\r
+       $(NM) -n $< > $@\r
+\r
+\r
+\r
+# Create library from object files.\r
+.SECONDARY : $(TARGET).a\r
+.PRECIOUS : $(OBJ)\r
+%.a: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_CREATING_LIBRARY) $@\r
+       $(AR) $@ $(OBJ)\r
+\r
+\r
+# Link: create ELF output file from object files.\r
+.SECONDARY : $(TARGET).elf\r
+.PRECIOUS : $(OBJ)\r
+%.elf: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_LINKING) $@\r
+       $(CC) $(ALL_CFLAGS) $^ --output $@ $(LDFLAGS)\r
+\r
+\r
+# Compile: create object files from C source files.\r
+$(OBJDIR)/%.o : %.c\r
+       @echo\r
+       @echo $(MSG_COMPILING) $<\r
+       $(CC) -c $(ALL_CFLAGS) $< -o $@ \r
+\r
+\r
+# Compile: create object files from C++ source files.\r
+$(OBJDIR)/%.o : %.cpp\r
+       @echo\r
+       @echo $(MSG_COMPILING_CPP) $<\r
+       $(CC) -c $(ALL_CPPFLAGS) $< -o $@ \r
+\r
+\r
+# Compile: create assembler files from C source files.\r
+%.s : %.c\r
+       $(CC) -S $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C++ source files.\r
+%.s : %.cpp\r
+       $(CC) -S $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Assemble: create object files from assembler source files.\r
+$(OBJDIR)/%.o : %.S\r
+       @echo\r
+       @echo $(MSG_ASSEMBLING) $<\r
+       $(CC) -c $(ALL_ASFLAGS) $< -o $@\r
+\r
+\r
+# Create preprocessed source for use in sending a bug report.\r
+%.i : %.c\r
+       $(CC) -E -mmcu=$(MCU) -I. $(CFLAGS) $< -o $@ \r
+\r
+\r
+# Target: clean project.\r
+clean: begin clean_list end\r
+\r
+clean_list :\r
+       @echo\r
+       @echo $(MSG_CLEANING)\r
+       $(REMOVE) $(TARGET).hex\r
+       $(REMOVE) $(TARGET).cof\r
+       $(REMOVE) $(TARGET).elf\r
+       $(REMOVE) $(TARGET).map\r
+       $(REMOVE) $(TARGET).sym\r
+       $(REMOVE) $(TARGET).lss\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+       $(REMOVE) $(SRC:.c=.s)\r
+       $(REMOVE) $(SRC:.c=.d)\r
+       $(REMOVE) $(SRC:.c=.i)\r
+       $(REMOVEDIR) .dep\r
+\r
+doxygen:\r
+       @echo Generating Project Documentation \($(TARGET)\)...\r
+       @if ( doxygen Doxygen.conf 2>&1 | grep -v "warning: ignoring unsupported tag" ;); then \\r
+         exit 1; \\r
+       fi;\r
+       @echo Documentation Generation Complete.\r
+\r
+clean_doxygen:\r
+       rm -rf Documentation\r
+\r
+checksource:\r
+       @for f in $(SRC) $(CPPSRC) $(ASRC); do \\r
+               if [ -f $$f ]; then \\r
+                       echo "Found Source File: $$f" ; \\r
+               else \\r
+                       echo "Source File Not Found: $$f" ; \\r
+               fi; done \r
+\r
+\r
+# Create object files directory\r
+$(shell mkdir $(OBJDIR) 2>/dev/null)\r
+\r
+\r
+# Include the dependency files.\r
+-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*)\r
+\r
+\r
+# Listing of phony targets.\r
+.PHONY : all begin finish end sizebefore sizeafter gccversion \\r
+build elf hex lss sym doxygen clean clean_list clean_doxygen  \\r
+dfu flip checksource\r
+\r
diff --git a/BuildTests/BoardDriverTest/makefile.xmega b/BuildTests/BoardDriverTest/makefile.xmega
new file mode 100644 (file)
index 0000000..5a048b8
--- /dev/null
@@ -0,0 +1,704 @@
+# Hey Emacs, this is a -*- makefile -*-\r
+#----------------------------------------------------------------------------\r
+# WinAVR Makefile Template written by Eric B. Weddington, Jörg Wunsch, et al.\r
+#  >> Modified for use with the LUFA project. <<\r
+#\r
+# Released to the Public Domain\r
+#\r
+# Additional material for this makefile was written by:\r
+# Peter Fleury\r
+# Tim Henigan\r
+# Colin O'Flynn\r
+# Reiner Patommel\r
+# Markus Pfaff\r
+# Sander Pool\r
+# Frederik Rouleau\r
+# Carlos Lamas\r
+# Dean Camera\r
+# Opendous Inc.\r
+# Denver Gingerich\r
+#\r
+#----------------------------------------------------------------------------\r
+# On command line:\r
+#\r
+# make all = Make software.\r
+#\r
+# make clean = Clean out built project files.\r
+#\r
+# make coff = Convert ELF to AVR COFF.\r
+#\r
+# make extcoff = Convert ELF to AVR Extended COFF.\r
+#\r
+# make program = Download the hex file to the device, using avrdude.\r
+#                Please customize the avrdude settings below first!\r
+#\r
+# make dfu = Download the hex file to the device, using dfu-programmer (must\r
+#            have dfu-programmer installed).\r
+#\r
+# make flip = Download the hex file to the device, using Atmel FLIP (must\r
+#             have Atmel FLIP installed).\r
+#\r
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer\r
+#               (must have dfu-programmer installed).\r
+#\r
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP\r
+#                (must have Atmel FLIP installed).\r
+#\r
+# make doxygen = Generate DoxyGen documentation for the project (must have\r
+#                DoxyGen installed)\r
+#\r
+# make debug = Start either simulavr or avarice as specified for debugging, \r
+#              with avr-gdb or avr-insight as the front end for debugging.\r
+#\r
+# make filename.s = Just compile filename.c into the assembler code only.\r
+#\r
+# make filename.i = Create a preprocessed source file for use in submitting\r
+#                   bug reports to the GCC project.\r
+#\r
+# To rebuild project do "make clean" then "make all".\r
+#----------------------------------------------------------------------------\r
+\r
+\r
+# MCU name\r
+MCU = atxmega128a1u\r
+\r
+\r
+# Targeted chip architecture (see library "Architectures" documentation)\r
+ARCH = XMEGA\r
+\r
+\r
+# Target board (see library "Board Types" documentation, NONE for projects not requiring\r
+# LUFA board drivers). If USER is selected, put custom board drivers in a directory called \r
+# "Board" inside the application directory.\r
+BOARD = NONE\r
+\r
+\r
+# Processor frequency.\r
+#     This will define a symbol, F_CPU, in all source code files equal to the\r
+#     processor frequency in Hz. You can then use this symbol in your source code to\r
+#     calculate timings. Do NOT tack on a 'UL' at the end, this will be done\r
+#     automatically to create a 32-bit value in your source code.\r
+#\r
+#     This should be the frequency the system core runs at, after the system clock\r
+#     has been set up correctly and started.\r
+F_CPU = 24000000\r
+\r
+\r
+# USB controller master clock frequency.\r
+#     This will define a symbol, F_USB, in all source code files equal to the\r
+#     input clock frequency of the USB controller's clock generator in Hz.\r
+#\r
+#     For the XMEGA chips, this should be equal to a multiple of 6MHz for Low\r
+#     Speed USB mode, or a multiple of 48MHz for Full Speed USB mode.\r
+F_USB = 48000000\r
+\r
+\r
+# Output format. (can be srec, ihex, binary)\r
+FORMAT = ihex\r
+\r
+\r
+# Target file name (without extension).\r
+TARGET = Test\r
+\r
+\r
+# Object files directory\r
+#     To put object files in current directory, use a dot (.), do NOT make\r
+#     this an empty or blank macro!\r
+OBJDIR = .\r
+\r
+\r
+# Path to the LUFA library\r
+LUFA_PATH = ../..\r
+\r
+\r
+# LUFA library compile-time options and predefined tokens\r
+LUFA_OPTS  = \r
+\r
+\r
+# Create the LUFA source path variables by including the LUFA root makefile\r
+include $(LUFA_PATH)/LUFA/makefile\r
+\r
+\r
+# List C source files here. (C dependencies are automatically generated.)\r
+SRC = Test.c\r
+\r
+\r
+# List C++ source files here. (C dependencies are automatically generated.)\r
+CPPSRC = \r
+\r
+\r
+# List Assembler source files here.\r
+#     Make them always end in a capital .S.  Files ending in a lowercase .s\r
+#     will not be considered source files but generated files (assembler\r
+#     output from the compiler), and will be deleted upon "make clean"!\r
+#     Even though the DOS/Win* filesystem matches both .s and .S the same,\r
+#     it will preserve the spelling of the filenames, and gcc itself does\r
+#     care about how the name is spelled on its command-line.\r
+ASRC = \r
+\r
+\r
+# Optimization level, can be [0, 1, 2, 3, s]. \r
+#     0 = turn off optimization. s = optimize for size.\r
+#     (Note: 3 is not always the best optimization level. See avr-libc FAQ.)\r
+OPT = s\r
+\r
+\r
+# List any extra directories to look for include files here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRAINCDIRS = $(LUFA_PATH)/\r
+\r
+\r
+# Compiler flag to set the C Standard level.\r
+#     c89   = "ANSI" C\r
+#     gnu89 = c89 plus GCC extensions\r
+#     c99   = ISO C99 standard (not yet fully implemented)\r
+#     gnu99 = c99 plus GCC extensions\r
+CSTANDARD = -std=gnu99\r
+\r
+\r
+# Place -D or -U options here for C sources\r
+CDEFS  = -DF_CPU=$(F_CPU)UL\r
+CDEFS += -DF_USB=$(F_USB)UL\r
+CDEFS += -DBOARD=BOARD_$(BOARD)\r
+CDEFS += -DARCH=ARCH_$(ARCH)\r
+CDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Place -D or -U options here for ASM sources\r
+ADEFS  = -DF_CPU=$(F_CPU)\r
+ADEFS += -DF_USB=$(F_USB)UL\r
+ADEFS += -DBOARD=BOARD_$(BOARD)\r
+ADEFS += -DARCH=ARCH_$(ARCH)\r
+ADEFS += $(LUFA_OPTS)\r
+\r
+# Place -D or -U options here for C++ sources\r
+CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
+CPPDEFS += -DF_USB=$(F_USB)UL\r
+CPPDEFS += -DBOARD=BOARD_$(BOARD)\r
+CPPDEFS += -DARCH=ARCH_$(ARCH)\r
+CPPDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Debugging format.\r
+#     Native formats for AVR-GCC's -g are dwarf-2 [default] or stabs.\r
+#     AVR Studio 4.10 requires dwarf-2.\r
+#     AVR [Extended] COFF format requires stabs, plus an avr-objcopy run.\r
+DEBUG = dwarf-2\r
+\r
+\r
+#---------------- Compiler Options C ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CFLAGS = -g$(DEBUG)\r
+CFLAGS += $(CDEFS)\r
+CFLAGS += -O$(OPT)\r
+CFLAGS += -funsigned-char\r
+CFLAGS += -funsigned-bitfields\r
+CFLAGS += -ffunction-sections\r
+CFLAGS += -fno-inline-small-functions\r
+CFLAGS += -fpack-struct\r
+CFLAGS += -fshort-enums\r
+CFLAGS += -fno-strict-aliasing\r
+CFLAGS += -Wall\r
+CFLAGS += -Wstrict-prototypes\r
+CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)\r
+CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+CFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Compiler Options C++ ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CPPFLAGS = -g$(DEBUG)\r
+CPPFLAGS += $(CPPDEFS)\r
+CPPFLAGS += -O$(OPT)\r
+CPPFLAGS += -funsigned-char\r
+CPPFLAGS += -funsigned-bitfields\r
+CPPFLAGS += -fpack-struct\r
+CPPFLAGS += -fshort-enums\r
+CPPFLAGS += -ffunction-sections\r
+CPPFLAGS += -fno-strict-aliasing\r
+CPPFLAGS += -fno-exceptions\r
+CPPFLAGS += -Wall\r
+CPPFLAGS += -Wundef\r
+CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)\r
+CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+#CPPFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Assembler Options ----------------\r
+#  -Wa,...:   tell GCC to pass this to the assembler.\r
+#  -adhlns:   create listing\r
+#  -gstabs:   have the assembler create line number information; note that\r
+#             for use in COFF files, additional information about filenames\r
+#             and function names needs to be present in the assembler source\r
+#             files -- see avr-libc docs [FIXME: not yet described there]\r
+#  -listing-cont-lines: Sets the maximum number of continuation lines of hex \r
+#       dump that will be displayed for a given single line of source input.\r
+ASFLAGS = $(ADEFS) -Wa,-adhlns=$(<:%.S=$(OBJDIR)/%.lst),-gstabs,--listing-cont-lines=100\r
+\r
+\r
+#---------------- Library Options ----------------\r
+# Minimalistic printf version\r
+PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min\r
+\r
+# Floating point printf version (requires MATH_LIB = -lm below)\r
+PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt\r
+\r
+# If this is left blank, then it will use the Standard printf version.\r
+PRINTF_LIB = \r
+#PRINTF_LIB = $(PRINTF_LIB_MIN)\r
+#PRINTF_LIB = $(PRINTF_LIB_FLOAT)\r
+\r
+\r
+# Minimalistic scanf version\r
+SCANF_LIB_MIN = -Wl,-u,vfscanf -lscanf_min\r
+\r
+# Floating point + %[ scanf version (requires MATH_LIB = -lm below)\r
+SCANF_LIB_FLOAT = -Wl,-u,vfscanf -lscanf_flt\r
+\r
+# If this is left blank, then it will use the Standard scanf version.\r
+SCANF_LIB = \r
+#SCANF_LIB = $(SCANF_LIB_MIN)\r
+#SCANF_LIB = $(SCANF_LIB_FLOAT)\r
+\r
+\r
+MATH_LIB = -lm\r
+\r
+\r
+# List any extra directories to look for libraries here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRALIBDIRS = \r
+\r
+\r
+\r
+#---------------- External Memory Options ----------------\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# used for variables (.data/.bss) and heap (malloc()).\r
+#EXTMEMOPTS = -Wl,-Tdata=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# only used for heap (malloc()).\r
+#EXTMEMOPTS = -Wl,--section-start,.data=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+EXTMEMOPTS =\r
+\r
+\r
+\r
+#---------------- Linker Options ----------------\r
+#  -Wl,...:     tell GCC to pass this to linker.\r
+#    -Map:      create map file\r
+#    --cref:    add cross reference to  map file\r
+LDFLAGS  = -Wl,-Map=$(TARGET).map,--cref\r
+LDFLAGS += -Wl,--relax \r
+LDFLAGS += -Wl,--gc-sections\r
+LDFLAGS += $(EXTMEMOPTS)\r
+LDFLAGS += $(patsubst %,-L%,$(EXTRALIBDIRS))\r
+LDFLAGS += $(PRINTF_LIB) $(SCANF_LIB) $(MATH_LIB)\r
+#LDFLAGS += -T linker_script.x\r
+\r
+\r
+\r
+#---------------- Programming Options (avrdude) ----------------\r
+\r
+# Programming hardware\r
+# Type: avrdude -c ?\r
+# to get a full listing.\r
+#\r
+AVRDUDE_PROGRAMMER = jtagmkII\r
+\r
+# com1 = serial port. Use lpt1 to connect to parallel port.\r
+AVRDUDE_PORT = usb\r
+\r
+AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex\r
+#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep\r
+\r
+\r
+# Uncomment the following if you want avrdude's erase cycle counter.\r
+# Note that this counter needs to be initialized first using -Yn,\r
+# see avrdude manual.\r
+#AVRDUDE_ERASE_COUNTER = -y\r
+\r
+# Uncomment the following if you do /not/ wish a verification to be\r
+# performed after programming the device.\r
+#AVRDUDE_NO_VERIFY = -V\r
+\r
+# Increase verbosity level.  Please use this when submitting bug\r
+# reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude> \r
+# to submit bug reports.\r
+#AVRDUDE_VERBOSE = -v -v\r
+\r
+AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER)\r
+AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)\r
+AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)\r
+AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)\r
+\r
+\r
+\r
+#---------------- Debugging Options ----------------\r
+\r
+# For simulavr only - target MCU frequency.\r
+DEBUG_MFREQ = $(F_CPU)\r
+\r
+# Set the DEBUG_UI to either gdb or insight.\r
+# DEBUG_UI = gdb\r
+DEBUG_UI = insight\r
+\r
+# Set the debugging back-end to either avarice, simulavr.\r
+DEBUG_BACKEND = avarice\r
+#DEBUG_BACKEND = simulavr\r
+\r
+# GDB Init Filename.\r
+GDBINIT_FILE = __avr_gdbinit\r
+\r
+# When using avarice settings for the JTAG\r
+JTAG_DEV = /dev/com1\r
+\r
+# Debugging port used to communicate between GDB / avarice / simulavr.\r
+DEBUG_PORT = 4242\r
+\r
+# Debugging host used to communicate between GDB / avarice / simulavr, normally\r
+#     just set to localhost unless doing some sort of crazy debugging when \r
+#     avarice is running on a different computer.\r
+DEBUG_HOST = localhost\r
+\r
+\r
+\r
+#============================================================================\r
+\r
+\r
+# Define programs and commands.\r
+SHELL = sh\r
+CC = avr-gcc\r
+OBJCOPY = avr-objcopy\r
+OBJDUMP = avr-objdump\r
+SIZE = avr-size\r
+AR = avr-ar rcs\r
+NM = avr-nm\r
+AVRDUDE = avrdude\r
+REMOVE = rm -f\r
+REMOVEDIR = rm -rf\r
+COPY = cp\r
+WINSHELL = cmd\r
+\r
+\r
+# Define Messages\r
+# English\r
+MSG_ERRORS_NONE = Errors: none\r
+MSG_BEGIN = -------- begin --------\r
+MSG_END = --------  end  --------\r
+MSG_SIZE_BEFORE = Size before: \r
+MSG_SIZE_AFTER = Size after:\r
+MSG_COFF = Converting to AVR COFF:\r
+MSG_EXTENDED_COFF = Converting to AVR Extended COFF:\r
+MSG_FLASH = Creating load file for Flash:\r
+MSG_EEPROM = Creating load file for EEPROM:\r
+MSG_EXTENDED_LISTING = Creating Extended Listing:\r
+MSG_SYMBOL_TABLE = Creating Symbol Table:\r
+MSG_LINKING = Linking:\r
+MSG_COMPILING = Compiling C:\r
+MSG_COMPILING_CPP = Compiling C++:\r
+MSG_ASSEMBLING = Assembling:\r
+MSG_CLEANING = Cleaning project:\r
+MSG_CREATING_LIBRARY = Creating library:\r
+\r
+\r
+\r
+\r
+# Define all object files.\r
+OBJ = $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o) \r
+\r
+# Define all listing files.\r
+LST = $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst) \r
+\r
+\r
+# Compiler flags to generate dependency files.\r
+GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d\r
+\r
+\r
+# Combine all necessary flags and optional flags.\r
+# Add target processor to flags.\r
+ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS)\r
+ALL_CPPFLAGS = -mmcu=$(MCU) -I. -x c++ $(CPPFLAGS) $(GENDEPFLAGS)\r
+ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS)\r
+\r
+\r
+\r
+\r
+\r
+# Default target.\r
+all: begin gccversion sizebefore build sizeafter end\r
+\r
+# Change the build target to build a HEX file or a library.\r
+build: elf hex eep lss sym\r
+#build: lib\r
+\r
+\r
+elf: $(TARGET).elf\r
+hex: $(TARGET).hex\r
+eep: $(TARGET).eep\r
+lss: $(TARGET).lss\r
+sym: $(TARGET).sym\r
+LIBNAME=lib$(TARGET).a\r
+lib: $(LIBNAME)\r
+\r
+\r
+\r
+# Eye candy.\r
+# AVR Studio 3.x does not check make's exit code but relies on\r
+# the following magic strings to be generated by the compile job.\r
+begin:\r
+       @echo\r
+       @echo $(MSG_BEGIN)\r
+\r
+end:\r
+       @echo $(MSG_END)\r
+       @echo\r
+\r
+\r
+# Display size of file.\r
+HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex\r
+ELFSIZE = $(SIZE) $(MCU_FLAG) $(FORMAT_FLAG) $(TARGET).elf\r
+MCU_FLAG = $(shell $(SIZE) --help | grep -- --mcu > /dev/null && echo --mcu=$(MCU) )\r
+FORMAT_FLAG = $(shell $(SIZE) --help | grep -- --format=.*avr > /dev/null && echo --format=avr )\r
+\r
+\r
+sizebefore:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+sizeafter:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+\r
+\r
+# Display compiler version information.\r
+gccversion : \r
+       @$(CC) --version\r
+\r
+\r
+# Program the device.  \r
+program: $(TARGET).hex $(TARGET).eep\r
+       $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM)\r
+\r
+flip: $(TARGET).hex\r
+       batchisp -hardware usb -device $(MCU) -operation erase f\r
+       batchisp -hardware usb -device $(MCU) -operation loadbuffer $(TARGET).hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+\r
+dfu: $(TARGET).hex\r
+       dfu-programmer $(MCU) erase\r
+       dfu-programmer $(MCU) flash $(TARGET).hex\r
+       dfu-programmer $(MCU) reset\r
+\r
+flip-ee: $(TARGET).hex $(TARGET).eep\r
+       $(COPY) $(TARGET).eep $(TARGET)eep.hex\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM erase\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM loadbuffer $(TARGET)eep.hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+       $(REMOVE) $(TARGET)eep.hex\r
+\r
+dfu-ee: $(TARGET).hex $(TARGET).eep\r
+       dfu-programmer $(MCU) eeprom-flash $(TARGET).eep\r
+       dfu-programmer $(MCU) reset\r
+\r
+\r
+# Generate avr-gdb config/init file which does the following:\r
+#     define the reset signal, load the target file, connect to target, and set \r
+#     a breakpoint at main().\r
+gdb-config: \r
+       @$(REMOVE) $(GDBINIT_FILE)\r
+       @echo define reset >> $(GDBINIT_FILE)\r
+       @echo SIGNAL SIGHUP >> $(GDBINIT_FILE)\r
+       @echo end >> $(GDBINIT_FILE)\r
+       @echo file $(TARGET).elf >> $(GDBINIT_FILE)\r
+       @echo target remote $(DEBUG_HOST):$(DEBUG_PORT)  >> $(GDBINIT_FILE)\r
+ifeq ($(DEBUG_BACKEND),simulavr)\r
+       @echo load  >> $(GDBINIT_FILE)\r
+endif\r
+       @echo break main >> $(GDBINIT_FILE)\r
+\r
+debug: gdb-config $(TARGET).elf\r
+ifeq ($(DEBUG_BACKEND), avarice)\r
+       @echo Starting AVaRICE - Press enter when "waiting to connect" message displays.\r
+       @$(WINSHELL) /c start avarice --jtag $(JTAG_DEV) --erase --program --file \\r
+       $(TARGET).elf $(DEBUG_HOST):$(DEBUG_PORT)\r
+       @$(WINSHELL) /c pause\r
+\r
+else\r
+       @$(WINSHELL) /c start simulavr --gdbserver --device $(MCU) --clock-freq \\r
+       $(DEBUG_MFREQ) --port $(DEBUG_PORT)\r
+endif\r
+       @$(WINSHELL) /c start avr-$(DEBUG_UI) --command=$(GDBINIT_FILE)\r
+\r
+\r
+\r
+\r
+# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB.\r
+COFFCONVERT = $(OBJCOPY) --debugging\r
+COFFCONVERT += --change-section-address .data-0x800000\r
+COFFCONVERT += --change-section-address .bss-0x800000\r
+COFFCONVERT += --change-section-address .noinit-0x800000\r
+COFFCONVERT += --change-section-address .eeprom-0x810000\r
+\r
+\r
+\r
+coff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-avr $< $(TARGET).cof\r
+\r
+\r
+extcoff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof\r
+\r
+\r
+\r
+# Create final output files (.hex, .eep) from ELF output file.\r
+%.hex: %.elf\r
+       @echo\r
+       @echo $(MSG_FLASH) $@\r
+       $(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock -R .signature $< $@\r
+\r
+%.eep: %.elf\r
+       @echo\r
+       @echo $(MSG_EEPROM) $@\r
+       -$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \\r
+       --change-section-lma .eeprom=0 --no-change-warnings -O $(FORMAT) $< $@ || exit 0\r
+\r
+# Create extended listing file from ELF output file.\r
+%.lss: %.elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_LISTING) $@\r
+       $(OBJDUMP) -h -S -z $< > $@\r
+\r
+# Create a symbol table from ELF output file.\r
+%.sym: %.elf\r
+       @echo\r
+       @echo $(MSG_SYMBOL_TABLE) $@\r
+       $(NM) -n $< > $@\r
+\r
+\r
+\r
+# Create library from object files.\r
+.SECONDARY : $(TARGET).a\r
+.PRECIOUS : $(OBJ)\r
+%.a: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_CREATING_LIBRARY) $@\r
+       $(AR) $@ $(OBJ)\r
+\r
+\r
+# Link: create ELF output file from object files.\r
+.SECONDARY : $(TARGET).elf\r
+.PRECIOUS : $(OBJ)\r
+%.elf: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_LINKING) $@\r
+       $(CC) $(ALL_CFLAGS) $^ --output $@ $(LDFLAGS)\r
+\r
+\r
+# Compile: create object files from C source files.\r
+$(OBJDIR)/%.o : %.c\r
+       @echo\r
+       @echo $(MSG_COMPILING) $<\r
+       $(CC) -c $(ALL_CFLAGS) $< -o $@ \r
+\r
+\r
+# Compile: create object files from C++ source files.\r
+$(OBJDIR)/%.o : %.cpp\r
+       @echo\r
+       @echo $(MSG_COMPILING_CPP) $<\r
+       $(CC) -c $(ALL_CPPFLAGS) $< -o $@ \r
+\r
+\r
+# Compile: create assembler files from C source files.\r
+%.s : %.c\r
+       $(CC) -S $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C++ source files.\r
+%.s : %.cpp\r
+       $(CC) -S $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Assemble: create object files from assembler source files.\r
+$(OBJDIR)/%.o : %.S\r
+       @echo\r
+       @echo $(MSG_ASSEMBLING) $<\r
+       $(CC) -c $(ALL_ASFLAGS) $< -o $@\r
+\r
+\r
+# Create preprocessed source for use in sending a bug report.\r
+%.i : %.c\r
+       $(CC) -E -mmcu=$(MCU) -I. $(CFLAGS) $< -o $@ \r
+\r
+\r
+# Target: clean project.\r
+clean: begin clean_list end\r
+\r
+clean_list :\r
+       @echo\r
+       @echo $(MSG_CLEANING)\r
+       $(REMOVE) $(TARGET).hex\r
+       $(REMOVE) $(TARGET).eep\r
+       $(REMOVE) $(TARGET).cof\r
+       $(REMOVE) $(TARGET).elf\r
+       $(REMOVE) $(TARGET).map\r
+       $(REMOVE) $(TARGET).sym\r
+       $(REMOVE) $(TARGET).lss\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+       $(REMOVE) $(SRC:.c=.s)\r
+       $(REMOVE) $(SRC:.c=.d)\r
+       $(REMOVE) $(SRC:.c=.i)\r
+       $(REMOVEDIR) .dep\r
+\r
+doxygen:\r
+       @echo Generating Project Documentation \($(TARGET)\)...\r
+       @if ( doxygen Doxygen.conf 2>&1 | grep -v "warning: ignoring unsupported tag" ;); then \\r
+         exit 1; \\r
+       fi;\r
+       @echo Documentation Generation Complete.\r
+\r
+clean_doxygen:\r
+       rm -rf Documentation\r
+\r
+checksource:\r
+       @for f in $(SRC) $(CPPSRC) $(ASRC); do \\r
+               if [ -f $$f ]; then \\r
+                       echo "Found Source File: $$f" ; \\r
+               else \\r
+                       echo "Source File Not Found: $$f" ; \\r
+               fi; done \r
+\r
+\r
+# Create object files directory\r
+$(shell mkdir $(OBJDIR) 2>/dev/null)\r
+\r
+\r
+# Include the dependency files.\r
+-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*)\r
+\r
+\r
+# Listing of phony targets.\r
+.PHONY : all begin finish end sizebefore sizeafter gccversion \\r
+build elf hex eep lss sym coff extcoff doxygen clean          \\r
+clean_list clean_doxygen program dfu flip flip-ee dfu-ee      \\r
+debug gdb-config checksource\r
index 974a3dd..5970073 100644 (file)
@@ -15,7 +15,7 @@
 \r
 # List of device families per architecture, one device per architecture sub-family\r
 AVR8_FAMILIES  = at90usb1287 at90usb1286 atmega16u4 atmega16u2 at90usb162\r
-XMEGA_FAMILIES = atxmega128a1u atxmega128a3u atxmega256a3bu atxmega128a4u atxmega128b1 atxmega128b3\r
+XMEGA_FAMILIES = atxmega128a1u atxmega128a3u atxmega256a3bu atxmega128a4u atxmega128b1 atxmega128b3 atxmega128c3 atxmega32c4\r
 UC3_FAMILIES   = uc3a0256 uc3a1256 uc3a3256 uc3a4256 uc3b0256 uc3b1256\r
 \r
 # List of all device families, with a family postfix\r
@@ -24,6 +24,10 @@ DEVICE_FAMILIES = $(AVR8_FAMILIES:%=%.avr8) $(XMEGA_FAMILIES:%=%.xmega) $(UC3_FA
 \r
 all: begin $(DEVICE_FAMILIES) clean end\r
 \r
+arch_avr8:  begin $(AVR8_FAMILIES:%=%.avr8) end\r
+arch_xmega: begin $(XMEGA_FAMILIES:%=%.xmega) end\r
+arch_uc3:   begin $(UC3_FAMILIES:%=%.uc3) end\r
+\r
 begin:\r
        @echo Executing build test "ModuleTest".\r
        @echo\r
@@ -33,21 +37,21 @@ end:
        @echo\r
 \r
 %.avr8:\r
-       $(MAKE) -f makefile.avr8 clean -s\r
-       $(MAKE) -f makefile.avr8 all MCU=$(@:%.avr8=%) -s\r
+       $(MAKE) -s -f makefile.avr8 clean\r
+       $(MAKE) -s -f makefile.avr8 all MCU=$(@:%.avr8=%) elf\r
 \r
 %.xmega:\r
-       $(MAKE) -f makefile.xmega clean -s\r
-       $(MAKE) -f makefile.xmega all MCU=$(@:%.xmega=%) -s\r
+       $(MAKE) -s -f makefile.xmega clean\r
+       $(MAKE) -s -f makefile.xmega all MCU=$(@:%.xmega=%) elf\r
 \r
 %.uc3:\r
-       $(MAKE) -f makefile.uc3 clean -s\r
-       $(MAKE) -f makefile.uc3 all MCU=$(@:%.uc3=%) -s\r
+       $(MAKE) -s -f makefile.uc3 clean\r
+       $(MAKE) -s -f makefile.uc3 all MCU=$(@:%.uc3=%) elf\r
 \r
 clean:\r
-       $(MAKE) -f makefile.avr8 clean -s\r
-       $(MAKE) -f makefile.xmega clean -s\r
-       $(MAKE) -f makefile.uc3 clean -s\r
+       $(MAKE) -s -f makefile.avr8 clean\r
+       $(MAKE) -s -f makefile.xmega clean\r
+       $(MAKE) -s -f makefile.uc3 clean\r
 \r
 %:\r
        
\ No newline at end of file
index 701a4b9..725f4a5 100644 (file)
@@ -23,23 +23,23 @@ end:
        @echo\r
 \r
 compile:\r
-       $(MAKE) -f makefile.avr8 clean -s\r
-       $(MAKE) -f makefile.avr8 LUFA_OPTS='-D USB_DEVICE_ONLY' -s\r
-       $(MAKE) -f makefile.avr8 clean -s\r
-       $(MAKE) -f makefile.avr8 LUFA_OPTS='-D USB_HOST_ONLY' -s\r
-\r
-       $(MAKE) -f makefile.xmega clean -s\r
-       $(MAKE) -f makefile.xmega LUFA_OPTS='-D USB_DEVICE_ONLY' -s\r
-\r
-       $(MAKE) -f makefile.uc3 clean -s\r
-       $(MAKE) -f makefile.uc3 LUFA_OPTS='-D USB_DEVICE_ONLY' -s\r
-       $(MAKE) -f makefile.uc3 clean -s\r
-       $(MAKE) -f makefile.uc3 LUFA_OPTS='-D USB_HOST_ONLY' -s\r
+       $(MAKE) -s -f makefile.avr8 clean\r
+       $(MAKE) -s -f makefile.avr8 LUFA_OPTS='-D USB_DEVICE_ONLY' elf\r
+       $(MAKE) -s -f makefile.avr8 clean\r
+       $(MAKE) -s -f makefile.avr8 LUFA_OPTS='-D USB_HOST_ONLY' elf\r
+\r
+       $(MAKE) -s -f makefile.xmega clean\r
+       $(MAKE) -s -f makefile.xmega LUFA_OPTS='-D USB_DEVICE_ONLY' elf\r
+       \r
+       $(MAKE) -s -f makefile.uc3 clean\r
+       $(MAKE) -s -f makefile.uc3 LUFA_OPTS='-D USB_DEVICE_ONLY' elf\r
+       $(MAKE) -s -f makefile.uc3 clean\r
+       $(MAKE) -s -f makefile.uc3 LUFA_OPTS='-D USB_HOST_ONLY' elf\r
 \r
 clean:\r
-       $(MAKE) -f makefile.avr8 clean -s\r
-       $(MAKE) -f makefile.xmega clean -s\r
-       $(MAKE) -f makefile.uc3 clean -s\r
+       $(MAKE) -s -f makefile.avr8 clean\r
+       $(MAKE) -s -f makefile.xmega clean\r
+       $(MAKE) -s -f makefile.uc3 clean\r
 \r
 %:\r
        
\ No newline at end of file
index 817727e..70adf0f 100644 (file)
@@ -24,7 +24,8 @@ SUPPRESS_WARNINGS = variableScope     \
                     missingInclude\r
 \r
 # Extra paths to search for include files\r
-INCLUDE_PATHS     = $(LUFA_ROOT_PATH)/LUFA/CodeTemplates/\r
+INCLUDE_PATHS     = $(LUFA_ROOT_PATH)/LUFA/CodeTemplates/      \\r
+                                       $(LUFA_ROOT_PATH)/Projects/AVRISP-MKII/\r
 \r
 # Configuration options to pass to cppcheck\r
 CPPCHECK_OPTIONS  = --template=$(MESSAGE_TEMPLATE) $(INCLUDE_PATHS:%=-I%) $(EXCLUDE_LIST:%=-i%) --inline-suppr --force --error-exitcode=1 --std=c99\r
index e296436..ac0cde2 100644 (file)
 # not intended to be modified or compiled by non-developers.\r
 \r
 all:\r
-       $(MAKE) -C ModuleTest all\r
-       $(MAKE) -C SingleUSBModeTest all\r
-       $(MAKE) -C StaticAnalysisTest all\r
-\r
 %:\r
+       $(MAKE) -C BoardDriverTest $@\r
        $(MAKE) -C ModuleTest $@\r
        $(MAKE) -C SingleUSBModeTest $@\r
        $(MAKE) -C StaticAnalysisTest $@\r
index 382446a..867a09e 100644 (file)
@@ -46,9 +46,12 @@ USB_ClassInfo_Audio_Device_t Microphone_Audio_Interface =
                        {
                                .ControlInterfaceNumber   = 0,
                                .StreamingInterfaceNumber = 1,
-
-                               .DataINEndpointNumber     = AUDIO_STREAM_EPNUM,
-                               .DataINEndpointSize       = AUDIO_STREAM_EPSIZE,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = AUDIO_STREAM_EPADDR,
+                                               .Size             = AUDIO_STREAM_EPSIZE,
+                                               .Banks            = 2,
+                                       },
                        },
        };
 
@@ -197,7 +200,7 @@ bool CALLBACK_Audio_Device_GetSetEndpointProperty(USB_ClassInfo_Audio_Device_t*
                                                   uint8_t* Data)
 {
        /* Check the requested endpoint to see if a supported endpoint is being manipulated */
-       if (EndpointAddress == (ENDPOINT_DIR_IN | Microphone_Audio_Interface.Config.DataINEndpointNumber))
+       if (EndpointAddress == Microphone_Audio_Interface.Config.DataINEndpoint.Address)
        {
                /* Check the requested control to see if a supported control is being manipulated */
                if (EndpointControl == AUDIO_EPCONTROL_SamplingFreq)
index 6b7593f..8557e18 100644 (file)
@@ -220,7 +220,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_IN | AUDIO_STREAM_EPNUM),
+                                       .EndpointAddress     = AUDIO_STREAM_EPADDR,
                                        .Attributes          = (EP_TYPE_ISOCHRONOUS | ENDPOINT_ATTR_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = AUDIO_STREAM_EPSIZE,
                                        .PollingIntervalMS   = 0x01
index ac0a536..359a287 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the Audio isochronous streaming data endpoint. */
-               #define AUDIO_STREAM_EPNUM           1
+               /** Endpoint address of the Audio isochronous streaming data IN endpoint. */
+               #define AUDIO_STREAM_EPADDR           (ENDPOINT_DIR_IN | 1)
 
-               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. The Windows audio stack requires
-                *  at least 192 bytes for correct output, thus the smaller 128 byte maximum endpoint size on some of the smaller
-                *  USB AVR models will result in unavoidable distorted output.
-                */
-               #define AUDIO_STREAM_EPSIZE          ENDPOINT_MAX_SIZE(AUDIO_STREAM_EPNUM)
+               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. */
+               #define AUDIO_STREAM_EPSIZE           256
 
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
index 78d81f5..82f664a 100644 (file)
@@ -46,9 +46,12 @@ USB_ClassInfo_Audio_Device_t Speaker_Audio_Interface =
                        {
                                .ControlInterfaceNumber   = 0,
                                .StreamingInterfaceNumber = 1,
-
-                               .DataOUTEndpointNumber    = AUDIO_STREAM_EPNUM,
-                               .DataOUTEndpointSize      = AUDIO_STREAM_EPSIZE,
+                               .DataOUTEndpoint          =
+                                       {
+                                               .Address          = AUDIO_STREAM_EPADDR,
+                                               .Size             = AUDIO_STREAM_EPSIZE,
+                                               .Banks            = 2,
+                                       },
                        },
        };
 
@@ -234,7 +237,7 @@ bool CALLBACK_Audio_Device_GetSetEndpointProperty(USB_ClassInfo_Audio_Device_t*
                                                   uint8_t* Data)
 {
        /* Check the requested endpoint to see if a supported endpoint is being manipulated */
-       if (EndpointAddress == (ENDPOINT_DIR_OUT | Speaker_Audio_Interface.Config.DataOUTEndpointNumber))
+       if (EndpointAddress == Speaker_Audio_Interface.Config.DataOUTEndpoint.Address)
        {
                /* Check the requested control to see if a supported control is being manipulated */
                if (EndpointControl == AUDIO_EPCONTROL_SamplingFreq)
index 06cc5ca..0df2745 100644 (file)
@@ -220,7 +220,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_OUT | AUDIO_STREAM_EPNUM),
+                                       .EndpointAddress     = AUDIO_STREAM_EPADDR,
                                        .Attributes          = (EP_TYPE_ISOCHRONOUS | ENDPOINT_ATTR_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = AUDIO_STREAM_EPSIZE,
                                        .PollingIntervalMS   = 0x01
index ac0a536..d5c8a2b 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the Audio isochronous streaming data endpoint. */
-               #define AUDIO_STREAM_EPNUM           1
+               /** Endpoint address of the Audio isochronous streaming data OUT endpoint. */
+               #define AUDIO_STREAM_EPADDR           (ENDPOINT_DIR_OUT | 1)
 
-               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. The Windows audio stack requires
-                *  at least 192 bytes for correct output, thus the smaller 128 byte maximum endpoint size on some of the smaller
-                *  USB AVR models will result in unavoidable distorted output.
-                */
-               #define AUDIO_STREAM_EPSIZE          ENDPOINT_MAX_SIZE(AUDIO_STREAM_EPNUM)
+               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. */
+               #define AUDIO_STREAM_EPSIZE           256
 
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
index 5df6808..1a4860a 100644 (file)
@@ -157,7 +157,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC1_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC1_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -183,20 +183,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC1_RX_EPNUM),
+                       .EndpointAddress        = CDC1_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC1_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC1_TX_EPNUM),
+                       .EndpointAddress        = CDC1_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC2_IAD =
@@ -258,7 +258,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC2_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC2_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -284,20 +284,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC2_RX_EPNUM),
+                       .EndpointAddress        = CDC2_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC2_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC2_TX_EPNUM),
+                       .EndpointAddress        = CDC2_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 01d10f2..dc3aa0b 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the first CDC interface's device-to-host data IN endpoint. */
-               #define CDC1_TX_EPNUM                  1
+               /** Endpoint address of the first CDC interface's device-to-host data IN endpoint. */
+               #define CDC1_TX_EPADDR                 (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the first CDC interface's host-to-device data OUT endpoint. */
-               #define CDC1_RX_EPNUM                  2
+               /** Endpoint address of the first CDC interface's host-to-device data OUT endpoint. */
+               #define CDC1_RX_EPADDR                 (ENDPOINT_DIR_OUT | 2)
 
-               /** Endpoint number of the first CDC interface's device-to-host notification IN endpoint. */
-               #define CDC1_NOTIFICATION_EPNUM        3
+               /** Endpoint address of the first CDC interface's device-to-host notification IN endpoint. */
+               #define CDC1_NOTIFICATION_EPADDR       (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the second CDC interface's device-to-host data IN endpoint. */
-               #define CDC2_TX_EPNUM                  4
+               /** Endpoint address of the second CDC interface's device-to-host data IN endpoint. */
+               #define CDC2_TX_EPADDR                 (ENDPOINT_DIR_IN  | 4)
 
-               /** Endpoint number of the second CDC interface's host-to-device data OUT endpoint. */
-               #define CDC2_RX_EPNUM                  5
+               /** Endpoint address of the second CDC interface's host-to-device data OUT endpoint. */
+               #define CDC2_RX_EPADDR                 (ENDPOINT_DIR_OUT | 5)
 
-               /** Endpoint number of the second CDC interface's device-to-host notification IN endpoint. */
-               #define CDC2_NOTIFICATION_EPNUM        6
+               /** Endpoint address of the second CDC interface's device-to-host notification IN endpoint. */
+               #define CDC2_NOTIFICATION_EPADDR       (ENDPOINT_DIR_IN  | 6)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoints. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 8f1eb96..a07967c 100644 (file)
@@ -45,19 +45,25 @@ USB_ClassInfo_CDC_Device_t VirtualSerial1_CDC_Interface =
        {
                .Config =
                        {
-                               .ControlInterfaceNumber           = 0,
-
-                               .DataINEndpointNumber             = CDC1_TX_EPNUM,
-                               .DataINEndpointSize               = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank         = false,
-
-                               .DataOUTEndpointNumber            = CDC1_RX_EPNUM,
-                               .DataOUTEndpointSize              = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank        = false,
-
-                               .NotificationEndpointNumber       = CDC1_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize         = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank   = false,
+                               .ControlInterfaceNumber   = 0,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC1_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC1_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC1_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
@@ -70,19 +76,26 @@ USB_ClassInfo_CDC_Device_t VirtualSerial2_CDC_Interface =
        {
                .Config =
                        {
-                               .ControlInterfaceNumber           = 2,
-
-                               .DataINEndpointNumber             = CDC2_TX_EPNUM,
-                               .DataINEndpointSize               = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank         = false,
-
-                               .DataOUTEndpointNumber            = CDC2_RX_EPNUM,
-                               .DataOUTEndpointSize              = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank        = false,
+                               .ControlInterfaceNumber   = 2,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC2_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC2_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC2_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
 
-                               .NotificationEndpointNumber       = CDC2_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize         = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank   = false,
                        },
        };
 
index ee1ba49..a9ca6be 100644 (file)
@@ -135,10 +135,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | GENERIC_IN_EPNUM),
+                       .EndpointAddress        = GENERIC_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = GENERIC_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index ddeef24..0b9ec8f 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Generic HID reporting IN endpoint. */
-               #define GENERIC_IN_EPNUM          1
+               /** Endpoint address of the Generic HID reporting IN endpoint. */
+               #define GENERIC_IN_EPADDR         (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the Generic HID reporting endpoint. */
                #define GENERIC_EPSIZE            8
index 36eb8f7..aa365bd 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Generic_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = GENERIC_IN_EPNUM,
-                               .ReportINEndpointSize         = GENERIC_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = GENERIC_IN_EPADDR,
+                                               .Size                 = GENERIC_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevHIDReportBuffer),
                        },
index da6fc3d..903e35c 100644 (file)
@@ -135,10 +135,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | JOYSTICK_EPNUM),
+                       .EndpointAddress        = JOYSTICK_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = JOYSTICK_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index f0ad9c2..d2e2943 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Joystick HID reporting IN endpoint. */
-               #define JOYSTICK_EPNUM               1
+               /** Endpoint address of the Joystick HID reporting IN endpoint. */
+               #define JOYSTICK_EPADDR              (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the Joystick HID reporting IN endpoint. */
                #define JOYSTICK_EPSIZE              8
index 3c1913f..4f361da 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Joystick_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = JOYSTICK_EPNUM,
-                               .ReportINEndpointSize         = JOYSTICK_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = JOYSTICK_EPADDR,
+                                               .Size                 = JOYSTICK_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevJoystickHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevJoystickHIDReportBuffer),
                        },
index cb78526..c74368b 100644 (file)
@@ -131,10 +131,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_EPNUM),
+                       .EndpointAddress        = KEYBOARD_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = KEYBOARD_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index 3704895..f032b72 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Keyboard HID reporting IN endpoint. */
-               #define KEYBOARD_EPNUM               1
+               /** Endpoint address of the Keyboard HID reporting IN endpoint. */
+               #define KEYBOARD_EPADDR              (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the Keyboard HID reporting IN endpoint. */
                #define KEYBOARD_EPSIZE              8
index 15a7f17..24bf8d5 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = KEYBOARD_EPNUM,
-                               .ReportINEndpointSize         = KEYBOARD_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = KEYBOARD_EPADDR,
+                                               .Size                 = KEYBOARD_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevKeyboardHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevKeyboardHIDReportBuffer),
                        },
index d6471d6..448fe05 100644 (file)
@@ -147,10 +147,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_IN_EPNUM),
+                       .EndpointAddress        = KEYBOARD_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID2_MouseInterface =
@@ -184,10 +184,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_IN_EPNUM),
+                       .EndpointAddress        = MOUSE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index fe41f92..e35e266 100644 (file)
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Keyboard HID reporting IN endpoint. */
-               #define KEYBOARD_IN_EPNUM         1
+               /** Endpoint address of the Keyboard HID reporting IN endpoint. */
+               #define KEYBOARD_IN_EPADDR        (ENDPOINT_DIR_IN | 1)
 
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_IN_EPNUM            3
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_IN_EPADDR           (ENDPOINT_DIR_IN | 3)
 
                /** Size in bytes of each of the HID reporting IN endpoints. */
                #define HID_EPSIZE                8
index cb2eebf..7b5caa4 100644 (file)
@@ -52,11 +52,12 @@ USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = KEYBOARD_IN_EPNUM,
-                               .ReportINEndpointSize         = HID_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = KEYBOARD_IN_EPADDR,
+                                               .Size                 = HID_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevKeyboardHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevKeyboardHIDReportBuffer),
                        },
@@ -72,10 +73,12 @@ USB_ClassInfo_HID_Device_t Mouse_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 1,
-
-                               .ReportINEndpointNumber       = MOUSE_IN_EPNUM,
-                               .ReportINEndpointSize         = HID_EPSIZE,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = MOUSE_IN_EPADDR,
+                                               .Size                 = HID_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevMouseHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevMouseHIDReportBuffer),
                        },
index f08cdc7..f80678f 100644 (file)
@@ -194,10 +194,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | HID_IN_EPNUM),
+                       .EndpointAddress        = HID_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index f579edf..5632aa8 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the HID reporting IN endpoint. */
-               #define HID_IN_EPNUM              1
+               /** Endpoint address of the HID reporting IN endpoint. */
+               #define HID_IN_EPADDR             (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of each of the HID reporting IN endpoint. */
                #define HID_EPSIZE                8
index 7197959..c0526ab 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Device_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = HID_IN_EPNUM,
-                               .ReportINEndpointSize         = HID_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = HID_IN_EPADDR,
+                                               .Size                 = HID_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevHIDReportBuffer),
                        },
index 9ad0e86..44db1ee 100644 (file)
@@ -199,10 +199,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_OUT | MIDI_STREAM_OUT_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_OUT_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
@@ -224,10 +224,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_IN | MIDI_STREAM_IN_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_IN_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
index c5dc2e2..8384444 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
-               #define MIDI_STREAM_IN_EPNUM        2
+               /** Endpoint address of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
+               #define MIDI_STREAM_IN_EPADDR       (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
-               #define MIDI_STREAM_OUT_EPNUM       1
+               /** Endpoint address of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
+               #define MIDI_STREAM_OUT_EPADDR      (ENDPOINT_DIR_OUT | 1)
 
                /** Endpoint size in bytes of the Audio isochronous streaming data IN and OUT endpoints. */
                #define MIDI_STREAM_EPSIZE          64
index 317c37d..6a117ab 100644 (file)
@@ -45,14 +45,18 @@ USB_ClassInfo_MIDI_Device_t Keyboard_MIDI_Interface =
                .Config =
                        {
                                .StreamingInterfaceNumber = 1,
-
-                               .DataINEndpointNumber      = MIDI_STREAM_IN_EPNUM,
-                               .DataINEndpointSize        = MIDI_STREAM_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MIDI_STREAM_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MIDI_STREAM_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = MIDI_STREAM_IN_EPADDR,
+                                               .Size             = MIDI_STREAM_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint          =
+                                       {
+                                               .Address          = MIDI_STREAM_OUT_EPADDR,
+                                               .Size             = MIDI_STREAM_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
@@ -74,7 +78,7 @@ int main(void)
                MIDI_EventPacket_t ReceivedMIDIEvent;
                while (MIDI_Device_ReceiveEventPacket(&Keyboard_MIDI_Interface, &ReceivedMIDIEvent))
                {
-                       if ((ReceivedMIDIEvent.Command == (MIDI_COMMAND_NOTE_ON >> 4)) && (ReceivedMIDIEvent.Data3 > 0))
+                       if ((ReceivedMIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_ON)) && (ReceivedMIDIEvent.Data3 > 0))
                          LEDs_SetAllLEDs(ReceivedMIDIEvent.Data2 > 64 ? LEDS_LED1 : LEDS_LED2);
                        else
                          LEDs_SetAllLEDs(LEDS_NO_LEDS);
@@ -151,8 +155,7 @@ void CheckJoystickMovement(void)
        {
                MIDI_EventPacket_t MIDIEvent = (MIDI_EventPacket_t)
                        {
-                               .CableNumber = 0,
-                               .Command     = (MIDICommand >> 4),
+                               .Event       = MIDI_EVENT(0, MIDICommand),
 
                                .Data1       = MIDICommand | Channel,
                                .Data2       = MIDIPitch,
index fb82942..5c62f7f 100644 (file)
@@ -118,20 +118,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 813f995..84879e8 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
index 6a720f9..0ba06a5 100644 (file)
@@ -45,15 +45,18 @@ USB_ClassInfo_MS_Device_t Disk_MS_Interface =
                .Config =
                        {
                                .InterfaceNumber           = 0,
-
-                               .DataINEndpointNumber      = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize        = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
-
+                               .DataINEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_IN_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
+                               .DataOUTEndpoint           =
+                                       {
+                                               .Address           = MASS_STORAGE_OUT_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
                                .TotalLUNs                 = TOTAL_LUNS,
                        },
        };
index 2790903..6818a7a 100644 (file)
@@ -133,20 +133,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID_KeyboardInterface =
@@ -180,10 +180,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_EPNUM),
+                       .EndpointAddress        = KEYBOARD_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = KEYBOARD_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index 86f6cc4..fb1a379 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the Keyboard HID reporting IN endpoint. */
-               #define KEYBOARD_EPNUM               1
+               /** Endpoint address of the Keyboard HID reporting IN endpoint. */
+               #define KEYBOARD_EPADDR              (ENDPOINT_DIR_IN  | 1)
 
                /** Size in bytes of the Keyboard HID reporting IN endpoint. */
                #define KEYBOARD_EPSIZE              8
 
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM        3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR       (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM       4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR      (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE       64
index bfdf09c..7e12a5d 100644 (file)
@@ -46,15 +46,18 @@ USB_ClassInfo_MS_Device_t Disk_MS_Interface =
                .Config =
                        {
                                .InterfaceNumber           = 0,
-
-                               .DataINEndpointNumber      = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize        = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
-
+                               .DataINEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_IN_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
+                               .DataOUTEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_OUT_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
                                .TotalLUNs                 = TOTAL_LUNS,
                        },
        };
@@ -71,11 +74,12 @@ USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 1,
-
-                               .ReportINEndpointNumber       = KEYBOARD_EPNUM,
-                               .ReportINEndpointSize         = KEYBOARD_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = KEYBOARD_EPADDR,
+                                               .Size                 = KEYBOARD_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevKeyboardHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevKeyboardHIDReportBuffer),
                        },
index 1a7af87..174d238 100644 (file)
@@ -136,10 +136,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_EPNUM),
+                       .EndpointAddress        = MOUSE_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MOUSE_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index da78dd0..abcd938 100644 (file)
 
                #include <avr/pgmspace.h>
 
+       /* Macros: */
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPADDR              (ENDPOINT_DIR_IN | 1)
+
+               /** Size in bytes of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPSIZE              8
+
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
                 *  application code, as the configuration descriptor contains several sub-descriptors which
                USB_Descriptor_Endpoint_t             HID_ReportINEndpoint;
                } USB_Descriptor_Configuration_t;
 
-       /* Macros: */
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPNUM               1
-
-               /** Size in bytes of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPSIZE              8
-
        /* Function Prototypes: */
                uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
                                                    const uint8_t wIndex,
index 04d4268..00cadb4 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Mouse_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = MOUSE_EPNUM,
-                               .ReportINEndpointSize         = MOUSE_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = MOUSE_EPADDR,
+                                               .Size                 = MOUSE_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevMouseHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevMouseHIDReportBuffer),
                        },
index 41bc4b5..d1ca1df 100644 (file)
@@ -131,7 +131,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -157,20 +157,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .RNDIS_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 7c40d87..6301b83 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         3
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   1
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   2
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 2)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 2a8ba97..37fb817 100644 (file)
@@ -45,19 +45,24 @@ USB_ClassInfo_RNDIS_Device_t Ethernet_RNDIS_Interface =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
-
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                                .AdapterVendorDescription       = "LUFA RNDIS Demo Adapter",
                                .AdapterMACAddress              = {ADAPTER_MAC_ADDRESS},
                        },
index f4e9fb3..9dcf4e4 100644 (file)
@@ -143,7 +143,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -169,20 +169,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index fb69344..af9183e 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index c3e16ed..8b11c29 100644 (file)
@@ -44,19 +44,25 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
        {
                .Config =
                        {
-                               .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .ControlInterfaceNumber   = 0,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
index 299ddbd..cfccac0 100644 (file)
@@ -157,7 +157,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -183,20 +183,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_Interface =
@@ -219,20 +219,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index b4b5ef6..544a2b5 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         1
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   2
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   3
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 3)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
                /** Size in bytes of the CDC data IN and OUT endpoints. */
                #define CDC_TXRX_EPSIZE                16
 
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          4
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 4)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         5
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 5)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
index d8ffea8..14d6abd 100644 (file)
@@ -45,18 +45,24 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                        },
        };
 
@@ -69,15 +75,18 @@ USB_ClassInfo_MS_Device_t Disk_MS_Interface =
                .Config =
                        {
                                .InterfaceNumber                = 2,
-
-                               .DataINEndpointNumber           = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize             = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize            = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = MASS_STORAGE_IN_EPADDR,
+                                               .Size                   = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = MASS_STORAGE_OUT_EPADDR,
+                                               .Size                   = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                                .TotalLUNs                      = TOTAL_LUNS,
                        },
        };
index af67456..9997121 100644 (file)
@@ -176,7 +176,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -202,20 +202,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID_Interface =
@@ -249,10 +249,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_EPNUM),
+                       .EndpointAddress        = MOUSE_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MOUSE_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 2509314..06cfd45 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
@@ -57,8 +57,8 @@
                /** Size in bytes of the CDC data IN and OUT endpoints. */
                #define CDC_TXRX_EPSIZE                16
 
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPNUM                    1
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPADDR                   (ENDPOINT_DIR_IN  | 1)
 
                /** Size in bytes of the Mouse HID reporting IN endpoint. */
                #define MOUSE_EPSIZE                   8
index f2d6754..dbbc8e7 100644 (file)
@@ -45,18 +45,24 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                        },
        };
 
@@ -72,11 +78,12 @@ USB_ClassInfo_HID_Device_t Mouse_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber                = 2,
-
-                               .ReportINEndpointNumber         = MOUSE_EPNUM,
-                               .ReportINEndpointSize           = MOUSE_EPSIZE,
-                               .ReportINEndpointDoubleBank     = false,
-
+                               .ReportINEndpoint               =
+                                       {
+                                               .Address                = MOUSE_EPADDR,
+                                               .Size                   = MOUSE_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                                .PrevReportINBuffer             = PrevMouseHIDReportBuffer,
                                .PrevReportINBufferSize         = sizeof(PrevMouseHIDReportBuffer),
                        },
index 533c921..cc1a094 100644 (file)
@@ -89,7 +89,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        Header:                 {Size: sizeof(USB_Descriptor_Endpoint_t), Type: DTYPE_Endpoint},
 
-                       EndpointAddress:        (ENDPOINT_DIR_IN | SIDESHOW_IN_EPNUM),
+                       EndpointAddress:        SIDESHOW_IN_EPADDR,
                        Attributes:             EP_TYPE_BULK,
                        EndpointSize:           SIDESHOW_IO_EPSIZE,
                        PollingIntervalMS:      0x00
@@ -99,7 +99,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        Header:                 {Size: sizeof(USB_Descriptor_Endpoint_t), Type: DTYPE_Endpoint},
 
-                       EndpointAddress:        (ENDPOINT_DIR_OUT | SIDESHOW_OUT_EPNUM),
+                       EndpointAddress:        SIDESHOW_OUT_EPADDR,
                        Attributes:             EP_TYPE_BULK,
                        EndpointSize:           SIDESHOW_IO_EPSIZE,
                        PollingIntervalMS:      0x00
index 6c9c6e3..1725a79 100644 (file)
@@ -39,8 +39,8 @@
                #include "Sideshow.h"
 
        /* Macros: */
-               #define SIDESHOW_IN_EPNUM          3
-               #define SIDESHOW_OUT_EPNUM         4
+               #define SIDESHOW_IN_EPADDR         3
+               #define SIDESHOW_OUT_EPADDR        4
                #define SIDESHOW_IO_EPSIZE         64
 
        /* Type Defines: */
index 4634036..3e23924 100644 (file)
@@ -47,7 +47,7 @@ void Sideshow_ProcessCommandPacket(void)
 {
        SideShow_PacketHeader_t PacketHeader;
 
-       Endpoint_SelectEndpoint(SIDESHOW_OUT_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_OUT_EPADDR);
        Endpoint_Read_Stream_LE(&PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
 
        PacketHeader.Type.TypeFields.Response = true;
@@ -110,7 +110,7 @@ void Sideshow_ProcessCommandPacket(void)
                        PacketHeader.Length   = sizeof(SideShow_PacketHeader_t);
                        PacketHeader.Type.TypeFields.NAK = true;
 
-                       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+                       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
                        Endpoint_Write_Stream_LE(&PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
                        Endpoint_ClearIN();
 
@@ -122,7 +122,7 @@ static void SideShow_Ping(SideShow_PacketHeader_t* const PacketHeader)
 {
        Endpoint_ClearOUT();
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -137,7 +137,7 @@ static void SideShow_Sync(SideShow_PacketHeader_t* const PacketHeader)
        if (!(GUID_COMPARE(&ProtocolGUID, (uint32_t[])STANDARD_PROTOCOL_GUID)))
          PacketHeader->Type.TypeFields.NAK = true;
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_Write_Stream_LE(&ProtocolGUID, sizeof(GUID_t), NULL);
        Endpoint_ClearIN();
@@ -149,7 +149,7 @@ static void SideShow_GetCurrentUser(SideShow_PacketHeader_t* const PacketHeader)
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t) + sizeof(uint32_t) + UserSID.LengthInBytes;
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        SideShow_Write_Unicode_String(&UserSID);
        Endpoint_ClearIN();
@@ -162,7 +162,7 @@ static void SideShow_SetCurrentUser(SideShow_PacketHeader_t* const PacketHeader)
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -254,7 +254,7 @@ static void SideShow_GetCapabilities(SideShow_PacketHeader_t* const PacketHeader
                                           Property.PropertyGUID.Chunks[2],  Property.PropertyGUID.Chunks[3]);
        }
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
 
        if (!(PacketHeader->Type.TypeFields.NAK))
@@ -288,7 +288,7 @@ static void SideShow_GetString(SideShow_PacketHeader_t* const PacketHeader,
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t) +
                               sizeof(uint32_t) + ((Unicode_String_t*)UnicodeStruct)->LengthInBytes;
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        SideShow_Write_Unicode_String(UnicodeStruct);
        Endpoint_ClearIN();
@@ -309,7 +309,7 @@ static void SideShow_GetApplicationOrder(SideShow_PacketHeader_t* const PacketHe
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t) +
                               sizeof(uint32_t) + (TotalApplications * sizeof(GUID_t));
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_Write_32_LE(TotalApplications);
 
@@ -330,7 +330,7 @@ static void SideShow_GetSupportedEndpoints(SideShow_PacketHeader_t* const Packet
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t) + sizeof(uint32_t) + sizeof(GUID_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_Write_32_LE(1);
        Endpoint_Write_Stream_LE(&SupportedEndpointGUID, sizeof(GUID_t), NULL);
@@ -377,7 +377,7 @@ static void SideShow_AddApplication(SideShow_PacketHeader_t* const PacketHeader)
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -398,7 +398,7 @@ static void SideShow_DeleteApplication(SideShow_PacketHeader_t* const PacketHead
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -410,7 +410,7 @@ static void SideShow_DeleteAllApplications(SideShow_PacketHeader_t* const Packet
        for (uint8_t App = 0; App < MAX_APPLICATIONS; App++)
          InstalledApplications[App].InUse = false;
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -440,7 +440,7 @@ static void SideShow_AddContent(SideShow_PacketHeader_t* const PacketHeader)
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -465,7 +465,7 @@ static void SideShow_DeleteContent(SideShow_PacketHeader_t* const PacketHeader)
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
@@ -488,7 +488,7 @@ static void SideShow_DeleteAllContent(SideShow_PacketHeader_t* const PacketHeade
 
        PacketHeader->Length = sizeof(SideShow_PacketHeader_t);
 
-       Endpoint_SelectEndpoint(SIDESHOW_IN_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_IN_EPADDR);
        Endpoint_Write_Stream_LE(PacketHeader, sizeof(SideShow_PacketHeader_t), NULL);
        Endpoint_ClearIN();
 }
index 3bc58d3..41009f3 100644 (file)
@@ -101,10 +101,8 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup Sideshow Data Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(SIDESHOW_IN_EPNUM,  EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   SIDESHOW_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(SIDESHOW_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   SIDESHOW_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(SIDESHOW_IN_EPADDR,  EP_TYPE_BULK, SIDESHOW_IO_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(SIDESHOW_OUT_EPADDR, EP_TYPE_BULK, SIDESHOW_IO_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -142,7 +140,7 @@ void SideShow_Task(void)
          return;
 
        /* Select the SideShow data out endpoint */
-       Endpoint_SelectEndpoint(SIDESHOW_OUT_EPNUM);
+       Endpoint_SelectEndpoint(SIDESHOW_OUT_EPADDR);
 
        /* Check to see if a new SideShow message has been received */
        if (Endpoint_IsReadWriteAllowed())
index 14be2ec..bf16ab0 100644 (file)
@@ -119,27 +119,27 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | TMC_OUT_EPNUM),
+                       .EndpointAddress        = TMC_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = TMC_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .TM_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | TMC_IN_EPNUM),
+                       .EndpointAddress        = TMC_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = TMC_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .TM_NotificationEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | TMC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = TMC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = TMC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
index 8876f73..e45654a 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>\r
 \r
        /* Macros: */\r
-               /** Endpoint number of the TMC notification IN endpoint. */\r
-               #define TMC_NOTIFICATION_EPNUM  2       \r
+               /** Endpoint address of the TMC notification IN endpoint. */\r
+               #define TMC_NOTIFICATION_EPADDR  (ENDPOINT_DIR_IN  | 2)\r
 \r
-               /** Endpoint number of the TMC device-to-host data IN endpoint. */\r
-               #define TMC_IN_EPNUM            3       \r
+               /** Endpoint address of the TMC device-to-host data IN endpoint. */\r
+               #define TMC_IN_EPADDR            (ENDPOINT_DIR_IN  | 3)\r
 \r
-               /** Endpoint number of the TMC host-to-device data OUT endpoint. */\r
-               #define TMC_OUT_EPNUM           4       \r
+               /** Endpoint address of the TMC host-to-device data OUT endpoint. */\r
+               #define TMC_OUT_EPADDR           (ENDPOINT_DIR_OUT | 4)\r
 \r
                /** Size in bytes of the TMC data endpoints. */\r
-               #define TMC_IO_EPSIZE           64\r
+               #define TMC_IO_EPSIZE            64\r
 \r
                /** Size in bytes of the TMC notification endpoint. */\r
-               #define TMC_NOTIFICATION_EPSIZE 8\r
+               #define TMC_NOTIFICATION_EPSIZE  8\r
 \r
        /* Type Defines: */\r
                /** Type define for the device configuration descriptor structure. This must be defined in the\r
index c77b01e..5102f10 100644 (file)
@@ -129,12 +129,9 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup TMC In, Out and Notification Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   TMC_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_IN_EPNUM,  EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   TMC_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   TMC_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT, TMC_IO_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_IN_EPADDR,  EP_TYPE_BULK, TMC_IO_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(TMC_OUT_EPADDR, EP_TYPE_BULK, TMC_IO_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -418,7 +415,7 @@ bool ReadTMCHeader(TMC_MessageHeader_t* const MessageHeader)
        uint8_t  ErrorCode;
 
        /* Select the Data Out endpoint */
-       Endpoint_SelectEndpoint(TMC_OUT_EPNUM);
+       Endpoint_SelectEndpoint(TMC_OUT_EPADDR);
 
        /* Abort if no command has been sent from the host */
        if (!(Endpoint_IsOUTReceived()))
@@ -450,7 +447,7 @@ bool WriteTMCHeader(TMC_MessageHeader_t* const MessageHeader)
        MessageHeader->InverseTag = ~CurrentTransferTag;
 
        /* Select the Data In endpoint */
-       Endpoint_SelectEndpoint(TMC_IN_EPNUM);
+       Endpoint_SelectEndpoint(TMC_IN_EPADDR);
 
        /* Send the command header to the host */
        BytesTransferred = 0;
index 60eeaf6..eb9c4b5 100644 (file)
@@ -118,8 +118,7 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup Audio Stream Endpoint */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(AUDIO_STREAM_EPNUM, EP_TYPE_ISOCHRONOUS, ENDPOINT_DIR_IN,
-                                                   AUDIO_STREAM_EPSIZE, ENDPOINT_BANK_DOUBLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(AUDIO_STREAM_EPADDR, EP_TYPE_ISOCHRONOUS, AUDIO_STREAM_EPSIZE, 2);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -165,7 +164,7 @@ void EVENT_USB_Device_ControlRequest(void)
                                uint8_t EndpointControl = (USB_ControlRequest.wValue >> 8);
 
                                /* Only handle SET CURRENT requests to the audio endpoint's sample frequency property */
-                               if ((EndpointAddress == (ENDPOINT_DIR_IN | AUDIO_STREAM_EPNUM)) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
+                               if ((EndpointAddress == AUDIO_STREAM_EPADDR) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
                                {
                                        uint8_t SampleRate[3];
 
@@ -190,7 +189,7 @@ void EVENT_USB_Device_ControlRequest(void)
                                uint8_t EndpointControl = (USB_ControlRequest.wValue >> 8);
 
                                /* Only handle GET CURRENT requests to the audio endpoint's sample frequency property */
-                               if ((EndpointAddress == (ENDPOINT_DIR_IN | AUDIO_STREAM_EPNUM)) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
+                               if ((EndpointAddress == AUDIO_STREAM_EPADDR) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
                                {
                                        uint8_t SampleRate[3];
 
@@ -215,7 +214,7 @@ ISR(TIMER0_COMPA_vect, ISR_BLOCK)
        uint8_t PrevEndpoint = Endpoint_GetCurrentEndpoint();
 
        /* Select the audio stream endpoint */
-       Endpoint_SelectEndpoint(AUDIO_STREAM_EPNUM);
+       Endpoint_SelectEndpoint(AUDIO_STREAM_EPADDR);
 
        /* Check if the current endpoint can be written to and that the audio interface is enabled */
        if (Endpoint_IsINReady() && StreamingAudioInterfaceSelected)
index 0b16522..ee37aff 100644 (file)
@@ -220,7 +220,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_IN | AUDIO_STREAM_EPNUM),
+                                       .EndpointAddress     = AUDIO_STREAM_EPADDR,
                                        .Attributes          = (EP_TYPE_ISOCHRONOUS | ENDPOINT_ATTR_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = AUDIO_STREAM_EPSIZE,
                                        .PollingIntervalMS   = 0x01
index ac0a536..4680294 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the Audio isochronous streaming data endpoint. */
-               #define AUDIO_STREAM_EPNUM           1
+               /** Endpoint address of the Audio isochronous streaming data IN endpoint. */
+               #define AUDIO_STREAM_EPADDR          (ENDPOINT_DIR_IN | 1)
 
-               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. The Windows audio stack requires
-                *  at least 192 bytes for correct output, thus the smaller 128 byte maximum endpoint size on some of the smaller
-                *  USB AVR models will result in unavoidable distorted output.
-                */
-               #define AUDIO_STREAM_EPSIZE          ENDPOINT_MAX_SIZE(AUDIO_STREAM_EPNUM)
+               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. */
+               #define AUDIO_STREAM_EPSIZE           256
 
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
index 813108a..ebf4ad5 100644 (file)
@@ -144,8 +144,7 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup Audio Stream Endpoint */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(AUDIO_STREAM_EPNUM, EP_TYPE_ISOCHRONOUS, ENDPOINT_DIR_OUT,
-                                                   AUDIO_STREAM_EPSIZE, ENDPOINT_BANK_DOUBLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(AUDIO_STREAM_EPADDR, EP_TYPE_ISOCHRONOUS, AUDIO_STREAM_EPSIZE, 2);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -191,7 +190,7 @@ void EVENT_USB_Device_ControlRequest(void)
                                uint8_t EndpointControl = (USB_ControlRequest.wValue >> 8);
 
                                /* Only handle SET CURRENT requests to the audio endpoint's sample frequency property */
-                               if ((EndpointAddress == (ENDPOINT_DIR_OUT | AUDIO_STREAM_EPNUM)) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
+                               if ((EndpointAddress == AUDIO_STREAM_EPADDR) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
                                {
                                        uint8_t SampleRate[3];
 
@@ -216,7 +215,7 @@ void EVENT_USB_Device_ControlRequest(void)
                                uint8_t EndpointControl = (USB_ControlRequest.wValue >> 8);
 
                                /* Only handle GET CURRENT requests to the audio endpoint's sample frequency property */
-                               if ((EndpointAddress == (ENDPOINT_DIR_OUT | AUDIO_STREAM_EPNUM)) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
+                               if ((EndpointAddress == AUDIO_STREAM_EPADDR) && (EndpointControl == AUDIO_EPCONTROL_SamplingFreq))
                                {
                                        uint8_t SampleRate[3];
 
@@ -241,7 +240,7 @@ ISR(TIMER0_COMPA_vect, ISR_BLOCK)
        uint8_t PrevEndpoint = Endpoint_GetCurrentEndpoint();
 
        /* Select the audio stream endpoint */
-       Endpoint_SelectEndpoint(AUDIO_STREAM_EPNUM);
+       Endpoint_SelectEndpoint(AUDIO_STREAM_EPADDR);
 
        /* Check if the current endpoint can be read from (contains a packet) and the host is sending data */
        if (Endpoint_IsOUTReceived() && StreamingAudioInterfaceSelected)
index 7f12fc7..12a5a15 100644 (file)
@@ -220,7 +220,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_OUT | AUDIO_STREAM_EPNUM),
+                                       .EndpointAddress     = AUDIO_STREAM_EPADDR,
                                        .Attributes          = (EP_TYPE_ISOCHRONOUS | ENDPOINT_ATTR_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = AUDIO_STREAM_EPSIZE,
                                        .PollingIntervalMS   = 0x01
index ac0a536..e0c7567 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the Audio isochronous streaming data endpoint. */
-               #define AUDIO_STREAM_EPNUM           1
+               /** Endpoint address of the Audio isochronous streaming data OUT endpoint. */
+               #define AUDIO_STREAM_EPADDR          (ENDPOINT_DIR_OUT | 1)
 
-               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. The Windows audio stack requires
-                *  at least 192 bytes for correct output, thus the smaller 128 byte maximum endpoint size on some of the smaller
-                *  USB AVR models will result in unavoidable distorted output.
-                */
-               #define AUDIO_STREAM_EPSIZE          ENDPOINT_MAX_SIZE(AUDIO_STREAM_EPNUM)
+               /** Endpoint size in bytes of the Audio isochronous streaming data endpoint. */
+               #define AUDIO_STREAM_EPSIZE           256
 
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
index 5df6808..1a4860a 100644 (file)
@@ -157,7 +157,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC1_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC1_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -183,20 +183,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC1_RX_EPNUM),
+                       .EndpointAddress        = CDC1_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC1_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC1_TX_EPNUM),
+                       .EndpointAddress        = CDC1_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC2_IAD =
@@ -258,7 +258,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC2_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC2_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -284,20 +284,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC2_RX_EPNUM),
+                       .EndpointAddress        = CDC2_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC2_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC2_TX_EPNUM),
+                       .EndpointAddress        = CDC2_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 0a172d8..fee2c85 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the first CDC interface's device-to-host data IN endpoint. */
-               #define CDC1_TX_EPNUM                  1
+               /** Endpoint address of the first CDC interface's device-to-host data IN endpoint. */
+               #define CDC1_TX_EPADDR                 (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the first CDC interface's host-to-device data OUT endpoint. */
-               #define CDC1_RX_EPNUM                  2
+               /** Endpoint address of the first CDC interface's host-to-device data OUT endpoint. */
+               #define CDC1_RX_EPADDR                 (ENDPOINT_DIR_OUT | 2)
 
-               /** Endpoint number of the first CDC interface's device-to-host notification IN endpoint. */
-               #define CDC1_NOTIFICATION_EPNUM        3
+               /** Endpoint address of the first CDC interface's device-to-host notification IN endpoint. */
+               #define CDC1_NOTIFICATION_EPADDR       (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the second CDC interface's device-to-host data IN endpoint. */
-               #define CDC2_TX_EPNUM                  4
+               /** Endpoint address of the second CDC interface's device-to-host data IN endpoint. */
+               #define CDC2_TX_EPADDR                 (ENDPOINT_DIR_IN  | 4)
 
-               /** Endpoint number of the second CDC interface's host-to-device data OUT endpoint. */
-               #define CDC2_RX_EPNUM                  5
+               /** Endpoint address of the second CDC interface's host-to-device data OUT endpoint. */
+               #define CDC2_RX_EPADDR                 (ENDPOINT_DIR_OUT | 5)
 
-               /** Endpoint number of the second CDC interface's device-to-host notification IN endpoint. */
-               #define CDC2_NOTIFICATION_EPNUM        6
+               /** Endpoint address of the second CDC interface's device-to-host notification IN endpoint. */
+               #define CDC2_NOTIFICATION_EPADDR       (ENDPOINT_DIR_IN | 6)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoints. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 9208b2c..2db6f4e 100644 (file)
@@ -123,20 +123,14 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup first CDC Interface's Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_TX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_RX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   CDC_NOTIFICATION_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_TX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_RX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC1_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT, CDC_NOTIFICATION_EPSIZE, 1);
 
        /* Setup second CDC Interface's Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_TX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_RX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   CDC_NOTIFICATION_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_TX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_RX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC2_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT, CDC_NOTIFICATION_EPSIZE, 1);
 
        /* Reset line encoding baud rates so that the host knows to send new values */
        LineEncoding1.BaudRateBPS = 0;
@@ -224,7 +218,7 @@ void CDC1_Task(void)
                ActionSent = true;
 
                /* Select the Serial Tx Endpoint */
-               Endpoint_SelectEndpoint(CDC1_TX_EPNUM);
+               Endpoint_SelectEndpoint(CDC1_TX_EPADDR);
 
                /* Write the String to the Endpoint */
                Endpoint_Write_Stream_LE(ReportString, strlen(ReportString), NULL);
@@ -240,7 +234,7 @@ void CDC1_Task(void)
        }
 
        /* Select the Serial Rx Endpoint */
-       Endpoint_SelectEndpoint(CDC1_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC1_RX_EPADDR);
 
        /* Throw away any received data from the host */
        if (Endpoint_IsOUTReceived())
@@ -257,7 +251,7 @@ void CDC2_Task(void)
          return;
 
        /* Select the Serial Rx Endpoint */
-       Endpoint_SelectEndpoint(CDC2_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC2_RX_EPADDR);
 
        /* Check to see if any data has been received */
        if (Endpoint_IsOUTReceived())
@@ -275,7 +269,7 @@ void CDC2_Task(void)
                Endpoint_ClearOUT();
 
                /* Select the Serial Tx Endpoint */
-               Endpoint_SelectEndpoint(CDC2_TX_EPNUM);
+               Endpoint_SelectEndpoint(CDC2_TX_EPADDR);
 
                /* Write the received data to the endpoint */
                Endpoint_Write_Stream_LE(&Buffer, DataLength, NULL);
index 2dcdcf0..3a6f135 100644 (file)
@@ -143,20 +143,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | GENERIC_IN_EPNUM),
+                       .EndpointAddress        = GENERIC_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = GENERIC_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID_ReportOUTEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | GENERIC_OUT_EPNUM),
+                       .EndpointAddress        = GENERIC_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = GENERIC_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 4647a05..e47220a 100644 (file)
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Generic HID reporting IN endpoint. */
-               #define GENERIC_IN_EPNUM          1
+               /** Endpoint address of the Generic HID reporting IN endpoint. */
+               #define GENERIC_IN_EPADDR         (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the Generic HID reporting OUT endpoint. */
-               #define GENERIC_OUT_EPNUM         2
+               /** Endpoint address of the Generic HID reporting OUT endpoint. */
+               #define GENERIC_OUT_EPADDR        (ENDPOINT_DIR_OUT | 2)
 
                /** Size in bytes of the Generic HID reporting endpoint. */
                #define GENERIC_EPSIZE            8
index 4d61acf..c36c33f 100644 (file)
@@ -95,10 +95,8 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup HID Report Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(GENERIC_IN_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   GENERIC_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(GENERIC_OUT_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_OUT,
-                                                   GENERIC_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(GENERIC_IN_EPADDR, EP_TYPE_INTERRUPT, GENERIC_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(GENERIC_OUT_EPADDR, EP_TYPE_INTERRUPT, GENERIC_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -200,7 +198,7 @@ void HID_Task(void)
        if (USB_DeviceState != DEVICE_STATE_Configured)
          return;
 
-       Endpoint_SelectEndpoint(GENERIC_OUT_EPNUM);
+       Endpoint_SelectEndpoint(GENERIC_OUT_EPADDR);
 
        /* Check to see if a packet has been sent from the host */
        if (Endpoint_IsOUTReceived())
@@ -222,7 +220,7 @@ void HID_Task(void)
                Endpoint_ClearOUT();
        }
 
-       Endpoint_SelectEndpoint(GENERIC_IN_EPNUM);
+       Endpoint_SelectEndpoint(GENERIC_IN_EPADDR);
 
        /* Check to see if the host is ready to accept another packet */
        if (Endpoint_IsINReady())
index 272595d..bcadacd 100644 (file)
@@ -155,10 +155,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | JOYSTICK_EPNUM),
+                       .EndpointAddress        = JOYSTICK_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = JOYSTICK_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 93b315b..bc90fb7 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Joystick HID reporting IN endpoint. */
-               #define JOYSTICK_EPNUM            1
+               /** Endpoint address of the Joystick HID reporting IN endpoint. */
+               #define JOYSTICK_EPADDR           (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the Joystick HID reporting IN endpoint. */
                #define JOYSTICK_EPSIZE           8
index 9e84b61..cfdfaae 100644 (file)
@@ -96,8 +96,7 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup HID Report Endpoint */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(JOYSTICK_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   JOYSTICK_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(JOYSTICK_EPADDR, EP_TYPE_INTERRUPT, JOYSTICK_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -183,7 +182,7 @@ void HID_Task(void)
          return;
 
        /* Select the Joystick Report Endpoint */
-       Endpoint_SelectEndpoint(JOYSTICK_EPNUM);
+       Endpoint_SelectEndpoint(JOYSTICK_EPADDR);
 
        /* Check to see if the host is ready for another packet */
        if (Endpoint_IsINReady())
index 46b9fde..f4e2942 100644 (file)
@@ -160,20 +160,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_IN_EPNUM),
+                       .EndpointAddress        = KEYBOARD_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = KEYBOARD_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID_ReportOUTEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | KEYBOARD_OUT_EPNUM),
+                       .EndpointAddress        = KEYBOARD_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = KEYBOARD_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 3c0ea17..2e1fe3c 100644 (file)
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Keyboard HID reporting IN endpoint. */
-               #define KEYBOARD_IN_EPNUM         1
+               /** Endpoint address of the Keyboard HID reporting IN endpoint. */
+               #define KEYBOARD_IN_EPADDR        (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the Keyboard HID reporting OUT endpoint. */
-               #define KEYBOARD_OUT_EPNUM        2
+               /** Endpoint address of the Keyboard HID reporting OUT endpoint. */
+               #define KEYBOARD_OUT_EPADDR       (ENDPOINT_DIR_OUT | 2)
 
                /** Size in bytes of the Keyboard HID reporting IN and OUT endpoints. */
                #define KEYBOARD_EPSIZE           8
index 45bf010..3755d09 100644 (file)
@@ -117,10 +117,8 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup HID Report Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_IN_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   KEYBOARD_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_OUT_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_OUT,
-                                                   KEYBOARD_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_IN_EPADDR, EP_TYPE_INTERRUPT, KEYBOARD_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_OUT_EPADDR, EP_TYPE_INTERRUPT, KEYBOARD_EPSIZE, 1);
 
        /* Turn on Start-of-Frame events for tracking HID report period expiry */
        USB_Device_EnableSOFEvents();
@@ -315,7 +313,7 @@ void SendNextReport(void)
        }
 
        /* Select the Keyboard Report Endpoint */
-       Endpoint_SelectEndpoint(KEYBOARD_IN_EPNUM);
+       Endpoint_SelectEndpoint(KEYBOARD_IN_EPADDR);
 
        /* Check if Keyboard Endpoint Ready for Read/Write and if we should send a new report */
        if (Endpoint_IsReadWriteAllowed() && SendReport)
@@ -335,7 +333,7 @@ void SendNextReport(void)
 void ReceiveNextReport(void)
 {
        /* Select the Keyboard LED Report Endpoint */
-       Endpoint_SelectEndpoint(KEYBOARD_OUT_EPNUM);
+       Endpoint_SelectEndpoint(KEYBOARD_OUT_EPADDR);
 
        /* Check if Keyboard LED Endpoint contains a packet */
        if (Endpoint_IsOUTReceived())
index 9d02fa4..a058373 100644 (file)
@@ -195,20 +195,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_IN_EPNUM),
+                       .EndpointAddress        = KEYBOARD_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID1_ReportOUTEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | KEYBOARD_OUT_EPNUM),
+                       .EndpointAddress        = KEYBOARD_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID2_MouseInterface =
@@ -242,10 +242,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_IN_EPNUM),
+                       .EndpointAddress        = MOUSE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 573cb65..178f5ed 100644 (file)
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Keyboard HID reporting IN endpoint. */
-               #define KEYBOARD_IN_EPNUM         1
+               /** Endpoint address of the Keyboard HID reporting IN endpoint. */
+               #define KEYBOARD_IN_EPADDR        (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the Keyboard HID reporting OUT endpoint. */
-               #define KEYBOARD_OUT_EPNUM        2
+               /** Endpoint address of the Keyboard HID reporting OUT endpoint. */
+               #define KEYBOARD_OUT_EPADDR       (ENDPOINT_DIR_OUT | 2)
 
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_IN_EPNUM            3
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_IN_EPADDR           (ENDPOINT_DIR_IN  | 3)
 
                /** Size in bytes of each of the HID reporting IN and OUT endpoints. */
                #define HID_EPSIZE                8
index 4de6f64..a916659 100644 (file)
@@ -104,14 +104,11 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup Keyboard HID Report Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_IN_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   HID_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_OUT_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_OUT,
-                                                   HID_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_IN_EPADDR, EP_TYPE_INTERRUPT, HID_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(KEYBOARD_OUT_EPADDR, EP_TYPE_INTERRUPT, HID_EPSIZE, 1);
 
        /* Setup Mouse HID Report Endpoint */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MOUSE_IN_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   HID_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MOUSE_IN_EPADDR, EP_TYPE_INTERRUPT, HID_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -236,7 +233,7 @@ void Keyboard_HID_Task(void)
        }
 
        /* Select the Keyboard Report Endpoint */
-       Endpoint_SelectEndpoint(KEYBOARD_IN_EPNUM);
+       Endpoint_SelectEndpoint(KEYBOARD_IN_EPADDR);
 
        /* Check if Keyboard Endpoint Ready for Read/Write */
        if (Endpoint_IsReadWriteAllowed())
@@ -252,7 +249,7 @@ void Keyboard_HID_Task(void)
        }
 
        /* Select the Keyboard LED Report Endpoint */
-       Endpoint_SelectEndpoint(KEYBOARD_OUT_EPNUM);
+       Endpoint_SelectEndpoint(KEYBOARD_OUT_EPADDR);
 
        /* Check if Keyboard LED Endpoint Ready for Read/Write */
        if (Endpoint_IsReadWriteAllowed())
@@ -294,7 +291,7 @@ void Mouse_HID_Task(void)
        }
 
        /* Select the Mouse Report Endpoint */
-       Endpoint_SelectEndpoint(MOUSE_IN_EPNUM);
+       Endpoint_SelectEndpoint(MOUSE_IN_EPADDR);
 
        /* Check if Mouse Endpoint Ready for Read/Write */
        if (Endpoint_IsReadWriteAllowed())
index 9ad0e86..44db1ee 100644 (file)
@@ -199,10 +199,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_OUT | MIDI_STREAM_OUT_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_OUT_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
@@ -224,10 +224,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_IN | MIDI_STREAM_IN_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_IN_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
index 5415a31..7947a46 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
-               #define MIDI_STREAM_IN_EPNUM        1
+               /** Endpoint address of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
+               #define MIDI_STREAM_IN_EPADDR       (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
-               #define MIDI_STREAM_OUT_EPNUM       2
+               /** Endpoint address of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
+               #define MIDI_STREAM_OUT_EPADDR      (ENDPOINT_DIR_OUT | 2)
 
                /** Endpoint size in bytes of the Audio isochronous streaming data IN and OUT endpoints. */
                #define MIDI_STREAM_EPSIZE          64
index a29a8c8..335c714 100644 (file)
@@ -94,10 +94,8 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup MIDI Data Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MIDI_STREAM_IN_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   MIDI_STREAM_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MIDI_STREAM_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   MIDI_STREAM_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MIDI_STREAM_IN_EPADDR, EP_TYPE_BULK, MIDI_STREAM_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MIDI_STREAM_OUT_EPADDR, EP_TYPE_BULK, MIDI_STREAM_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -114,7 +112,7 @@ void MIDI_Task(void)
        if (USB_DeviceState != DEVICE_STATE_Configured)
          return;
 
-       Endpoint_SelectEndpoint(MIDI_STREAM_IN_EPNUM);
+       Endpoint_SelectEndpoint(MIDI_STREAM_IN_EPADDR);
 
        if (Endpoint_IsINReady())
        {
@@ -162,8 +160,7 @@ void MIDI_Task(void)
                {
                        MIDI_EventPacket_t MIDIEvent = (MIDI_EventPacket_t)
                                {
-                                       .CableNumber = 0,
-                                       .Command     = (MIDICommand >> 4),
+                                       .Event       = MIDI_EVENT(0, MIDICommand),
 
                                        .Data1       = MIDICommand | Channel,
                                        .Data2       = MIDIPitch,
@@ -182,7 +179,7 @@ void MIDI_Task(void)
        }
 
        /* Select the MIDI OUT stream */
-       Endpoint_SelectEndpoint(MIDI_STREAM_OUT_EPNUM);
+       Endpoint_SelectEndpoint(MIDI_STREAM_OUT_EPADDR);
 
        /* Check if a MIDI command has been received */
        if (Endpoint_IsOUTReceived())
@@ -193,7 +190,7 @@ void MIDI_Task(void)
                Endpoint_Read_Stream_LE(&MIDIEvent, sizeof(MIDIEvent), NULL);
 
                /* Check to see if the sent command is a note on message with a non-zero velocity */
-               if ((MIDIEvent.Command == (MIDI_COMMAND_NOTE_ON >> 4)) && (MIDIEvent.Data3 > 0))
+               if ((MIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_ON)) && (MIDIEvent.Data3 > 0))
                {
                        /* Change LEDs depending on the pitch of the sent note */
                        LEDs_SetAllLEDs(MIDIEvent.Data2 > 64 ? LEDS_LED1 : LEDS_LED2);
index fb82942..5c62f7f 100644 (file)
@@ -118,20 +118,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 0e7a91f..34a85f6 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
index 947636c..0e8e108 100644 (file)
@@ -118,10 +118,8 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup Mass Storage Data Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MASS_STORAGE_IN_EPNUM,  EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   MASS_STORAGE_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MASS_STORAGE_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   MASS_STORAGE_IO_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MASS_STORAGE_IN_EPADDR,  EP_TYPE_BULK, MASS_STORAGE_IO_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MASS_STORAGE_OUT_EPADDR, EP_TYPE_BULK, MASS_STORAGE_IO_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -180,7 +178,7 @@ void MassStorage_Task(void)
 
                /* Check direction of command, select Data IN endpoint if data is from the device */
                if (CommandBlock.Flags & MS_COMMAND_DIR_DATA_IN)
-                 Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPNUM);
+                 Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPADDR);
 
                /* Decode the received SCSI command, set returned status code */
                CommandStatus.Status = SCSI_DecodeSCSICommand() ? MS_SCSI_COMMAND_Pass : MS_SCSI_COMMAND_Fail;
@@ -206,13 +204,13 @@ void MassStorage_Task(void)
        if (IsMassStoreReset)
        {
                /* Reset the data endpoint banks */
-               Endpoint_ResetEndpoint(MASS_STORAGE_OUT_EPNUM);
-               Endpoint_ResetEndpoint(MASS_STORAGE_IN_EPNUM);
+               Endpoint_ResetEndpoint(MASS_STORAGE_OUT_EPADDR);
+               Endpoint_ResetEndpoint(MASS_STORAGE_IN_EPADDR);
 
-               Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPNUM);
+               Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPADDR);
                Endpoint_ClearStall();
                Endpoint_ResetDataToggle();
-               Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPNUM);
+               Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPADDR);
                Endpoint_ClearStall();
                Endpoint_ResetDataToggle();
 
@@ -231,7 +229,7 @@ static bool ReadInCommandBlock(void)
        uint16_t BytesTransferred;
 
        /* Select the Data Out endpoint */
-       Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPNUM);
+       Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPADDR);
 
        /* Abort if no command has been sent from the host */
        if (!(Endpoint_IsOUTReceived()))
@@ -256,7 +254,7 @@ static bool ReadInCommandBlock(void)
        {
                /* Stall both data pipes until reset by host */
                Endpoint_StallTransaction();
-               Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPNUM);
+               Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPADDR);
                Endpoint_StallTransaction();
 
                return false;
@@ -286,7 +284,7 @@ static void ReturnCommandStatus(void)
        uint16_t BytesTransferred;
 
        /* Select the Data Out endpoint */
-       Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPNUM);
+       Endpoint_SelectEndpoint(MASS_STORAGE_OUT_EPADDR);
 
        /* While data pipe is stalled, wait until the host issues a control request to clear the stall */
        while (Endpoint_IsStalled())
@@ -297,7 +295,7 @@ static void ReturnCommandStatus(void)
        }
 
        /* Select the Data In endpoint */
-       Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPNUM);
+       Endpoint_SelectEndpoint(MASS_STORAGE_IN_EPADDR);
 
        /* While data pipe is stalled, wait until the host issues a control request to clear the stall */
        while (Endpoint_IsStalled())
index d42fb83..03ea0e7 100644 (file)
@@ -155,10 +155,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_EPNUM),
+                       .EndpointAddress        = MOUSE_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MOUSE_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index da78dd0..abcd938 100644 (file)
 
                #include <avr/pgmspace.h>
 
+       /* Macros: */
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPADDR              (ENDPOINT_DIR_IN | 1)
+
+               /** Size in bytes of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPSIZE              8
+
        /* Type Defines: */
                /** Type define for the device configuration descriptor structure. This must be defined in the
                 *  application code, as the configuration descriptor contains several sub-descriptors which
                USB_Descriptor_Endpoint_t             HID_ReportINEndpoint;
                } USB_Descriptor_Configuration_t;
 
-       /* Macros: */
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPNUM               1
-
-               /** Size in bytes of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPSIZE              8
-
        /* Function Prototypes: */
                uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
                                                    const uint8_t wIndex,
index 98da9be..e9f92e4 100644 (file)
@@ -116,8 +116,7 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup HID Report Endpoint */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(MOUSE_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   MOUSE_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(MOUSE_EPADDR, EP_TYPE_INTERRUPT, MOUSE_EPSIZE, 1);
 
        /* Turn on Start-of-Frame events for tracking HID report period expiry */
        USB_Device_EnableSOFEvents();
@@ -271,7 +270,7 @@ void SendNextReport(void)
        }
 
        /* Select the Mouse Report Endpoint */
-       Endpoint_SelectEndpoint(MOUSE_EPNUM);
+       Endpoint_SelectEndpoint(MOUSE_EPADDR);
 
        /* Check if Mouse Endpoint Ready for Read/Write and if we should send a new report */
        if (Endpoint_IsReadWriteAllowed() && SendReport)
index 41bc4b5..d1ca1df 100644 (file)
@@ -131,7 +131,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -157,20 +157,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .RNDIS_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 9ffa526..6337335 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   1
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   2
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 2)
 
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         3
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 3)
 
                /** Size in bytes of the CDC data IN and OUT endpoints. */
                #define CDC_TXRX_EPSIZE                64
index a36ecf4..c041bb9 100644 (file)
@@ -104,12 +104,9 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup RNDIS Data Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_TX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_RX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   CDC_NOTIFICATION_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_TX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_RX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT, CDC_NOTIFICATION_EPSIZE, 1);
 
        /* Indicate endpoint configuration success or failure */
        LEDs_SetAllLEDs(ConfigSuccess ? LEDMASK_USB_READY : LEDMASK_USB_ERROR);
@@ -170,7 +167,7 @@ void EVENT_USB_Device_ControlRequest(void)
 void RNDIS_Task(void)
 {
        /* Select the notification endpoint */
-       Endpoint_SelectEndpoint(CDC_NOTIFICATION_EPNUM);
+       Endpoint_SelectEndpoint(CDC_NOTIFICATION_EPADDR);
 
        /* Check if a message response is ready for the host */
        if (Endpoint_IsINReady() && ResponseReady)
@@ -201,7 +198,7 @@ void RNDIS_Task(void)
                RNDIS_Packet_Message_t RNDISPacketHeader;
 
                /* Select the data OUT endpoint */
-               Endpoint_SelectEndpoint(CDC_RX_EPNUM);
+               Endpoint_SelectEndpoint(CDC_RX_EPADDR);
 
                /* Check if the data OUT endpoint contains data, and that the IN buffer is empty */
                if (Endpoint_IsOUTReceived() && !(FrameIN.FrameLength))
@@ -227,7 +224,7 @@ void RNDIS_Task(void)
                }
 
                /* Select the data IN endpoint */
-               Endpoint_SelectEndpoint(CDC_TX_EPNUM);
+               Endpoint_SelectEndpoint(CDC_TX_EPADDR);
 
                /* Check if the data IN endpoint is ready for more data, and that the IN buffer is full */
                if (Endpoint_IsINReady() && FrameOUT.FrameLength)
index f4e9fb3..9dcf4e4 100644 (file)
@@ -143,7 +143,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -169,20 +169,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 765345b..36ec8f9 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 93fd435..7d18548 100644 (file)
@@ -109,12 +109,9 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup CDC Data Endpoints */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPNUM, EP_TYPE_INTERRUPT, ENDPOINT_DIR_IN,
-                                                   CDC_NOTIFICATION_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_TX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_RX_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   CDC_TXRX_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_NOTIFICATION_EPADDR, EP_TYPE_INTERRUPT, CDC_NOTIFICATION_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_TX_EPADDR, EP_TYPE_BULK, CDC_TXRX_EPSIZE, 1);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(CDC_RX_EPADDR, EP_TYPE_BULK,  CDC_TXRX_EPSIZE, 1);
 
        /* Reset line encoding baud rate so that the host knows to send new values */
        LineEncoding.BaudRateBPS = 0;
@@ -201,7 +198,7 @@ void CDC_Task(void)
                ActionSent = true;
 
                /* Select the Serial Tx Endpoint */
-               Endpoint_SelectEndpoint(CDC_TX_EPNUM);
+               Endpoint_SelectEndpoint(CDC_TX_EPADDR);
 
                /* Write the String to the Endpoint */
                Endpoint_Write_Stream_LE(ReportString, strlen(ReportString), NULL);
@@ -225,7 +222,7 @@ void CDC_Task(void)
        }
 
        /* Select the Serial Rx Endpoint */
-       Endpoint_SelectEndpoint(CDC_RX_EPNUM);
+       Endpoint_SelectEndpoint(CDC_RX_EPADDR);
 
        /* Throw away any received data from the host */
        if (Endpoint_IsOUTReceived())
index 2ee35de..71643be 100644 (file)
@@ -136,10 +136,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MOUSE_EPNUM),
+                       .EndpointAddress        = MOUSE_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MOUSE_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index da78dd0..14cb8e9 100644 (file)
@@ -57,8 +57,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Mouse HID reporting IN endpoint. */
-               #define MOUSE_EPNUM               1
+               /** Endpoint address of the Mouse HID reporting IN endpoint. */
+               #define MOUSE_EPADDR              (ENDPOINT_DIR_IN | 1)
 
                /** Size in bytes of the Mouse HID reporting IN endpoint. */
                #define MOUSE_EPSIZE              8
index 16fc3fb..39a682a 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t Mouse_HID_Device_Interface =
                .Config =
                        {
                                .InterfaceNumber            = 0,
-
-                               .ReportINEndpointNumber     = MOUSE_EPNUM,
-                               .ReportINEndpointSize       = MOUSE_EPSIZE,
-                               .ReportINEndpointDoubleBank = false,
-
+                               .ReportINEndpoint           =
+                                       {
+                                               .Address            = MOUSE_EPADDR,
+                                               .Size               = MOUSE_EPSIZE,
+                                               .Banks              = 1,
+                                       },
                                .PrevReportINBuffer         = PrevMouseHIDReportBuffer,
                                .PrevReportINBufferSize     = sizeof(PrevMouseHIDReportBuffer),
                        },
index a71e85b..29def30 100644 (file)
@@ -44,9 +44,16 @@ USB_ClassInfo_HID_Host_t Mouse_HID_Host_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataOUTPipeNumber      = 2,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_MouseBootProtocol,
                        },
        };
index d0737ac..4c53cc2 100644 (file)
@@ -44,12 +44,16 @@ USB_ClassInfo_AOA_Host_t AndroidDevice_AOA_Interface =
        {\r
                .Config =\r
                        {\r
-                               .DataINPipeNumber           = 1,\r
-                               .DataINPipeDoubleBank       = false,\r
-\r
-                               .DataOUTPipeNumber          = 2,\r
-                               .DataOUTPipeDoubleBank      = false,\r
-                               \r
+                               .DataINPipe             =\r
+                                       {\r
+                                               .Address        = (PIPE_DIR_IN  | 1),\r
+                                               .Banks          = 1,\r
+                                       },\r
+                               .DataOUTPipe            =\r
+                                       {\r
+                                               .Address        = (PIPE_DIR_OUT | 2),\r
+                                               .Banks          = 1,\r
+                                       },                              \r
                                .PropertyStrings =\r
                                        {\r
                                                [AOA_STRING_Manufacturer] = "Dean Camera",\r
index 3e4a69a..aa27493 100644 (file)
@@ -44,7 +44,10 @@ USB_ClassInfo_Audio_Host_t Microphone_Audio_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber = 1,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                       },
                        },
        };
 
@@ -179,7 +182,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        }
 
        USB_Audio_SampleFreq_t SampleRate = AUDIO_SAMPLE_FREQ(48000);
-       if (Audio_Host_GetSetEndpointProperty(&Microphone_Audio_Interface, Microphone_Audio_Interface.Config.DataINPipeNumber,
+       if (Audio_Host_GetSetEndpointProperty(&Microphone_Audio_Interface, Microphone_Audio_Interface.Config.DataINPipe.Address,
                                              AUDIO_REQ_SetCurrent, AUDIO_EPCONTROL_SamplingFreq,
                                              sizeof(SampleRate), &SampleRate) != HOST_SENDCONTROL_Successful)
        {
index 783b0a5..833be1b 100644 (file)
@@ -44,7 +44,10 @@ USB_ClassInfo_Audio_Host_t Speaker_Audio_Interface =
        {
                .Config =
                        {
-                               .DataOUTPipeNumber = 1,
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                       },
                        },
        };
 
@@ -187,7 +190,7 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void)
        }
 
        USB_Audio_SampleFreq_t SampleRate = AUDIO_SAMPLE_FREQ(48000);
-       if (Audio_Host_GetSetEndpointProperty(&Speaker_Audio_Interface, Speaker_Audio_Interface.Config.DataOUTPipeNumber,
+       if (Audio_Host_GetSetEndpointProperty(&Speaker_Audio_Interface, Speaker_Audio_Interface.Config.DataOUTPipe.Address,
                                              AUDIO_REQ_SetCurrent, AUDIO_EPCONTROL_SamplingFreq,
                                              sizeof(SampleRate), &SampleRate) != HOST_SENDCONTROL_Successful)
        {
index 5d91249..18c02d7 100644 (file)
@@ -47,14 +47,17 @@ USB_ClassInfo_HID_Host_t Joystick_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
-
                                .HIDParserData          = &HIDReportInfo
                        },
        };
index f67cd11..6949908 100644 (file)
@@ -44,12 +44,16 @@ USB_ClassInfo_HID_Host_t Keyboard_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_KeyboardBootProtocol,
                        },
        };
index 4247e9e..6ef1820 100644 (file)
@@ -47,14 +47,17 @@ USB_ClassInfo_HID_Host_t Keyboard_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
-
                                .HIDParserData          = &HIDReportInfo
                        },
        };
index 8293fbd..472d19a 100644 (file)
@@ -44,11 +44,16 @@ USB_ClassInfo_MIDI_Host_t Keyboard_MIDI_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
@@ -106,8 +111,8 @@ void JoystickHost_Task(void)
        MIDI_EventPacket_t MIDIEvent;
        while (MIDI_Host_ReceiveEventPacket(&Keyboard_MIDI_Interface, &MIDIEvent))
        {
-               bool NoteOnEvent  = ((MIDIEvent.Command & 0x0F) == (MIDI_COMMAND_NOTE_ON  >> 4));
-               bool NoteOffEvent = ((MIDIEvent.Command & 0x0F) == (MIDI_COMMAND_NOTE_OFF >> 4));
+               bool NoteOnEvent  = (MIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_ON));
+               bool NoteOffEvent = (MIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_OFF));
 
                /* Display note events from the host */
                if (NoteOnEvent || NoteOffEvent)
@@ -168,8 +173,7 @@ void CheckJoystickMovement(void)
        {
                MIDI_EventPacket_t MIDIEvent = (MIDI_EventPacket_t)
                        {
-                               .CableNumber = 0,
-                               .Command     = (MIDICommand >> 4),
+                               .Event       = MIDI_EVENT(0, MIDICommand),
 
                                .Data1       = MIDICommand | Channel,
                                .Data2       = MIDIPitch,
index 10c7f79..aacc078 100644 (file)
@@ -44,11 +44,16 @@ USB_ClassInfo_MS_Host_t FlashDisk_MS_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
index 4272591..1290e48 100644 (file)
@@ -44,12 +44,16 @@ USB_ClassInfo_HID_Host_t Mouse_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_MouseBootProtocol,
                        },
        };
index 857d494..8004b5c 100644 (file)
@@ -47,14 +47,17 @@ USB_ClassInfo_HID_Host_t Mouse_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
-
                                .HIDParserData          = &HIDReportInfo
                        },
        };
index 3df0eed..51157a3 100644 (file)
@@ -44,11 +44,16 @@ USB_ClassInfo_PRNT_Host_t Printer_PRNT_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
index f03ee49..d27aab1 100644 (file)
@@ -47,16 +47,22 @@ USB_ClassInfo_RNDIS_Host_t Ethernet_RNDIS_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber           = 1,
-                               .DataINPipeDoubleBank       = false,
-
-                               .DataOUTPipeNumber          = 2,
-                               .DataOUTPipeDoubleBank      = false,
-
-                               .NotificationPipeNumber     = 3,
-                               .NotificationPipeDoubleBank = false,
-
-                               .HostMaxPacketSize          = sizeof(PacketBuffer),
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
+                               .NotificationPipe       =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 3),
+                                               .Banks          = 1,
+                                       },
+                               .HostMaxPacketSize      = sizeof(PacketBuffer),
                        },
        };
 
index eeac14d..9a89452 100644 (file)
@@ -44,14 +44,21 @@ USB_ClassInfo_SI_Host_t DigitalCamera_SI_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
-                               .EventsPipeNumber       = 3,
-                               .EventsPipeDoubleBank   = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
+                               .EventsPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 3),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
index 631925e..bce7804 100644 (file)
@@ -44,14 +44,21 @@ USB_ClassInfo_CDC_Host_t VirtualSerial_CDC_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber           = 1,
-                               .DataINPipeDoubleBank       = false,
-
-                               .DataOUTPipeNumber          = 2,
-                               .DataOUTPipeDoubleBank      = false,
-
-                               .NotificationPipeNumber     = 3,
-                               .NotificationPipeDoubleBank = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
+                               .NotificationPipe       =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 3),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
index 7d10506..fa19052 100644 (file)
@@ -105,16 +105,13 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the Bluetooth data IN pipe */
-       Pipe_ConfigurePipe(BLUETOOTH_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(BLUETOOTH_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the Bluetooth data OUT pipe */
-       Pipe_ConfigurePipe(BLUETOOTH_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(BLUETOOTH_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Configure the Bluetooth events pipe */
-       Pipe_ConfigurePipe(BLUETOOTH_EVENTS_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                                          EventsEndpoint->EndpointAddress, EventsEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(BLUETOOTH_EVENTS_PIPE, EP_TYPE_INTERRUPT, EventsEndpoint->EndpointAddress, EventsEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(EventsEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index 9c40fcd..c46add7 100644 (file)
@@ -40,9 +40,9 @@
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               #define BLUETOOTH_DATA_IN_PIPE         1
-               #define BLUETOOTH_DATA_OUT_PIPE        2
-               #define BLUETOOTH_EVENTS_PIPE          3
+               #define BLUETOOTH_DATA_IN_PIPE         (PIPE_DIR_IN  | 1)
+               #define BLUETOOTH_DATA_OUT_PIPE        (PIPE_DIR_OUT | 2)
+               #define BLUETOOTH_EVENTS_PIPE          (PIPE_DIR_IN  | 3)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 1b8613b..6db8532 100644 (file)
@@ -95,12 +95,10 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the Android Accessory data IN pipe */
-       Pipe_ConfigurePipe(ANDROID_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(ANDROID_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the Android Accessory data OUT pipe */
-       Pipe_ConfigurePipe(ANDROID_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(ANDROID_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index 05e1b91..53b7280 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               #define ANDROID_DATA_IN_PIPE         1
-               #define ANDROID_DATA_OUT_PIPE        2
+               /** Pipe address of the Android Accessory data IN pipe. */
+               #define ANDROID_DATA_IN_PIPE         (PIPE_DIR_IN  | 1)
+
+               /** Pipe address of the Android Accessory data OUT pipe. */
+               #define ANDROID_DATA_OUT_PIPE        (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index b26dbb8..9274e63 100644 (file)
@@ -130,8 +130,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        StreamingEndpointAddress     = DataINEndpoint->EndpointAddress;
 
        /* Configure the Audio data IN pipe */
-       Pipe_ConfigurePipe(AUDIO_DATA_IN_PIPE, EP_TYPE_ISOCHRONOUS, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_DOUBLE);
+       Pipe_ConfigurePipe(AUDIO_DATA_IN_PIPE, EP_TYPE_ISOCHRONOUS, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 2);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index a5f4259..84d27c7 100644 (file)
@@ -42,8 +42,8 @@
                #include "AudioInputHost.h"
 
        /* Macros: */
-               /** Pipe number for the Audio data IN pipe. */
-               #define AUDIO_DATA_IN_PIPE          1
+               /** Pipe address for the Audio data IN pipe. */
+               #define AUDIO_DATA_IN_PIPE          (PIPE_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index b98cf1f..44513ef 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - Audio Input Host"
+PROJECT_NAME           = "LUFA Library - Audio Input Host Demo"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index 99980fd..cc25062 100644 (file)
@@ -130,8 +130,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        StreamingEndpointAddress     = DataOUTEndpoint->EndpointAddress;
 
        /* Configure the Audio data OUT pipe */
-       Pipe_ConfigurePipe(AUDIO_DATA_OUT_PIPE, EP_TYPE_ISOCHRONOUS, PIPE_TOKEN_OUT,
-                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_DOUBLE);
+       Pipe_ConfigurePipe(AUDIO_DATA_OUT_PIPE, EP_TYPE_ISOCHRONOUS, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 2);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index dcf367e..0c4f067 100644 (file)
@@ -42,8 +42,8 @@
                #include "AudioOutputHost.h"
 
        /* Macros: */
-               /** Pipe number for the Audio data OUT pipe. */
-               #define AUDIO_DATA_OUT_PIPE          1
+               /** Pipe address for the Audio data OUT pipe. */
+               #define AUDIO_DATA_OUT_PIPE          (PIPE_DIR_OUT | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 55c9bb5..9cb0e55 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - Audio Output Host"
+PROJECT_NAME           = "LUFA Library - Audio Output Host Demo"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index 6df253c..9067450 100644 (file)
@@ -109,16 +109,14 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(HID_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(HID_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Check if the HID interface contained an optional OUT data endpoint */
        if (DataOUTEndpoint)
        {
                /* Configure the HID data OUT pipe */
-               Pipe_ConfigurePipe(HID_DATA_OUT_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_OUT,
-                                                  DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+               Pipe_ConfigurePipe(HID_DATA_OUT_PIPE, EP_TYPE_INTERRUPT, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
        }
 
        /* Valid data found, return success */
index 4614893..547f154 100644 (file)
                #include "GenericHIDHost.h"
 
        /* Macros: */
-               /** Pipe number for the HID data IN pipe. */
-               #define HID_DATA_IN_PIPE          1
+               /** Pipe address for the HID data IN pipe. */
+               #define HID_DATA_IN_PIPE          (PIPE_DIR_IN  | 1)
 
-               /** Pipe number for the HID data OUT pipe. */
-               #define HID_DATA_OUT_PIPE         2
+               /** Pipe address for the HID data OUT pipe. */
+               #define HID_DATA_OUT_PIPE         (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 4f7a0d6..be6eb09 100644 (file)
@@ -110,8 +110,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(JOYSTICK_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(JOYSTICK_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Get the HID report size from the HID report descriptor */
index 69fdfed..fba5713 100644 (file)
@@ -42,8 +42,8 @@
                #include "HIDReport.h"
 
        /* Macros: */
-               /** Pipe number for the joystick report data pipe. */
-               #define JOYSTICK_DATA_IN_PIPE       1
+               /** Pipe address for the joystick report data pipe. */
+               #define JOYSTICK_DATA_IN_PIPE       (PIPE_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 4366e6e..65c6086 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - Joystick Host (Using HID Descriptor Parser)"
+PROJECT_NAME           = "LUFA Library - Joystick Host Demo (Using HID Descriptor Parser)"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index cfcee7b..73dc5df 100644 (file)
@@ -98,8 +98,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(KEYBOARD_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(KEYBOARD_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index 5b44d3f..eb09f69 100644 (file)
@@ -42,8 +42,8 @@
                #include "KeyboardHost.h"
 
        /* Macros: */
-               /** Pipe number for the keyboard data IN pipe. */
-               #define KEYBOARD_DATA_IN_PIPE          1
+               /** Pipe address for the keyboard data IN pipe. */
+               #define KEYBOARD_DATA_IN_PIPE          (PIPE_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 765b325..ddd4359 100644 (file)
@@ -110,8 +110,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(KEYBOARD_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(KEYBOARD_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Get the HID report size from the HID report descriptor */
index ffa2afd..c40211c 100644 (file)
@@ -42,8 +42,8 @@
                #include "HIDReport.h"
 
        /* Macros: */
-               /** Pipe number for the keyboard report data pipe. */
-               #define KEYBOARD_DATA_IN_PIPE          1
+               /** Pipe address for the keyboard report data IN pipe. */
+               #define KEYBOARD_DATA_IN_PIPE          (PIPE_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 9f76d7e..3e48157 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - Keyboard Host (Using HID Descriptor Parser)"
+PROJECT_NAME           = "LUFA Library - Keyboard Host Demo (Using HID Descriptor Parser)"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index 39e513c..70381ea 100644 (file)
@@ -105,12 +105,10 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the MIDI data IN pipe */
-       Pipe_ConfigurePipe(MIDI_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MIDI_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the MIDI data OUT pipe */
-       Pipe_ConfigurePipe(MIDI_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MIDI_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index d41513e..40d4dc9 100644 (file)
                #include "MIDIHost.h"
 
        /* Macros: */
-               /** Pipe number for the MIDI data IN pipe. */
-               #define MIDI_DATA_IN_PIPE              1
+               /** Pipe address for the MIDI data IN pipe. */
+               #define MIDI_DATA_IN_PIPE              (PIPE_DIR_IN  | 1)
 
-               /** Pipe number for the MIDI data OUT pipe. */
-               #define MIDI_DATA_OUT_PIPE             2
+               /** Pipe address for the MIDI data OUT pipe. */
+               #define MIDI_DATA_OUT_PIPE             (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 060761f..f4a52ac 100644 (file)
@@ -177,8 +177,8 @@ void MIDIHost_Task(void)
                if (!(Pipe_BytesInPipe()))
                  Pipe_ClearIN();
 
-               bool NoteOnEvent  = ((MIDIEvent.Command & 0x0F) == (MIDI_COMMAND_NOTE_ON  >> 4));
-               bool NoteOffEvent = ((MIDIEvent.Command & 0x0F) == (MIDI_COMMAND_NOTE_OFF >> 4));
+               bool NoteOnEvent  = (MIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_ON));
+               bool NoteOffEvent = (MIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_OFF));
 
                if (NoteOnEvent || NoteOffEvent)
                {
@@ -237,8 +237,7 @@ void MIDIHost_Task(void)
                {
                        MIDI_EventPacket_t MIDIEvent = (MIDI_EventPacket_t)
                                {
-                                       .CableNumber = 0,
-                                       .Command     = (MIDICommand >> 4),
+                                       .Event       = MIDI_EVENT(0, MIDICommand),
 
                                        .Data1       = MIDICommand | Channel,
                                        .Data2       = MIDIPitch,
index 566cdb1..0e967f9 100644 (file)
@@ -105,12 +105,10 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the Mass Storage data IN pipe */
-       Pipe_ConfigurePipe(MASS_STORE_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MASS_STORE_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the Mass Storage data OUT pipe */
-       Pipe_ConfigurePipe(MASS_STORE_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MASS_STORE_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index a40debd..eb0746b 100644 (file)
                /** Interface Protocol value for the Bulk Only transport protocol. */
                #define MASS_STORE_PROTOCOL            0x50
 
-               /** Pipe number of the Mass Storage data IN pipe. */
-               #define MASS_STORE_DATA_IN_PIPE        1
+               /** Pipe address of the Mass Storage data IN pipe. */
+               #define MASS_STORE_DATA_IN_PIPE        (PIPE_DIR_IN  | 1)
 
-               /** Pipe number of the Mass Storage data OUT pipe. */
-               #define MASS_STORE_DATA_OUT_PIPE       2
+               /** Pipe address of the Mass Storage data OUT pipe. */
+               #define MASS_STORE_DATA_OUT_PIPE       (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index c33e087..4992e3a 100644 (file)
@@ -98,8 +98,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(MOUSE_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MOUSE_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index 9619c44..14051a6 100644 (file)
@@ -42,8 +42,8 @@
                #include "MouseHost.h"
 
        /* Macros: */
-               /** Pipe number for the mouse data IN pipe. */
-               #define MOUSE_DATA_IN_PIPE          1
+               /** Pipe address for the mouse data IN pipe. */
+               #define MOUSE_DATA_IN_PIPE          (PIPE_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index c664700..7d63d2b 100644 (file)
@@ -110,8 +110,7 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(MOUSE_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(MOUSE_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Get the HID report size from the HID report descriptor */
index 799761b..0a2582b 100644 (file)
@@ -42,8 +42,8 @@
                #include "HIDReport.h"
 
        /* Macros: */
-               /** Pipe number for the mouse report data pipe. */
-               #define MOUSE_DATA_IN_PIPE          1
+               /** Pipe address for the mouse report data IN pipe. */
+               #define MOUSE_DATA_IN_PIPE          (ENDPOINT_DIR_IN | 1)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index fcf8356..b41e8d8 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - Mouse Host (Using HID Descriptor Parser)"
+PROJECT_NAME           = "LUFA Library - Mouse Host Demo (Using HID Descriptor Parser)"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index f259c1f..922734f 100644 (file)
@@ -108,12 +108,10 @@ uint8_t ProcessConfigurationDescriptor(void)
        PrinterAltSetting      = PrinterInterface->AlternateSetting;
 
        /* Configure the Printer data IN pipe */
-       Pipe_ConfigurePipe(PRINTER_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(PRINTER_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the Printer data OUT pipe */
-       Pipe_ConfigurePipe(PRINTER_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(PRINTER_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Valid data found, return success */
        return SuccessfulConfigRead;
index cc9e2cb..d5a32cd 100644 (file)
                #include "Lib/PrinterCommands.h"
 
        /* Macros: */
-               /** Pipe number of the Printer data IN pipe. */
-               #define PRINTER_DATA_IN_PIPE             1
+               /** Pipe address of the Printer data IN pipe. */
+               #define PRINTER_DATA_IN_PIPE             (PIPE_DIR_IN  | 1)
 
-               /** Pipe number of the Printer data OUT pipe. */
-               #define PRINTER_DATA_OUT_PIPE            2
+               /** Pipe address of the Printer data OUT pipe. */
+               #define PRINTER_DATA_OUT_PIPE            (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 0493000..df317ef 100644 (file)
@@ -131,16 +131,13 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the RNDIS data IN pipe */
-       Pipe_ConfigurePipe(RNDIS_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(RNDIS_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the RNDIS data OUT pipe */
-       Pipe_ConfigurePipe(RNDIS_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(RNDIS_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Configure the RNDIS notification pipe */
-       Pipe_ConfigurePipe(RNDIS_NOTIFICATION_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                                          NotificationEndpoint->EndpointAddress, NotificationEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(RNDIS_NOTIFICATION_PIPE, EP_TYPE_INTERRUPT, NotificationEndpoint->EndpointAddress, NotificationEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(NotificationEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index e9cf19f..19f26b4 100644 (file)
                #include "RNDISEthernetHost.h"
 
        /* Macros: */
-               /** Pipe number for the RNDIS data IN pipe. */
-               #define RNDIS_DATA_IN_PIPE             1
+               /** Pipe address for the RNDIS data IN pipe. */
+               #define RNDIS_DATA_IN_PIPE             (PIPE_DIR_IN  | 1)
 
-               /** Pipe number for the RNDIS data OUT pipe. */
-               #define RNDIS_DATA_OUT_PIPE            2
+               /** Pipe address for the RNDIS data OUT pipe. */
+               #define RNDIS_DATA_OUT_PIPE            (PIPE_DIR_OUT | 2)
 
-               /** Pipe number for the RNDIS notification pipe. */
-               #define RNDIS_NOTIFICATION_PIPE        3
+               /** Pipe address for the RNDIS notification IN pipe. */
+               #define RNDIS_NOTIFICATION_PIPE        (PIPE_DIR_IN  | 3)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 269dc3b..c5c78ce 100644 (file)
@@ -115,16 +115,13 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the Still Image data IN pipe */
-       Pipe_ConfigurePipe(SIMAGE_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(SIMAGE_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the Still Image data OUT pipe */
-       Pipe_ConfigurePipe(SIMAGE_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(SIMAGE_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Configure the Still Image events pipe */
-       Pipe_ConfigurePipe(SIMAGE_EVENTS_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                                          EventsEndpoint->EndpointAddress, EventsEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(SIMAGE_EVENTS_PIPE, EP_TYPE_INTERRUPT, EventsEndpoint->EndpointAddress, EventsEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(EventsEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index 04b81a2..93dcfc6 100644 (file)
                #include "StillImageHost.h"
 
        /* Macros: */
-               /** Pipe number of the Still Image data IN pipe. */
-               #define SIMAGE_DATA_IN_PIPE            1
+               /** Pipe address of the Still Image data IN pipe. */
+               #define SIMAGE_DATA_IN_PIPE            (PIPE_DIR_IN  | 1)
 
-               /** Pipe number of the Still Image data OUT pipe. */
-               #define SIMAGE_DATA_OUT_PIPE           2
+               /** Pipe address of the Still Image data OUT pipe. */
+               #define SIMAGE_DATA_OUT_PIPE           (PIPE_DIR_OUT | 2)
 
-               /** Pipe number of the Still Image events pipe. */
-               #define SIMAGE_EVENTS_PIPE             3
+               /** Pipe address of the Still Image events IN pipe. */
+               #define SIMAGE_EVENTS_PIPE             (PIPE_DIR_IN  | 3)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 4126d76..552b02a 100644 (file)
@@ -131,16 +131,13 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the CDC data IN pipe */
-       Pipe_ConfigurePipe(CDC_DATA_IN_PIPE, EP_TYPE_BULK, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(CDC_DATA_IN_PIPE, EP_TYPE_BULK, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
 
        /* Configure the CDC data OUT pipe */
-       Pipe_ConfigurePipe(CDC_DATA_OUT_PIPE, EP_TYPE_BULK, PIPE_TOKEN_OUT,
-                                          DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(CDC_DATA_OUT_PIPE, EP_TYPE_BULK, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
 
        /* Configure the CDC notification pipe */
-       Pipe_ConfigurePipe(CDC_NOTIFICATION_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                                          NotificationEndpoint->EndpointAddress, NotificationEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(CDC_NOTIFICATION_PIPE, EP_TYPE_INTERRUPT, NotificationEndpoint->EndpointAddress, NotificationEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(NotificationEndpoint->PollingIntervalMS);
 
        /* Valid data found, return success */
index c5a60b4..e9f12dc 100644 (file)
                #include "VirtualSerialHost.h"
 
        /* Macros: */
-               /** Pipe number for the CDC data IN pipe. */
-               #define CDC_DATA_IN_PIPE               1
+               /** Pipe address for the CDC data IN pipe. */
+               #define CDC_DATA_IN_PIPE               (PIPE_DIR_IN  | 1)
 
-               /** Pipe number for the CDC data OUT pipe. */
-               #define CDC_DATA_OUT_PIPE              2
+               /** Pipe address for the CDC data OUT pipe. */
+               #define CDC_DATA_OUT_PIPE              (PIPE_DIR_OUT | 2)
 
-               /** Pipe number for the CDC notification pipe. */
-               #define CDC_NOTIFICATION_PIPE          3
+               /** Pipe address for the CDC notification IN pipe. */
+               #define CDC_NOTIFICATION_PIPE          (PIPE_DIR_IN  | 3)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 4fc91f6..16ad85f 100644 (file)
@@ -1 +1 @@
-<Project name="LUFA"><Folder name="Demos"><Folder name="Device"><Folder name="ClassDriver"><Folder name="AudioInput"><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.c"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.h"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.txt"></File><File path="Demos\Device\ClassDriver\AudioInput\Descriptors.c"></File><File path="Demos\Device\ClassDriver\AudioInput\Descriptors.h"></File><File path="Demos\Device\ClassDriver\AudioInput\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\AudioInput\makefile"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.aps"></File></Folder><Folder name="AudioOutput"><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.c"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.h"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.txt"></File><File path="Demos\Device\ClassDriver\AudioOutput\Descriptors.c"></File><File path="Demos\Device\ClassDriver\AudioOutput\Descriptors.h"></File><File path="Demos\Device\ClassDriver\AudioOutput\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\AudioOutput\makefile"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.aps"></File></Folder><Folder name="DualVirtualSerial"><File path="Demos\Device\ClassDriver\DualVirtualSerial\Descriptors.c"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\Descriptors.h"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.c"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.h"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.txt"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\LUFA DualVirtualSerial.inf"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\makefile"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.aps"></File></Folder><Folder name="GenericHID"><File path="Demos\Device\ClassDriver\GenericHID\Descriptors.c"></File><File path="Demos\Device\ClassDriver\GenericHID\Descriptors.h"></File><File path="Demos\Device\ClassDriver\GenericHID\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.c"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.h"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.txt"></File><File path="Demos\Device\ClassDriver\GenericHID\makefile"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.aps"></File></Folder><Folder name="Joystick"><File path="Demos\Device\ClassDriver\Joystick\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Joystick\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Joystick\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.c"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.h"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.txt"></File><File path="Demos\Device\ClassDriver\Joystick\makefile"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.aps"></File></Folder><Folder name="Keyboard"><File path="Demos\Device\ClassDriver\Keyboard\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Keyboard\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Keyboard\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.c"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.h"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.txt"></File><File path="Demos\Device\ClassDriver\Keyboard\makefile"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.aps"></File></Folder><Folder name="KeyboardMouse"><File path="Demos\Device\ClassDriver\KeyboardMouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.txt"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\makefile"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.aps"></File></Folder><Folder name="KeyboardMouseMultiReport"><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Descriptors.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Descriptors.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.txt"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\makefile"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.aps"></File></Folder><Folder name="MassStorage"><Folder name="Lib"><File path="Demos\Device\ClassDriver\MassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\MassStorage\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MassStorage\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MassStorage\makefile"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.c"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.h"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.txt"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.aps"></File></Folder><Folder name="MassStorageKeyboard"><Folder name="Lib"><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\makefile"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.txt"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.aps"></File></Folder><Folder name="MIDI"><File path="Demos\Device\ClassDriver\MIDI\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MIDI\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MIDI\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MIDI\makefile"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.c"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.h"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.txt"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.aps"></File></Folder><Folder name="Mouse"><File path="Demos\Device\ClassDriver\Mouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Mouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Mouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Mouse\makefile"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.c"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.h"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.txt"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.aps"></File></Folder><Folder name="RNDISEthernet"><Folder name="Lib"><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Webserver.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ARP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ARP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\DHCP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\DHCP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Ethernet.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Ethernet.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\EthernetProtocols.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ICMP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ICMP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\IP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\IP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ProtocolDecoders.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ProtocolDecoders.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\TCP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\TCP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\UDP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\UDP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Webserver.c"></File></Folder><File path="Demos\Device\ClassDriver\RNDISEthernet\Descriptors.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Descriptors.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\LUFA RNDIS.inf"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\makefile"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.txt"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.aps"></File></Folder><Folder name="VirtualSerial"><File path="Demos\Device\ClassDriver\VirtualSerial\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerial\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerial\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerial\LUFA VirtualSerial.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerial\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.c"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.h"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.aps"></File></Folder><Folder name="VirtualSerialMassStorage"><Folder name="Lib"><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\LUFA VirtualSerialMassStorage.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.aps"></File></Folder><Folder name="VirtualSerialMouse"><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\LUFA VirtualSerialMouse.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.aps"></File></Folder><File path="Demos\Device\ClassDriver\makefile"></File></Folder><Folder name="LowLevel"><Folder name="AudioInput"><File path="Demos\Device\LowLevel\AudioInput\AudioInput.c"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.h"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.txt"></File><File path="Demos\Device\LowLevel\AudioInput\Descriptors.c"></File><File path="Demos\Device\LowLevel\AudioInput\Descriptors.h"></File><File path="Demos\Device\LowLevel\AudioInput\Doxygen.conf"></File><File path="Demos\Device\LowLevel\AudioInput\makefile"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.aps"></File></Folder><Folder name="AudioOutput"><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.c"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.h"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.txt"></File><File path="Demos\Device\LowLevel\AudioOutput\Descriptors.c"></File><File path="Demos\Device\LowLevel\AudioOutput\Descriptors.h"></File><File path="Demos\Device\LowLevel\AudioOutput\Doxygen.conf"></File><File path="Demos\Device\LowLevel\AudioOutput\makefile"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.aps"></File></Folder><Folder name="DualVirtualSerial"><File path="Demos\Device\LowLevel\DualVirtualSerial\Descriptors.c"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\Descriptors.h"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\Doxygen.conf"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.c"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.h"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.txt"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\LUFA DualVirtualSerial.inf"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\makefile"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.aps"></File></Folder><Folder name="GenericHID"><File path="Demos\Device\LowLevel\GenericHID\Descriptors.c"></File><File path="Demos\Device\LowLevel\GenericHID\Descriptors.h"></File><File path="Demos\Device\LowLevel\GenericHID\Doxygen.conf"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.c"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.h"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.txt"></File><File path="Demos\Device\LowLevel\GenericHID\makefile"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.aps"></File></Folder><Folder name="Joystick"><File path="Demos\Device\LowLevel\Joystick\Descriptors.c"></File><File path="Demos\Device\LowLevel\Joystick\Descriptors.h"></File><File path="Demos\Device\LowLevel\Joystick\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.c"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.h"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.txt"></File><File path="Demos\Device\LowLevel\Joystick\makefile"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.aps"></File></Folder><Folder name="Keyboard"><File path="Demos\Device\LowLevel\Keyboard\Descriptors.c"></File><File path="Demos\Device\LowLevel\Keyboard\Descriptors.h"></File><File path="Demos\Device\LowLevel\Keyboard\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.c"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.h"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.txt"></File><File path="Demos\Device\LowLevel\Keyboard\makefile"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.aps"></File></Folder><Folder name="KeyboardMouse"><File path="Demos\Device\LowLevel\KeyboardMouse\Descriptors.c"></File><File path="Demos\Device\LowLevel\KeyboardMouse\Descriptors.h"></File><File path="Demos\Device\LowLevel\KeyboardMouse\Doxygen.conf"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.c"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.h"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.txt"></File><File path="Demos\Device\LowLevel\KeyboardMouse\makefile"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.aps"></File></Folder><Folder name="MassStorage"><Folder name="Lib"><File path="Demos\Device\LowLevel\MassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\SCSI.c"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\LowLevel\MassStorage\Descriptors.c"></File><File path="Demos\Device\LowLevel\MassStorage\Descriptors.h"></File><File path="Demos\Device\LowLevel\MassStorage\Doxygen.conf"></File><File path="Demos\Device\LowLevel\MassStorage\makefile"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.c"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.h"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.txt"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.aps"></File></Folder><Folder name="MIDI"><File path="Demos\Device\LowLevel\MIDI\Descriptors.c"></File><File path="Demos\Device\LowLevel\MIDI\Descriptors.h"></File><File path="Demos\Device\LowLevel\MIDI\Doxygen.conf"></File><File path="Demos\Device\LowLevel\MIDI\makefile"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.c"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.h"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.txt"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.aps"></File></Folder><Folder name="Mouse"><File path="Demos\Device\LowLevel\Mouse\Descriptors.c"></File><File path="Demos\Device\LowLevel\Mouse\Descriptors.h"></File><File path="Demos\Device\LowLevel\Mouse\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Mouse\makefile"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.c"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.h"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.txt"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.aps"></File></Folder><Folder name="RNDISEthernet"><Folder name="Lib"><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Webserver.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ARP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ARP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\DHCP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\DHCP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Ethernet.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Ethernet.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\EthernetProtocols.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ICMP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ICMP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\IP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\IP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ProtocolDecoders.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ProtocolDecoders.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\RNDIS.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\RNDIS.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\TCP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\TCP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\UDP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\UDP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Webserver.c"></File></Folder><File path="Demos\Device\LowLevel\RNDISEthernet\Descriptors.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Descriptors.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Doxygen.conf"></File><File path="Demos\Device\LowLevel\RNDISEthernet\LUFA RNDIS.inf"></File><File path="Demos\Device\LowLevel\RNDISEthernet\makefile"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.txt"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.aps"></File></Folder><Folder name="VirtualSerial"><File path="Demos\Device\LowLevel\VirtualSerial\Descriptors.c"></File><File path="Demos\Device\LowLevel\VirtualSerial\Descriptors.h"></File><File path="Demos\Device\LowLevel\VirtualSerial\Doxygen.conf"></File><File path="Demos\Device\LowLevel\VirtualSerial\LUFA VirtualSerial.inf"></File><File path="Demos\Device\LowLevel\VirtualSerial\makefile"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.c"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.h"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.txt"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.aps"></File></Folder><File path="Demos\Device\LowLevel\makefile"></File></Folder><Folder name="Incomplete"><Folder name="SideShow"><Folder name="Lib"><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowApplications.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowApplications.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommands.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommands.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommon.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommon.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowContent.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowContent.h"></File></Folder><File path="Demos\Device\Incomplete\Sideshow\Descriptors.c"></File><File path="Demos\Device\Incomplete\Sideshow\Descriptors.h"></File><File path="Demos\Device\Incomplete\Sideshow\makefile"></File><File path="Demos\Device\Incomplete\Sideshow\Sideshow.c"></File><File path="Demos\Device\Incomplete\Sideshow\Sideshow.h"></File></Folder><Folder name="TestAndMeasurement"><File path="Demos\Device\Incomplete\TestAndMeasurement\Descriptors.c"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\Descriptors.h"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\TestAndMeasurement.c"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\TestAndMeasurement.h"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\makefile"></File></Folder></Folder><File path="Demos\Device\makefile"></File></Folder><Folder name="Host"><Folder name="ClassDriver"><Folder name="AndroidAccessoryHost"><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.c"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.h"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.txt"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\makefile"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.aps"></File></Folder><Folder name="AudioInputHost"><File path="Demos\Host\ClassDriver\AudioInputHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AudioInputHost\makefile"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.c"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.h"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.aps"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.txt"></File></Folder><Folder name="AudioOutputHost"><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.c"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.h"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\makefile"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.txt"></File></Folder><Folder name="JoystickHostWithParser"><File path="Demos\Host\ClassDriver\JoystickHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.c"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.h"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.aps"></File></Folder><Folder name="KeyboardHost"><File path="Demos\Host\ClassDriver\KeyboardHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.c"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.h"></File><File path="Demos\Host\ClassDriver\KeyboardHost\makefile"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.txt"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.aps"></File></Folder><Folder name="KeyboardHostWithParser"><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.c"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.h"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.aps"></File></Folder><Folder name="MassStorageHost"><File path="Demos\Host\ClassDriver\MassStorageHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MassStorageHost\makefile"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.c"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.h"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.txt"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.aps"></File></Folder><Folder name="MIDIHost"><File path="Demos\Host\ClassDriver\MIDIHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MIDIHost\makefile"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.c"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.h"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.txt"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.aps"></File></Folder><Folder name="MouseHost"><File path="Demos\Host\ClassDriver\MouseHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MouseHost\makefile"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.c"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.h"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.txt"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.aps"></File></Folder><Folder name="MouseHostWithParser"><File path="Demos\Host\ClassDriver\MouseHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.c"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.h"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.aps"></File></Folder><Folder name="PrinterHost"><File path="Demos\Host\ClassDriver\PrinterHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\PrinterHost\makefile"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.c"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.h"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.txt"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.aps"></File></Folder><Folder name="RNDISEthernetHost"><File path="Demos\Host\ClassDriver\RNDISEthernetHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\makefile"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.c"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.h"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.txt"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.aps"></File></Folder><Folder name="StillImageHost"><File path="Demos\Host\ClassDriver\StillImageHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\StillImageHost\makefile"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.c"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.h"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.txt"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.aps"></File></Folder><Folder name="VirtualSerialHost"><File path="Demos\Host\ClassDriver\VirtualSerialHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\makefile"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.c"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.h"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.txt"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.aps"></File></Folder><File path="Demos\Host\ClassDriver\makefile"></File></Folder><Folder name="LowLevel"><Folder name="AndroidAccessoryHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Lib\AndroidAccessoryCommands.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Lib\AndroidAccessoryCommands.h"></File></Folder><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\DeviceDescriptor.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\DeviceDescriptor.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\makefile"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.txt"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.aps"></File></Folder><Folder name="AudioInputHost"><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.c"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.h"></File><File path="Demos\Host\LowLevel\AudioInputHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AudioInputHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AudioInputHost\makefile"></File><File path="Demos\Host\LowLevel\AudioInputHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.aps"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.txt"></File></Folder><Folder name="AudioOutputHost"><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.c"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.h"></File><File path="Demos\Host\LowLevel\AudioOutputHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AudioOutputHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AudioOutputHost\makefile"></File><File path="Demos\Host\LowLevel\AudioOutputHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.aps"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.txt"></File></Folder><Folder name="GenericHIDHost"><File path="Demos\Host\LowLevel\GenericHIDHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\GenericHIDHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\GenericHIDHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.c"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.h"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.txt"></File><File path="Demos\Host\LowLevel\GenericHIDHost\makefile"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.aps"></File></Folder><Folder name="JoystickHostWithParser"><File path="Demos\Host\LowLevel\JoystickHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.txt"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.aps"></File></Folder><Folder name="KeyboardHost"><File path="Demos\Host\LowLevel\KeyboardHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\KeyboardHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\KeyboardHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.c"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.h"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.txt"></File><File path="Demos\Host\LowLevel\KeyboardHost\makefile"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.aps"></File></Folder><Folder name="KeyboardHostWithParser"><File path="Demos\Host\LowLevel\KeyboardHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.txt"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.aps"></File></Folder><Folder name="MassStorageHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\MassStorageHost\Lib\MassStoreCommands.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\Lib\MassStoreCommands.h"></File></Folder><File path="Demos\Host\LowLevel\MassStorageHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MassStorageHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MassStorageHost\makefile"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.h"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.txt"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.aps"></File></Folder><Folder name="MIDIHost"><File path="Demos\Host\LowLevel\MIDIHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MIDIHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MIDIHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MIDIHost\makefile"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.c"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.h"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.txt"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.aps"></File></Folder><Folder name="MouseHost"><File path="Demos\Host\LowLevel\MouseHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MouseHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MouseHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MouseHost\makefile"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.c"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.h"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.txt"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.aps"></File></Folder><Folder name="MouseHostWithParser"><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.txt"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.aps"></File></Folder><Folder name="PrinterHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\PrinterHost\Lib\PrinterCommands.c"></File><File path="Demos\Host\LowLevel\PrinterHost\Lib\PrinterCommands.h"></File></Folder><File path="Demos\Host\LowLevel\PrinterHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\PrinterHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\PrinterHost\makefile"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.c"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.h"></File><File path="Demos\Host\LowLevel\PrinterHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.txt"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.aps"></File></Folder><Folder name="RNDISEthernetHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\RNDISEthernetHost\Lib\RNDISCommands.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\Lib\RNDISCommands.h"></File></Folder><File path="Demos\Host\LowLevel\RNDISEthernetHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\makefile"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.h"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISHost.txt"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.aps"></File></Folder><Folder name="StillImageHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\StillImageHost\Lib\StillImageCommands.c"></File><File path="Demos\Host\LowLevel\StillImageHost\Lib\StillImageCommands.h"></File><File path="Demos\Host\LowLevel\StillImageHost\Lib\PIMACodes.h"></File></Folder><File path="Demos\Host\LowLevel\StillImageHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\StillImageHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\StillImageHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\StillImageHost\makefile"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.c"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.h"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.txt"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.aps"></File></Folder><Folder name="VirtualSerialHost"><File path="Demos\Host\LowLevel\VirtualSerialHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\makefile"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.c"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.h"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.txt"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.aps"></File></Folder><File path="Demos\Host\LowLevel\makefile"></File></Folder><Folder name="Incomplete"><Folder name="BluetoothHost"><Folder name="Lib"><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothACLPackets.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothACLPackets.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothClassCodes.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothHCICommands.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothHCICommands.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothStack.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothStack.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDPServices.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDPServices.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMM.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMM.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDP.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDP.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMMControl.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMMControl.h"></File></Folder><File path="Demos\Host\Incomplete\BluetoothHost\makefile"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothHost.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothHost.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\ConfigDescriptor.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\ConfigDescriptor.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\DeviceDescriptor.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\DeviceDescriptor.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Doxygen.conf"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothEvents.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothEvents.h"></File></Folder></Folder><File path="Demos\Host\makefile"></File></Folder><Folder name="DualRole"><Folder name="ClassDriver"><Folder name="MouseHostDevice"><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Doxygen.conf"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\makefile"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Descriptors.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Descriptors.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\DeviceFunctions.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\HostFunctions.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\HostFunctions.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\DeviceFunctions.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.txt"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.aps"></File></Folder><File path="Demos\DualRole\ClassDriver\makefile"></File></Folder><File path="Demos\DualRole\makefile"></File></Folder><File path="Demos\makefile"></File></Folder><Folder name="LUFA"><Folder name="CodeTemplates"><Folder name="DriverStubs"><File path="LUFA\CodeTemplates\DriverStubs\Buttons.h"></File><File path="LUFA\CodeTemplates\DriverStubs\Dataflash.h"></File><File path="LUFA\CodeTemplates\DriverStubs\Joystick.h"></File><File path="LUFA\CodeTemplates\DriverStubs\LEDs.h"></File></Folder><File path="LUFA\CodeTemplates\makefile_template.avr8"></File><File path="LUFA\CodeTemplates\makefile_template.uc3"></File><File path="LUFA\CodeTemplates\makefile_template.xmega"></File><File path="LUFA\CodeTemplates\LUFAConfig.h"></File></Folder><Folder name="Common"><File path="LUFA\Common\Common.h"></File><File path="LUFA\Common\BoardTypes.h"></File><File path="LUFA\Common\Attributes.h"></File><File path="LUFA\Common\Architectures.h"></File><File path="LUFA\Common\Endianness.h"></File><File path="LUFA\Common\CompilerSpecific.h"></File><File path="LUFA\Common\ArchitectureSpecific.h"></File></Folder><Folder name="DoxygenPages"><Folder name="Style"><File path="LUFA\DoxygenPages\Style\Footer.htm"></File><File path="LUFA\DoxygenPages\Style\Style.css"></File></Folder><Folder name="Images"><Folder name="AS5_AS6_Import"><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step1.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step2.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step3.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step4.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_1.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_2.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_3.png"></File></Folder><File path="LUFA\DoxygenPages\Images\Author.jpg"></File><File path="LUFA\DoxygenPages\Images\LUFA.png"></File><File path="LUFA\DoxygenPages\Images\LUFA_thumb.png"></File></Folder><File path="LUFA\DoxygenPages\BuildingLinkableLibraries.txt"></File><File path="LUFA\DoxygenPages\ChangeLog.txt"></File><File path="LUFA\DoxygenPages\CompileTimeTokens.txt"></File><File path="LUFA\DoxygenPages\CompilingApps.txt"></File><File path="LUFA\DoxygenPages\ConfiguringApps.txt"></File><File path="LUFA\DoxygenPages\DevelopingWithLUFA.txt"></File><File path="LUFA\DoxygenPages\DeviceSupport.txt"></File><File path="LUFA\DoxygenPages\DirectorySummaries.txt"></File><File path="LUFA\DoxygenPages\Donating.txt"></File><File path="LUFA\DoxygenPages\FutureChanges.txt"></File><File path="LUFA\DoxygenPages\GettingStarted.txt"></File><File path="LUFA\DoxygenPages\Groups.txt"></File><File path="LUFA\DoxygenPages\LibraryResources.txt"></File><File path="LUFA\DoxygenPages\LicenseInfo.txt"></File><File path="LUFA\DoxygenPages\LUFAPoweredProjects.txt"></File><File path="LUFA\DoxygenPages\MainPage.txt"></File><File path="LUFA\DoxygenPages\MigrationInformation.txt"></File><File path="LUFA\DoxygenPages\ProgrammingApps.txt"></File><File path="LUFA\DoxygenPages\SoftwareBootloaderJump.txt"></File><File path="LUFA\DoxygenPages\VIDAndPIDValues.txt"></File><File path="LUFA\DoxygenPages\WritingBoardDrivers.txt"></File><File path="LUFA\DoxygenPages\ExportingLibrary.txt"></File></Folder><Folder name="Drivers"><Folder name="USB"><Folder name="Class"><Folder name="Device"><File path="LUFA\Drivers\USB\Class\Device\AudioClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\AudioClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\CDCClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\CDCClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\HIDClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\HIDClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\MassStorageClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\MassStorageClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\MIDIClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\MIDIClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\RNDISClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\RNDISClassDevice.h"></File></Folder><Folder name="Host"><File path="LUFA\Drivers\USB\Class\Host\AudioClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\AudioClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\CDCClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\CDCClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\HIDClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\HIDClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\MassStorageClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\MassStorageClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\MIDIClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\MIDIClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\PrinterClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\PrinterClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\RNDISClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\RNDISClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\StillImageClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\StillImageClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\AndroidAccessoryClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\AndroidAccessoryClassHost.h"></File></Folder><Folder name="Common"><File path="LUFA\Drivers\USB\Class\Common\AudioClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\CDCClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDParser.c"></File><File path="LUFA\Drivers\USB\Class\Common\HIDParser.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDReportData.h"></File><File path="LUFA\Drivers\USB\Class\Common\MassStorageClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\MIDIClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\PrinterClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\RNDISClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\StillImageClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\AndroidAccessoryClassCommon.h"></File></Folder><File path="LUFA\Drivers\USB\Class\AudioClass.h"></File><File path="LUFA\Drivers\USB\Class\CDCClass.h"></File><File path="LUFA\Drivers\USB\Class\HIDClass.h"></File><File path="LUFA\Drivers\USB\Class\MassStorageClass.h"></File><File path="LUFA\Drivers\USB\Class\MIDIClass.h"></File><File path="LUFA\Drivers\USB\Class\PrinterClass.h"></File><File path="LUFA\Drivers\USB\Class\RNDISClass.h"></File><File path="LUFA\Drivers\USB\Class\StillImageClass.h"></File><File path="LUFA\Drivers\USB\Class\AndroidAccessoryClass.h"></File></Folder><Folder name="Core"><Folder name="AVR8"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_RW.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Pipe_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\AVR8\Device_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Device_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Endpoint_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Endpoint_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Host_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Host_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\OTG_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Pipe_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Pipe_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBController_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBController_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBInterrupt_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBInterrupt_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\EndpointStream_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\EndpointStream_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\PipeStream_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\PipeStream_AVR8.h"></File></Folder><Folder name="UC3"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_RW.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Pipe_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\UC3\Device_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Device_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Endpoint_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Endpoint_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Pipe_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Pipe_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\USBController_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\USBController_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\USBInterrupt_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\USBInterrupt_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Host_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Host_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\EndpointStream_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\EndpointStream_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\PipeStream_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\PipeStream_UC3.h"></File></Folder><Folder name="XMEGA"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\XMEGA\Device_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Device_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Endpoint_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Endpoint_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\EndpointStream_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\EndpointStream_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Host_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Pipe_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\PipeStream_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBController_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBController_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBInterrupt_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBInterrupt_XMEGA.h"></File></Folder><File path="LUFA\Drivers\USB\Core\ConfigDescriptor.c"></File><File path="LUFA\Drivers\USB\Core\ConfigDescriptor.h"></File><File path="LUFA\Drivers\USB\Core\DeviceStandardReq.c"></File><File path="LUFA\Drivers\USB\Core\DeviceStandardReq.h"></File><File path="LUFA\Drivers\USB\Core\Events.c"></File><File path="LUFA\Drivers\USB\Core\Events.h"></File><File path="LUFA\Drivers\USB\Core\HostStandardReq.c"></File><File path="LUFA\Drivers\USB\Core\HostStandardReq.h"></File><File path="LUFA\Drivers\USB\Core\StdDescriptors.h"></File><File path="LUFA\Drivers\USB\Core\StdRequestType.h"></File><File path="LUFA\Drivers\USB\Core\USBMode.h"></File><File path="LUFA\Drivers\USB\Core\USBTask.c"></File><File path="LUFA\Drivers\USB\Core\USBTask.h"></File><File path="LUFA\Drivers\USB\Core\Device.h"></File><File path="LUFA\Drivers\USB\Core\Endpoint.h"></File><File path="LUFA\Drivers\USB\Core\Host.h"></File><File path="LUFA\Drivers\USB\Core\Pipe.h"></File><File path="LUFA\Drivers\USB\Core\USBController.h"></File><File path="LUFA\Drivers\USB\Core\USBInterrupt.h"></File><File path="LUFA\Drivers\USB\Core\OTG.h"></File><File path="LUFA\Drivers\USB\Core\EndpointStream.h"></File><File path="LUFA\Drivers\USB\Core\PipeStream.h"></File></Folder><File path="LUFA\Drivers\USB\USB.h"></File></Folder><Folder name="Misc"><File path="LUFA\Drivers\Misc\TerminalCodes.h"></File><File path="LUFA\Drivers\Misc\RingBuffer.h"></File><File path="LUFA\Drivers\Misc\AT45DB321C.h"></File><File path="LUFA\Drivers\Misc\AT45DB642D.h"></File></Folder><Folder name="Board"><Folder name="AVR8"><Folder name="ADAFRUITU4"><File path="LUFA\Drivers\Board\AVR8\ADAFRUITU4\LEDs.h"></File></Folder><Folder name="ATAVRUSBRF01"><File path="LUFA\Drivers\Board\AVR8\ATAVRUSBRF01\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\ATAVRUSBRF01\LEDs.h"></File></Folder><Folder name="BENITO"><File path="LUFA\Drivers\Board\AVR8\BENITO\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\BENITO\LEDs.h"></File></Folder><Folder name="BIGMULTIO"><File path="LUFA\Drivers\Board\AVR8\BIGMULTIO\LEDs.h"></File></Folder><Folder name="BLACKCAT"><File path="LUFA\Drivers\Board\AVR8\BLACKCAT\LEDs.h"></File></Folder><Folder name="BUI"><File path="LUFA\Drivers\Board\AVR8\BUI\LEDs.h"></File></Folder><Folder name="BUMBLEB"><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\LEDs.h"></File></Folder><Folder name="CULV3"><File path="LUFA\Drivers\Board\AVR8\CULV3\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\CULV3\LEDs.h"></File></Folder><Folder name="EVK527"><File path="LUFA\Drivers\Board\AVR8\EVK527\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\LEDs.h"></File></Folder><Folder name="JMDBU2"><File path="LUFA\Drivers\Board\AVR8\JMDBU2\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\JMDBU2\LEDs.h"></File></Folder><Folder name="MAXIMUS"><File path="LUFA\Drivers\Board\AVR8\MAXIMUS\LEDs.h"></File></Folder><Folder name="MICROPENDOUS"><File path="LUFA\Drivers\Board\AVR8\MICROPENDOUS\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MICROPENDOUS\LEDs.h"></File></Folder><Folder name="MICROSIN162"><File path="LUFA\Drivers\Board\AVR8\MICROSIN162\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MICROSIN162\LEDs.h"></File></Folder><Folder name="MINIMUS"><File path="LUFA\Drivers\Board\AVR8\MINIMUS\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MINIMUS\LEDs.h"></File></Folder><Folder name="MULTIO"><File path="LUFA\Drivers\Board\AVR8\MULTIO\LEDs.h"></File></Folder><Folder name="OLIMEX162"><File path="LUFA\Drivers\Board\AVR8\OLIMEX162\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\OLIMEX162\LEDs.h"></File></Folder><Folder name="RZUSBSTICK"><File path="LUFA\Drivers\Board\AVR8\RZUSBSTICK\LEDs.h"></File></Folder><Folder name="SPARKFUN8U2"><File path="LUFA\Drivers\Board\AVR8\SPARKFUN8U2\LEDs.h"></File></Folder><Folder name="STK525"><File path="LUFA\Drivers\Board\AVR8\STK525\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\LEDs.h"></File></Folder><Folder name="STK526"><File path="LUFA\Drivers\Board\AVR8\STK526\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\LEDs.h"></File></Folder><Folder name="TEENSY"><File path="LUFA\Drivers\Board\AVR8\TEENSY\LEDs.h"></File></Folder><Folder name="TUL"><File path="LUFA\Drivers\Board\AVR8\TUL\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\TUL\LEDs.h"></File></Folder><Folder name="UDIP"><File path="LUFA\Drivers\Board\AVR8\UDIP\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\UDIP\LEDs.h"></File></Folder><Folder name="UNO"><File path="LUFA\Drivers\Board\AVR8\UNO\LEDs.h"></File></Folder><Folder name="USB2AX"><File path="LUFA\Drivers\Board\AVR8\USB2AX\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USB2AX\LEDs.h"></File></Folder><Folder name="USBFOO"><File path="LUFA\Drivers\Board\AVR8\USBFOO\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBFOO\LEDs.h"></File></Folder><Folder name="USBKEY"><File path="LUFA\Drivers\Board\AVR8\USBKEY\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\LEDs.h"></File></Folder><Folder name="USBTINYMKII"><File path="LUFA\Drivers\Board\AVR8\USBTINYMKII\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBTINYMKII\LEDs.h"></File></Folder><Folder name="XPLAIN"><File path="LUFA\Drivers\Board\AVR8\XPLAIN\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\XPLAIN\LEDs.h"></File></Folder></Folder><Folder name="UC3"><Folder name="EVK1100"><File path="LUFA\Drivers\Board\UC3\EVK1100\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1100\Joystick.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1100\LEDs.h"></File></Folder><Folder name="EVK1101"><File path="LUFA\Drivers\Board\UC3\EVK1101\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1101\Joystick.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1101\LEDs.h"></File></Folder><Folder name="EVK1104"><File path="LUFA\Drivers\Board\UC3\EVK1104\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1104\LEDs.h"></File></Folder></Folder><Folder name="XMEGA"><Folder name="A3BU_XPLAINED"><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\Buttons.h"></File><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\LEDs.h"></File><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\Dataflash.h"></File></Folder><Folder name="B1_XPLAINED"><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\Buttons.h"></File><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\LEDs.h"></File><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\Dataflash.h"></File></Folder></Folder><File path="LUFA\Drivers\Board\Temperature.h"></File><File path="LUFA\Drivers\Board\Dataflash.h"></File><File path="LUFA\Drivers\Board\Joystick.h"></File><File path="LUFA\Drivers\Board\Temperature.c"></File><File path="LUFA\Drivers\Board\LEDs.h"></File><File path="LUFA\Drivers\Board\Buttons.h"></File></Folder><Folder name="Peripheral"><Folder name="AVR8"><File path="LUFA\Drivers\Peripheral\AVR8\ADC_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\Serial_AVR8.c"></File><File path="LUFA\Drivers\Peripheral\AVR8\Serial_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\SPI_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\TWI_AVR8.c"></File><File path="LUFA\Drivers\Peripheral\AVR8\TWI_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\SerialSPI_AVR8.h"></File></Folder><Folder name="UC3"></Folder><Folder name="XMEGA"><File path="LUFA\Drivers\Peripheral\XMEGA\SPI_XMEGA.h"></File><File path="LUFA\Drivers\Peripheral\XMEGA\Serial_XMEGA.c"></File><File path="LUFA\Drivers\Peripheral\XMEGA\Serial_XMEGA.h"></File><File path="LUFA\Drivers\Peripheral\XMEGA\SerialSPI_XMEGA.h"></File></Folder><File path="LUFA\Drivers\Peripheral\ADC.h"></File><File path="LUFA\Drivers\Peripheral\TWI.h"></File><File path="LUFA\Drivers\Peripheral\Serial.h"></File><File path="LUFA\Drivers\Peripheral\SPI.h"></File><File path="LUFA\Drivers\Peripheral\SerialSPI.h"></File></Folder></Folder><Folder name="Platform"><Folder name="AVR8"></Folder><Folder name="UC3"><File path="LUFA\Platform\UC3\InterruptManagement.h"></File><File path="LUFA\Platform\UC3\InterruptManagement.c"></File><File path="LUFA\Platform\UC3\Exception.S"></File><File path="LUFA\Platform\UC3\ClockManagement.h"></File></Folder><Folder name="XMEGA"><File path="LUFA\Platform\XMEGA\ClockManagement.h"></File></Folder></Folder><File path="LUFA\makefile"></File><File path="LUFA\Version.h"></File><File path="LUFA\Doxygen.conf"></File><File path="LUFA\License.txt"></File></Folder><Folder name="Bootloaders"><Folder name="CDC"><File path="Bootloaders\CDC\BootloaderCDC.c"></File><File path="Bootloaders\CDC\BootloaderCDC.h"></File><File path="Bootloaders\CDC\Descriptors.c"></File><File path="Bootloaders\CDC\Descriptors.h"></File><File path="Bootloaders\CDC\makefile"></File><File path="Bootloaders\CDC\LUFA CDC Bootloader.inf"></File><File path="Bootloaders\CDC\Doxygen.conf"></File><File path="Bootloaders\CDC\BootloaderCDC.txt"></File><File path="Bootloaders\CDC\BootloaderCDC.aps"></File><File path="Bootloaders\CDC\BootloaderAPI.c"></File><File path="Bootloaders\CDC\BootloaderAPI.h"></File><File path="Bootloaders\CDC\BootloaderAPITable.S"></File></Folder><Folder name="DFU"><File path="Bootloaders\DFU\BootloaderDFU.c"></File><File path="Bootloaders\DFU\BootloaderDFU.h"></File><File path="Bootloaders\DFU\Descriptors.c"></File><File path="Bootloaders\DFU\Descriptors.h"></File><File path="Bootloaders\DFU\makefile"></File><File path="Bootloaders\DFU\BootloaderDFU.txt"></File><File path="Bootloaders\DFU\Doxygen.conf"></File><File path="Bootloaders\DFU\BootloaderDFU.aps"></File><File path="Bootloaders\DFU\BootloaderAPI.c"></File><File path="Bootloaders\DFU\BootloaderAPI.h"></File><File path="Bootloaders\DFU\BootloaderAPITable.S"></File></Folder><Folder name="HID"><Folder name="HostLoaderApp"><File path="Bootloaders\HID\HostLoaderApp\gpl3.txt"></File><File path="Bootloaders\HID\HostLoaderApp\Makefile"></File><File path="Bootloaders\HID\HostLoaderApp\Makefile.bsd"></File><File path="Bootloaders\HID\HostLoaderApp\hid_bootloader_cli.c"></File></Folder><File path="Bootloaders\HID\Descriptors.c"></File><File path="Bootloaders\HID\Descriptors.h"></File><File path="Bootloaders\HID\makefile"></File><File path="Bootloaders\HID\BootloaderHID.txt"></File><File path="Bootloaders\HID\BootloaderHID.c"></File><File path="Bootloaders\HID\BootloaderHID.h"></File><File path="Bootloaders\HID\Doxygen.conf"></File><File path="Bootloaders\HID\BootloaderHID.aps"></File></Folder><File path="Bootloaders\makefile"></File></Folder><Folder name="Projects"><Folder name="AVRISP-MKII"><Folder name="Lib"><Folder name="ISP"><File path="Projects\AVRISP-MKII\Lib\ISP\ISPProtocol.c"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPProtocol.h"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPTarget.c"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPTarget.h"></File></Folder><Folder name="XPROG"><File path="Projects\AVRISP-MKII\Lib\XPROG\TINYNVM.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\TINYNVM.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XMEGANVM.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XMEGANVM.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGProtocol.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGProtocol.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGTarget.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGTarget.h"></File></Folder><File path="Projects\AVRISP-MKII\Lib\V2Protocol.c"></File><File path="Projects\AVRISP-MKII\Lib\V2Protocol.h"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolConstants.h"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolParams.c"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolParams.h"></File></Folder><File path="Projects\AVRISP-MKII\Descriptors.c"></File><File path="Projects\AVRISP-MKII\Descriptors.h"></File><File path="Projects\AVRISP-MKII\Doxygen.conf"></File><File path="Projects\AVRISP-MKII\makefile"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.c"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.h"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.txt"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.aps"></File></Folder><Folder name="Benito"><File path="Projects\Benito\Benito.c"></File><File path="Projects\Benito\Benito.h"></File><File path="Projects\Benito\Descriptors.c"></File><File path="Projects\Benito\Descriptors.h"></File><File path="Projects\Benito\Doxygen.conf"></File><File path="Projects\Benito\makefile"></File><File path="Projects\Benito\Benito.txt"></File><File path="Projects\Benito\Benito Programmer.inf"></File><File path="Projects\Benito\Benito.aps"></File></Folder><Folder name="HIDReportViewer"><File path="Projects\HIDReportViewer\HIDReportViewer.c"></File><File path="Projects\HIDReportViewer\HIDReportViewer.h"></File><File path="Projects\HIDReportViewer\makefile"></File><File path="Projects\HIDReportViewer\HIDReportViewer.txt"></File><File path="Projects\HIDReportViewer\Doxygen.conf"></File><File path="Projects\HIDReportViewer\HIDReportViewer.aps"></File></Folder><Folder name="LEDNotifier"><Folder name="CPUUsageApp"><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.cs"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.csproj"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.Designer.cs"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.resx"></File><File path="Projects\LEDNotifier\CPUUsageApp\Program.cs"></File></Folder><Folder name="HotmailNotifierApp"><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.cs"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.csproj"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.Designer.cs"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.resx"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\Program.cs"></File></Folder><Folder name="LEDMixerApp"><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.cs"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.csproj"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.Designer.cs"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.resx"></File><File path="Projects\LEDNotifier\LEDMixerApp\Program.cs"></File></Folder><File path="Projects\LEDNotifier\Descriptors.c"></File><File path="Projects\LEDNotifier\Descriptors.h"></File><File path="Projects\LEDNotifier\Doxygen.conf"></File><File path="Projects\LEDNotifier\LEDNotifier.c"></File><File path="Projects\LEDNotifier\LEDNotifier.h"></File><File path="Projects\LEDNotifier\LEDNotifier.txt"></File><File path="Projects\LEDNotifier\LUFA LED Notifier.inf"></File><File path="Projects\LEDNotifier\makefile"></File><File path="Projects\LEDNotifier\LEDNotifier.aps"></File></Folder><Folder name="MagStripe"><Folder name="Lib"><File path="Projects\Magstripe\Lib\CircularBitBuffer.c"></File><File path="Projects\Magstripe\Lib\CircularBitBuffer.h"></File><File path="Projects\Magstripe\Lib\MagstripeHW.h"></File></Folder><File path="Projects\Magstripe\Descriptors.c"></File><File path="Projects\Magstripe\Descriptors.h"></File><File path="Projects\Magstripe\Magstripe.c"></File><File path="Projects\Magstripe\Magstripe.h"></File><File path="Projects\Magstripe\makefile"></File><File path="Projects\Magstripe\Magstripe.txt"></File><File path="Projects\Magstripe\Doxygen.conf"></File><File path="Projects\Magstripe\Magstripe.aps"></File></Folder><Folder name="MediaController"><File path="Projects\MediaController\Descriptors.c"></File><File path="Projects\MediaController\Descriptors.h"></File><File path="Projects\MediaController\Doxygen.conf"></File><File path="Projects\MediaController\makefile"></File><File path="Projects\MediaController\MediaController.c"></File><File path="Projects\MediaController\MediaController.h"></File><File path="Projects\MediaController\MediaController.txt"></File><File path="Projects\MediaController\MediaController.aps"></File></Folder><Folder name="MIDIToneGenerator"><File path="Projects\MIDIToneGenerator\Descriptors.c"></File><File path="Projects\MIDIToneGenerator\Descriptors.h"></File><File path="Projects\MIDIToneGenerator\makefile"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.c"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.h"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.txt"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.aps"></File><File path="Projects\MIDIToneGenerator\Doxygen.conf"></File></Folder><Folder name="MissileLauncher"><File path="Projects\MissileLauncher\ConfigDescriptor.c"></File><File path="Projects\MissileLauncher\ConfigDescriptor.h"></File><File path="Projects\MissileLauncher\Doxygen.conf"></File><File path="Projects\MissileLauncher\makefile"></File><File path="Projects\MissileLauncher\MissileLauncher.c"></File><File path="Projects\MissileLauncher\MissileLauncher.h"></File><File path="Projects\MissileLauncher\MissileLauncher.txt"></File><File path="Projects\MissileLauncher\MissileLauncher.aps"></File></Folder><Folder name="RelayBoard"><File path="Projects\RelayBoard\Descriptors.c"></File><File path="Projects\RelayBoard\Descriptors.h"></File><File path="Projects\RelayBoard\Doxygen.conf"></File><File path="Projects\RelayBoard\makefile"></File><File path="Projects\RelayBoard\RelayBoard.c"></File><File path="Projects\RelayBoard\RelayBoard.h"></File><File path="Projects\RelayBoard\RelayBoard.txt"></File><File path="Projects\RelayBoard\RelayBoard.aps"></File></Folder><Folder name="TempDataLogger"><Folder name="Lib"><Folder name="FATFs"><File path="Projects\TempDataLogger\Lib\FATFs\diskio.c"></File><File path="Projects\TempDataLogger\Lib\FATFs\diskio.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\ff.c"></File><File path="Projects\TempDataLogger\Lib\FATFs\ff.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\ffconf.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\integer.h"></File></Folder><File path="Projects\TempDataLogger\Lib\DataflashManager.c"></File><File path="Projects\TempDataLogger\Lib\DataflashManager.h"></File><File path="Projects\TempDataLogger\Lib\DS1307.c"></File><File path="Projects\TempDataLogger\Lib\DS1307.h"></File><File path="Projects\TempDataLogger\Lib\SCSI.c"></File><File path="Projects\TempDataLogger\Lib\SCSI.h"></File></Folder><Folder name="TempLogHostApp"><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.Designer.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.resx"></File><File path="Projects\TempDataLogger\TempLogHostApp\Program.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\TempLoggerHostApp.csproj"></File></Folder><File path="Projects\TempDataLogger\Descriptors.c"></File><File path="Projects\TempDataLogger\Descriptors.h"></File><File path="Projects\TempDataLogger\Doxygen.conf"></File><File path="Projects\TempDataLogger\makefile"></File><File path="Projects\TempDataLogger\TempDataLogger.c"></File><File path="Projects\TempDataLogger\TempDataLogger.h"></File><File path="Projects\TempDataLogger\TemperatureDataLogger.txt"></File><File path="Projects\TempDataLogger\TempDataLogger.aps"></File></Folder><Folder name="USBtoSerial"><File path="Projects\USBtoSerial\Descriptors.h"></File><File path="Projects\USBtoSerial\Doxygen.conf"></File><File path="Projects\USBtoSerial\LUFA USBtoSerial.inf"></File><File path="Projects\USBtoSerial\makefile"></File><File path="Projects\USBtoSerial\USBtoSerial.c"></File><File path="Projects\USBtoSerial\USBtoSerial.h"></File><File path="Projects\USBtoSerial\USBtoSerial.txt"></File><File path="Projects\USBtoSerial\USBtoSerial.aps"></File><File path="Projects\USBtoSerial\Descriptors.c"></File></Folder><Folder name="Webserver"><Folder name="Lib"><Folder name="uip"><File path="Projects\Webserver\Lib\uip\clock.c"></File><File path="Projects\Webserver\Lib\uip\clock.h"></File><File path="Projects\Webserver\Lib\uip\timer.c"></File><File path="Projects\Webserver\Lib\uip\timer.h"></File><File path="Projects\Webserver\Lib\uip\uip.c"></File><File path="Projects\Webserver\Lib\uip\uip.h"></File><File path="Projects\Webserver\Lib\uip\uip_arp.c"></File><File path="Projects\Webserver\Lib\uip\uip_arp.h"></File><File path="Projects\Webserver\Lib\uip\uipopt.h"></File><File path="Projects\Webserver\Lib\uip\uip-split.c"></File><File path="Projects\Webserver\Lib\uip\uip-split.h"></File></Folder><Folder name="FATFs"><File path="Projects\Webserver\Lib\FATFs\diskio.c"></File><File path="Projects\Webserver\Lib\FATFs\diskio.h"></File><File path="Projects\Webserver\Lib\FATFs\ff.c"></File><File path="Projects\Webserver\Lib\FATFs\ff.h"></File><File path="Projects\Webserver\Lib\FATFs\ffconf.h"></File><File path="Projects\Webserver\Lib\FATFs\integer.h"></File></Folder><File path="Projects\Webserver\Lib\DataflashManager.c"></File><File path="Projects\Webserver\Lib\DataflashManager.h"></File><File path="Projects\Webserver\Lib\uIPManagement.c"></File><File path="Projects\Webserver\Lib\uIPManagement.h"></File><File path="Projects\Webserver\Lib\HTTPServerApp.c"></File><File path="Projects\Webserver\Lib\HTTPServerApp.h"></File><File path="Projects\Webserver\Lib\SCSI.c"></File><File path="Projects\Webserver\Lib\SCSI.h"></File><File path="Projects\Webserver\Lib\TELNETServerApp.c"></File><File path="Projects\Webserver\Lib\TELNETServerApp.h"></File><File path="Projects\Webserver\Lib\DHCPClientApp.c"></File><File path="Projects\Webserver\Lib\DHCPClientApp.h"></File><File path="Projects\Webserver\Lib\DHCPCommon.h"></File><File path="Projects\Webserver\Lib\DHCPServerApp.c"></File><File path="Projects\Webserver\Lib\DHCPServerApp.h"></File><File path="Projects\Webserver\Lib\DHCPCommon.c"></File></Folder><File path="Projects\Webserver\makefile"></File><File path="Projects\Webserver\Webserver.c"></File><File path="Projects\Webserver\Webserver.h"></File><File path="Projects\Webserver\Doxygen.conf"></File><File path="Projects\Webserver\Webserver.txt"></File><File path="Projects\Webserver\Descriptors.c"></File><File path="Projects\Webserver\Descriptors.h"></File><File path="Projects\Webserver\USBHostMode.c"></File><File path="Projects\Webserver\USBHostMode.h"></File><File path="Projects\Webserver\USBDeviceMode.c"></File><File path="Projects\Webserver\USBDeviceMode.h"></File><File path="Projects\Webserver\Webserver.aps"></File><File path="Projects\Webserver\LUFA Webserver RNDIS.inf"></File></Folder><Folder name="XPLAINBridge"><Folder name="Lib"><File path="Projects\XPLAINBridge\Lib\SoftUART.c"></File><File path="Projects\XPLAINBridge\Lib\SoftUART.h"></File></Folder><File path="Projects\XPLAINBridge\XPLAINBridge.txt"></File><File path="Projects\XPLAINBridge\XPLAINBridge.h"></File><File path="Projects\XPLAINBridge\XPLAINBridge.c"></File><File path="Projects\XPLAINBridge\XPLAINBridge.aps"></File><File path="Projects\XPLAINBridge\USARTDescriptors.h"></File><File path="Projects\XPLAINBridge\USARTDescriptors.c"></File><File path="Projects\XPLAINBridge\makefile"></File><File path="Projects\XPLAINBridge\LUFA XPLAIN Bridge.inf"></File><File path="Projects\XPLAINBridge\Doxygen.conf"></File><File path="Projects\XPLAINBridge\AVRISPDescriptors.h"></File><File path="Projects\XPLAINBridge\AVRISPDescriptors.c"></File></Folder><Folder name="Incomplete"><Folder name="StandaloneProgrammer"><Folder name="Lib"><Folder name="PetiteFATFs"><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\diskio.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\diskio.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\integer.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\pff.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\pff.h"></File></Folder><File path="Projects\Incomplete\StandaloneProgrammer\Lib\DataflashManager.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\DataflashManager.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\SCSI.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\SCSI.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\ProgrammerConfig.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\ProgrammerConfig.h"></File></Folder><File path="Projects\Incomplete\StandaloneProgrammer\Descriptors.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Descriptors.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\makefile"></File><File path="Projects\Incomplete\StandaloneProgrammer\StandaloneProgrammer.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\StandaloneProgrammer.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskDevice.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskDevice.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskHost.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskHost.h"></File></Folder></Folder><File path="Projects\makefile"></File></Folder><Folder name="BuildTests"><Folder name="ModuleTest"><File path="BuildTests\ModuleTest\makefile"></File><File path="BuildTests\ModuleTest\makefile.avr8"></File><File path="BuildTests\ModuleTest\makefile.uc3"></File><File path="BuildTests\ModuleTest\makefile.xmega"></File><File path="BuildTests\ModuleTest\Modules.h"></File><File path="BuildTests\ModuleTest\Test_C.c"></File><File path="BuildTests\ModuleTest\Test_CPP.cpp"></File><File path="BuildTests\ModuleTest\Dummy.S"></File></Folder><Folder name="SingleUSBModeTest"><File path="BuildTests\SingleUSBModeTest\Dummy.S"></File><File path="BuildTests\SingleUSBModeTest\makefile"></File><File path="BuildTests\SingleUSBModeTest\makefile.avr8"></File><File path="BuildTests\SingleUSBModeTest\makefile.uc3"></File><File path="BuildTests\SingleUSBModeTest\makefile.xmega"></File><File path="BuildTests\SingleUSBModeTest\Test.c"></File></Folder><Folder name="StaticAnalysisTest"><File path="BuildTests\StaticAnalysisTest\makefile"></File></Folder><File path="BuildTests\makefile"></File></Folder><Folder name="Maintenance"><File path="Maintenance\makefile"></File></Folder><File path="makefile"></File><File path="README.txt"></File></Project>
\ No newline at end of file
+<Project name="LUFA"><Folder name="Demos"><Folder name="Device"><Folder name="ClassDriver"><Folder name="AudioInput"><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.c"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.h"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.txt"></File><File path="Demos\Device\ClassDriver\AudioInput\Descriptors.c"></File><File path="Demos\Device\ClassDriver\AudioInput\Descriptors.h"></File><File path="Demos\Device\ClassDriver\AudioInput\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\AudioInput\makefile"></File><File path="Demos\Device\ClassDriver\AudioInput\AudioInput.aps"></File></Folder><Folder name="AudioOutput"><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.c"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.h"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.txt"></File><File path="Demos\Device\ClassDriver\AudioOutput\Descriptors.c"></File><File path="Demos\Device\ClassDriver\AudioOutput\Descriptors.h"></File><File path="Demos\Device\ClassDriver\AudioOutput\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\AudioOutput\makefile"></File><File path="Demos\Device\ClassDriver\AudioOutput\AudioOutput.aps"></File></Folder><Folder name="DualVirtualSerial"><File path="Demos\Device\ClassDriver\DualVirtualSerial\Descriptors.c"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\Descriptors.h"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.c"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.h"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.txt"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\LUFA DualVirtualSerial.inf"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\makefile"></File><File path="Demos\Device\ClassDriver\DualVirtualSerial\DualVirtualSerial.aps"></File></Folder><Folder name="GenericHID"><File path="Demos\Device\ClassDriver\GenericHID\Descriptors.c"></File><File path="Demos\Device\ClassDriver\GenericHID\Descriptors.h"></File><File path="Demos\Device\ClassDriver\GenericHID\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.c"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.h"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.txt"></File><File path="Demos\Device\ClassDriver\GenericHID\makefile"></File><File path="Demos\Device\ClassDriver\GenericHID\GenericHID.aps"></File></Folder><Folder name="Joystick"><File path="Demos\Device\ClassDriver\Joystick\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Joystick\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Joystick\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.c"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.h"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.txt"></File><File path="Demos\Device\ClassDriver\Joystick\makefile"></File><File path="Demos\Device\ClassDriver\Joystick\Joystick.aps"></File></Folder><Folder name="Keyboard"><File path="Demos\Device\ClassDriver\Keyboard\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Keyboard\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Keyboard\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.c"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.h"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.txt"></File><File path="Demos\Device\ClassDriver\Keyboard\makefile"></File><File path="Demos\Device\ClassDriver\Keyboard\Keyboard.aps"></File></Folder><Folder name="KeyboardMouse"><File path="Demos\Device\ClassDriver\KeyboardMouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.txt"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\makefile"></File><File path="Demos\Device\ClassDriver\KeyboardMouse\KeyboardMouse.aps"></File></Folder><Folder name="KeyboardMouseMultiReport"><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Descriptors.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Descriptors.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.c"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.h"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.txt"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\makefile"></File><File path="Demos\Device\ClassDriver\KeyboardMouseMultiReport\KeyboardMouseMultiReport.aps"></File></Folder><Folder name="MassStorage"><Folder name="Lib"><File path="Demos\Device\ClassDriver\MassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\MassStorage\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MassStorage\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MassStorage\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MassStorage\makefile"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.c"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.h"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.txt"></File><File path="Demos\Device\ClassDriver\MassStorage\MassStorage.aps"></File></Folder><Folder name="MassStorageKeyboard"><Folder name="Lib"><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\makefile"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.c"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.h"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.txt"></File><File path="Demos\Device\ClassDriver\MassStorageKeyboard\MassStorageKeyboard.aps"></File></Folder><Folder name="MIDI"><File path="Demos\Device\ClassDriver\MIDI\Descriptors.c"></File><File path="Demos\Device\ClassDriver\MIDI\Descriptors.h"></File><File path="Demos\Device\ClassDriver\MIDI\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\MIDI\makefile"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.c"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.h"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.txt"></File><File path="Demos\Device\ClassDriver\MIDI\MIDI.aps"></File></Folder><Folder name="Mouse"><File path="Demos\Device\ClassDriver\Mouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\Mouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\Mouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\Mouse\makefile"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.c"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.h"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.txt"></File><File path="Demos\Device\ClassDriver\Mouse\Mouse.aps"></File></Folder><Folder name="RNDISEthernet"><Folder name="Lib"><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Webserver.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ARP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ARP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\DHCP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\DHCP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Ethernet.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Ethernet.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\EthernetProtocols.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ICMP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ICMP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\IP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\IP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ProtocolDecoders.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\ProtocolDecoders.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\TCP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\TCP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\UDP.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\UDP.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Lib\Webserver.c"></File></Folder><File path="Demos\Device\ClassDriver\RNDISEthernet\Descriptors.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Descriptors.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\LUFA RNDIS.inf"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\makefile"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.c"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.h"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.txt"></File><File path="Demos\Device\ClassDriver\RNDISEthernet\RNDISEthernet.aps"></File></Folder><Folder name="VirtualSerial"><File path="Demos\Device\ClassDriver\VirtualSerial\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerial\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerial\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerial\LUFA VirtualSerial.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerial\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.c"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.h"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerial\VirtualSerial.aps"></File></Folder><Folder name="VirtualSerialMassStorage"><Folder name="Lib"><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\SCSI.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\LUFA VirtualSerialMassStorage.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMassStorage\VirtualSerialMassStorage.aps"></File></Folder><Folder name="VirtualSerialMouse"><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Descriptors.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Descriptors.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\Doxygen.conf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\LUFA VirtualSerialMouse.inf"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\makefile"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.c"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.h"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.txt"></File><File path="Demos\Device\ClassDriver\VirtualSerialMouse\VirtualSerialMouse.aps"></File></Folder><File path="Demos\Device\ClassDriver\makefile"></File></Folder><Folder name="LowLevel"><Folder name="AudioInput"><File path="Demos\Device\LowLevel\AudioInput\AudioInput.c"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.h"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.txt"></File><File path="Demos\Device\LowLevel\AudioInput\Descriptors.c"></File><File path="Demos\Device\LowLevel\AudioInput\Descriptors.h"></File><File path="Demos\Device\LowLevel\AudioInput\Doxygen.conf"></File><File path="Demos\Device\LowLevel\AudioInput\makefile"></File><File path="Demos\Device\LowLevel\AudioInput\AudioInput.aps"></File></Folder><Folder name="AudioOutput"><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.c"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.h"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.txt"></File><File path="Demos\Device\LowLevel\AudioOutput\Descriptors.c"></File><File path="Demos\Device\LowLevel\AudioOutput\Descriptors.h"></File><File path="Demos\Device\LowLevel\AudioOutput\Doxygen.conf"></File><File path="Demos\Device\LowLevel\AudioOutput\makefile"></File><File path="Demos\Device\LowLevel\AudioOutput\AudioOutput.aps"></File></Folder><Folder name="DualVirtualSerial"><File path="Demos\Device\LowLevel\DualVirtualSerial\Descriptors.c"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\Descriptors.h"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\Doxygen.conf"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.c"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.h"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.txt"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\LUFA DualVirtualSerial.inf"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\makefile"></File><File path="Demos\Device\LowLevel\DualVirtualSerial\DualVirtualSerial.aps"></File></Folder><Folder name="GenericHID"><File path="Demos\Device\LowLevel\GenericHID\Descriptors.c"></File><File path="Demos\Device\LowLevel\GenericHID\Descriptors.h"></File><File path="Demos\Device\LowLevel\GenericHID\Doxygen.conf"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.c"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.h"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.txt"></File><File path="Demos\Device\LowLevel\GenericHID\makefile"></File><File path="Demos\Device\LowLevel\GenericHID\GenericHID.aps"></File></Folder><Folder name="Joystick"><File path="Demos\Device\LowLevel\Joystick\Descriptors.c"></File><File path="Demos\Device\LowLevel\Joystick\Descriptors.h"></File><File path="Demos\Device\LowLevel\Joystick\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.c"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.h"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.txt"></File><File path="Demos\Device\LowLevel\Joystick\makefile"></File><File path="Demos\Device\LowLevel\Joystick\Joystick.aps"></File></Folder><Folder name="Keyboard"><File path="Demos\Device\LowLevel\Keyboard\Descriptors.c"></File><File path="Demos\Device\LowLevel\Keyboard\Descriptors.h"></File><File path="Demos\Device\LowLevel\Keyboard\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.c"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.h"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.txt"></File><File path="Demos\Device\LowLevel\Keyboard\makefile"></File><File path="Demos\Device\LowLevel\Keyboard\Keyboard.aps"></File></Folder><Folder name="KeyboardMouse"><File path="Demos\Device\LowLevel\KeyboardMouse\Descriptors.c"></File><File path="Demos\Device\LowLevel\KeyboardMouse\Descriptors.h"></File><File path="Demos\Device\LowLevel\KeyboardMouse\Doxygen.conf"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.c"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.h"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.txt"></File><File path="Demos\Device\LowLevel\KeyboardMouse\makefile"></File><File path="Demos\Device\LowLevel\KeyboardMouse\KeyboardMouse.aps"></File></Folder><Folder name="MassStorage"><Folder name="Lib"><File path="Demos\Device\LowLevel\MassStorage\Lib\DataflashManager.c"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\DataflashManager.h"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\SCSI.c"></File><File path="Demos\Device\LowLevel\MassStorage\Lib\SCSI.h"></File></Folder><File path="Demos\Device\LowLevel\MassStorage\Descriptors.c"></File><File path="Demos\Device\LowLevel\MassStorage\Descriptors.h"></File><File path="Demos\Device\LowLevel\MassStorage\Doxygen.conf"></File><File path="Demos\Device\LowLevel\MassStorage\makefile"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.c"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.h"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.txt"></File><File path="Demos\Device\LowLevel\MassStorage\MassStorage.aps"></File></Folder><Folder name="MIDI"><File path="Demos\Device\LowLevel\MIDI\Descriptors.c"></File><File path="Demos\Device\LowLevel\MIDI\Descriptors.h"></File><File path="Demos\Device\LowLevel\MIDI\Doxygen.conf"></File><File path="Demos\Device\LowLevel\MIDI\makefile"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.c"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.h"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.txt"></File><File path="Demos\Device\LowLevel\MIDI\MIDI.aps"></File></Folder><Folder name="Mouse"><File path="Demos\Device\LowLevel\Mouse\Descriptors.c"></File><File path="Demos\Device\LowLevel\Mouse\Descriptors.h"></File><File path="Demos\Device\LowLevel\Mouse\Doxygen.conf"></File><File path="Demos\Device\LowLevel\Mouse\makefile"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.c"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.h"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.txt"></File><File path="Demos\Device\LowLevel\Mouse\Mouse.aps"></File></Folder><Folder name="RNDISEthernet"><Folder name="Lib"><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Webserver.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ARP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ARP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\DHCP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\DHCP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Ethernet.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Ethernet.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\EthernetProtocols.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ICMP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ICMP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\IP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\IP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ProtocolDecoders.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\ProtocolDecoders.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\RNDIS.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\RNDIS.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\TCP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\TCP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\UDP.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\UDP.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Lib\Webserver.c"></File></Folder><File path="Demos\Device\LowLevel\RNDISEthernet\Descriptors.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Descriptors.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\Doxygen.conf"></File><File path="Demos\Device\LowLevel\RNDISEthernet\LUFA RNDIS.inf"></File><File path="Demos\Device\LowLevel\RNDISEthernet\makefile"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.c"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.h"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.txt"></File><File path="Demos\Device\LowLevel\RNDISEthernet\RNDISEthernet.aps"></File></Folder><Folder name="VirtualSerial"><File path="Demos\Device\LowLevel\VirtualSerial\Descriptors.c"></File><File path="Demos\Device\LowLevel\VirtualSerial\Descriptors.h"></File><File path="Demos\Device\LowLevel\VirtualSerial\Doxygen.conf"></File><File path="Demos\Device\LowLevel\VirtualSerial\LUFA VirtualSerial.inf"></File><File path="Demos\Device\LowLevel\VirtualSerial\makefile"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.c"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.h"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.txt"></File><File path="Demos\Device\LowLevel\VirtualSerial\VirtualSerial.aps"></File></Folder><File path="Demos\Device\LowLevel\makefile"></File></Folder><Folder name="Incomplete"><Folder name="SideShow"><Folder name="Lib"><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowApplications.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowApplications.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommands.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommands.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommon.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowCommon.h"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowContent.c"></File><File path="Demos\Device\Incomplete\Sideshow\Lib\SideshowContent.h"></File></Folder><File path="Demos\Device\Incomplete\Sideshow\Descriptors.c"></File><File path="Demos\Device\Incomplete\Sideshow\Descriptors.h"></File><File path="Demos\Device\Incomplete\Sideshow\makefile"></File><File path="Demos\Device\Incomplete\Sideshow\Sideshow.c"></File><File path="Demos\Device\Incomplete\Sideshow\Sideshow.h"></File></Folder><Folder name="TestAndMeasurement"><File path="Demos\Device\Incomplete\TestAndMeasurement\Descriptors.c"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\Descriptors.h"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\TestAndMeasurement.c"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\TestAndMeasurement.h"></File><File path="Demos\Device\Incomplete\TestAndMeasurement\makefile"></File></Folder></Folder><File path="Demos\Device\makefile"></File></Folder><Folder name="Host"><Folder name="ClassDriver"><Folder name="AndroidAccessoryHost"><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.c"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.h"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.txt"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\makefile"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AndroidAccessoryHost\AndroidAccessoryHost.aps"></File></Folder><Folder name="AudioInputHost"><File path="Demos\Host\ClassDriver\AudioInputHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AudioInputHost\makefile"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.c"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.h"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.aps"></File><File path="Demos\Host\ClassDriver\AudioInputHost\AudioInputHost.txt"></File></Folder><Folder name="AudioOutputHost"><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.c"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.h"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\makefile"></File><File path="Demos\Host\ClassDriver\AudioOutputHost\AudioOutputHost.txt"></File></Folder><Folder name="JoystickHostWithParser"><File path="Demos\Host\ClassDriver\JoystickHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.c"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.h"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\JoystickHostWithParser\JoystickHostWithParser.aps"></File></Folder><Folder name="KeyboardHost"><File path="Demos\Host\ClassDriver\KeyboardHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.c"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.h"></File><File path="Demos\Host\ClassDriver\KeyboardHost\makefile"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.txt"></File><File path="Demos\Host\ClassDriver\KeyboardHost\KeyboardHost.aps"></File></Folder><Folder name="KeyboardHostWithParser"><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.c"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.h"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\KeyboardHostWithParser\KeyboardHostWithParser.aps"></File></Folder><Folder name="MassStorageHost"><File path="Demos\Host\ClassDriver\MassStorageHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MassStorageHost\makefile"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.c"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.h"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.txt"></File><File path="Demos\Host\ClassDriver\MassStorageHost\MassStorageHost.aps"></File></Folder><Folder name="MIDIHost"><File path="Demos\Host\ClassDriver\MIDIHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MIDIHost\makefile"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.c"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.h"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.txt"></File><File path="Demos\Host\ClassDriver\MIDIHost\MIDIHost.aps"></File></Folder><Folder name="MouseHost"><File path="Demos\Host\ClassDriver\MouseHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MouseHost\makefile"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.c"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.h"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.txt"></File><File path="Demos\Host\ClassDriver\MouseHost\MouseHost.aps"></File></Folder><Folder name="MouseHostWithParser"><File path="Demos\Host\ClassDriver\MouseHostWithParser\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\makefile"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.txt"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.c"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.h"></File><File path="Demos\Host\ClassDriver\MouseHostWithParser\MouseHostWithParser.aps"></File></Folder><Folder name="PrinterHost"><File path="Demos\Host\ClassDriver\PrinterHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\PrinterHost\makefile"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.c"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.h"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.txt"></File><File path="Demos\Host\ClassDriver\PrinterHost\PrinterHost.aps"></File></Folder><Folder name="RNDISEthernetHost"><File path="Demos\Host\ClassDriver\RNDISEthernetHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\makefile"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.c"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.h"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.txt"></File><File path="Demos\Host\ClassDriver\RNDISEthernetHost\RNDISEthernetHost.aps"></File></Folder><Folder name="StillImageHost"><File path="Demos\Host\ClassDriver\StillImageHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\StillImageHost\makefile"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.c"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.h"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.txt"></File><File path="Demos\Host\ClassDriver\StillImageHost\StillImageHost.aps"></File></Folder><Folder name="VirtualSerialHost"><File path="Demos\Host\ClassDriver\VirtualSerialHost\Doxygen.conf"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\makefile"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.c"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.h"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.txt"></File><File path="Demos\Host\ClassDriver\VirtualSerialHost\VirtualSerialHost.aps"></File></Folder><File path="Demos\Host\ClassDriver\makefile"></File></Folder><Folder name="LowLevel"><Folder name="AndroidAccessoryHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Lib\AndroidAccessoryCommands.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Lib\AndroidAccessoryCommands.h"></File></Folder><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\DeviceDescriptor.c"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\DeviceDescriptor.h"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\makefile"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.txt"></File><File path="Demos\Host\LowLevel\AndroidAccessoryHost\AndroidAccessoryHost.aps"></File></Folder><Folder name="AudioInputHost"><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.c"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.h"></File><File path="Demos\Host\LowLevel\AudioInputHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AudioInputHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AudioInputHost\makefile"></File><File path="Demos\Host\LowLevel\AudioInputHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.aps"></File><File path="Demos\Host\LowLevel\AudioInputHost\AudioInputHost.txt"></File></Folder><Folder name="AudioOutputHost"><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.c"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.h"></File><File path="Demos\Host\LowLevel\AudioOutputHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\AudioOutputHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\AudioOutputHost\makefile"></File><File path="Demos\Host\LowLevel\AudioOutputHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.aps"></File><File path="Demos\Host\LowLevel\AudioOutputHost\AudioOutputHost.txt"></File></Folder><Folder name="GenericHIDHost"><File path="Demos\Host\LowLevel\GenericHIDHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\GenericHIDHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\GenericHIDHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.c"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.h"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.txt"></File><File path="Demos\Host\LowLevel\GenericHIDHost\makefile"></File><File path="Demos\Host\LowLevel\GenericHIDHost\GenericHIDHost.aps"></File></Folder><Folder name="JoystickHostWithParser"><File path="Demos\Host\LowLevel\JoystickHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.c"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.h"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.txt"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\JoystickHostWithParser\JoystickHostWithParser.aps"></File></Folder><Folder name="KeyboardHost"><File path="Demos\Host\LowLevel\KeyboardHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\KeyboardHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\KeyboardHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.c"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.h"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.txt"></File><File path="Demos\Host\LowLevel\KeyboardHost\makefile"></File><File path="Demos\Host\LowLevel\KeyboardHost\KeyboardHost.aps"></File></Folder><Folder name="KeyboardHostWithParser"><File path="Demos\Host\LowLevel\KeyboardHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.c"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.h"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.txt"></File><File path="Demos\Host\LowLevel\KeyboardHostWithParser\KeyboardHostWithParser.aps"></File></Folder><Folder name="MassStorageHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\MassStorageHost\Lib\MassStoreCommands.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\Lib\MassStoreCommands.h"></File></Folder><File path="Demos\Host\LowLevel\MassStorageHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MassStorageHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MassStorageHost\makefile"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.c"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.h"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.txt"></File><File path="Demos\Host\LowLevel\MassStorageHost\MassStorageHost.aps"></File></Folder><Folder name="MIDIHost"><File path="Demos\Host\LowLevel\MIDIHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MIDIHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MIDIHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MIDIHost\makefile"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.c"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.h"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.txt"></File><File path="Demos\Host\LowLevel\MIDIHost\MIDIHost.aps"></File></Folder><Folder name="MouseHost"><File path="Demos\Host\LowLevel\MouseHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MouseHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MouseHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MouseHost\makefile"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.c"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.h"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.txt"></File><File path="Demos\Host\LowLevel\MouseHost\MouseHost.aps"></File></Folder><Folder name="MouseHostWithParser"><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.txt"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\Doxygen.conf"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\HIDReport.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\HIDReport.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\makefile"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.c"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.h"></File><File path="Demos\Host\LowLevel\MouseHostWithParser\MouseHostWithParser.aps"></File></Folder><Folder name="PrinterHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\PrinterHost\Lib\PrinterCommands.c"></File><File path="Demos\Host\LowLevel\PrinterHost\Lib\PrinterCommands.h"></File></Folder><File path="Demos\Host\LowLevel\PrinterHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\PrinterHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\PrinterHost\makefile"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.c"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.h"></File><File path="Demos\Host\LowLevel\PrinterHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.txt"></File><File path="Demos\Host\LowLevel\PrinterHost\PrinterHost.aps"></File></Folder><Folder name="RNDISEthernetHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\RNDISEthernetHost\Lib\RNDISCommands.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\Lib\RNDISCommands.h"></File></Folder><File path="Demos\Host\LowLevel\RNDISEthernetHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\makefile"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.c"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.h"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISHost.txt"></File><File path="Demos\Host\LowLevel\RNDISEthernetHost\RNDISEthernetHost.aps"></File></Folder><Folder name="StillImageHost"><Folder name="Lib"><File path="Demos\Host\LowLevel\StillImageHost\Lib\StillImageCommands.c"></File><File path="Demos\Host\LowLevel\StillImageHost\Lib\StillImageCommands.h"></File><File path="Demos\Host\LowLevel\StillImageHost\Lib\PIMACodes.h"></File></Folder><File path="Demos\Host\LowLevel\StillImageHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\StillImageHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\StillImageHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\StillImageHost\makefile"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.c"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.h"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.txt"></File><File path="Demos\Host\LowLevel\StillImageHost\StillImageHost.aps"></File></Folder><Folder name="VirtualSerialHost"><File path="Demos\Host\LowLevel\VirtualSerialHost\ConfigDescriptor.c"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\ConfigDescriptor.h"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\Doxygen.conf"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\makefile"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.c"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.h"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.txt"></File><File path="Demos\Host\LowLevel\VirtualSerialHost\VirtualSerialHost.aps"></File></Folder><File path="Demos\Host\LowLevel\makefile"></File></Folder><Folder name="Incomplete"><Folder name="BluetoothHost"><Folder name="Lib"><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothACLPackets.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothACLPackets.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothClassCodes.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothHCICommands.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothHCICommands.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothStack.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\BluetoothStack.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDPServices.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDPServices.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMM.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMM.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDP.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\SDP.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMMControl.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\Lib\RFCOMMControl.h"></File></Folder><File path="Demos\Host\Incomplete\BluetoothHost\makefile"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothHost.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothHost.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\ConfigDescriptor.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\ConfigDescriptor.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\DeviceDescriptor.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\DeviceDescriptor.h"></File><File path="Demos\Host\Incomplete\BluetoothHost\Doxygen.conf"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothEvents.c"></File><File path="Demos\Host\Incomplete\BluetoothHost\BluetoothEvents.h"></File></Folder></Folder><File path="Demos\Host\makefile"></File></Folder><Folder name="DualRole"><Folder name="ClassDriver"><Folder name="MouseHostDevice"><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Doxygen.conf"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\makefile"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Descriptors.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\Descriptors.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\DeviceFunctions.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\HostFunctions.c"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\HostFunctions.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\DeviceFunctions.h"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.txt"></File><File path="Demos\DualRole\ClassDriver\MouseHostDevice\MouseHostDevice.aps"></File></Folder><File path="Demos\DualRole\ClassDriver\makefile"></File></Folder><File path="Demos\DualRole\makefile"></File></Folder><File path="Demos\makefile"></File></Folder><Folder name="LUFA"><Folder name="CodeTemplates"><Folder name="DriverStubs"><File path="LUFA\CodeTemplates\DriverStubs\Buttons.h"></File><File path="LUFA\CodeTemplates\DriverStubs\Dataflash.h"></File><File path="LUFA\CodeTemplates\DriverStubs\Joystick.h"></File><File path="LUFA\CodeTemplates\DriverStubs\LEDs.h"></File></Folder><File path="LUFA\CodeTemplates\makefile_template.avr8"></File><File path="LUFA\CodeTemplates\makefile_template.uc3"></File><File path="LUFA\CodeTemplates\makefile_template.xmega"></File><File path="LUFA\CodeTemplates\LUFAConfig.h"></File></Folder><Folder name="Common"><File path="LUFA\Common\Common.h"></File><File path="LUFA\Common\BoardTypes.h"></File><File path="LUFA\Common\Attributes.h"></File><File path="LUFA\Common\Architectures.h"></File><File path="LUFA\Common\Endianness.h"></File><File path="LUFA\Common\CompilerSpecific.h"></File><File path="LUFA\Common\ArchitectureSpecific.h"></File></Folder><Folder name="DoxygenPages"><Folder name="Style"><File path="LUFA\DoxygenPages\Style\Footer.htm"></File><File path="LUFA\DoxygenPages\Style\Style.css"></File></Folder><Folder name="Images"><Folder name="AS5_AS6_Import"><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step1.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step2.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step3.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step4.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_1.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_2.png"></File><File path="LUFA\DoxygenPages\Images\AS5_AS6_Import\AS5_AS6_Import_Step5_3.png"></File></Folder><File path="LUFA\DoxygenPages\Images\Author.jpg"></File><File path="LUFA\DoxygenPages\Images\LUFA.png"></File><File path="LUFA\DoxygenPages\Images\LUFA_thumb.png"></File></Folder><File path="LUFA\DoxygenPages\BuildingLinkableLibraries.txt"></File><File path="LUFA\DoxygenPages\ChangeLog.txt"></File><File path="LUFA\DoxygenPages\CompileTimeTokens.txt"></File><File path="LUFA\DoxygenPages\CompilingApps.txt"></File><File path="LUFA\DoxygenPages\ConfiguringApps.txt"></File><File path="LUFA\DoxygenPages\DevelopingWithLUFA.txt"></File><File path="LUFA\DoxygenPages\DeviceSupport.txt"></File><File path="LUFA\DoxygenPages\DirectorySummaries.txt"></File><File path="LUFA\DoxygenPages\Donating.txt"></File><File path="LUFA\DoxygenPages\FutureChanges.txt"></File><File path="LUFA\DoxygenPages\GettingStarted.txt"></File><File path="LUFA\DoxygenPages\Groups.txt"></File><File path="LUFA\DoxygenPages\LibraryResources.txt"></File><File path="LUFA\DoxygenPages\LicenseInfo.txt"></File><File path="LUFA\DoxygenPages\LUFAPoweredProjects.txt"></File><File path="LUFA\DoxygenPages\MainPage.txt"></File><File path="LUFA\DoxygenPages\MigrationInformation.txt"></File><File path="LUFA\DoxygenPages\ProgrammingApps.txt"></File><File path="LUFA\DoxygenPages\SoftwareBootloaderJump.txt"></File><File path="LUFA\DoxygenPages\VIDAndPIDValues.txt"></File><File path="LUFA\DoxygenPages\WritingBoardDrivers.txt"></File><File path="LUFA\DoxygenPages\ExportingLibrary.txt"></File><File path="LUFA\DoxygenPages\KnownIssues.txt"></File></Folder><Folder name="Drivers"><Folder name="USB"><Folder name="Class"><Folder name="Device"><File path="LUFA\Drivers\USB\Class\Device\AudioClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\AudioClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\CDCClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\CDCClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\HIDClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\HIDClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\MassStorageClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\MassStorageClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\MIDIClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\MIDIClassDevice.h"></File><File path="LUFA\Drivers\USB\Class\Device\RNDISClassDevice.c"></File><File path="LUFA\Drivers\USB\Class\Device\RNDISClassDevice.h"></File></Folder><Folder name="Host"><File path="LUFA\Drivers\USB\Class\Host\AudioClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\AudioClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\CDCClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\CDCClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\HIDClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\HIDClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\MassStorageClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\MassStorageClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\MIDIClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\MIDIClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\PrinterClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\PrinterClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\RNDISClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\RNDISClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\StillImageClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\StillImageClassHost.h"></File><File path="LUFA\Drivers\USB\Class\Host\AndroidAccessoryClassHost.c"></File><File path="LUFA\Drivers\USB\Class\Host\AndroidAccessoryClassHost.h"></File></Folder><Folder name="Common"><File path="LUFA\Drivers\USB\Class\Common\AudioClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\CDCClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDParser.c"></File><File path="LUFA\Drivers\USB\Class\Common\HIDParser.h"></File><File path="LUFA\Drivers\USB\Class\Common\HIDReportData.h"></File><File path="LUFA\Drivers\USB\Class\Common\MassStorageClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\MIDIClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\PrinterClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\RNDISClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\StillImageClassCommon.h"></File><File path="LUFA\Drivers\USB\Class\Common\AndroidAccessoryClassCommon.h"></File></Folder><File path="LUFA\Drivers\USB\Class\AudioClass.h"></File><File path="LUFA\Drivers\USB\Class\CDCClass.h"></File><File path="LUFA\Drivers\USB\Class\HIDClass.h"></File><File path="LUFA\Drivers\USB\Class\MassStorageClass.h"></File><File path="LUFA\Drivers\USB\Class\MIDIClass.h"></File><File path="LUFA\Drivers\USB\Class\PrinterClass.h"></File><File path="LUFA\Drivers\USB\Class\RNDISClass.h"></File><File path="LUFA\Drivers\USB\Class\StillImageClass.h"></File><File path="LUFA\Drivers\USB\Class\AndroidAccessoryClass.h"></File></Folder><Folder name="Core"><Folder name="AVR8"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Endpoint_RW.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Template\Template_Pipe_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\AVR8\Device_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Device_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Endpoint_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Endpoint_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Host_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Host_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\OTG_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\Pipe_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\Pipe_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBController_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBController_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBInterrupt_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\USBInterrupt_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\EndpointStream_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\EndpointStream_AVR8.h"></File><File path="LUFA\Drivers\USB\Core\AVR8\PipeStream_AVR8.c"></File><File path="LUFA\Drivers\USB\Core\AVR8\PipeStream_AVR8.h"></File></Folder><Folder name="UC3"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Endpoint_RW.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Template\Template_Pipe_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\UC3\Device_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Device_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Endpoint_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Endpoint_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Pipe_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Pipe_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\USBController_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\USBController_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\USBInterrupt_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\USBInterrupt_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\Host_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\Host_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\EndpointStream_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\EndpointStream_UC3.h"></File><File path="LUFA\Drivers\USB\Core\UC3\PipeStream_UC3.c"></File><File path="LUFA\Drivers\USB\Core\UC3\PipeStream_UC3.h"></File></Folder><Folder name="XMEGA"><Folder name="Template"><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_Control_R.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_Control_W.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Template\Template_Endpoint_RW.c"></File></Folder><File path="LUFA\Drivers\USB\Core\XMEGA\Device_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Device_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Endpoint_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Endpoint_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\EndpointStream_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\EndpointStream_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Host_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\Pipe_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\PipeStream_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBController_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBController_XMEGA.h"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBInterrupt_XMEGA.c"></File><File path="LUFA\Drivers\USB\Core\XMEGA\USBInterrupt_XMEGA.h"></File></Folder><File path="LUFA\Drivers\USB\Core\ConfigDescriptor.c"></File><File path="LUFA\Drivers\USB\Core\ConfigDescriptor.h"></File><File path="LUFA\Drivers\USB\Core\DeviceStandardReq.c"></File><File path="LUFA\Drivers\USB\Core\DeviceStandardReq.h"></File><File path="LUFA\Drivers\USB\Core\Events.c"></File><File path="LUFA\Drivers\USB\Core\Events.h"></File><File path="LUFA\Drivers\USB\Core\HostStandardReq.c"></File><File path="LUFA\Drivers\USB\Core\HostStandardReq.h"></File><File path="LUFA\Drivers\USB\Core\StdDescriptors.h"></File><File path="LUFA\Drivers\USB\Core\StdRequestType.h"></File><File path="LUFA\Drivers\USB\Core\USBMode.h"></File><File path="LUFA\Drivers\USB\Core\USBTask.c"></File><File path="LUFA\Drivers\USB\Core\USBTask.h"></File><File path="LUFA\Drivers\USB\Core\Device.h"></File><File path="LUFA\Drivers\USB\Core\Endpoint.h"></File><File path="LUFA\Drivers\USB\Core\Host.h"></File><File path="LUFA\Drivers\USB\Core\Pipe.h"></File><File path="LUFA\Drivers\USB\Core\USBController.h"></File><File path="LUFA\Drivers\USB\Core\USBInterrupt.h"></File><File path="LUFA\Drivers\USB\Core\OTG.h"></File><File path="LUFA\Drivers\USB\Core\EndpointStream.h"></File><File path="LUFA\Drivers\USB\Core\PipeStream.h"></File></Folder><File path="LUFA\Drivers\USB\USB.h"></File></Folder><Folder name="Misc"><File path="LUFA\Drivers\Misc\TerminalCodes.h"></File><File path="LUFA\Drivers\Misc\RingBuffer.h"></File><File path="LUFA\Drivers\Misc\AT45DB321C.h"></File><File path="LUFA\Drivers\Misc\AT45DB642D.h"></File></Folder><Folder name="Board"><Folder name="AVR8"><Folder name="ADAFRUITU4"><File path="LUFA\Drivers\Board\AVR8\ADAFRUITU4\LEDs.h"></File></Folder><Folder name="ATAVRUSBRF01"><File path="LUFA\Drivers\Board\AVR8\ATAVRUSBRF01\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\ATAVRUSBRF01\LEDs.h"></File></Folder><Folder name="BENITO"><File path="LUFA\Drivers\Board\AVR8\BENITO\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\BENITO\LEDs.h"></File></Folder><Folder name="BIGMULTIO"><File path="LUFA\Drivers\Board\AVR8\BIGMULTIO\LEDs.h"></File></Folder><Folder name="BLACKCAT"><File path="LUFA\Drivers\Board\AVR8\BLACKCAT\LEDs.h"></File></Folder><Folder name="BUI"><File path="LUFA\Drivers\Board\AVR8\BUI\LEDs.h"></File></Folder><Folder name="BUMBLEB"><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\BUMBLEB\LEDs.h"></File></Folder><Folder name="CULV3"><File path="LUFA\Drivers\Board\AVR8\CULV3\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\CULV3\LEDs.h"></File></Folder><Folder name="DUCE"><File path="LUFA\Drivers\Board\AVR8\DUCE\LEDs.h"></File></Folder><Folder name="EVK527"><File path="LUFA\Drivers\Board\AVR8\EVK527\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\EVK527\LEDs.h"></File></Folder><Folder name="JMDBU2"><File path="LUFA\Drivers\Board\AVR8\JMDBU2\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\JMDBU2\LEDs.h"></File></Folder><Folder name="MAXIMUS"><File path="LUFA\Drivers\Board\AVR8\MAXIMUS\LEDs.h"></File></Folder><Folder name="MICROPENDOUS"><File path="LUFA\Drivers\Board\AVR8\MICROPENDOUS\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MICROPENDOUS\LEDs.h"></File></Folder><Folder name="MICROSIN162"><File path="LUFA\Drivers\Board\AVR8\MICROSIN162\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MICROSIN162\LEDs.h"></File></Folder><Folder name="MINIMUS"><File path="LUFA\Drivers\Board\AVR8\MINIMUS\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\MINIMUS\LEDs.h"></File></Folder><Folder name="MULTIO"><File path="LUFA\Drivers\Board\AVR8\MULTIO\LEDs.h"></File></Folder><Folder name="OLIMEX32U4"><File path="LUFA\Drivers\Board\AVR8\OLIMEX32U4\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\OLIMEX32U4\LEDs.h"></File></Folder><Folder name="OLIMEX162"><File path="LUFA\Drivers\Board\AVR8\OLIMEX162\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\OLIMEX162\LEDs.h"></File></Folder><Folder name="OLIMEXT32U4"><File path="LUFA\Drivers\Board\AVR8\OLIMEXT32U4\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\OLIMEXT32U4\LEDs.h"></File></Folder><Folder name="RZUSBSTICK"><File path="LUFA\Drivers\Board\AVR8\RZUSBSTICK\LEDs.h"></File></Folder><Folder name="SPARKFUN8U2"><File path="LUFA\Drivers\Board\AVR8\SPARKFUN8U2\LEDs.h"></File></Folder><Folder name="STK525"><File path="LUFA\Drivers\Board\AVR8\STK525\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\STK525\LEDs.h"></File></Folder><Folder name="STK526"><File path="LUFA\Drivers\Board\AVR8\STK526\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\STK526\LEDs.h"></File></Folder><Folder name="TEENSY"><File path="LUFA\Drivers\Board\AVR8\TEENSY\LEDs.h"></File></Folder><Folder name="TUL"><File path="LUFA\Drivers\Board\AVR8\TUL\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\TUL\LEDs.h"></File></Folder><Folder name="UDIP"><File path="LUFA\Drivers\Board\AVR8\UDIP\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\UDIP\LEDs.h"></File></Folder><Folder name="UNO"><File path="LUFA\Drivers\Board\AVR8\UNO\LEDs.h"></File></Folder><Folder name="USB2AX"><File path="LUFA\Drivers\Board\AVR8\USB2AX\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USB2AX\LEDs.h"></File></Folder><Folder name="USBFOO"><File path="LUFA\Drivers\Board\AVR8\USBFOO\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBFOO\LEDs.h"></File></Folder><Folder name="USBKEY"><File path="LUFA\Drivers\Board\AVR8\USBKEY\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\Joystick.h"></File><File path="LUFA\Drivers\Board\AVR8\USBKEY\LEDs.h"></File></Folder><Folder name="USBTINYMKII"><File path="LUFA\Drivers\Board\AVR8\USBTINYMKII\Buttons.h"></File><File path="LUFA\Drivers\Board\AVR8\USBTINYMKII\LEDs.h"></File></Folder><Folder name="XPLAIN"><File path="LUFA\Drivers\Board\AVR8\XPLAIN\Dataflash.h"></File><File path="LUFA\Drivers\Board\AVR8\XPLAIN\LEDs.h"></File></Folder></Folder><Folder name="UC3"><Folder name="EVK1100"><File path="LUFA\Drivers\Board\UC3\EVK1100\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1100\Joystick.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1100\LEDs.h"></File></Folder><Folder name="EVK1101"><File path="LUFA\Drivers\Board\UC3\EVK1101\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1101\Joystick.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1101\LEDs.h"></File></Folder><Folder name="EVK1104"><File path="LUFA\Drivers\Board\UC3\EVK1104\Buttons.h"></File><File path="LUFA\Drivers\Board\UC3\EVK1104\LEDs.h"></File></Folder></Folder><Folder name="XMEGA"><Folder name="A3BU_XPLAINED"><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\Buttons.h"></File><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\LEDs.h"></File><File path="LUFA\Drivers\Board\XMEGA\A3BU_XPLAINED\Dataflash.h"></File></Folder><Folder name="B1_XPLAINED"><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\Buttons.h"></File><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\LEDs.h"></File><File path="LUFA\Drivers\Board\XMEGA\B1_XPLAINED\Dataflash.h"></File></Folder></Folder><File path="LUFA\Drivers\Board\Temperature.h"></File><File path="LUFA\Drivers\Board\Dataflash.h"></File><File path="LUFA\Drivers\Board\Joystick.h"></File><File path="LUFA\Drivers\Board\Temperature.c"></File><File path="LUFA\Drivers\Board\LEDs.h"></File><File path="LUFA\Drivers\Board\Buttons.h"></File></Folder><Folder name="Peripheral"><Folder name="AVR8"><File path="LUFA\Drivers\Peripheral\AVR8\ADC_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\Serial_AVR8.c"></File><File path="LUFA\Drivers\Peripheral\AVR8\Serial_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\SPI_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\TWI_AVR8.c"></File><File path="LUFA\Drivers\Peripheral\AVR8\TWI_AVR8.h"></File><File path="LUFA\Drivers\Peripheral\AVR8\SerialSPI_AVR8.h"></File></Folder><Folder name="UC3"></Folder><Folder name="XMEGA"><File path="LUFA\Drivers\Peripheral\XMEGA\SPI_XMEGA.h"></File><File path="LUFA\Drivers\Peripheral\XMEGA\Serial_XMEGA.c"></File><File path="LUFA\Drivers\Peripheral\XMEGA\Serial_XMEGA.h"></File><File path="LUFA\Drivers\Peripheral\XMEGA\SerialSPI_XMEGA.h"></File></Folder><File path="LUFA\Drivers\Peripheral\ADC.h"></File><File path="LUFA\Drivers\Peripheral\TWI.h"></File><File path="LUFA\Drivers\Peripheral\Serial.h"></File><File path="LUFA\Drivers\Peripheral\SPI.h"></File><File path="LUFA\Drivers\Peripheral\SerialSPI.h"></File></Folder></Folder><Folder name="Platform"><Folder name="AVR8"></Folder><Folder name="UC3"><File path="LUFA\Platform\UC3\InterruptManagement.h"></File><File path="LUFA\Platform\UC3\InterruptManagement.c"></File><File path="LUFA\Platform\UC3\Exception.S"></File><File path="LUFA\Platform\UC3\ClockManagement.h"></File></Folder><Folder name="XMEGA"><File path="LUFA\Platform\XMEGA\ClockManagement.h"></File></Folder></Folder><File path="LUFA\makefile"></File><File path="LUFA\Version.h"></File><File path="LUFA\Doxygen.conf"></File><File path="LUFA\License.txt"></File></Folder><Folder name="Bootloaders"><Folder name="CDC"><Folder name="Config"><File path="Bootloaders\CDC\Config\LUFAConfig.h"></File></Folder><File path="Bootloaders\CDC\BootloaderCDC.c"></File><File path="Bootloaders\CDC\BootloaderCDC.h"></File><File path="Bootloaders\CDC\Descriptors.c"></File><File path="Bootloaders\CDC\Descriptors.h"></File><File path="Bootloaders\CDC\makefile"></File><File path="Bootloaders\CDC\LUFA CDC Bootloader.inf"></File><File path="Bootloaders\CDC\Doxygen.conf"></File><File path="Bootloaders\CDC\BootloaderCDC.txt"></File><File path="Bootloaders\CDC\BootloaderCDC.aps"></File><File path="Bootloaders\CDC\BootloaderAPI.c"></File><File path="Bootloaders\CDC\BootloaderAPI.h"></File><File path="Bootloaders\CDC\BootloaderAPITable.S"></File></Folder><Folder name="DFU"><File path="Bootloaders\DFU\BootloaderDFU.c"></File><File path="Bootloaders\DFU\BootloaderDFU.h"></File><File path="Bootloaders\DFU\Descriptors.c"></File><File path="Bootloaders\DFU\Descriptors.h"></File><File path="Bootloaders\DFU\makefile"></File><File path="Bootloaders\DFU\BootloaderDFU.txt"></File><File path="Bootloaders\DFU\Doxygen.conf"></File><File path="Bootloaders\DFU\BootloaderDFU.aps"></File><File path="Bootloaders\DFU\BootloaderAPI.c"></File><File path="Bootloaders\DFU\BootloaderAPI.h"></File><File path="Bootloaders\DFU\BootloaderAPITable.S"></File></Folder><Folder name="HID"><Folder name="HostLoaderApp"><File path="Bootloaders\HID\HostLoaderApp\gpl3.txt"></File><File path="Bootloaders\HID\HostLoaderApp\Makefile"></File><File path="Bootloaders\HID\HostLoaderApp\Makefile.bsd"></File><File path="Bootloaders\HID\HostLoaderApp\hid_bootloader_cli.c"></File></Folder><File path="Bootloaders\HID\Descriptors.c"></File><File path="Bootloaders\HID\Descriptors.h"></File><File path="Bootloaders\HID\makefile"></File><File path="Bootloaders\HID\BootloaderHID.txt"></File><File path="Bootloaders\HID\BootloaderHID.c"></File><File path="Bootloaders\HID\BootloaderHID.h"></File><File path="Bootloaders\HID\Doxygen.conf"></File><File path="Bootloaders\HID\BootloaderHID.aps"></File></Folder><File path="Bootloaders\makefile"></File></Folder><Folder name="Projects"><Folder name="AVRISP-MKII"><Folder name="Lib"><Folder name="ISP"><File path="Projects\AVRISP-MKII\Lib\ISP\ISPProtocol.c"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPProtocol.h"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPTarget.c"></File><File path="Projects\AVRISP-MKII\Lib\ISP\ISPTarget.h"></File></Folder><Folder name="XPROG"><File path="Projects\AVRISP-MKII\Lib\XPROG\TINYNVM.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\TINYNVM.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XMEGANVM.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XMEGANVM.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGProtocol.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGProtocol.h"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGTarget.c"></File><File path="Projects\AVRISP-MKII\Lib\XPROG\XPROGTarget.h"></File></Folder><File path="Projects\AVRISP-MKII\Lib\V2Protocol.c"></File><File path="Projects\AVRISP-MKII\Lib\V2Protocol.h"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolConstants.h"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolParams.c"></File><File path="Projects\AVRISP-MKII\Lib\V2ProtocolParams.h"></File></Folder><File path="Projects\AVRISP-MKII\Descriptors.c"></File><File path="Projects\AVRISP-MKII\Descriptors.h"></File><File path="Projects\AVRISP-MKII\Doxygen.conf"></File><File path="Projects\AVRISP-MKII\makefile"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.c"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.h"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.txt"></File><File path="Projects\AVRISP-MKII\AVRISP-MKII.aps"></File></Folder><Folder name="Benito"><File path="Projects\Benito\Benito.c"></File><File path="Projects\Benito\Benito.h"></File><File path="Projects\Benito\Descriptors.c"></File><File path="Projects\Benito\Descriptors.h"></File><File path="Projects\Benito\Doxygen.conf"></File><File path="Projects\Benito\makefile"></File><File path="Projects\Benito\Benito.txt"></File><File path="Projects\Benito\Benito Programmer.inf"></File><File path="Projects\Benito\Benito.aps"></File></Folder><Folder name="HIDReportViewer"><File path="Projects\HIDReportViewer\HIDReportViewer.c"></File><File path="Projects\HIDReportViewer\HIDReportViewer.h"></File><File path="Projects\HIDReportViewer\makefile"></File><File path="Projects\HIDReportViewer\HIDReportViewer.txt"></File><File path="Projects\HIDReportViewer\Doxygen.conf"></File><File path="Projects\HIDReportViewer\HIDReportViewer.aps"></File></Folder><Folder name="LEDNotifier"><Folder name="CPUUsageApp"><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.cs"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.csproj"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.Designer.cs"></File><File path="Projects\LEDNotifier\CPUUsageApp\CPUMonitor.resx"></File><File path="Projects\LEDNotifier\CPUUsageApp\Program.cs"></File></Folder><Folder name="HotmailNotifierApp"><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.cs"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.csproj"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.Designer.cs"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\MailNotifier.resx"></File><File path="Projects\LEDNotifier\HotmailNotifierApp\Program.cs"></File></Folder><Folder name="LEDMixerApp"><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.cs"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.csproj"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.Designer.cs"></File><File path="Projects\LEDNotifier\LEDMixerApp\LEDMixer.resx"></File><File path="Projects\LEDNotifier\LEDMixerApp\Program.cs"></File></Folder><File path="Projects\LEDNotifier\Descriptors.c"></File><File path="Projects\LEDNotifier\Descriptors.h"></File><File path="Projects\LEDNotifier\Doxygen.conf"></File><File path="Projects\LEDNotifier\LEDNotifier.c"></File><File path="Projects\LEDNotifier\LEDNotifier.h"></File><File path="Projects\LEDNotifier\LEDNotifier.txt"></File><File path="Projects\LEDNotifier\LUFA LED Notifier.inf"></File><File path="Projects\LEDNotifier\makefile"></File><File path="Projects\LEDNotifier\LEDNotifier.aps"></File></Folder><Folder name="MagStripe"><Folder name="Lib"><File path="Projects\Magstripe\Lib\CircularBitBuffer.c"></File><File path="Projects\Magstripe\Lib\CircularBitBuffer.h"></File><File path="Projects\Magstripe\Lib\MagstripeHW.h"></File></Folder><File path="Projects\Magstripe\Descriptors.c"></File><File path="Projects\Magstripe\Descriptors.h"></File><File path="Projects\Magstripe\Magstripe.c"></File><File path="Projects\Magstripe\Magstripe.h"></File><File path="Projects\Magstripe\makefile"></File><File path="Projects\Magstripe\Magstripe.txt"></File><File path="Projects\Magstripe\Doxygen.conf"></File><File path="Projects\Magstripe\Magstripe.aps"></File></Folder><Folder name="MediaController"><File path="Projects\MediaController\Descriptors.c"></File><File path="Projects\MediaController\Descriptors.h"></File><File path="Projects\MediaController\Doxygen.conf"></File><File path="Projects\MediaController\makefile"></File><File path="Projects\MediaController\MediaController.c"></File><File path="Projects\MediaController\MediaController.h"></File><File path="Projects\MediaController\MediaController.txt"></File><File path="Projects\MediaController\MediaController.aps"></File></Folder><Folder name="MIDIToneGenerator"><File path="Projects\MIDIToneGenerator\Descriptors.c"></File><File path="Projects\MIDIToneGenerator\Descriptors.h"></File><File path="Projects\MIDIToneGenerator\makefile"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.c"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.h"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.txt"></File><File path="Projects\MIDIToneGenerator\MIDIToneGenerator.aps"></File><File path="Projects\MIDIToneGenerator\Doxygen.conf"></File></Folder><Folder name="MissileLauncher"><File path="Projects\MissileLauncher\ConfigDescriptor.c"></File><File path="Projects\MissileLauncher\ConfigDescriptor.h"></File><File path="Projects\MissileLauncher\Doxygen.conf"></File><File path="Projects\MissileLauncher\makefile"></File><File path="Projects\MissileLauncher\MissileLauncher.c"></File><File path="Projects\MissileLauncher\MissileLauncher.h"></File><File path="Projects\MissileLauncher\MissileLauncher.txt"></File><File path="Projects\MissileLauncher\MissileLauncher.aps"></File></Folder><Folder name="RelayBoard"><File path="Projects\RelayBoard\Descriptors.c"></File><File path="Projects\RelayBoard\Descriptors.h"></File><File path="Projects\RelayBoard\Doxygen.conf"></File><File path="Projects\RelayBoard\makefile"></File><File path="Projects\RelayBoard\RelayBoard.c"></File><File path="Projects\RelayBoard\RelayBoard.h"></File><File path="Projects\RelayBoard\RelayBoard.txt"></File><File path="Projects\RelayBoard\RelayBoard.aps"></File></Folder><Folder name="SerialToLCD"><Folder name="Lib"><File path="Projects\SerialToLCD\Lib\HD44780.c"></File><File path="Projects\SerialToLCD\Lib\HD44780.h"></File></Folder><File path="Projects\SerialToLCD\Descriptors.c"></File><File path="Projects\SerialToLCD\Descriptors.h"></File><File path="Projects\SerialToLCD\makefile"></File><File path="Projects\SerialToLCD\SerialToLCD.c"></File><File path="Projects\SerialToLCD\SerialToLCD.h"></File><File path="Projects\SerialToLCD\SerialToLCD.txt"></File><File path="Projects\SerialToLCD\Doxygen.conf"></File></Folder><Folder name="TempDataLogger"><Folder name="Lib"><Folder name="FATFs"><File path="Projects\TempDataLogger\Lib\FATFs\diskio.c"></File><File path="Projects\TempDataLogger\Lib\FATFs\diskio.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\ff.c"></File><File path="Projects\TempDataLogger\Lib\FATFs\ff.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\ffconf.h"></File><File path="Projects\TempDataLogger\Lib\FATFs\integer.h"></File></Folder><File path="Projects\TempDataLogger\Lib\DataflashManager.c"></File><File path="Projects\TempDataLogger\Lib\DataflashManager.h"></File><File path="Projects\TempDataLogger\Lib\DS1307.c"></File><File path="Projects\TempDataLogger\Lib\DS1307.h"></File><File path="Projects\TempDataLogger\Lib\SCSI.c"></File><File path="Projects\TempDataLogger\Lib\SCSI.h"></File></Folder><Folder name="TempLogHostApp"><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.Designer.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\DataLoggerSettings.resx"></File><File path="Projects\TempDataLogger\TempLogHostApp\Program.cs"></File><File path="Projects\TempDataLogger\TempLogHostApp\TempLoggerHostApp.csproj"></File></Folder><File path="Projects\TempDataLogger\Descriptors.c"></File><File path="Projects\TempDataLogger\Descriptors.h"></File><File path="Projects\TempDataLogger\Doxygen.conf"></File><File path="Projects\TempDataLogger\makefile"></File><File path="Projects\TempDataLogger\TempDataLogger.c"></File><File path="Projects\TempDataLogger\TempDataLogger.h"></File><File path="Projects\TempDataLogger\TemperatureDataLogger.txt"></File><File path="Projects\TempDataLogger\TempDataLogger.aps"></File></Folder><Folder name="USBtoSerial"><File path="Projects\USBtoSerial\Descriptors.h"></File><File path="Projects\USBtoSerial\Doxygen.conf"></File><File path="Projects\USBtoSerial\LUFA USBtoSerial.inf"></File><File path="Projects\USBtoSerial\makefile"></File><File path="Projects\USBtoSerial\USBtoSerial.c"></File><File path="Projects\USBtoSerial\USBtoSerial.h"></File><File path="Projects\USBtoSerial\USBtoSerial.txt"></File><File path="Projects\USBtoSerial\USBtoSerial.aps"></File><File path="Projects\USBtoSerial\Descriptors.c"></File></Folder><Folder name="Webserver"><Folder name="Lib"><Folder name="uip"><File path="Projects\Webserver\Lib\uip\clock.c"></File><File path="Projects\Webserver\Lib\uip\clock.h"></File><File path="Projects\Webserver\Lib\uip\timer.c"></File><File path="Projects\Webserver\Lib\uip\timer.h"></File><File path="Projects\Webserver\Lib\uip\uip.c"></File><File path="Projects\Webserver\Lib\uip\uip.h"></File><File path="Projects\Webserver\Lib\uip\uip_arp.c"></File><File path="Projects\Webserver\Lib\uip\uip_arp.h"></File><File path="Projects\Webserver\Lib\uip\uipopt.h"></File><File path="Projects\Webserver\Lib\uip\uip-split.c"></File><File path="Projects\Webserver\Lib\uip\uip-split.h"></File></Folder><Folder name="FATFs"><File path="Projects\Webserver\Lib\FATFs\diskio.c"></File><File path="Projects\Webserver\Lib\FATFs\diskio.h"></File><File path="Projects\Webserver\Lib\FATFs\ff.c"></File><File path="Projects\Webserver\Lib\FATFs\ff.h"></File><File path="Projects\Webserver\Lib\FATFs\ffconf.h"></File><File path="Projects\Webserver\Lib\FATFs\integer.h"></File></Folder><File path="Projects\Webserver\Lib\DataflashManager.c"></File><File path="Projects\Webserver\Lib\DataflashManager.h"></File><File path="Projects\Webserver\Lib\uIPManagement.c"></File><File path="Projects\Webserver\Lib\uIPManagement.h"></File><File path="Projects\Webserver\Lib\HTTPServerApp.c"></File><File path="Projects\Webserver\Lib\HTTPServerApp.h"></File><File path="Projects\Webserver\Lib\SCSI.c"></File><File path="Projects\Webserver\Lib\SCSI.h"></File><File path="Projects\Webserver\Lib\TELNETServerApp.c"></File><File path="Projects\Webserver\Lib\TELNETServerApp.h"></File><File path="Projects\Webserver\Lib\DHCPClientApp.c"></File><File path="Projects\Webserver\Lib\DHCPClientApp.h"></File><File path="Projects\Webserver\Lib\DHCPCommon.h"></File><File path="Projects\Webserver\Lib\DHCPServerApp.c"></File><File path="Projects\Webserver\Lib\DHCPServerApp.h"></File><File path="Projects\Webserver\Lib\DHCPCommon.c"></File></Folder><File path="Projects\Webserver\makefile"></File><File path="Projects\Webserver\Webserver.c"></File><File path="Projects\Webserver\Webserver.h"></File><File path="Projects\Webserver\Doxygen.conf"></File><File path="Projects\Webserver\Webserver.txt"></File><File path="Projects\Webserver\Descriptors.c"></File><File path="Projects\Webserver\Descriptors.h"></File><File path="Projects\Webserver\USBHostMode.c"></File><File path="Projects\Webserver\USBHostMode.h"></File><File path="Projects\Webserver\USBDeviceMode.c"></File><File path="Projects\Webserver\USBDeviceMode.h"></File><File path="Projects\Webserver\Webserver.aps"></File><File path="Projects\Webserver\LUFA Webserver RNDIS.inf"></File></Folder><Folder name="XPLAINBridge"><Folder name="Lib"><File path="Projects\XPLAINBridge\Lib\SoftUART.c"></File><File path="Projects\XPLAINBridge\Lib\SoftUART.h"></File></Folder><File path="Projects\XPLAINBridge\XPLAINBridge.txt"></File><File path="Projects\XPLAINBridge\XPLAINBridge.h"></File><File path="Projects\XPLAINBridge\XPLAINBridge.c"></File><File path="Projects\XPLAINBridge\XPLAINBridge.aps"></File><File path="Projects\XPLAINBridge\USARTDescriptors.h"></File><File path="Projects\XPLAINBridge\USARTDescriptors.c"></File><File path="Projects\XPLAINBridge\makefile"></File><File path="Projects\XPLAINBridge\LUFA XPLAIN Bridge.inf"></File><File path="Projects\XPLAINBridge\Doxygen.conf"></File><File path="Projects\XPLAINBridge\AVRISPDescriptors.h"></File><File path="Projects\XPLAINBridge\AVRISPDescriptors.c"></File></Folder><Folder name="Incomplete"><Folder name="StandaloneProgrammer"><Folder name="Lib"><Folder name="PetiteFATFs"><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\diskio.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\diskio.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\integer.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\pff.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\PetiteFATFs\pff.h"></File></Folder><File path="Projects\Incomplete\StandaloneProgrammer\Lib\DataflashManager.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\DataflashManager.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\SCSI.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\SCSI.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\ProgrammerConfig.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Lib\ProgrammerConfig.h"></File></Folder><File path="Projects\Incomplete\StandaloneProgrammer\Descriptors.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\Descriptors.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\makefile"></File><File path="Projects\Incomplete\StandaloneProgrammer\StandaloneProgrammer.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\StandaloneProgrammer.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskDevice.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskDevice.h"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskHost.c"></File><File path="Projects\Incomplete\StandaloneProgrammer\DiskHost.h"></File></Folder></Folder><File path="Projects\makefile"></File></Folder><Folder name="BuildTests"><Folder name="BoardDriverTest"><Folder name="Board"><File path="BuildTests\BoardDriverTest\Board\Buttons.h"></File><File path="BuildTests\BoardDriverTest\Board\Dataflash.h"></File><File path="BuildTests\BoardDriverTest\Board\Joystick.h"></File><File path="BuildTests\BoardDriverTest\Board\LEDs.h"></File></Folder><File path="BuildTests\BoardDriverTest\BoardDeviceMap.cfg"></File><File path="BuildTests\BoardDriverTest\makefile"></File><File path="BuildTests\BoardDriverTest\makefile.avr8"></File><File path="BuildTests\BoardDriverTest\makefile.uc3"></File><File path="BuildTests\BoardDriverTest\makefile.xmega"></File><File path="BuildTests\BoardDriverTest\Test.c"></File></Folder><Folder name="ModuleTest"><File path="BuildTests\ModuleTest\makefile"></File><File path="BuildTests\ModuleTest\makefile.avr8"></File><File path="BuildTests\ModuleTest\makefile.uc3"></File><File path="BuildTests\ModuleTest\makefile.xmega"></File><File path="BuildTests\ModuleTest\Modules.h"></File><File path="BuildTests\ModuleTest\Test_C.c"></File><File path="BuildTests\ModuleTest\Test_CPP.cpp"></File><File path="BuildTests\ModuleTest\Dummy.S"></File></Folder><Folder name="SingleUSBModeTest"><File path="BuildTests\SingleUSBModeTest\makefile"></File><File path="BuildTests\SingleUSBModeTest\makefile.avr8"></File><File path="BuildTests\SingleUSBModeTest\makefile.uc3"></File><File path="BuildTests\SingleUSBModeTest\makefile.xmega"></File><File path="BuildTests\SingleUSBModeTest\Test.c"></File><File path="BuildTests\SingleUSBModeTest\Dummy.S"></File></Folder><Folder name="StaticAnalysisTest"><File path="BuildTests\StaticAnalysisTest\makefile"></File></Folder><File path="BuildTests\makefile"></File></Folder><Folder name="Maintenance"><File path="Maintenance\makefile"></File></Folder><File path="makefile"></File><File path="README.txt"></File></Project>
\ No newline at end of file
index 35e8f65..0c9dca3 100644 (file)
 //      #define NO_AUTO_VBUS_MANAGEMENT
 //      #define INVERTED_VBUS_ENABLE_LINE
 
+       #else
+
+               #error Unsupported architecture for this LUFA configuration file.
+
        #endif
 #endif
 
index 3ba7a5c..f7dca66 100644 (file)
 
        /* Public Interface - May be used in end-application: */
                /* Macros: */
-                       #if (ARCH == ARCH_AVR8) || defined(__DOXYGEN__)
-                               /** Disables the AVR's JTAG bus in software, until a system reset. This will override the current JTAG
-                                *  status as set by the JTAGEN fuse, disabling JTAG debugging and reverting the JTAG pins back to GPIO
-                                *  mode.
-                                *
-                                *  \note This macro is not available for all architectures.
-                                */
-                               #define JTAG_DISABLE()                  MACROS{                                      \
-                                                                               __asm__ __volatile__ (               \
-                                                                               "in __tmp_reg__,__SREG__" "\n\t"     \
-                                                                               "cli" "\n\t"                         \
-                                                                               "out %1, %0" "\n\t"                  \
-                                                                               "out __SREG__, __tmp_reg__" "\n\t"   \
-                                                                               "out %1, %0" "\n\t"                  \
-                                                                               :                                    \
-                                                                               : "r" (1 << JTD),                    \
-                                                                                 "M" (_SFR_IO_ADDR(MCUCR))          \
-                                                                               : "r0");                             \
-                                                                       }MACROE
+                       #if (ARCH == ARCH_AVR8) || (ARCH == ARCH_XMEGA) || defined(__DOXYGEN__)
+                               #if (ARCH == ARCH_AVR8) || defined(__DOXYGEN__)
+                                       /** Disables the AVR's JTAG bus in software, until a system reset. This will override the current JTAG
+                                        *  status as set by the JTAGEN fuse, disabling JTAG debugging and reverting the JTAG pins back to GPIO
+                                        *  mode.
+                                        *
+                                        *  \note This macro is not available for all architectures.
+                                        */
+                                       #define JTAG_DISABLE()                  MACROS{                                      \
+                                                                                                                                       __asm__ __volatile__ (               \
+                                                                                                                                       "in __tmp_reg__,__SREG__" "\n\t"     \
+                                                                                                                                       "cli" "\n\t"                         \
+                                                                                                                                       "out %1, %0" "\n\t"                  \
+                                                                                                                                       "out __SREG__, __tmp_reg__" "\n\t"   \
+                                                                                                                                       "out %1, %0" "\n\t"                  \
+                                                                                                                                       :                                    \
+                                                                                                                                       : "r" (1 << JTD),                    \
+                                                                                                                                         "M" (_SFR_IO_ADDR(MCUCR))          \
+                                                                                                                                       : "r0");                             \
+                                                                                                                       }MACROE
+                               #endif
 
                                /** Defines a volatile \c NOP statement which cannot be optimized out by the compiler, and thus can always
                                 *  be set as a breakpoint in the resulting code. Useful for debugging purposes, where the optimizer
                                 *
                                 *  \param[in] Condition  Condition that will be evaluated,
                                 */
-                               #define STDOUT_ASSERT(Condition)        MACROS{ if (!(x)) { printf_P(PSTR("%s: Function \"%s\", Line %d: "   \
-                                                                               "Assertion \"%s\" failed.\r\n"),     \
-                                                                               __FILE__, __func__, __LINE__, #Condition); } }MACROE
+                               #define STDOUT_ASSERT(Condition)        MACROS{ if (!(x)) {                                             \
+                                                                                    printf_P(PSTR("%s: Function \"%s\", Line %d: "     \
+                                                                                                  "Assertion \"%s\" failed.\r\n"),     \
+                                                                                                  __FILE__, __func__, __LINE__, #Condition); } }MACROE
 
                                #if !defined(pgm_read_ptr) || defined(__DOXYGEN__)
                                        /** Reads a pointer out of PROGMEM space on the AVR8 architecture. This is currently a wrapper for the
                                         */
                                        #define pgm_read_ptr(Address)        (void*)pgm_read_word(Address)
                                #endif
+                       #elif (ARCH == ARCH_UC3)
+                               #define JTAG_DEBUG_POINT()              __asm__ __volatile__ ("nop" ::)
+                               #define JTAG_DEBUG_BREAK()              __asm__ __volatile__ ("breakpoint" ::)
+                               #define JTAG_ASSERT(Condition)          MACROS{ if (!(Condition)) { JTAG_DEBUG_BREAK(); } }MACROE
+                               #define STDOUT_ASSERT(Condition)        MACROS{ if (!(x)) {                                      \
+                                                                                    printf("%s: Function \"%s\", Line %d: "     \
+                                                                                           "Assertion \"%s\" failed.\r\n"),     \
+                                                                                           __FILE__, __func__, __LINE__, #Condition); } }MACROE
                        #endif
 
        /* Disable C linkage for C++ Compilers: */
index 1a3fccb..0a40b19 100644 (file)
                        /** Selects the Bitwizard Big-Multio specific board drivers, including the driver for the board LEDs. */
                        #define BOARD_BIGMULTIO            46
 
+                       /** Selects the DorkbotPDX Duce specific board drivers, including the driver for the board LEDs. */
+                       #define BOARD_DUCE                 47
+                       
+                       /** Selects the Olimex AVR-USB-32U4 specific board drivers, including the Button and LED drivers. */
+                       #define BOARD_OLIMEX32U4           48
+                       
+                       /** Selects the Olimex AVR-USB-T32U4 specific board drivers, including the Button and LED drivers. */
+                       #define BOARD_OLIMEXT32U4          49
+
+
                        #if !defined(__DOXYGEN__)
                                #define BOARD_                 BOARD_NONE
 
index b35a39c..f8e1b8f 100644 (file)
   *  <b>New:</b>
   *  - Core:
   *   - Added support for the BitWizard Multio and Big-Multio boards
+  *   - Added support for the DorkbotPDX Duce board
+  *   - Added support for the Olimex AVR-USB-32U4 board
+  *   - Added support for the Olimex AVR-USB-T32U4 board
+  *   - Added new Endpoint_ConfigureEndpointTable() function
+  *   - Added new Pipe_ConfigurePipeTable() function
   *  - Library Applications:
   *   - Modified the CDC Host demos to set a default CDC Line Encoding on enumerated devices
   *   - Added Dataflash operational checks and aborts to all projects using the Dataflash to ensure it is working correctly before use
+  *   - Added new SerialToLCD user project contributed by Simon Foster
   *
   *  <b>Changed:</b>
   *  - Core:
   *   - Audio Device Class driver changed to also require the index of the Audio Control interface within the device, for SET/GET/CUR/MIN/MAX/RES property adjustments
   *   - Removed variable axis support from the HID_DESCRIPTOR_JOYSTICK() macro due to OS incompatibilities, replaced with fixed 3-axis joystick report structure
   *   - Removed the old pseudo-scheduler from the library as it was unused and deprecated since the 090810 release
+  *   - Endpoint indexes are now specified as full endpoint addresses within the device in device mode, rather than a logical index
+  *   - The Endpoint_ConfigureEndpoint() function no longer takes an endpoint direction as a parameter, as this is now deduced from the specified full endpoint
+  *     address and type
+  *   - The Endpoint_ConfigureEndpoint() function no longer takes a number of banks as a special mask; the number of banks is now specified as an integer parameter
+  *   - Endpoints are now configured via instances of a new struct USB_Endpoint_Table_t in all device mode class drivers, rather than a list of endpoint parameters
+  *   - Pipe indexes are now specified as full pipe addresses within the host in host mode, rather than a logical index
+  *   - The Pipe_ConfigurePipe() function no longer takes an pipe token as a parameter, as this is now deduced from the specified full pipe address and type
+  *   - The Pipe_ConfigurePipe() function no longer takes a number of banks as a special mask; the number of banks is now specified as an integer parameter
+  *   - Pipes are now configured via instances of a new struct USB_Pipe_Table_t in all host mode class drivers, rather than a list of pipe parameters
+  *   - Added support for various assert and debugging macros for the UC3 devices
+  *   - Changed MIDI event structure MIDI_EventPacket_t to use a single field for the combined virtual cable index and command ID, to prevent bitfield packing issues
+  *     on some architectures (thanks to Darren Gibbs)
+  *   - Changed board LED driver implementations of LEDs_ToggleLEDs() for the AVR8 architecture to use the fast PIN register toggle alternative function for speed
   *  - Library Applications:
   *   - Raised the guard bits in the AVRISP-MKII clone project when in PDI and TPI to 32, to prevent communication errors on low quality connections to a target
   *   - Added additional bootloader API data to expose the bootloader start address and class to the DFU and CDC class bootloaders
   *   - Reverted AVRISP-MKII clone project watchdog based command timeout patch in favour of a hardware timer, to allow for use in devices with WDTRST fuse programmed
+  *   - The library bootloaders will now correctly start the user application after a watchdog-based application start, even if the /HWB line is held low externally
+  *     during the reset phase
+  *   - Increased endpoint polling interval for all demos and projects to 5ms, as 1ms was causing some enumeration issues on some machines (thanks to Riku Salminen)
   *
   *  <b>Fixed:</b>
   *  - Core:
   *   - Fixed compile error for the UC3 architecture when INTERRUPT_CONTROL_ENDPOINT is specified (thanks to Andrus Aaslaid)
   *   - Fixed compile error if LEDs_Disable() is called and BOARD=NONE is set (thanks to Sam Lin)
   *   - Fixed inverted LED logic in the OLIMEX162 board LED driver
+  *   - Fixed incorrect reponse to GET STATUS requests in device mode if NO_DEVICE_SELF_POWER or NO_DEVICE_REMOTE_WAKEUP tokens are defined (thanks to Georg Glock)
+  *   - Fixed inverted LED logic in the USB2AX board LED driver
+  *   - Fixed possible deadlock in the CDC device driver if the USB connection is dropped while the CDC_REQ_SetLineEncoding control request is being processed by
+  *     the stack (thanks to Jonathan Hudgins)
+  *   - Fixed broken MIDI host driver MIDI_Host_ReceiveEventPacket() function due to not unfreezing the MIDI data IN pipe before use (thanks to Michael Brown)
   *  - Library Applications:
   *   - Fixed error in the AVRISP-MKII programmer when ISP mode is used at 64KHz (thanks to Ben R. Porter)
   *   - Fixed AVRISP-MKII programmer project failing to compile for the U4 chips when VTARGET_ADC_CHANNEL is defined to an invalid channel and NO_VTARGET_DETECT is
   *     defined (thanks to Steven Morehouse)
+  *   - Fixed AVRISP-MKII programmer project reset line polarity inverted when the generated EEP file is loaded into the USB AVR's EEPROM and avr-dude is used
   *   - Fixed CDC and DFU bootloaders failing to compile when the bootloader section size is 8KB or more (thanks to Georg Glock)
+  *   - Fixed incorrect DFU version number reported to the host in the  DFU bootloader descriptors (thanks to Georg Glock)
+  *   - Fixed incorrect version hundredths value encoding in VERSION_BCD() macro (thanks to Georg Glock)
   *
   *  \section Sec_ChangeLog120219 Version 120219
   *  <b>New:</b>
index c8083d2..d1fe4f3 100644 (file)
  *   - Busware BUI
  *   - Busware CUL V3
  *   - Busware TUL
+ *   - DorkbotPDX Duce
  *   - Fletchtronics Bumble-B (using manufacturer recommended peripheral layout)
  *   - Kernel Concepts USBFOO
  *   - Linnix UDIP
  *   - Microsin AVR-USB162
  *   - Minimus USB
  *   - Olimex AVR-USB-162
+ *   - Olimex AVR-USB-32U4
+ *   - Olimex AVR-USB-T32U4
  *   - Paranoid Studio's US2AX (V1, V2 and V3 hardware revisions)
  *   - PJRC Teensy (1.x and 2.x versions)
  *   - Sparkfun U2 Breakout Board
  *   <td bgcolor="#00EE00">Yes</td>
  *   <td bgcolor="#EE0000">No</td>
  *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA64C3</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA128C3</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA192C3</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA256C3</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA384C3</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA16C4</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
+ *  <tr>
+ *   <td>ATXMEGA32C4</td>
+ *   <td bgcolor="#00EE00">Yes</td>
+ *   <td bgcolor="#EE0000">No</td>
+ *  </tr>
  *  </table>
  *
  *  \section Sec_XMEGASupport_Boards Supported Atmel Boards
index b75e94d..d0453a2 100644 (file)
   *      -# Pull out third party libraries into a separate folder and reference them as required
   *      -# Add a LUFA_YIELD macro for integration into a third-party RTOS
   *      -# Abstract out Mass Storage byte send/receive to prevent low level API use in projects
-  *      -# Consider switch from endpoint numbers to full endpoint addresses to ease future architecture expansion
   *      -# Fix HID report parser usage support for array types
   *      -# Make HOST_DEVICE_SETTLE_DELAY_MS a global variable that can be changed
   *      -# Add MANDATORY_EVENT_FUNCTIONS compile time option
   *      -# Add watchdog support to the library and apps/bootloaders
-  *      -# Fix Still Image Host class driver - missing reqs, parameters
   *  - Testing/Verification
   *      -# Re-run USBIF test suite on all classes to formally verify operation
   *      -# Implement automated functional testing of all demos
diff --git a/LUFA/DoxygenPages/KnownIssues.txt b/LUFA/DoxygenPages/KnownIssues.txt
new file mode 100644 (file)
index 0000000..9b64814
--- /dev/null
@@ -0,0 +1,40 @@
+/** \file\r
+ *\r
+ *  This file contains special DoxyGen information for the generation of the main page and other special\r
+ *  documentation pages. It is not a project source file.\r
+ */\r
+\r
+ /** \page Page_KnownIssues Known Issues\r
+  *  The following are known issues present in each official LUFA release. This list should contain all known\r
+  *  issues in the library. Most of these issues should be corrected in the future release - see\r
+  *  \ref Page_FutureChanges for a list of planned changes in future releases.\r
+  *\r
+  *  \section Sec_KnownIssuesXXXXXX Version XXXXXX\r
+  *  - AVR8 Architecture\r
+  *    - No known issues.\r
+  *  - XMEGA Architecture\r
+  *    - No demos, bootloaders or projects have been ported for the XMEGA devices in the current release,\r
+  *      although the architecture is supported in the LUFA core library.\r
+  *    - Endpoints of more than 64 bytes are not currently supported in this release.\r
+  *    - Isochronous endpoints are not currently supported in this release. As a result, the audio class\r
+  *      cannot be used on XMEGA devices.\r
+  *    - Multiple-bank endpoints are not currently supported in this release.\r
+  *    - Early revisions of the ATXMEGA128A1U are incompatible with LUFA, due to their various errata\r
+  *      relating to the USB controller.\r
+  *  - UC3 Architecture\r
+  *    - No demos, bootloaders or projects have been ported for the UC3 devices in the current release,\r
+  *      although the architecture is supported in the LUFA core library.\r
+  *    - DMA transfers to and from the USB controller are not yet implemented for this release.\r
+  *    - The UC3C, UC3D and UC3L sub-families of UC3 are not currently supported by the library due to their\r
+  *      altered USB controller design.\r
+  *    - The various \c CreateStream() functions for creating standard \c <stdio.h> compatible virtual file\r
+  *      streams are not available on the UC3 architecture, due to a lack of suitable library support.\r
+  *  - Architecture Independant\r
+  *    - The HID parser fails for array type elements that have a MIN and MAX usage applied; each element\r
+  *      in the array will receive a unique incrementing usage from the MIN value, up to MAX.\r
+  *    - The current application makefiles do not work if the output directory is not the same directory\r
+  *      as the makefile itself.\r
+  *    - The LUFA library is not watchdog aware, and thus timeouts are possible if short periods are used\r
+  *      and a lengthy USB operation is initiated.\r
+  */\r
+\r
index ea08705..842d98f 100644 (file)
@@ -20,6 +20,7 @@
  *
  *  \li AVR-USB-162, a USBKEY-like development board for the AT90USB162: http://olimex.com/dev/avr-usb-162.html
  *  \li Benito #7, a no-frills USB board: http://www.dorkbotpdx.org/wiki/benito
+ *  \li Duce, the sucessor to the Benito #7: http://dorkbotpdx.org/wiki/duce
  *  \li JM-DB-U2, an ATMEGA32U2 development board: http://u2.mattair.net/index.html
  *  \li Micropendous, an open design/source set of AVR USB development boards: http://micropendous.org/
  *  \li Microsin AVR-USB162 breakout board, a DIY AT90USB162 development board: http://microsin.ru/content/view/685/44/
@@ -36,6 +37,7 @@
  *  The following are known hobbyist projects using LUFA. Most are open source, and show off interesting ways that the LUFA library
  *  can be incorporated into many different applications.
  *
+ *  \li Accelerometer Game Joystick: http://www.crictor.co.il/he/episodes/joystick/
  *  \li Arcade Controller: http://fletchtronics.net/arcade-controller-made-petunia
  *  \li Arcade Joystick: http://jamie.lentin.co.uk/embedded/arcade-joystick/
  *  \li AttoBasic AVR BASIC interpreter: http://www.cappels.org/dproj/AttoBasic2_1/AttoBasic_2.1_with_USB_and_Arduino_support.html
index 7137a56..ac1915c 100644 (file)
@@ -9,6 +9,7 @@
  *
  *  \section Sec_UnofficialResources Unofficial Resources
  *  Unofficial Russian LUFA documentation translation: http://microsin.ru/Download.cnt/doc/LUFA/ \n
+ *  Tutorial for LUFA USB Control Transfers: http://www.avrbeginners.net/new/tutorials/usb-control-transfers-with-lufa/
  *
  *  \section Sec_ProjectPages LUFA Related Webpages
  *  Project Homepage: http://www.lufa-lib.org \n
@@ -22,8 +23,8 @@
  *
  *  \section Sec_InDevelopment Latest In-Development Source Code
  *  Issue Tracker: http://www.lufa-lib.org/tracker \n
- *  SVN Access: http://www.lufa-lib.org/svn \n
- *  GIT Access: http://www.lufa-lib.org/git \n
+ *  Public SVN Repository: http://www.lufa-lib.org/svn \n
+ *  Public GIT Repository: http://www.lufa-lib.org/git \n
  *  Latest Repository Source Archive: http://www.lufa-lib.org/latest-archive \n
  *  Commit RSS Feed: http://www.lufa-lib.org/rss \n
  *
index ed96d1a..e737c39 100644 (file)
@@ -42,6 +42,7 @@
  *  \li \subpage Page_Donating - Donating to support this project
  *  \li \subpage Page_DeviceSupport - Current Device and Hardware Support
  *  \li \subpage Page_ChangeLog - Project Changelog
+ *  \li \subpage Page_KnownIssues - Known Issues
  *  \li \subpage Page_FutureChanges - Planned Changes to the Library
  *  \li \subpage Page_GettingStarted - Getting started with LUFA
  *  \li \subpage Page_DevelopingWithLUFA - Developing with LUFA
index 93082bb..f0fd9b2 100644 (file)
  *    - The HID_DESCRIPTOR_JOYSTICK() macro no longer takes a variable number of axis as a parameter, due to OS incompatibilities; this macro now uses a fixed
  *      3 axis of data. User applications should update their calls to this macro and their report structures to suit a fixed 3-axis joystick report. If a user
  *      application requires more than 3 axis' of data, a custom report descriptor will need to be constructed by hand.
+ *    - The \ref Endpoint_ConfigureEndpoint() function no longer takes in masks for the banks and direction; the number of banks is now an integer argument, and
+ *      the direction is obtained from the full endpoint address within the device. Applications calling Endpoint_ConfigureEndpoint() should update their API
+ *      call to use a full endpoint address (including ENDPOINT_DIR_IN or ENDPOINT_DIR_OUT direction in the MSB of the endpoint address) and an integer number
+ *      of banks.
+ *    - All endpoint functions now operate on full endpoint addresses within the device, rather than a directionless endpoint index. Applications should update
+ *      their API calls to use full endpoint addresses when required within the device.
+ *    - All device mode class drivers have been updated to use a new unified endpoint description structure for all endpoints; existing applications will need
+ *      to update their class driver struct instantiation to match the new scheme (see \ref USB_Endpoint_Table_t).
+ *    - The \c ENDPOINT_BANKS_SUPPORTED() and \c ENDPOINT_MAX_ENDPOINT_SIZE() macros have been removed, as these do not function correctly with the new addressing
+ *      scheme for the endpoint APIs. Please refer to the target device's datasheet for the maximum bank size of each endpoint.
+ *    - The MIDI class driver \ref MIDI_EventPacket_t event packet no longer contains seperate \c CableIndex and \c Command entries; these have been combined
+ *      into a single \c Event element which can be contructed using the new macro \ref MIDI_EVENT(). Existing applications should use the new macro and structure
+ *      element name.
  *
  *  <b>Host Mode</b>
  *    - The Android Accessory Host class driver property strings are now a array of \c char* rather than a struct of named pointers. Existing applications
  *      should use C99 Designated Initializers with the property string indexes located in \ref AOA_Strings_t instead.
+ *    - The \ref Pipe_ConfigurePipe() function no longer takes in masks for the banks and token; the number of banks is now an integer argument, and the token
+ *      is now inferred from the full pipe address within the device, and the pipe type. Applications calling Pipe_ConfigurePipe() should update their API
+ *      call to use a full pipe address (including PIPE_DIR_IN or PIPE_DIR_OUT direction in the MSB of the pipe address) and an integer number of banks.
+ *    - All pipe functions now operate on full pipe addresses within the device, rather than a directionless pipe index. Applications should update their API
+ *      calls to use full pipe addresses when required within the device.
+ *    - All host mode class drivers have been updated to use a new unified pipe description structure for all pipes; existing applications will need to update
+ *      their class driver struct instantiation to match the new scheme (see \ref USB_Pipe_Table_t).
+ *    - The MIDI class driver \ref MIDI_EventPacket_t event packet no longer contains seperate \c CableIndex and \c Command entries; these have been combined
+ *      into a single \c Event element which can be contructed using the new macro \ref MIDI_EVENT(). Existing applications should use the new macro and structure
+ *      element name.
  *
  *  \section Sec_Migration120219 Migrating from 111009 to 120219
  *  <b>USB Core</b>
  *      eliminate any casting of descriptor pointers to a non \c const pointer.
  *    - The names of the class specific descriptor type defines in the USB Class drivers have changed - refer to the driver documentation
  *      for each class driver for the new class specific descriptor type names.
- *    - The \c ENDPOINT_DOUBLEBANK_SUPPORTED() macro is has been renamed \ref ENDPOINT_BANKS_SUPPORTED() and now returns the total number of
+ *    - The \c ENDPOINT_DOUBLEBANK_SUPPORTED() macro is has been renamed \c ENDPOINT_BANKS_SUPPORTED() and now returns the total number of
  *      banks supported by the given endpoint. Existing code should switch to the new naming scheme, and test that the return value of the
  *      macro is equal to or greater than 2 to regain the previous functionality.
  *    - The \c EVENT_USB_Device_UnhandledControlRequest() event is now named \ref EVENT_USB_Device_ControlRequest() and fires before (not after)
index 3fca656..661749b 100644 (file)
  *
  *  Board specific LED driver header for the Adafruit U4 Breakout board (http://ladyada.net/products/atmega32u4breakout).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTE.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTE ^= LEDMask;
+                               PINE   = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index adec49a..c7cce17 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel ATAVRUSBRF01.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 77fc05b..2cc953b 100644 (file)
  *
  *  Board specific LED driver header for the Atmel ATAVRUSBRF01.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>RX LED</td><td>High</td><td>PORTD.0</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Red</td><td>TX LED</td><td>High</td><td>PORTD.1</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
                        #error Do not include this file directly. Include LUFA/Drivers/Board/LEDS.h instead.
                #endif
 
-       /* Private Interface - For use in library only: */
-       #if !defined(__DOXYGEN__)
-               /* Macros: */
-                       #define LEDS_PORTD_LEDS       (LEDS_LED1 | LEDS_LED2)
-                       #define LEDS_PORTE_LEDS       (LEDS_LED3 | LEDS_LED4)
-
-                       #define LEDS_PORTE_MASK_SHIFT 4
-       #endif
-
        /* Public Interface - May be used in end-application: */
                /* Macros: */
                        /** LED mask for the first LED on the board. */
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index a7ce1b5..800fa15 100644 (file)
  *
  *  Board specific Buttons driver header for the Tempusdictum Benito (http://dorkbotpdx.org/wiki/benito).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 6e7de07..875130f 100644 (file)
  *
  *  Board specific LED driver header for the Tempusdictum Benito (http://dorkbotpdx.org/wiki/benito).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>TX LED</td><td>Low</td><td>PORTC.7</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Red</td><td>RX LED</td><td>Low</td><td>PORTC.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTC ^= LEDMask;
+                               PINC  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 77b7d97..89516dc 100644 (file)
  *\r
  *  Board specific LED driver header for the Bitwizard Big-Multio (http://www.bitwizard.nl/wiki/index.php/Usbbigmultio).\r
  *\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>LEDS_LED1</td><td>Unknown</td><td>LED0</td><td>High</td><td>PORTF.6</td></tr>\r
+ *    <tr><td>LEDS_LED2</td><td>Unknown</td><td>LED1</td><td>High</td><td>PORTF.7</td></tr>\r
+ *    <tr><td>LEDS_LED3</td><td>Unknown</td><td>LED2</td><td>High</td><td>PORTE.2</td></tr>\r
+ *  </table>\r
+ *\r
  *  @{\r
  */\r
 \r
 \r
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)\r
                        {\r
-                               PORTF ^= (LEDMask & LEDS_PORTF_LEDS);\r
-                               PORTE ^= (LEDMask & LEDS_PORTE_LEDS);\r
+                               PINF  = (LEDMask & LEDS_PORTF_LEDS);\r
+                               PINE  = (LEDMask & LEDS_PORTE_LEDS);\r
                        }\r
 \r
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;\r
index 4313db5..1212420 100644 (file)
  *  \defgroup Group_LEDs_BLACKCAT BLACKCAT
  *  \brief Board specific LED driver header for the BLACKCAT USB JTAG.
  *
- *  Board specific LED driver header for the TCNISO Blackcat USB JTAG (http://www.embeddedcomputers.net/products/BlackcatUSB/.
+ *  Board specific LED driver header for the TCNISO Blackcat USB JTAG (http://www.embeddedcomputers.net/products/BlackcatUSB).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Unknown</td><td>LED0</td><td>High</td><td>PORTD.6</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Unknown</td><td>LED1</td><td>High</td><td>PORTD.3</td></tr>
+ *  </table>
  *
  *  @{
  */
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index f49f51d..039e9ef 100644 (file)
  *
  *  Board specific LED driver header for the Busware BUI (http://www.busware.de/tiki-index.php?page=BUI).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>RGB LED</td><td>High</td><td>PORTC.2</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>RGB LED</td><td>High</td><td>PORTC.3</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Blue</td><td>RGB LED</td><td>High</td><td>PORTC.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTC ^= LEDMask;
+                               PINC  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 8fdd002..a4d8169 100644 (file)
  *  third-party board does not include any on-board peripherals, but does have an officially recommended external peripheral
  *  layout for buttons, LEDs and a Joystick.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index f952536..6b0df05 100644 (file)
  *  third-party board does not include any on-board peripherals, but does have an officially recommended external peripheral
  *  layout for buttons, LEDs and a Joystick.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>PORTD.2</td><td>PORTD.3</td><td>PORTD.0</td><td>PORTD.1</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 9f82cc1..a09ab96 100644 (file)
  *  third-party board does not include any on-board peripherals, but does have an officially recommended external
  *  peripheral layout for buttons, LEDs and a Joystick.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>N/A</td><td>User Supplied</td><td>High</td><td>PORTB.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>N/A</td><td>User Supplied</td><td>High</td><td>PORTB.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>N/A</td><td>User Supplied</td><td>High</td><td>PORTB.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>N/A</td><td>User Supplied</td><td>High</td><td>PORTB.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= LEDMask;
+                               PINB  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 19e09fe..16feb7d 100644 (file)
  *
  *  Board specific Buttons driver header for the Busware CUL V3 (http://busware.de/tiki-index.php?page=CUL).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 3fb8c87..6172912 100644 (file)
  *
  *  Board specific LED driver header for the Busware CUL V3 (http://busware.de/tiki-index.php?page=CUL).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>General Indicator</td><td>High</td><td>PORTE.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTE ^= LEDMask;
+                               PINE  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
diff --git a/LUFA/Drivers/Board/AVR8/DUCE/LEDs.h b/LUFA/Drivers/Board/AVR8/DUCE/LEDs.h
new file mode 100644 (file)
index 0000000..1063d75
--- /dev/null
@@ -0,0 +1,147 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief Board specific LED driver header for the DorkbotPDX Duce.
+ *  \copydetails Group_LEDs_DUCE
+ *
+ *  \note This file should not be included directly. It is automatically included as needed by the LEDs driver
+ *        dispatch header located in LUFA/Drivers/Board/LEDs.h.
+ */
+
+/** \ingroup Group_LEDs
+ *  \defgroup Group_LEDs_DUCE DUCE
+ *  \brief Board specific LED driver header for the DorkbotPDX Duce.
+ *
+ *  Board specific LED driver header for the DorkbotPDX Duce (http://dorkbotpdx.org/wiki/duce).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTC.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTC.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Red</td><td>Bicolor Indicator 2</td><td>High</td><td>PORTC.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>Bicolor Indicator 2</td><td>High</td><td>PORTC.7</td></tr>
+ *  </table>
+ *
+ *  @{
+ */
+
+#ifndef __LEDS_DUCE_H__
+#define __LEDS_DUCE_H__
+
+       /* Includes: */
+               #include "../../../../Common/Common.h"
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_LEDS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/LEDS.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** LED mask for the first LED on the board. */
+                       #define LEDS_LED1        (1 << 4)
+
+                       /** LED mask for the second LED on the board. */
+                       #define LEDS_LED2        (1 << 5)
+
+                       /** LED mask for the third LED on the board. */
+                       #define LEDS_LED3        (1 << 6)
+
+                       /** LED mask for the fourth LED on the board. */
+                       #define LEDS_LED4        (1 << 7)
+
+                       /** LED mask for all the LEDs on the board. */
+                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2 | LEDS_LED3 | LEDS_LED4)
+
+                       /** LED mask for none of the board LEDs. */
+                       #define LEDS_NO_LEDS     0
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void LEDs_Init(void)
+                       {
+                               DDRC  |=  LEDS_ALL_LEDS;
+                               PORTC &= ~LEDS_ALL_LEDS;
+                       }
+
+                       static inline void LEDs_Disable(void)
+                       {
+                               DDRC  &= ~LEDS_ALL_LEDS;
+                               PORTC &= ~LEDS_ALL_LEDS;
+                       }
+
+                       static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)
+                       {
+                               PORTC |= LEDMask;
+                       }
+
+                       static inline void LEDs_TurnOffLEDs(const uint8_t LEDMask)
+                       {
+                               PORTC &= ~LEDMask;
+                       }
+
+                       static inline void LEDs_SetAllLEDs(const uint8_t LEDMask)
+                       {
+                               PORTC = ((PORTC & ~LEDS_ALL_LEDS) | LEDMask);
+                       }
+
+                       static inline void LEDs_ChangeLEDs(const uint8_t LEDMask,
+                                                          const uint8_t ActiveMask)
+                       {
+                               PORTC = ((PORTC & ~LEDMask) | ActiveMask);
+                       }
+
+                       static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
+                       {
+                               PINC  = LEDMask;
+                       }
+
+                       static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t LEDs_GetLEDs(void)
+                       {
+                               return (PORTC & LEDS_ALL_LEDS);
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
+/** @} */
+
index 89ba274..829f356 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel EVK527.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 595492f..0f7b674 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel EVK527.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB321C (4MB)</td><td>PORTE.6</td><td>SPI0</td></tr>
+ *  </table> 
+ *
  *  @{
  */
 
index 5315c2e..b264f47 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel EVK527.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>PORTF.4</td><td>PORTF.5</td><td>PORTF.7</td><td>PORTC.6</td><td>PORTF.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 551bba6..7e3dc4f 100644 (file)
  *
  *  Board specific LED driver header for the Atmel EVK527.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.6</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index a3a246d..d36a115 100644 (file)
  *
  *  Board specific Buttons driver header for the Mattairtech JM-DB-U2 (http://u2.mattair.net/index.html).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 3361f58..adca2de 100644 (file)
  *
  *  Board specific LED driver header for the Mattairtech JM-DB-U2 (http://u2.mattair.net/index.html).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 45ca124..815fc29 100644 (file)
  *
  *  Board specific LED driver header for the Maximus (http://www.avrusb.com/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>LG</td><td>High</td><td>PORTB.6</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Red</td><td>LR</td><td>High</td><td>PORTB.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= LEDMask;
+                               PINB  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 5c5825a..731d1b0 100644 (file)
  *\r
  *  Board specific Buttons driver header for the Micropendous 32U2 (https://code.google.com/p/micropendous/wiki/Micropendous_32U2).\r
  *\r
+ *  <b>BOARD_MICROPENDOUS_1 and BOARD_MICROPENDOUS_32U2</b>:\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>\r
+ *  </table>\r
+ *\r
+ *  <b>Other Revisions</b>:\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>\r
+ *  </table>\r
+ *\r
  *  @{\r
  */\r
 \r
index 649d961..963c15a 100644 (file)
  *
  *  Board specific LED driver header for the Micropendous 32U2 (https://code.google.com/p/micropendous/wiki/Micropendous_32U2).
  *
+ *  <b>BOARD_MICROPENDOUS_32U2</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.6</td></tr>
+ *  </table>
+ *
+ *  <b>Other Revisions</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTB.1</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
                #define _BOARD_LED_CONCAT(Reg, Letter)      _BOARD_LED_CONCAT2(Reg, Letter)
 
                #define _BOARD_LED_PORT                     _BOARD_LED_CONCAT(PORT, _BOARD_LED_PORTLETTER)
+               #define _BOARD_LED_PIN                      _BOARD_LED_CONCAT(PIN,  _BOARD_LED_PORTLETTER)
                #define _BOARD_LED_DDR                      _BOARD_LED_CONCAT(DDR,  _BOARD_LED_PORTLETTER)
        #endif
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               _BOARD_LED_PORT ^= LEDMask;
+                               _BOARD_LED_PIN  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 27d75bf..3105ba8 100644 (file)
  *
  *  Board specific Buttons driver header for the Microsin AVR-USB162 board (http://microsin.ru/content/view/685/44/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 36f610d..31aaa67 100644 (file)
  *
  *  Board specific LED driver header for the Microsin AVR-USB162 board (http://microsin.ru/content/view/685/44/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 016ea2d..f8666cf 100644 (file)
  *
  *  Board specific Buttons driver header for the MINIMUS.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 11ab648..f23317d 100644 (file)
  *
  *  Board specific LED driver header for the Minimus USB (http://www.minimususb.com/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>General Indicator</td><td>Low</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTD.6</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Blue</td><td>General Indicator</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
                        /** LED mask for the second LED on the board. */
                        #define LEDS_LED2        (1 << 6)
 
+                       /** LED mask for the third LED on the board. */
+                       #define LEDS_LED3        (1 << 7)
+
                        /** LED mask for all the LEDs on the board. */
-                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2)
+                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2 | LEDS_LED3)
 
                        /** LED mask for the none of the board LEDs. */
-                       #define LEDS_NO_LEDS     1
+                       #define LEDS_NO_LEDS     0
 
                /* Inline Functions: */
                #if !defined(__DOXYGEN__)
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index af2f7b3..64f68a5 100644 (file)
  *\r
  *  Board specific LED driver header for the Bitwizard Multio (http://www.bitwizard.nl/wiki/index.php/USB-multio).\r
  *\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.0</td></tr>\r
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTC.2</td></tr>\r
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.7</td></tr>\r
+ *  </table>\r
+ *\r
  *  @{\r
  */\r
 \r
 \r
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)\r
                        {\r
-                               PORTD ^= (LEDMask & LEDS_PORTD_LEDS);\r
-                               PORTC ^= (LEDMask & LEDS_PORTC_LEDS);\r
+                               PIND  = (LEDMask & LEDS_PORTD_LEDS);\r
+                               PINC  = (LEDMask & LEDS_PORTC_LEDS);\r
                        }\r
 \r
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;\r
index b6d75be..1b7c291 100644 (file)
  *
  *  Board specific Buttons driver header for the Olimex AVR-USB-162 Development Board (http://www.olimex.com/dev/avr-usb-162.html).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index c9bd3f1..21fb500 100644 (file)
  *
  *  Board specific LED driver header for the Olimex AVR-USB-162 (http://www.olimex.com/dev/avr-usb-162.html).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>General Indicator</td><td>High</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
diff --git a/LUFA/Drivers/Board/AVR8/OLIMEX32U4/Buttons.h b/LUFA/Drivers/Board/AVR8/OLIMEX32U4/Buttons.h
new file mode 100644 (file)
index 0000000..d42c434
--- /dev/null
@@ -0,0 +1,103 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief Board specific Buttons driver header for the Olimex AVR-USB-32U4 Development Board.
+ *  \copydetails Group_Buttons_OLIMEX32U4
+ *
+ *  \note This file should not be included directly. It is automatically included as needed by the Buttons driver
+ *        dispatch header located in LUFA/Drivers/Board/Buttons.h.
+ */
+
+/** \ingroup Group_Buttons
+ *  \defgroup Group_Buttons_OLIMEX32U4 OLIMEX32U4
+ *  \brief Board specific Buttons driver header for the Olimex AVR-USB-32U4 Development Board.
+ *
+ *  Board specific Buttons driver header for the Olimex AVR-USB-32U4 Development Board (http://www.olimex.com/dev/olimexino-32u4.html).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
+ *  @{
+ */
+
+#ifndef __BUTTONS_OLIMEX32U4_H__
+#define __BUTTONS_OLIMEX32U4_H__
+
+       /* Includes: */
+               #include "../../../../Common/Common.h"
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_BUTTONS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/Buttons.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** Button mask for the first button on the board. */
+                       #define BUTTONS_BUTTON1      (1 << 2)
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void Buttons_Init(void)
+                       {
+                               DDRE  &= ~BUTTONS_BUTTON1;
+                               PORTE |=  BUTTONS_BUTTON1;
+                       }
+
+                       static inline void Buttons_Disable(void)
+                       {
+                               DDRE  &= ~BUTTONS_BUTTON1;
+                               PORTE &= ~BUTTONS_BUTTON1;
+                       }
+
+                       static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Buttons_GetStatus(void)
+                       {
+                               return ((PINE & BUTTONS_BUTTON1) ^ BUTTONS_BUTTON1);
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
+/** @} */
+
diff --git a/LUFA/Drivers/Board/AVR8/OLIMEX32U4/LEDs.h b/LUFA/Drivers/Board/AVR8/OLIMEX32U4/LEDs.h
new file mode 100644 (file)
index 0000000..62b7c78
--- /dev/null
@@ -0,0 +1,179 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief Board specific LED driver header for the Olimex AVR-USB-32U4.
+ *  \copydetails Group_LEDs_OLIMEX32U4
+ *
+ *  \note This file should not be included directly. It is automatically included as needed by the LEDs driver
+ *        dispatch header located in LUFA/Drivers/Board/LEDs.h.
+ */
+
+/** \ingroup Group_LEDs
+ *  \defgroup Group_LEDs_OLIMEX32U4 OLIMEX32U4
+ *  \brief Board specific LED driver header for the Olimex AVR-USB-32U4.
+ *
+ *  Board specific LED driver header for the Olimex AVR-USB-32U4 (http://www.olimex.com/dev/olimexino-32u4.html).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>TX</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Yellow</td><td>RX</td><td>High</td><td>PORTB.0</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>General Indicator (Default Unconnected)</td><td>High</td><td>PORTE.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Yellow</td><td>General Indicator (Default Unconnected)</td><td>High</td><td>PORTB.5</td></tr>
+ *  </table>
+ *
+ *  @{
+ */
+
+#ifndef __LEDS_OLIMEX32U4_H__
+#define __LEDS_OLIMEX32U4_H__
+
+       /* Includes: */
+               #include "../../../../Common/Common.h"
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_LEDS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/LEDS.h instead.
+               #endif
+
+       /* Private Interface - For use in library only: */
+       #if !defined(__DOXYGEN__)
+               /* Macros: */
+                       #define LEDS_PORTB_LEDS       (LEDS_LED2 | LEDS_LED4)
+                       #define LEDS_PORTD_LEDS       (LEDS_LED1)
+                       #define LEDS_PORTE_LEDS       (LEDS_LED3)
+
+                       #define LEDS_PORTD_MASK_SHIFT 1
+       #endif
+       
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** LED mask for the first LED on the board. */
+                       #define LEDS_LED1        ((1 << 5) >> LEDS_PORTD_MASK_SHIFT)
+
+                       /** LED mask for the second LED on the board. */
+                       #define LEDS_LED2        (1 << 0)
+                       
+                       /** LED mask for the third LED on the board. */
+                       #define LEDS_LED3        (1 << 5)
+
+                       /** LED mask for the fourth LED on the board. */
+                       #define LEDS_LED4        (1 << 6)
+                       
+                       /** LED mask for all the LEDs on the board. */
+                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2 | LEDS_LED3 | LEDS_LED4)
+
+                       /** LED mask for none of the board LEDs. */
+                       #define LEDS_NO_LEDS     0
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void LEDs_Init(void)
+                       {
+                               DDRB  |=  LEDS_PORTB_LEDS;
+                               PORTB &= ~LEDS_PORTB_LEDS;
+                               DDRD  |=  (LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT);
+                               PORTD &= ~(LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT);
+                               DDRE  |=  LEDS_PORTE_LEDS;
+                               PORTE &= ~LEDS_PORTE_LEDS;
+                       }
+
+                       static inline void LEDs_Disable(void)
+                       {
+                               DDRB  &=  LEDS_PORTB_LEDS;
+                               PORTB &= ~LEDS_PORTB_LEDS;
+                               DDRD  &=  (LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT);
+                               PORTD &= ~(LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT);
+                               DDRE  &=  LEDS_PORTE_LEDS;
+                               PORTE &= ~LEDS_PORTE_LEDS;
+                       }
+
+                       static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB |= (LEDMask & LEDS_PORTB_LEDS);
+                               PORTD |= ((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT);
+                               PORTE |= (LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline void LEDs_TurnOffLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB &= ~(LEDMask & LEDS_PORTB_LEDS);
+                               PORTD &= ~((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT);
+                               PORTE &= ~(LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline void LEDs_SetAllLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB = ((PORTB & ~LEDS_PORTB_LEDS) | (LEDMask & LEDS_PORTB_LEDS));
+                               PORTD = ((PORTD & ~(LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT)) |
+                                        ((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT));
+                               PORTE = ((PORTE & ~LEDS_PORTE_LEDS) | (LEDMask & LEDS_PORTE_LEDS));
+                       }
+
+                       static inline void LEDs_ChangeLEDs(const uint8_t LEDMask,
+                                                          const uint8_t ActiveMask)
+                       {
+                               PORTB = ((PORTB & ~(LEDMask & LEDS_PORTB_LEDS)) | (ActiveMask & LEDS_PORTB_LEDS));
+                               PORTD = ((PORTD & ~((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT)) |
+                                        ((ActiveMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT));
+                               PORTE = ((PORTE & ~(LEDMask & LEDS_PORTE_LEDS)) | (ActiveMask & LEDS_PORTE_LEDS));
+                       }
+
+                       static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
+                       {
+                               PINB  = (LEDMask & LEDS_PORTB_LEDS);
+                               PIND  = ((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT);
+                               PINE  = (LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t LEDs_GetLEDs(void)
+                       {
+                               return ((PORTB & LEDS_PORTB_LEDS) | 
+                                       ((PORTD & (LEDS_PORTD_LEDS << LEDS_PORTD_MASK_SHIFT)) >> LEDS_PORTD_MASK_SHIFT) |
+                                       (PORTE & LEDS_PORTE_LEDS));
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
+/** @} */
+
diff --git a/LUFA/Drivers/Board/AVR8/OLIMEXT32U4/Buttons.h b/LUFA/Drivers/Board/AVR8/OLIMEXT32U4/Buttons.h
new file mode 100644 (file)
index 0000000..106687a
--- /dev/null
@@ -0,0 +1,103 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief Board specific Buttons driver header for the Olimex AVR-USB-T32U4 Development Board.
+ *  \copydetails Group_Buttons_OLIMEXT32U4
+ *
+ *  \note This file should not be included directly. It is automatically included as needed by the Buttons driver
+ *        dispatch header located in LUFA/Drivers/Board/Buttons.h.
+ */
+
+/** \ingroup Group_Buttons
+ *  \defgroup Group_Buttons_OLIMEXT32U4 OLIMEXT32U4
+ *  \brief Board specific Buttons driver header for the Olimex AVR-USB-32U4 Development Board.
+ *
+ *  Board specific Buttons driver header for the Olimex AVR-USB-T32U4 Development Board (http://www.olimex.com/dev/avr-t32u4.html).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
+ *  @{
+ */
+
+#ifndef __BUTTONS_OLIMEXT32U4_H__
+#define __BUTTONS_OLIMEXT32U4_H__
+
+       /* Includes: */
+               #include "../../../../Common/Common.h"
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_BUTTONS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/Buttons.h instead.
+               #endif
+
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** Button mask for the first button on the board. */
+                       #define BUTTONS_BUTTON1      (1 << 2)
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void Buttons_Init(void)
+                       {
+                               DDRE  &= ~BUTTONS_BUTTON1;
+                               PORTE |=  BUTTONS_BUTTON1;
+                       }
+
+                       static inline void Buttons_Disable(void)
+                       {
+                               DDRE  &= ~BUTTONS_BUTTON1;
+                               PORTE &= ~BUTTONS_BUTTON1;
+                       }
+
+                       static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t Buttons_GetStatus(void)
+                       {
+                               return ((PINE & BUTTONS_BUTTON1) ^ BUTTONS_BUTTON1);
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
+/** @} */
+
diff --git a/LUFA/Drivers/Board/AVR8/OLIMEXT32U4/LEDs.h b/LUFA/Drivers/Board/AVR8/OLIMEXT32U4/LEDs.h
new file mode 100644 (file)
index 0000000..1602af8
--- /dev/null
@@ -0,0 +1,169 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *  \brief Board specific LED driver header for the Olimex AVR-USB-T32U4.
+ *  \copydetails Group_LEDs_OLIMEXT32U4
+ *
+ *  \note This file should not be included directly. It is automatically included as needed by the LEDs driver
+ *        dispatch header located in LUFA/Drivers/Board/LEDs.h.
+ */
+
+/** \ingroup Group_LEDs
+ *  \defgroup Group_LEDs_OLIMEXT32U4 OLIMEXT32U4
+ *  \brief Board specific LED driver header for the Olimex AVR-USB-T32U4.
+ *
+ *  Board specific LED driver header for the Olimex AVR-USB-T32U4 (http://www.olimex.com/dev/avr-t32u4.html).
+ *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>TX</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Yellow</td><td>RX</td><td>High</td><td>PORTB.0</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>N/A</td><td>General Indicator (Not Mounted)</td><td>High</td><td>PORTE.6</td></tr>
+ *  </table>
+ *
+ *  @{
+ */
+
+#ifndef __LEDS_OLIMEXT32U4_H__
+#define __LEDS_OLIMEXT32U4_H__
+
+       /* Includes: */
+               #include "../../../../Common/Common.h"
+
+       /* Enable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       extern "C" {
+               #endif
+
+       /* Preprocessor Checks: */
+               #if !defined(__INCLUDE_FROM_LEDS_H)
+                       #error Do not include this file directly. Include LUFA/Drivers/Board/LEDS.h instead.
+               #endif
+
+       /* Private Interface - For use in library only: */
+       #if !defined(__DOXYGEN__)
+               /* Macros: */
+                       #define LEDS_PORTB_LEDS       (LEDS_LED2)
+                       #define LEDS_PORTD_LEDS       (LEDS_LED1)
+                       #define LEDS_PORTE_LEDS       (LEDS_LED3)
+       #endif
+       
+       /* Public Interface - May be used in end-application: */
+               /* Macros: */
+                       /** LED mask for the first LED on the board. */
+                       #define LEDS_LED1        (1 << 5)
+
+                       /** LED mask for the second LED on the board. */
+                       #define LEDS_LED2        (1 << 0)
+
+                       /** LED mask for the third LED on the board. */
+                       #define LEDS_LED3        (1 << 6)
+                       
+                       /** LED mask for all the LEDs on the board. */
+                       #define LEDS_ALL_LEDS    (LEDS_LED1 | LEDS_LED2 | LEDS_LED3)
+
+                       /** LED mask for none of the board LEDs. */
+                       #define LEDS_NO_LEDS     0
+
+               /* Inline Functions: */
+               #if !defined(__DOXYGEN__)
+                       static inline void LEDs_Init(void)
+                       {
+                               DDRB  |=  LEDS_PORTB_LEDS;
+                               PORTB &= ~LEDS_PORTB_LEDS;
+                               DDRD  |=  LEDS_PORTD_LEDS;
+                               PORTD &= ~LEDS_PORTD_LEDS;
+                               DDRE  |=  LEDS_PORTE_LEDS;
+                               PORTE &= ~LEDS_PORTE_LEDS;
+                       }
+
+                       static inline void LEDs_Disable(void)
+                       {
+                               DDRB  &=  LEDS_PORTB_LEDS;
+                               PORTB &= ~LEDS_PORTB_LEDS;
+                               DDRD  &=  LEDS_PORTD_LEDS;
+                               PORTD &= ~LEDS_PORTD_LEDS;
+                               DDRE  &=  LEDS_PORTE_LEDS;
+                               PORTE &= ~LEDS_PORTE_LEDS;
+                       }
+
+                       static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB |= (LEDMask & LEDS_PORTB_LEDS);
+                               PORTD |= (LEDMask & LEDS_PORTD_LEDS);
+                               PORTE |= (LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline void LEDs_TurnOffLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB &= ~(LEDMask & LEDS_PORTB_LEDS);
+                               PORTD &= ~(LEDMask & LEDS_PORTD_LEDS);
+                               PORTE &= ~(LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline void LEDs_SetAllLEDs(const uint8_t LEDMask)
+                       {
+                               PORTB = ((PORTB & ~LEDS_PORTB_LEDS) | (LEDMask & LEDS_PORTB_LEDS));
+                               PORTD = ((PORTD & ~LEDS_PORTD_LEDS) | (LEDMask & LEDS_PORTD_LEDS));
+                               PORTE = ((PORTE & ~LEDS_PORTE_LEDS) | (LEDMask & LEDS_PORTE_LEDS));
+                       }
+
+                       static inline void LEDs_ChangeLEDs(const uint8_t LEDMask,
+                                                          const uint8_t ActiveMask)
+                       {
+                               PORTB = ((PORTB & ~(LEDMask & LEDS_PORTB_LEDS)) | (ActiveMask & LEDS_PORTB_LEDS));
+                               PORTD = ((PORTD & ~(LEDMask & LEDS_PORTD_LEDS)) | (ActiveMask & LEDS_PORTD_LEDS));
+                               PORTE = ((PORTE & ~(LEDMask & LEDS_PORTE_LEDS)) | (ActiveMask & LEDS_PORTE_LEDS));
+                       }
+
+                       static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
+                       {
+                               PINB  = (LEDMask & LEDS_PORTB_LEDS);
+                               PIND  = (LEDMask & LEDS_PORTD_LEDS);
+                               PINE  = (LEDMask & LEDS_PORTE_LEDS);
+                       }
+
+                       static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
+                       static inline uint8_t LEDs_GetLEDs(void)
+                       {
+                               return ((PORTB & LEDS_PORTB_LEDS) | (PORTD & LEDS_PORTD_LEDS) | (PORTE & LEDS_PORTE_LEDS));
+                       }
+               #endif
+
+       /* Disable C linkage for C++ Compilers: */
+               #if defined(__cplusplus)
+                       }
+               #endif
+
+#endif
+
+/** @} */
+
index c85d8ad..7be9b37 100644 (file)
  *
  *  Board specific LED driver header for the Atmel RZUSBSTICK.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Blue</td><td>General Indicator</td><td>High</td><td>PORTD.7</td></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>General Indicator</td><td>Low</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTE.6</td></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>General Indicator</td><td>Low</td><td>PORTE.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= (LEDMask & LEDS_PORTD_LEDS);
-                               PORTE ^= ((LEDMask & LEDS_PORTE_LEDS) << LEDS_PORTE_MASK_SHIFT);
+                               PIND  = (LEDMask & LEDS_PORTD_LEDS);
+                               PINE  = ((LEDMask & LEDS_PORTE_LEDS) << LEDS_PORTE_MASK_SHIFT);
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 8985306..6998fd3 100644 (file)
  *
  *  Board specific LED driver header for the Sparkfun ATMEGA8U2 breakout board (http://www.sparkfun.com/products/10277).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTB.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= LEDMask;
+                               PINB  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 13abb83..a08fa5d 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel STK525.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 6774297..60375f9 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel STK525.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB321C (4MB)</td><td>PORTB.4</td><td>SPI0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 8cc5653..fb6c857 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel STK525.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>PORTB.6</td><td>PORTB.7</td><td>PORTE.4</td><td>PORTE.5</td><td>PORTB.5</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
@@ -76,7 +81,7 @@
                        #define JOY_LEFT                  (1 << 6)
 
                        /** Mask for the joystick being pushed in the right direction. */
-                       #define JOY_RIGHT                ((1 << 4) >> 1)
+                       #define JOY_RIGHT                ((1 << 4) >> JOY_PORTE_MASK_SHIFT)
 
                        /** Mask for the joystick being pushed in the upward direction. */
                        #define JOY_UP                    (1 << 7)
index c0111a2..04d5662 100644 (file)
  *
  *  Board specific LED driver header for the Atmel STK525.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 2c6b928..13ec376 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel STK526.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index ce20ff1..d58ad05 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel STK525.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB642D (8MB)</td><td>PORTC.2</td><td>SPI0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 3ab6e84..823fbf1 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel STK526.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>PORTB.4</td><td>PORTB.5</td><td>PORTB.6</td><td>PORTB.7</td><td>PORTB.0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index ed83356..d254a69 100644 (file)
  *
  *  Board specific LED driver header for the Atmel STK526.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.1</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.0</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 9a71cf5..7149923 100644 (file)
  *
  *  Board specific LED driver header for the PJRC Teensy boards (http://www.pjrc.com/teensy/index.html).
  *
+ *  <b>TEENSY</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.6</td></tr>
+ *  </table>
+ *
+ *  <b>TEENSY2</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTD.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 3eed13a..76c9d85 100644 (file)
  *
  *  Board specific Buttons driver header for the Busware TUL (http://www.busware.de/tiki-index.php?page=TUL).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 121f3f4..e659a9a 100644 (file)
  *
  *  Board specific LED driver header for the Busware TUL (http://www.busware.de/tiki-index.php?page=TUL).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTF.0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTF ^= LEDMask;
+                               PINF  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index b078364..3df6bac 100644 (file)
  *
  *  Board specific Buttons driver header for the Linnix UDIP (http://linnix.com/udip/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 30eb9ad..7ad6c44 100644 (file)
  *
  *  Board specific LED driver header for the Linnix UDIP (http://linnix.com/udip/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTB.6</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Red</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTB.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>Bicolor Indicator 2</td><td>High</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Red</td><td>Bicolor Indicator 2</td><td>High</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= (LEDMask & LEDS_PORTB_LEDS);
-                               PORTD ^= ((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT);
+                               PINB  = (LEDMask & LEDS_PORTB_LEDS);
+                               PIND  = ((LEDMask & LEDS_PORTD_LEDS) << LEDS_PORTD_MASK_SHIFT);
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 1fddba7..2a6178c 100644 (file)
  *
  *  Board specific LED driver header for the Arduino Uno (http://arduino.cc/en/Main/ArduinoBoardUno).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>RX</td><td>Low</td><td>PORTD.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Yellow</td><td>TX</td><td>Low</td><td>PORTD.5</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 9b83acf..73d05a5 100644 (file)
  *\r
  *  Board specific Buttons driver header for the Paranoid Studio USB2AX (http://paranoidstudio.assembla.com/wiki/show/paranoidstudio/USB2AX).\r
  *\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>\r
+ *  </table>\r
+ *\r
  *  @{\r
  */\r
 \r
index c34715e..12fa73c 100644 (file)
  *\r
  *  Board specific LED driver header for the Paranoid Studio USB2AX (http://paranoidstudio.assembla.com/wiki/show/paranoidstudio/USB2AX).\r
  *\r
+ *  <b>USB2AX</b>:\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTC.6</td></tr>\r
+ *  </table>\r
+ *\r
+ *  <b>USB2AX_V3</b>:\r
+ *  <table>\r
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>\r
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>High</td><td>PORTD.1</td></tr>\r
+ *  </table>\r
+ *\r
  *  @{\r
  */\r
 \r
                        static inline void LEDs_Init(void)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               DDRC  |= LEDS_ALL_LEDS;\r
-                               PORTC |= LEDS_ALL_LEDS;                         \r
+                               DDRC  |=  LEDS_ALL_LEDS;\r
+                               PORTC &= ~LEDS_ALL_LEDS;                                \r
                                #else\r
-                               DDRD  |= LEDS_ALL_LEDS;\r
-                               PORTD |= LEDS_ALL_LEDS;                         \r
+                               DDRD  |=  LEDS_ALL_LEDS;\r
+                               PORTD &= ~LEDS_ALL_LEDS;                                \r
                                #endif                          \r
                        }\r
 \r
                        static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               PORTC &= ~LEDMask;                              \r
+                               PORTC |= LEDMask;                               \r
                                #else\r
-                               PORTD &= ~LEDMask;\r
+                               PORTD |= LEDMask;\r
                                #endif\r
                        }\r
 \r
                        static inline void LEDs_TurnOffLEDs(const uint8_t LEDMask)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               PORTC |= LEDMask;\r
+                               PORTC &= ~LEDMask;\r
                                #else\r
-                               PORTD |= LEDMask;\r
+                               PORTD &= ~LEDMask;\r
                                #endif\r
                        }\r
 \r
                        static inline void LEDs_SetAllLEDs(const uint8_t LEDMask)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               PORTC = ((PORTC | LEDS_ALL_LEDS) & ~LEDMask);                           \r
+                               PORTC = ((PORTC & ~LEDS_ALL_LEDS) | LEDMask);                           \r
                                #else\r
-                               PORTD = ((PORTD | LEDS_ALL_LEDS) & ~LEDMask);\r
+                               PORTD = ((PORTD & ~LEDS_ALL_LEDS) | LEDMask);\r
                                #endif\r
                        }\r
 \r
                                                           const uint8_t ActiveMask)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               PORTC = ((PORTC | LEDMask) & ~ActiveMask);                              \r
+                               PORTC = ((PORTC & ~LEDMask) | ActiveMask);                              \r
                                #else\r
-                               PORTD = ((PORTD | LEDMask) & ~ActiveMask);\r
+                               PORTD = ((PORTD & ~LEDMask) | ActiveMask);\r
                                #endif\r
                        }\r
 \r
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               PORTC ^= LEDMask;                               \r
+                               PINC  = LEDMask;                                \r
                                #else\r
-                               PORTD ^= LEDMask;\r
+                               PIND  = LEDMask;\r
                                #endif\r
                        }\r
 \r
                        static inline uint8_t LEDs_GetLEDs(void)\r
                        {\r
                                #if (BOARD == BOARD_USB2AX)\r
-                               return (~PORTC & LEDS_ALL_LEDS);                                \r
+                               return (PORTC & LEDS_ALL_LEDS);                         \r
                                #else\r
-                               return (~PORTD & LEDS_ALL_LEDS);\r
+                               return (PORTD & LEDS_ALL_LEDS);\r
                                #endif\r
                        }\r
                #endif\r
index d03918c..111f7ec 100644 (file)
  *
  *  Board specific Buttons driver header for the Kernel Concepts USBFOO (http://shop.kernelconcepts.de/product_info.php?products_id=102).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index f838983..2d68caf 100644 (file)
  *
  *  Board specific LED driver header for the Kernel Concepts USBFOO (http://shop.kernelconcepts.de/product_info.php?products_id=102).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTD.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 3180725..9399f4f 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel USBKEY.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 5b71d7d..32f7ff9 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel USBKEY board.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB642D (8MB)</td><td>PORTE.0</td><td>SPI0</td></tr>
+ *    <tr><td>DATAFLASH_CHIP2</td><td>AT45DB642D (8MB)</td><td>PORTE.1</td><td>SPI0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 8b6935b..4136f79 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel USBKEY.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>PORTB.6</td><td>PORTB.7</td><td>PORTE.4</td><td>PORTE.5</td><td>PORTB.5</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 4ca7691..25a90a7 100644 (file)
  *
  *  Board specific LED driver header for the Atmel USBKEY.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>Bicolor Indicator 1</td><td>Low</td><td>PORTD.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>Bicolor Indicator 1</td><td>Low</td><td>PORTD.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Red</td><td>Bicolor Indicator 2</td><td>Low</td><td>PORTD.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>Bicolor Indicator 2</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTD ^= LEDMask;
+                               PIND  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index 6a6d78c..7313db2 100644 (file)
  *
  *  Board specific Buttons driver header for Tom's USBTINY MKII (http://tom-itx.dyndns.org:81/~webpage/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>HWB Button</td><td>Low</td><td>PORTD.7</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 0fcbf07..96acd62 100644 (file)
  *
  *  Board specific LED driver header for Tom's USBTINY MKII (http://tom-itx.dyndns.org:81/~webpage/).
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Red</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTB.6</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>Bicolor Indicator 1</td><td>High</td><td>PORTB.7</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Red</td><td>Target Power</td><td>High</td><td>PORTB.5</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= LEDMask;
+                               PINB  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index c9bdbdc..9647cc1 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel XPLAIN.
  *
+ *  <b>Revision 1 Boards</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB041D (512KB)</td><td>PORTB.5</td><td>SPI0</td></tr>
+ *  </table>
+ *
+ *  <b>Other Board Revisions</b>:
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB642D (8MB)</td><td>PORTB.5</td><td>SPI0</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
@@ -59,6 +71,7 @@
 
        /* Includes: */
                #include "../../../../Common/Common.h"
+               
                #include "../../../Misc/AT45DB642D.h"
                #include "../../../Peripheral/SPI.h"
 
index 9381548..879d656 100644 (file)
  *
  *  Board specific LED driver header for the Atmel XPLAIN.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>General Indicator</td><td>Low</td><td>PORTB.6</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
 
                        static inline void LEDs_ToggleLEDs(const uint8_t LEDMask)
                        {
-                               PORTB ^= LEDMask;
+                               PINB  = LEDMask;
                        }
 
                        static inline uint8_t LEDs_GetLEDs(void) ATTR_WARN_UNUSED_RESULT;
index bf85246..c3d6c0d 100644 (file)
                        #include "AVR8/MICROPENDOUS/Buttons.h"
                #elif (BOARD == BOARD_B1_XPLAINED)
                        #include "XMEGA/B1_XPLAINED/Buttons.h"
+               #elif (BOARD == BOARD_OLIMEX32U4)
+                       #include "AVR8/OLIMEX32U4/Buttons.h"            
+               #elif (BOARD == BOARD_OLIMEXT32U4)
+                       #include "AVR8/OLIMEXT32U4/Buttons.h"           
                #else
                        #include "Board/Buttons.h"
                #endif
index 46589c2..f6f9d82 100644 (file)
  *      // Turn on each of the four LEDs in turn
  *      LEDs_SetAllLEDs(LEDS_LED1);
  *      Delay_MS(500);
- *      LEDs_SetAllLEDs(LEDS_LED1);
+ *      LEDs_SetAllLEDs(LEDS_LED2);
  *      Delay_MS(500);
- *      LEDs_SetAllLEDs(LEDS_LED1);
+ *      LEDs_SetAllLEDs(LEDS_LED3);
  *      Delay_MS(500);
- *      LEDs_SetAllLEDs(LEDS_LED1);
+ *      LEDs_SetAllLEDs(LEDS_LED4);
  *      Delay_MS(500);
  *
  *      // Turn on all LEDs
                        #include "AVR8/MULTIO/LEDs.h"
                #elif (BOARD == BOARD_BIGMULTIO)
                        #include "AVR8/BIGMULTIO/LEDs.h"
+               #elif (BOARD == BOARD_DUCE)
+                       #include "AVR8/DUCE/LEDs.h"
+               #elif (BOARD == BOARD_OLIMEX32U4)
+                       #include "AVR8/OLIMEX32U4/LEDs.h"               
+               #elif (BOARD == BOARD_OLIMEXT32U4)
+                       #include "AVR8/OLIMEXT32U4/LEDs.h"              
                #else
                        #include "Board/LEDs.h"
                #endif
index e1b34b1..a5a0fd6 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel EVK1100.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>SW0 Button</td><td>Low</td><td>GPIO88</td></tr>
+ *    <tr><td>BUTTONS_BUTTON2</td><td>SW1 Button</td><td>Low</td><td>GPIO85</td></tr>
+ *    <tr><td>BUTTONS_BUTTON3</td><td>SW2 Button</td><td>Low</td><td>GPIO82</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index b9dbfbc..256da60 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel EVK1100.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>GPIO25</td><td>GPIO26</td><td>GPIO28</td><td>GPIO27</td><td>GPIO20</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 43c3ecb..4663baf 100644 (file)
  *
  *  Board specific LED driver header for the Atmel EVK1100.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>LED0 LED</td><td>Low</td><td>GPIO51</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>LED1 LED</td><td>Low</td><td>GPIO52</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>LED2 LED</td><td>Low</td><td>GPIO53</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>LED3 LED</td><td>Low</td><td>GPIO54</td></tr>
+ *    <tr><td>LEDS_LED5</td><td>Green</td><td>LED4 LED</td><td>Low</td><td>GPIO59</td></tr>
+ *    <tr><td>LEDS_LED6</td><td>Green</td><td>LED5 LED</td><td>Low</td><td>GPIO60</td></tr>
+ *    <tr><td>LEDS_LED7</td><td>Green</td><td>LED6 LED</td><td>Low</td><td>GPIO61</td></tr>
+ *    <tr><td>LEDS_LED8</td><td>Green</td><td>LED7 LED</td><td>Low</td><td>GPIO62</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 2e89af4..8971479 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel EVK1101.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>SW0 Button</td><td>Low</td><td>GPIO34</td></tr>
+ *    <tr><td>BUTTONS_BUTTON2</td><td>SW1 Button</td><td>Low</td><td>GPIO35</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 9983374..7850bfb 100644 (file)
  *
  *  Board specific joystick driver header for the Atmel EVK1101.
  *
+ *  <table>
+ *    <tr><th>Left Port Pin</th><th>Up Port Pin</th><th>Right Port Pin</th><th>Down Port Pin</th><th>Press Port Pin</th></tr>
+ *    <tr><td>GPIO38</td><td>GPIO39</td><td>GPIO41</td><td>GPIO40</td><td>GPIO13</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 43f3949..79a95b7 100644 (file)
  *
  *  Board specific LED driver header for the Atmel EVK1101.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>LED0 LED</td><td>Low</td><td>GPIO7</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>LED1 LED</td><td>Low</td><td>GPIO8</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>LED2 LED</td><td>Low</td><td>GPIO21</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>LED3 LED</td><td>Low</td><td>GPIO22</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index af8246d..d255c0a 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel EVK1104.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>SW0 Button</td><td>Low</td><td>GPIO42</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 1f5863b..e1caf19 100644 (file)
  *
  *  Board specific LED driver header for the Atmel EVK1104.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Green</td><td>LED0 LED</td><td>Low</td><td>GPIO67</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Green</td><td>LED1 LED</td><td>Low</td><td>GPIO101</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Green</td><td>LED2 LED</td><td>Low</td><td>GPIO102</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Green</td><td>LED3 LED</td><td>Low</td><td>GPIO105</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index d4e2084..8146ee3 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel XMEGA A3BU Xplained.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>SW0 Button</td><td>Low</td><td>PORTE.5</td></tr>
+ *    <tr><td>BUTTONS_BUTTON2</td><td>SW1 Button</td><td>Low</td><td>PORTF.1</td></tr>
+ *    <tr><td>BUTTONS_BUTTON3</td><td>SW2 Button</td><td>Low</td><td>PORTF.2</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index abc8d85..672d4eb 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel XMEGA B1 Xplained board.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB642D (8MB)</td><td>PORTF.4</td><td>USARTD0 (In SPI Mode)</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
                        #define DATAFLASH_TOTALCHIPS                 1
 
                        /** Mask for no dataflash chip selected. */
-                       #define DATAFLASH_NO_CHIP                    DATAFLASH_CHIPCS_MASK
+                       #define DATAFLASH_NO_CHIP                    0
 
                        /** Mask for the first dataflash chip selected. */
-                       #define DATAFLASH_CHIP1                      0
+                       #define DATAFLASH_CHIP1                      (1 << 4)
 
                        /** Internal main memory page size for the board's dataflash ICs. */
                        #define DATAFLASH_PAGE_SIZE                  1024
                         */
                        static inline void Dataflash_Init(void)
                        {
-                               DATAFLASH_CHIPCS_PORT.DIRSET = DATAFLASH_CHIPCS_MASK;
-                               DATAFLASH_CHIPCS_PORT.OUTSET = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.DIRSET   = DATAFLASH_CHIPCS_MASK;
+                               
+                               PORTCFG.MPCMASK                = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.PIN0CTRL = PORT_INVEN_bm; 
                        }
 
                        /** Sends a byte to the currently selected dataflash IC, and returns a byte from the dataflash.
                        static inline void Dataflash_SelectChip(const uint8_t ChipMask) ATTR_ALWAYS_INLINE;
                        static inline void Dataflash_SelectChip(const uint8_t ChipMask)
                        {
-                               DATAFLASH_CHIPCS_PORT.OUT = ((DATAFLASH_CHIPCS_PORT.OUT & ~DATAFLASH_CHIPCS_MASK) | ChipMask);
+                               DATAFLASH_CHIPCS_PORT.OUTCLR = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.OUTSET = ChipMask;
                        }
 
                        /** Deselects the current dataflash chip, so that no dataflash is selected. */
index 6212c9a..b47199b 100644 (file)
  *
  *  Board specific LED driver header for the Atmel XMEGA A3BU Xplained.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>LED0 LED</td><td>Low</td><td>PORTR.0</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Yellow</td><td>LED1 LED</td><td>Low</td><td>PORTR.1</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 2a08ed5..0e09832 100644 (file)
  *
  *  Board specific Buttons driver header for the Atmel XMEGA B1 Xplained.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>BUTTONS_BUTTON1</td><td>Touch CS0 Button</td><td>Low</td><td>PORTE.0</td></tr>
+ *    <tr><td>BUTTONS_BUTTON2</td><td>Touch CS1 Button</td><td>Low</td><td>PORTE.1</td></tr>
+ *    <tr><td>BUTTONS_BUTTON3</td><td>Touch CS2 Button</td><td>Low</td><td>PORTE.2</td></tr>
+ *    <tr><td>BUTTONS_BUTTON4</td><td>Touch CS3 Button</td><td>Low</td><td>PORTE.3</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index f1e6da5..d7ad64a 100644 (file)
  *
  *  Board specific Dataflash driver header for the Atmel XMEGA A3BU Xplained board.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Info</th><th>Select Pin</th><th>SPI Port</th></tr>
+ *    <tr><td>DATAFLASH_CHIP1</td><td>AT45DB642D (8MB)</td><td>PORTD.2</td><td>USARTC0 (In SPI Mode, Remapped)</td></tr>
+ *  </table> 
+ *
  *  @{
  */
 
                        #define DATAFLASH_TOTALCHIPS                 1
 
                        /** Mask for no dataflash chip selected. */
-                       #define DATAFLASH_NO_CHIP                    DATAFLASH_CHIPCS_MASK
+                       #define DATAFLASH_NO_CHIP                    0
 
                        /** Mask for the first dataflash chip selected. */
-                       #define DATAFLASH_CHIP1                      0
+                       #define DATAFLASH_CHIP1                      (1 << 2)
 
                        /** Internal main memory page size for the board's dataflash ICs. */
                        #define DATAFLASH_PAGE_SIZE                  1024
                         */
                        static inline void Dataflash_Init(void)
                        {
-                               DATAFLASH_CHIPCS_PORT.DIRSET = DATAFLASH_CHIPCS_MASK;
-                               DATAFLASH_CHIPCS_PORT.OUTSET = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.DIRSET   = DATAFLASH_CHIPCS_MASK;
+                               
+                               PORTCFG.MPCMASK                = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.PIN0CTRL = PORT_INVEN_bm; 
                                
-                               PORTE.REMAP |= PORT_USART0_bm;
+                               PORTC.REMAP |= PORT_USART0_bm;
                        }
 
                        /** Sends a byte to the currently selected dataflash IC, and returns a byte from the dataflash.
                        static inline uint8_t Dataflash_TransferByte(const uint8_t Byte) ATTR_ALWAYS_INLINE;
                        static inline uint8_t Dataflash_TransferByte(const uint8_t Byte)
                        {
-                               return SerialSPI_TransferByte(&USARTE0, Byte);
+                               return SerialSPI_TransferByte(&USARTC0, Byte);
                        }
 
                        /** Sends a byte to the currently selected dataflash IC, and ignores the next byte from the dataflash.
                        static inline void Dataflash_SendByte(const uint8_t Byte) ATTR_ALWAYS_INLINE;
                        static inline void Dataflash_SendByte(const uint8_t Byte)
                        {
-                               SerialSPI_SendByte(&USARTE0, Byte);
+                               SerialSPI_SendByte(&USARTC0, Byte);
                        }
 
                        /** Sends a dummy byte to the currently selected dataflash IC, and returns the next byte from the dataflash.
                        static inline uint8_t Dataflash_ReceiveByte(void) ATTR_ALWAYS_INLINE ATTR_WARN_UNUSED_RESULT;
                        static inline uint8_t Dataflash_ReceiveByte(void)
                        {
-                               return SerialSPI_ReceiveByte(&USARTE0);
+                               return SerialSPI_ReceiveByte(&USARTC0);
                        }
 
                        /** Determines the currently selected dataflash chip.
                        static inline void Dataflash_SelectChip(const uint8_t ChipMask) ATTR_ALWAYS_INLINE;
                        static inline void Dataflash_SelectChip(const uint8_t ChipMask)
                        {
-                               DATAFLASH_CHIPCS_PORT.OUT = ((DATAFLASH_CHIPCS_PORT.OUT & ~DATAFLASH_CHIPCS_MASK) | ChipMask);
+                               DATAFLASH_CHIPCS_PORT.OUTCLR = DATAFLASH_CHIPCS_MASK;
+                               DATAFLASH_CHIPCS_PORT.OUTSET = (ChipMask & DATAFLASH_CHIPCS_MASK);
                        }
 
                        /** Deselects the current dataflash chip, so that no dataflash is selected. */
index 1849787..54a678e 100644 (file)
  *
  *  Board specific LED driver header for the Atmel XMEGA B1 Xplained.
  *
+ *  <table>
+ *    <tr><th>Name</th><th>Color</th><th>Info</th><th>Active Level</th><th>Port Pin</th></tr>
+ *    <tr><td>LEDS_LED1</td><td>Yellow</td><td>LED0 LED</td><td>High</td><td>PORTB.4</td></tr>
+ *    <tr><td>LEDS_LED2</td><td>Yellow</td><td>LED1 LED</td><td>High</td><td>PORTB.5</td></tr>
+ *    <tr><td>LEDS_LED3</td><td>Yellow</td><td>LED2 LED</td><td>High</td><td>PORTB.6</td></tr>
+ *    <tr><td>LEDS_LED4</td><td>Yellow</td><td>LED3 LED</td><td>High</td><td>PORTB.7</td></tr>
+ *    <tr><td>LEDS_LED5</td><td>Green</td><td>USB LED</td><td>Low</td><td>PORTE.4</td></tr>
+ *  </table>
+ *
  *  @{
  */
 
index 0126630..562aaec 100644 (file)
                         */
                        static inline void SerialSPI_SendByte(const uint8_t DataByte)
                        {
-                               UDR1 = DataByte;
-                               while (!(UCSR1A & (1 << TXC1)));
-                               UCSR1A = (1 << TXC1);
+                               SerialSPI_TransferByte(DataByte);
                        }
 
                        /** Sends a dummy byte through the USART SPI interface, blocking until the transfer is complete. The response
                         */
                        static inline uint8_t SerialSPI_ReceiveByte(void)
                        {
-                               UDR1 = 0;
-                               while (!(UCSR1A & (1 << TXC1)));
-                               UCSR1A = (1 << TXC1);
-                               return UDR1;
+                               return SerialSPI_TransferByte(0);
                        }
                        
        /* Disable C linkage for C++ Compilers: */
index 6f8251f..a0e9e33 100644 (file)
@@ -52,7 +52,7 @@
  *
  *  \code
  *      // Initialize the Master SPI mode USART driver before first use, with 1Mbit baud
- *      SerialSPI_Init(&USARTD0, (USART_SPI_SCK_LEAD_RISING | SPI_SAMPLE_LEADING | SPI_ORDER_MSB_FIRST), 1000000);
+ *      SerialSPI_Init(&USARTD0, (USART_SPI_SCK_LEAD_RISING | USART_SPI_SAMPLE_LEADING | USART_SPI_ORDER_MSB_FIRST), 1000000);
  *
  *      // Send several bytes, ignoring the returned data
  *      SerialSPI_SendByte(&USARTD0, 0x01);
                        static inline void SerialSPI_SendByte(USART_t* const USART,
                                                              const uint8_t DataByte)
                        {
-                               USART->DATA   = DataByte;
-                               while (!(USART->STATUS & USART_TXCIF_bm));
-                               USART->STATUS = USART_TXCIF_bm;
+                               SerialSPI_TransferByte(USART, DataByte);
                        }
 
                        /** Sends a dummy byte through the USART SPI interface, blocking until the transfer is complete. The response
                         */
                        static inline uint8_t SerialSPI_ReceiveByte(USART_t* const USART)
                        {
-                               USART->DATA   = 0;
-                               while (!(USART->STATUS & USART_TXCIF_bm));
-                               USART->STATUS = USART_TXCIF_bm;
-                               return USART->DATA;
+                               return SerialSPI_TransferByte(USART, 0);
                        }
                        
        /* Disable C linkage for C++ Compilers: */
index 60b0908..25b80b7 100644 (file)
                 *  addresses are zero-indexed. This converts a natural MIDI channel number into the logical channel address.
                 *
                 *  \param[in] channel  MIDI channel number to address.
+                *
+                *  \return Constructed MIDI channel ID.
                 */
                #define MIDI_CHANNEL(channel)        ((channel) - 1)
+               
+               /** Constructs a MIDI event ID from a given MIDI command and a virtual MIDI cable index. This can then be
+                *  used to create and decode \ref MIDI_EventPacket_t MIDI event packets.
+                *
+                *  \param[in] virtualcable  Index of the virtual MIDI cable the event relates to
+                *  \param[in] command       MIDI command to send through the virtual MIDI cable
+                *
+                *  \return Constructed MIDI event ID.
+                */
+               #define MIDI_EVENT(virtualcable, command) ((virtualcable << 4) | (command >> 4))
 
        /* Enums: */
                /** Enum for the possible MIDI jack types in a MIDI device jack descriptor. */
                 */
                typedef struct
                {
-                       unsigned Command     : 4; /**< Upper nibble of the MIDI command being sent or received in the event packet. */
-                       unsigned CableNumber : 4; /**< Virtual cable number of the event being sent or received in the given MIDI interface. */
+                       uint8_t Event; /**< MIDI event type, constructed with the \ref MIDI_EVENT() macro. */
 
                        uint8_t  Data1; /**< First byte of data in the MIDI event. */
                        uint8_t  Data2; /**< Second byte of data in the MIDI event. */
index 15fcd58..ad79e9b 100644 (file)
@@ -48,15 +48,16 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
        
                if ((InterfaceIndex != AudioInterfaceInfo->Config.ControlInterfaceNumber) &&
                    (InterfaceIndex != AudioInterfaceInfo->Config.StreamingInterfaceNumber))
-               
-                 return;
+               {
+                       return;
+               }
        }
        else if ((USB_ControlRequest.bmRequestType & CONTROL_REQTYPE_RECIPIENT) == REQREC_ENDPOINT)
        {
-               uint8_t EndpointIndex = (USB_ControlRequest.wIndex & 0xFF);
+               uint8_t EndpointAddress = (USB_ControlRequest.wIndex & 0xFF);
        
-               if ((EndpointIndex != (ENDPOINT_DIR_IN  | AudioInterfaceInfo->Config.DataINEndpointNumber)) &&
-                   (EndpointIndex != (ENDPOINT_DIR_OUT | AudioInterfaceInfo->Config.DataOUTEndpointNumber)))
+               if ((EndpointAddress != AudioInterfaceInfo->Config.DataINEndpoint.Address) &&
+                   (EndpointAddress != AudioInterfaceInfo->Config.DataOUTEndpoint.Address))
                {
                        return;
                }
@@ -88,7 +89,7 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
                case AUDIO_REQ_SetMinimum:
                case AUDIO_REQ_SetMaximum:
                case AUDIO_REQ_SetResolution:
-                       if (USB_ControlRequest.bmRequestType == (REQDIR_HOSTTODEVICE | REQTYPE_CLASS | REQREC_ENDPOINT))
+                       if ((USB_ControlRequest.bmRequestType & CONTROL_REQTYPE_RECIPIENT) == REQREC_ENDPOINT)
                        {
                                uint8_t EndpointProperty = USB_ControlRequest.bRequest;
                                uint8_t EndpointAddress  = (uint8_t)USB_ControlRequest.wIndex;
@@ -108,7 +109,7 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
                                                                                     EndpointControl, &ValueLength, Value);
                                }
                        }
-                       else if (USB_ControlRequest.bmRequestType == (REQDIR_HOSTTODEVICE | REQTYPE_CLASS | REQREC_INTERFACE))
+                       else if ((USB_ControlRequest.bmRequestType & CONTROL_REQTYPE_RECIPIENT) == REQREC_INTERFACE)
                        {
                                uint8_t  Property  = USB_ControlRequest.bRequest;
                                uint8_t  Entity    = (USB_ControlRequest.wIndex >> 8);
@@ -134,7 +135,7 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
                case AUDIO_REQ_GetMinimum:
                case AUDIO_REQ_GetMaximum:
                case AUDIO_REQ_GetResolution:
-                       if (USB_ControlRequest.bmRequestType == (REQDIR_DEVICETOHOST | REQTYPE_CLASS | REQREC_ENDPOINT))
+                       if ((USB_ControlRequest.bmRequestType & CONTROL_REQTYPE_RECIPIENT) == REQREC_ENDPOINT)
                        {
                                uint8_t  EndpointProperty = USB_ControlRequest.bRequest;
                                uint8_t  EndpointAddress  = (uint8_t)USB_ControlRequest.wIndex;
@@ -150,7 +151,7 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
                                        Endpoint_ClearOUT();
                                }
                        }
-                       else if (USB_ControlRequest.bmRequestType == (REQDIR_DEVICETOHOST | REQTYPE_CLASS | REQREC_INTERFACE))
+                       else if ((USB_ControlRequest.bmRequestType & CONTROL_REQTYPE_RECIPIENT) == REQREC_INTERFACE)
                        {
                                uint8_t  Property    = USB_ControlRequest.bRequest;
                                uint8_t  Entity      = (USB_ControlRequest.wIndex >> 8);
@@ -174,39 +175,15 @@ void Audio_Device_ProcessControlRequest(USB_ClassInfo_Audio_Device_t* const Audi
 bool Audio_Device_ConfigureEndpoints(USB_ClassInfo_Audio_Device_t* const AudioInterfaceInfo)
 {
        memset(&AudioInterfaceInfo->State, 0x00, sizeof(AudioInterfaceInfo->State));
+       
+       AudioInterfaceInfo->Config.DataINEndpoint.Type  = EP_TYPE_ISOCHRONOUS;
+       AudioInterfaceInfo->Config.DataOUTEndpoint.Type = EP_TYPE_ISOCHRONOUS;
 
-       for (uint8_t EndpointNum = 1; EndpointNum < ENDPOINT_TOTAL_ENDPOINTS; EndpointNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Direction;
-               bool     DoubleBanked;
+       if (!(Endpoint_ConfigureEndpointTable(&AudioInterfaceInfo->Config.DataINEndpoint, 1)))
+         return false;
 
-               if (EndpointNum == AudioInterfaceInfo->Config.DataINEndpointNumber)
-               {
-                       Size         = AudioInterfaceInfo->Config.DataINEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_ISOCHRONOUS;
-                       DoubleBanked = true;
-               }
-               else if (EndpointNum == AudioInterfaceInfo->Config.DataOUTEndpointNumber)
-               {
-                       Size         = AudioInterfaceInfo->Config.DataOUTEndpointSize;
-                       Direction    = ENDPOINT_DIR_OUT;
-                       Type         = EP_TYPE_ISOCHRONOUS;
-                       DoubleBanked = true;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Endpoint_ConfigureEndpoint(EndpointNum, Type, Direction, Size,
-                                                DoubleBanked ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-               {
-                       return false;
-               }
-       }
+       if (!(Endpoint_ConfigureEndpointTable(&AudioInterfaceInfo->Config.DataOUTEndpoint, 1)))
+         return false;
 
        return true;
 }
index 2391266..a8bfc78 100644 (file)
                                                                                                                *   structure controls.
                                                                                                                */
 
-                                       uint8_t  DataINEndpointNumber; /**< Endpoint number of the incoming Audio Streaming data, if available
-                                                                                                       *   (zero if unused).
-                                                                                                       */
-                                       uint16_t DataINEndpointSize; /**< Size in bytes of the incoming Audio Streaming data endpoint, if available
-                                                                                                 *   (zero if unused).
-                                                                                                 */
-
-                                       uint8_t  DataOUTEndpointNumber; /**< Endpoint number of the outgoing Audio Streaming data, if available
-                                                                                                        *   (zero if unused).
-                                                                                                        */
-                                       uint16_t DataOUTEndpointSize; /**< Size in bytes of the outgoing Audio Streaming data endpoint, if available
-                                                                                                  *   (zero if unused).
-                                                                                                  */
+                                       USB_Endpoint_Table_t DataINEndpoint; /**< Data IN endpoint configuration table. */
+                                       USB_Endpoint_Table_t DataOUTEndpoint; /**< Data OUT endpoint configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
                                if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled))
                                  return false;
 
-                               Endpoint_SelectEndpoint(AudioInterfaceInfo->Config.DataOUTEndpointNumber);
+                               Endpoint_SelectEndpoint(AudioInterfaceInfo->Config.DataOUTEndpoint.Address);
                                return Endpoint_IsOUTReceived();
                        }
 
                                if ((USB_DeviceState != DEVICE_STATE_Configured) || !(AudioInterfaceInfo->State.InterfaceEnabled))
                                  return false;
 
-                               Endpoint_SelectEndpoint(AudioInterfaceInfo->Config.DataINEndpointNumber);
+                               Endpoint_SelectEndpoint(AudioInterfaceInfo->Config.DataINEndpoint.Address);
                                return Endpoint_IsINReady();
                        }
 
                        {
                                Endpoint_Write_8(Sample);
 
-                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
+                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpoint.Size)
                                  Endpoint_ClearIN();
                        }
 
                        {
                                Endpoint_Write_16_LE(Sample);
 
-                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
+                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpoint.Size)
                                  Endpoint_ClearIN();
                        }
 
                                Endpoint_Write_16_LE(Sample);
                                Endpoint_Write_8(Sample >> 16);
 
-                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpointSize)
+                               if (Endpoint_BytesInEndpoint() == AudioInterfaceInfo->Config.DataINEndpoint.Size)
                                  Endpoint_ClearIN();
                        }
 
index 5b53438..ff0f9bb 100644 (file)
@@ -69,8 +69,12 @@ void CDC_Device_ProcessControlRequest(USB_ClassInfo_CDC_Device_t* const CDCInter
                        {
                                Endpoint_ClearSETUP();
 
-                               while (!(Endpoint_IsOUTReceived()));
-
+                               while (!(Endpoint_IsOUTReceived()))
+                               {
+                                       if (USB_DeviceState == DEVICE_STATE_Unattached)
+                                         return;
+                               }
+                               
                                CDCInterfaceInfo->State.LineEncoding.BaudRateBPS = Endpoint_Read_32_LE();
                                CDCInterfaceInfo->State.LineEncoding.CharFormat  = Endpoint_Read_8();
                                CDCInterfaceInfo->State.LineEncoding.ParityType  = Endpoint_Read_8();
@@ -112,45 +116,18 @@ bool CDC_Device_ConfigureEndpoints(USB_ClassInfo_CDC_Device_t* const CDCInterfac
 {
        memset(&CDCInterfaceInfo->State, 0x00, sizeof(CDCInterfaceInfo->State));
 
-       for (uint8_t EndpointNum = 1; EndpointNum < ENDPOINT_TOTAL_ENDPOINTS; EndpointNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Direction;
-               bool     DoubleBanked;
+       CDCInterfaceInfo->Config.DataINEndpoint.Type       = EP_TYPE_BULK;
+       CDCInterfaceInfo->Config.DataOUTEndpoint.Type      = EP_TYPE_BULK;
+       CDCInterfaceInfo->Config.NotificationEndpoint.Type = EP_TYPE_INTERRUPT;
 
-               if (EndpointNum == CDCInterfaceInfo->Config.DataINEndpointNumber)
-               {
-                       Size         = CDCInterfaceInfo->Config.DataINEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = CDCInterfaceInfo->Config.DataINEndpointDoubleBank;
-               }
-               else if (EndpointNum == CDCInterfaceInfo->Config.DataOUTEndpointNumber)
-               {
-                       Size         = CDCInterfaceInfo->Config.DataOUTEndpointSize;
-                       Direction    = ENDPOINT_DIR_OUT;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = CDCInterfaceInfo->Config.DataOUTEndpointDoubleBank;
-               }
-               else if (EndpointNum == CDCInterfaceInfo->Config.NotificationEndpointNumber)
-               {
-                       Size         = CDCInterfaceInfo->Config.NotificationEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_INTERRUPT;
-                       DoubleBanked = CDCInterfaceInfo->Config.NotificationEndpointDoubleBank;
-               }
-               else
-               {
-                       continue;
-               }
+       if (!(Endpoint_ConfigureEndpointTable(&CDCInterfaceInfo->Config.DataINEndpoint, 1)))
+         return false;
 
-               if (!(Endpoint_ConfigureEndpoint(EndpointNum, Type, Direction, Size,
-                                                DoubleBanked ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-               {
-                       return false;
-               }
-       }
+       if (!(Endpoint_ConfigureEndpointTable(&CDCInterfaceInfo->Config.DataOUTEndpoint, 1)))
+         return false;
+
+       if (!(Endpoint_ConfigureEndpointTable(&CDCInterfaceInfo->Config.NotificationEndpoint, 1)))
+         return false;
 
        return true;
 }
@@ -171,7 +148,7 @@ uint8_t CDC_Device_SendString(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo
        if ((USB_DeviceState != DEVICE_STATE_Configured) || !(CDCInterfaceInfo->State.LineEncoding.BaudRateBPS))
          return ENDPOINT_RWSTREAM_DeviceDisconnected;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpoint.Address);
        return Endpoint_Write_Stream_LE(String, strlen(String), NULL);
 }
 
@@ -182,7 +159,7 @@ uint8_t CDC_Device_SendData(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo,
        if ((USB_DeviceState != DEVICE_STATE_Configured) || !(CDCInterfaceInfo->State.LineEncoding.BaudRateBPS))
          return ENDPOINT_RWSTREAM_DeviceDisconnected;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpoint.Address);
        return Endpoint_Write_Stream_LE(Buffer, Length, NULL);
 }
 
@@ -192,7 +169,7 @@ uint8_t CDC_Device_SendByte(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo,
        if ((USB_DeviceState != DEVICE_STATE_Configured) || !(CDCInterfaceInfo->State.LineEncoding.BaudRateBPS))
          return ENDPOINT_RWSTREAM_DeviceDisconnected;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpoint.Address);
 
        if (!(Endpoint_IsReadWriteAllowed()))
        {
@@ -215,7 +192,7 @@ uint8_t CDC_Device_Flush(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo)
 
        uint8_t ErrorCode;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataINEndpoint.Address);
 
        if (!(Endpoint_BytesInEndpoint()))
          return ENDPOINT_READYWAIT_NoError;
@@ -240,7 +217,7 @@ uint16_t CDC_Device_BytesReceived(USB_ClassInfo_CDC_Device_t* const CDCInterface
        if ((USB_DeviceState != DEVICE_STATE_Configured) || !(CDCInterfaceInfo->State.LineEncoding.BaudRateBPS))
          return 0;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataOUTEndpoint.Address);
 
        if (Endpoint_IsOUTReceived())
        {
@@ -267,7 +244,7 @@ int16_t CDC_Device_ReceiveByte(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInf
 
        int16_t ReceivedByte = -1;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.DataOUTEndpoint.Address);
 
        if (Endpoint_IsOUTReceived())
        {
@@ -286,7 +263,7 @@ void CDC_Device_SendControlLineStateChange(USB_ClassInfo_CDC_Device_t* const CDC
        if ((USB_DeviceState != DEVICE_STATE_Configured) || !(CDCInterfaceInfo->State.LineEncoding.BaudRateBPS))
          return;
 
-       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.NotificationEndpointNumber);
+       Endpoint_SelectEndpoint(CDCInterfaceInfo->Config.NotificationEndpoint.Address);
 
        USB_Request_Header_t Notification = (USB_Request_Header_t)
                {
index cc0dd1b..508c234 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  ControlInterfaceNumber; /**< Interface number of the CDC control interface within the device. */
-
-                                       uint8_t  DataINEndpointNumber; /**< Endpoint number of the CDC interface's IN data endpoint. */
-                                       uint16_t DataINEndpointSize; /**< Size in bytes of the CDC interface's IN data endpoint. */
-                                       bool     DataINEndpointDoubleBank; /**< Indicates if the CDC interface's IN data endpoint should use double banking. */
-
-                                       uint8_t  DataOUTEndpointNumber; /**< Endpoint number of the CDC interface's OUT data endpoint. */
-                                       uint16_t DataOUTEndpointSize;  /**< Size in bytes of the CDC interface's OUT data endpoint. */
-                                       bool     DataOUTEndpointDoubleBank; /**< Indicates if the CDC interface's OUT data endpoint should use double banking. */
-
-                                       uint8_t  NotificationEndpointNumber; /**< Endpoint number of the CDC interface's IN notification endpoint, if used. */
-                                       uint16_t NotificationEndpointSize;  /**< Size in bytes of the CDC interface's IN notification endpoint, if used. */
-                                       bool     NotificationEndpointDoubleBank; /**< Indicates if the CDC interface's notification endpoint should use double banking. */
+                                       uint8_t ControlInterfaceNumber; /**< Interface number of the CDC control interface within the device. */
+                                       
+                                       USB_Endpoint_Table_t DataINEndpoint; /**< Data IN endpoint configuration table. */
+                                       USB_Endpoint_Table_t DataOUTEndpoint; /**< Data OUT endpoint configuration table. */
+                                       USB_Endpoint_Table_t NotificationEndpoint; /**< Notification IN Endpoint configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
index 5c8d878..e4b5653 100644 (file)
@@ -141,13 +141,11 @@ bool HID_Device_ConfigureEndpoints(USB_ClassInfo_HID_Device_t* const HIDInterfac
        HIDInterfaceInfo->State.UsingReportProtocol = true;
        HIDInterfaceInfo->State.IdleCount           = 500;
 
-       if (!(Endpoint_ConfigureEndpoint(HIDInterfaceInfo->Config.ReportINEndpointNumber, EP_TYPE_INTERRUPT,
-                                                                        ENDPOINT_DIR_IN, HIDInterfaceInfo->Config.ReportINEndpointSize,
-                                                                        HIDInterfaceInfo->Config.ReportINEndpointDoubleBank ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-       {
-               return false;
-       }
+       HIDInterfaceInfo->Config.ReportINEndpoint.Type = EP_TYPE_INTERRUPT;
 
+       if (!(Endpoint_ConfigureEndpointTable(&HIDInterfaceInfo->Config.ReportINEndpoint, 1)))
+         return false; 
+       
        return true;
 }
 
@@ -159,7 +157,7 @@ void HID_Device_USBTask(USB_ClassInfo_HID_Device_t* const HIDInterfaceInfo)
        if (HIDInterfaceInfo->State.PrevFrameNum == USB_Device_GetFrameNumber())
          return;
          
-       Endpoint_SelectEndpoint(HIDInterfaceInfo->Config.ReportINEndpointNumber);
+       Endpoint_SelectEndpoint(HIDInterfaceInfo->Config.ReportINEndpoint.Address);
 
        if (Endpoint_IsReadWriteAllowed())
        {
@@ -184,7 +182,7 @@ void HID_Device_USBTask(USB_ClassInfo_HID_Device_t* const HIDInterfaceInfo)
                {
                        HIDInterfaceInfo->State.IdleMSRemaining = HIDInterfaceInfo->State.IdleCount;
 
-                       Endpoint_SelectEndpoint(HIDInterfaceInfo->Config.ReportINEndpointNumber);
+                       Endpoint_SelectEndpoint(HIDInterfaceInfo->Config.ReportINEndpoint.Address);
 
                        if (ReportID)
                          Endpoint_Write_8(ReportID);
index a6361c6..e358dec 100644 (file)
@@ -85,9 +85,7 @@
                                {
                                        uint8_t  InterfaceNumber; /**< Interface number of the HID interface within the device. */
 
-                                       uint8_t  ReportINEndpointNumber; /**< Endpoint number of the HID interface's IN report endpoint. */
-                                       uint16_t ReportINEndpointSize; /**< Size in bytes of the HID interface's IN report endpoint. */
-                                       bool     ReportINEndpointDoubleBank; /**< Indicates if the HID interface's IN report endpoint should use double banking. */
+                                       USB_Endpoint_Table_t ReportINEndpoint; /**< Data IN HID report endpoint configuration table. */
 
                                        void*    PrevReportINBuffer; /**< Pointer to a buffer where the previously created HID input report can be
                                                                      *  stored by the driver, for comparison purposes to detect report changes that
index 9f0506e..c9553a4 100644 (file)
@@ -41,38 +41,14 @@ bool MIDI_Device_ConfigureEndpoints(USB_ClassInfo_MIDI_Device_t* const MIDIInter
 {
        memset(&MIDIInterfaceInfo->State, 0x00, sizeof(MIDIInterfaceInfo->State));
 
-       for (uint8_t EndpointNum = 1; EndpointNum < ENDPOINT_TOTAL_ENDPOINTS; EndpointNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Direction;
-               bool     DoubleBanked;
-
-               if (EndpointNum == MIDIInterfaceInfo->Config.DataINEndpointNumber)
-               {
-                       Size         = MIDIInterfaceInfo->Config.DataINEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = MIDIInterfaceInfo->Config.DataINEndpointDoubleBank;
-               }
-               else if (EndpointNum == MIDIInterfaceInfo->Config.DataOUTEndpointNumber)
-               {
-                       Size         = MIDIInterfaceInfo->Config.DataOUTEndpointSize;
-                       Direction    = ENDPOINT_DIR_OUT;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = MIDIInterfaceInfo->Config.DataOUTEndpointDoubleBank;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Endpoint_ConfigureEndpoint(EndpointNum, Type, Direction, Size,
-                                                DoubleBanked ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-               {
-                       return false;
-               }
-       }
+       MIDIInterfaceInfo->Config.DataINEndpoint.Type  = EP_TYPE_BULK;
+       MIDIInterfaceInfo->Config.DataOUTEndpoint.Type = EP_TYPE_BULK;
+
+       if (!(Endpoint_ConfigureEndpointTable(&MIDIInterfaceInfo->Config.DataINEndpoint, 1)))
+         return false;
+
+       if (!(Endpoint_ConfigureEndpointTable(&MIDIInterfaceInfo->Config.DataOUTEndpoint, 1)))
+         return false;
 
        return true;
 }
@@ -95,7 +71,7 @@ uint8_t MIDI_Device_SendEventPacket(USB_ClassInfo_MIDI_Device_t* const MIDIInter
 
        uint8_t ErrorCode;
 
-       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataINEndpoint.Address);
 
        if ((ErrorCode = Endpoint_Write_Stream_LE(Event, sizeof(MIDI_EventPacket_t), NULL)) != ENDPOINT_RWSTREAM_NoError)
          return ErrorCode;
@@ -113,7 +89,7 @@ uint8_t MIDI_Device_Flush(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo)
 
        uint8_t ErrorCode;
 
-       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataINEndpoint.Address);
 
        if (Endpoint_BytesInEndpoint())
        {
@@ -132,7 +108,7 @@ bool MIDI_Device_ReceiveEventPacket(USB_ClassInfo_MIDI_Device_t* const MIDIInter
        if (USB_DeviceState != DEVICE_STATE_Configured)
          return false;
 
-       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(MIDIInterfaceInfo->Config.DataOUTEndpoint.Address);
 
        if (!(Endpoint_IsReadWriteAllowed()))
          return false;
index 4fe49af..2703600 100644 (file)
                                {
                                        uint8_t  StreamingInterfaceNumber; /**< Index of the Audio Streaming interface within the device this structure controls. */
 
-                                       uint8_t  DataINEndpointNumber; /**< Endpoint number of the incoming MIDI IN data, if available (zero if unused). */
-                                       uint16_t DataINEndpointSize; /**< Size in bytes of the incoming MIDI IN data endpoint, if available (zero if unused). */
-                                       bool     DataINEndpointDoubleBank; /**< Indicates if the MIDI interface's IN data endpoint should use double banking. */
-
-                                       uint8_t  DataOUTEndpointNumber; /**< Endpoint number of the outgoing MIDI OUT data, if available (zero if unused). */
-                                       uint16_t DataOUTEndpointSize; /**< Size in bytes of the outgoing MIDI OUT data endpoint, if available (zero if unused). */
-                                       bool     DataOUTEndpointDoubleBank; /**< Indicates if the MIDI interface's OUT data endpoint should use double banking. */
+                                       USB_Endpoint_Table_t DataINEndpoint; /**< Data IN endpoint configuration table. */
+                                       USB_Endpoint_Table_t DataOUTEndpoint; /**< Data OUT endpoint configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
index 6294a0a..153ebbc 100644 (file)
@@ -75,38 +75,14 @@ bool MS_Device_ConfigureEndpoints(USB_ClassInfo_MS_Device_t* const MSInterfaceIn
 {
        memset(&MSInterfaceInfo->State, 0x00, sizeof(MSInterfaceInfo->State));
 
-       for (uint8_t EndpointNum = 1; EndpointNum < ENDPOINT_TOTAL_ENDPOINTS; EndpointNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Direction;
-               bool     DoubleBanked;
+       MSInterfaceInfo->Config.DataINEndpoint.Type  = EP_TYPE_BULK;
+       MSInterfaceInfo->Config.DataOUTEndpoint.Type = EP_TYPE_BULK;
 
-               if (EndpointNum == MSInterfaceInfo->Config.DataINEndpointNumber)
-               {
-                       Size         = MSInterfaceInfo->Config.DataINEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = MSInterfaceInfo->Config.DataINEndpointDoubleBank;
-               }
-               else if (EndpointNum == MSInterfaceInfo->Config.DataOUTEndpointNumber)
-               {
-                       Size         = MSInterfaceInfo->Config.DataOUTEndpointSize;
-                       Direction    = ENDPOINT_DIR_OUT;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = MSInterfaceInfo->Config.DataOUTEndpointDoubleBank;
-               }
-               else
-               {
-                       continue;
-               }
+       if (!(Endpoint_ConfigureEndpointTable(&MSInterfaceInfo->Config.DataINEndpoint, 1)))
+         return false;
 
-               if (!(Endpoint_ConfigureEndpoint(EndpointNum, Type, Direction, Size,
-                                                DoubleBanked ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-               {
-                       return false;
-               }
-       }
+       if (!(Endpoint_ConfigureEndpointTable(&MSInterfaceInfo->Config.DataOUTEndpoint, 1)))
+         return false;
 
        return true;
 }
@@ -116,14 +92,14 @@ void MS_Device_USBTask(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo)
        if (USB_DeviceState != DEVICE_STATE_Configured)
          return;
 
-       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpoint.Address);
 
-       if (Endpoint_IsReadWriteAllowed())
+       if (Endpoint_IsOUTReceived())
        {
                if (MS_Device_ReadInCommandBlock(MSInterfaceInfo))
                {
                        if (MSInterfaceInfo->State.CommandBlock.Flags & MS_COMMAND_DIR_DATA_IN)
-                         Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber);
+                         Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpoint.Address);
 
                        bool SCSICommandResult = CALLBACK_MS_Device_SCSICommandReceived(MSInterfaceInfo);
 
@@ -141,13 +117,13 @@ void MS_Device_USBTask(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo)
 
        if (MSInterfaceInfo->State.IsMassStoreReset)
        {
-               Endpoint_ResetEndpoint(MSInterfaceInfo->Config.DataOUTEndpointNumber);
-               Endpoint_ResetEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber);
+               Endpoint_ResetEndpoint(MSInterfaceInfo->Config.DataOUTEndpoint.Address);
+               Endpoint_ResetEndpoint(MSInterfaceInfo->Config.DataINEndpoint.Address);
 
-               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpointNumber);
+               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpoint.Address);
                Endpoint_ClearStall();
                Endpoint_ResetDataToggle();
-               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber);
+               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpoint.Address);
                Endpoint_ClearStall();
                Endpoint_ResetDataToggle();
 
@@ -159,8 +135,8 @@ static bool MS_Device_ReadInCommandBlock(USB_ClassInfo_MS_Device_t* const MSInte
 {
        uint16_t BytesProcessed;
 
-       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpointNumber);
-
+       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpoint.Address);
+       
        BytesProcessed = 0;
        while (Endpoint_Read_Stream_LE(&MSInterfaceInfo->State.CommandBlock,
                                       (sizeof(MS_CommandBlockWrapper_t) - 16), &BytesProcessed) ==
@@ -175,9 +151,9 @@ static bool MS_Device_ReadInCommandBlock(USB_ClassInfo_MS_Device_t* const MSInte
                (MSInterfaceInfo->State.CommandBlock.Flags              & 0x1F)                              ||
                (MSInterfaceInfo->State.CommandBlock.SCSICommandLength == 0)                                 ||
                (MSInterfaceInfo->State.CommandBlock.SCSICommandLength >  16))
-       {
+       {               
                Endpoint_StallTransaction();
-               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber);
+               Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpoint.Address);
                Endpoint_StallTransaction();
 
                return false;
@@ -199,7 +175,7 @@ static bool MS_Device_ReadInCommandBlock(USB_ClassInfo_MS_Device_t* const MSInte
 
 static void MS_Device_ReturnCommandStatus(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo)
 {
-       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataOUTEndpoint.Address);
 
        while (Endpoint_IsStalled())
        {
@@ -211,7 +187,7 @@ static void MS_Device_ReturnCommandStatus(USB_ClassInfo_MS_Device_t* const MSInt
                  return;
        }
 
-       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(MSInterfaceInfo->Config.DataINEndpoint.Address);
 
        while (Endpoint_IsStalled())
        {
index c2d536c..6b490ec 100644 (file)
                                {
                                        uint8_t  InterfaceNumber; /**< Interface number of the Mass Storage interface within the device. */
 
-                                       uint8_t  DataINEndpointNumber; /**< Endpoint number of the Mass Storage interface's IN data endpoint. */
-                                       uint16_t DataINEndpointSize; /**< Size in bytes of the Mass Storage interface's IN data endpoint. */
-                                       bool     DataINEndpointDoubleBank; /**< Indicates if the Mass Storage interface's IN data endpoint should use double banking. */
-
-                                       uint8_t  DataOUTEndpointNumber; /**< Endpoint number of the Mass Storage interface's OUT data endpoint. */
-                                       uint16_t DataOUTEndpointSize;  /**< Size in bytes of the Mass Storage interface's OUT data endpoint. */
-                                       bool     DataOUTEndpointDoubleBank; /**< Indicates if the Mass Storage interface's OUT data endpoint should use double banking. */
+                                       USB_Endpoint_Table_t DataINEndpoint; /**< Data IN endpoint configuration table. */
+                                       USB_Endpoint_Table_t DataOUTEndpoint; /**< Data OUT endpoint configuration table. */
 
                                        uint8_t  TotalLUNs; /**< Total number of logical drives in the Mass Storage interface. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
index f78a5ab..e5aa40c 100644 (file)
@@ -115,45 +115,18 @@ bool RNDIS_Device_ConfigureEndpoints(USB_ClassInfo_RNDIS_Device_t* const RNDISIn
 {
        memset(&RNDISInterfaceInfo->State, 0x00, sizeof(RNDISInterfaceInfo->State));
 
-       for (uint8_t EndpointNum = 1; EndpointNum < ENDPOINT_TOTAL_ENDPOINTS; EndpointNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Direction;
-               bool     DoubleBanked;
-
-               if (EndpointNum == RNDISInterfaceInfo->Config.DataINEndpointNumber)
-               {
-                       Size         = RNDISInterfaceInfo->Config.DataINEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = RNDISInterfaceInfo->Config.DataINEndpointDoubleBank;
-               }
-               else if (EndpointNum == RNDISInterfaceInfo->Config.DataOUTEndpointNumber)
-               {
-                       Size         = RNDISInterfaceInfo->Config.DataOUTEndpointSize;
-                       Direction    = ENDPOINT_DIR_OUT;
-                       Type         = EP_TYPE_BULK;
-                       DoubleBanked = RNDISInterfaceInfo->Config.DataOUTEndpointDoubleBank;
-               }
-               else if (EndpointNum == RNDISInterfaceInfo->Config.NotificationEndpointNumber)
-               {
-                       Size         = RNDISInterfaceInfo->Config.NotificationEndpointSize;
-                       Direction    = ENDPOINT_DIR_IN;
-                       Type         = EP_TYPE_INTERRUPT;
-                       DoubleBanked = RNDISInterfaceInfo->Config.NotificationEndpointDoubleBank;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Endpoint_ConfigureEndpoint(EndpointNum, Type, Direction, Size,
-                                                DoubleBanked ? ENDPOINT_BANK_DOUBLE : ENDPOINT_BANK_SINGLE)))
-               {
-                       return false;
-               }
-       }
+       RNDISInterfaceInfo->Config.DataINEndpoint.Type       = EP_TYPE_BULK;
+       RNDISInterfaceInfo->Config.DataOUTEndpoint.Type      = EP_TYPE_BULK;
+       RNDISInterfaceInfo->Config.NotificationEndpoint.Type = EP_TYPE_INTERRUPT;
+
+       if (!(Endpoint_ConfigureEndpointTable(&RNDISInterfaceInfo->Config.DataINEndpoint, 1)))
+         return false;
+
+       if (!(Endpoint_ConfigureEndpointTable(&RNDISInterfaceInfo->Config.DataOUTEndpoint, 1)))
+         return false;
+
+       if (!(Endpoint_ConfigureEndpointTable(&RNDISInterfaceInfo->Config.NotificationEndpoint, 1)))
+         return false;
 
        return true;
 }
@@ -163,7 +136,7 @@ void RNDIS_Device_USBTask(USB_ClassInfo_RNDIS_Device_t* const RNDISInterfaceInfo
        if (USB_DeviceState != DEVICE_STATE_Configured)
          return;
 
-       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.NotificationEndpointNumber);
+       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.NotificationEndpoint.Address);
 
        if (Endpoint_IsINReady() && RNDISInterfaceInfo->State.ResponseReady)
        {
@@ -454,7 +427,7 @@ bool RNDIS_Device_IsPacketReceived(USB_ClassInfo_RNDIS_Device_t* const RNDISInte
                return false;
        }
 
-       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataOUTEndpoint.Address);
        return Endpoint_IsOUTReceived();
 }
 
@@ -468,7 +441,7 @@ uint8_t RNDIS_Device_ReadPacket(USB_ClassInfo_RNDIS_Device_t* const RNDISInterfa
                return ENDPOINT_RWSTREAM_DeviceDisconnected;
        }
 
-       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataOUTEndpointNumber);
+       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataOUTEndpoint.Address);
 
        *PacketLength = 0;
 
@@ -505,7 +478,7 @@ uint8_t RNDIS_Device_SendPacket(USB_ClassInfo_RNDIS_Device_t* const RNDISInterfa
                return ENDPOINT_RWSTREAM_DeviceDisconnected;
        }
 
-       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataINEndpointNumber);
+       Endpoint_SelectEndpoint(RNDISInterfaceInfo->Config.DataINEndpoint.Address);
 
        if ((ErrorCode = Endpoint_WaitUntilReady()) != ENDPOINT_READYWAIT_NoError)
          return ErrorCode;
index ccd20e3..33b807d 100644 (file)
                                {
                                        uint8_t  ControlInterfaceNumber; /**< Interface number of the RNDIS control interface within the device. */
 
-                                       uint8_t  DataINEndpointNumber; /**< Endpoint number of the RNDIS interface's IN data endpoint. */
-                                       uint16_t DataINEndpointSize; /**< Size in bytes of the RNDIS interface's IN data endpoint. */
-                                       bool     DataINEndpointDoubleBank; /**< Indicates if the RNDIS interface's IN data endpoint should use double banking. */
-
-                                       uint8_t  DataOUTEndpointNumber; /**< Endpoint number of the RNDIS interface's OUT data endpoint. */
-                                       uint16_t DataOUTEndpointSize;  /**< Size in bytes of the RNDIS interface's OUT data endpoint. */
-                                       bool     DataOUTEndpointDoubleBank; /**< Indicates if the RNDIS interface's OUT data endpoint should use double banking. */
-
-                                       uint8_t  NotificationEndpointNumber; /**< Endpoint number of the RNDIS interface's IN notification endpoint, if used. */
-                                       uint16_t NotificationEndpointSize;  /**< Size in bytes of the RNDIS interface's IN notification endpoint, if used. */
-                                       bool     NotificationEndpointDoubleBank; /**< Indicates if the RNDIS interface's notification endpoint should use double banking. */
+                                       USB_Endpoint_Table_t DataINEndpoint; /**< Data IN endpoint configuration table. */
+                                       USB_Endpoint_Table_t DataOUTEndpoint; /**< Data OUT endpoint configuration table. */
+                                       USB_Endpoint_Table_t NotificationEndpoint; /**< Notification IN Endpoint configuration table. */
 
                                        char*         AdapterVendorDescription; /**< String description of the adapter vendor. */
                                        MAC_Address_t AdapterMACAddress; /**< MAC address of the adapter. */
index eb4c253..7c564e0 100644 (file)
@@ -89,45 +89,19 @@ uint8_t AOA_Host_ConfigurePipes(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo
                  DataOUTEndpoint = EndpointData;\r
        }\r
 \r
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)\r
-       {\r
-               uint16_t Size;\r
-               uint8_t  Type;\r
-               uint8_t  Token;\r
-               uint8_t  EndpointAddress;\r
-               bool     DoubleBanked;\r
-\r
-               if (PipeNum == AOAInterfaceInfo->Config.DataINPipeNumber)\r
-               {\r
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);\r
-                       EndpointAddress = DataINEndpoint->EndpointAddress;\r
-                       Token           = PIPE_TOKEN_IN;\r
-                       Type            = EP_TYPE_BULK;\r
-                       DoubleBanked    = AOAInterfaceInfo->Config.DataINPipeDoubleBank;\r
-\r
-                       AOAInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;\r
-               }\r
-               else if (PipeNum == AOAInterfaceInfo->Config.DataOUTPipeNumber)\r
-               {\r
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);\r
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;\r
-                       Token           = PIPE_TOKEN_OUT;\r
-                       Type            = EP_TYPE_BULK;\r
-                       DoubleBanked    = AOAInterfaceInfo->Config.DataOUTPipeDoubleBank;\r
-\r
-                       AOAInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;\r
-               }\r
-               else\r
-               {\r
-                       continue;\r
-               }\r
-               \r
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,\r
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))\r
-               {\r
-                       return AOA_ENUMERROR_PipeConfigurationFailed;\r
-               }\r
-       }\r
+       AOAInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);\r
+       AOAInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;\r
+       AOAInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;\r
+       \r
+       AOAInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);\r
+       AOAInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;\r
+       AOAInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;\r
+       \r
+       if (!(Pipe_ConfigurePipeTable(&AOAInterfaceInfo->Config.DataINPipe, 1)))\r
+         return false;\r
+       \r
+       if (!(Pipe_ConfigurePipeTable(&AOAInterfaceInfo->Config.DataOUTPipe, 1)))\r
+         return false;\r
 \r
        AOAInterfaceInfo->State.IsActive        = true;\r
        AOAInterfaceInfo->State.InterfaceNumber = AOAInterface->InterfaceNumber;\r
@@ -260,7 +234,7 @@ uint8_t AOA_Host_SendData(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo,
 \r
        uint8_t ErrorCode;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipe.Address);\r
 \r
        Pipe_Unfreeze();\r
        ErrorCode = Pipe_Write_Stream_LE(Buffer, Length, NULL);\r
@@ -277,7 +251,7 @@ uint8_t AOA_Host_SendString(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo,
 \r
        uint8_t ErrorCode;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipe.Address);\r
 \r
        Pipe_Unfreeze();\r
        ErrorCode = Pipe_Write_Stream_LE(String, strlen(String), NULL);\r
@@ -294,7 +268,7 @@ uint8_t AOA_Host_SendByte(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo,
 \r
        uint8_t ErrorCode;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipe.Address);\r
        Pipe_Unfreeze();\r
 \r
        if (!(Pipe_IsReadWriteAllowed()))\r
@@ -316,7 +290,7 @@ uint16_t AOA_Host_BytesReceived(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo
        if ((USB_HostState != HOST_STATE_Configured) || !(AOAInterfaceInfo->State.IsActive))\r
          return 0;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataINPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataINPipe.Address);\r
        Pipe_Unfreeze();\r
 \r
        if (Pipe_IsINReceived())\r
@@ -348,7 +322,7 @@ int16_t AOA_Host_ReceiveByte(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo)
 \r
        int16_t ReceivedByte = -1;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataINPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataINPipe.Address);\r
        Pipe_Unfreeze();\r
 \r
        if (Pipe_IsINReceived())\r
@@ -372,7 +346,7 @@ uint8_t AOA_Host_Flush(USB_ClassInfo_AOA_Host_t* const AOAInterfaceInfo)
 \r
        uint8_t ErrorCode;\r
 \r
-       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipeNumber);\r
+       Pipe_SelectPipe(AOAInterfaceInfo->Config.DataOUTPipe.Address);\r
        Pipe_Unfreeze();\r
 \r
        if (!(Pipe_BytesInPipe()))\r
index 0ec44e7..678feda 100644 (file)
                        {\r
                                struct\r
                                {\r
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the AOA interface's IN data pipe. */\r
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the AOA interface's IN data pipe should use double banking. */\r
-\r
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the AOA interface's OUT data pipe. */\r
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the AOA interface's OUT data pipe should use double banking. */\r
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */\r
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */\r
                                        \r
                                        char*    PropertyStrings[AOA_STRING_TOTAL_STRINGS]; /**< Android Accessory property strings, sent to identify the accessory when the\r
                                                                                             *   Android device is switched into Open Accessory mode. */\r
                                                        *   Configured state.\r
                                                        */\r
                                        uint8_t  InterfaceNumber; /**< Interface index of the AOA interface within the attached device. */\r
-\r
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the AOA interface's IN data pipe. */\r
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the AOA interface's OUT data pipe. */\r
                                } State; /**< State data for the USB class interface within the device. All elements in this section\r
                                                  *   <b>may</b> be set to initial values, but may also be ignored to default to sane values when\r
                                                  *   the interface is enumerated.\r
index e5591ec..12783a6 100644 (file)
@@ -51,8 +51,8 @@ uint8_t Audio_Host_ConfigurePipes(USB_ClassInfo_Audio_Host_t* const AudioInterfa
        if (DESCRIPTOR_TYPE(ConfigDescriptorData) != DTYPE_Configuration)
          return AUDIO_ENUMERROR_InvalidConfigDescriptor;
 
-       while ((AudioInterfaceInfo->Config.DataINPipeNumber  && !(DataINEndpoint)) ||
-              (AudioInterfaceInfo->Config.DataOUTPipeNumber && !(DataOUTEndpoint)))
+       while ((AudioInterfaceInfo->Config.DataINPipe.Address  && !(DataINEndpoint)) ||
+              (AudioInterfaceInfo->Config.DataOUTPipe.Address && !(DataOUTEndpoint)))
        {
                if (!(AudioControlInterface) ||
                    USB_GetNextDescriptorComp(&ConfigDescriptorSize, &ConfigDescriptorData,
@@ -93,45 +93,21 @@ uint8_t Audio_Host_ConfigurePipes(USB_ClassInfo_Audio_Host_t* const AudioInterfa
                  DataOUTEndpoint = EndpointData;
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               bool     DoubleBanked;
-
-               if (PipeNum == AudioInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_ISOCHRONOUS;
-                       DoubleBanked    = true;
-
-                       AudioInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == AudioInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_ISOCHRONOUS;
-                       DoubleBanked    = true;
-
-                       AudioInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return AUDIO_ENUMERROR_PipeConfigurationFailed;
-               }
-       }
+       AudioInterfaceInfo->Config.DataINPipe.Size   = le16_to_cpu(DataINEndpoint->EndpointSize);
+       AudioInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       AudioInterfaceInfo->Config.DataINPipe.Type   = EP_TYPE_ISOCHRONOUS;
+       AudioInterfaceInfo->Config.DataINPipe.Banks  = 2;
+       
+       AudioInterfaceInfo->Config.DataOUTPipe.Size  = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       AudioInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       AudioInterfaceInfo->Config.DataOUTPipe.Type  = EP_TYPE_ISOCHRONOUS;
+       AudioInterfaceInfo->Config.DataOUTPipe.Banks = 2;
+       
+       if (!(Pipe_ConfigurePipeTable(&AudioInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&AudioInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
 
        AudioInterfaceInfo->State.ControlInterfaceNumber    = AudioControlInterface->InterfaceNumber;
        AudioInterfaceInfo->State.StreamingInterfaceNumber  = AudioStreamingInterface->InterfaceNumber;
index a6e425d..2d39aa9 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the Audio interface's IN data pipe. If this interface should not
-                                                                   *   bind to an IN endpoint, this may be set to 0 to disable audio input streaming for
-                                                                   *   this driver instance.
-                                                                   */
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the Audio interface's OUT data pipe. If this interface should not
-                                                                   *   bind to an OUT endpoint, this may be set to 0 to disable audio output streaming for
-                                                                   *   this driver instance.
-                                                                   */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
                                        uint8_t StreamingInterfaceNumber; /**< Interface index of the Audio Streaming interface within the attached device. */
 
                                        uint8_t EnabledStreamingAltIndex; /**< Alternative setting index of the Audio Streaming interface when the stream is enabled. */
-
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the Audio interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the Audio interface's OUT data pipe. */
                                } State; /**< State data for the USB class interface within the device. All elements in this section
                                                  *   <b>may</b> be set to initial values, but may also be ignored to default to sane values when
                                                  *   the interface is enumerated.
 
                                bool SampleReceived = false;
 
-                               Pipe_SelectPipe(AudioInterfaceInfo->Config.DataINPipeNumber);
+                               Pipe_SelectPipe(AudioInterfaceInfo->Config.DataINPipe.Address);
                                Pipe_Unfreeze();
                                SampleReceived = Pipe_IsINReceived();
                                Pipe_Freeze();
                                if ((USB_HostState != HOST_STATE_Configured) || !(AudioInterfaceInfo->State.IsActive))
                                  return false;
 
-                               Pipe_SelectPipe(AudioInterfaceInfo->Config.DataOUTPipeNumber);
+                               Pipe_SelectPipe(AudioInterfaceInfo->Config.DataOUTPipe.Address);
                                return Pipe_IsOUTReady();
                        }
 
index 63df6b0..8c79e9c 100644 (file)
@@ -99,62 +99,26 @@ uint8_t CDC_Host_ConfigurePipes(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo
                }
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               uint8_t  InterruptPeriod;
-               bool     DoubleBanked;
-
-               if (PipeNum == CDCInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = CDCInterfaceInfo->Config.DataINPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       CDCInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == CDCInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = CDCInterfaceInfo->Config.DataOUTPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       CDCInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else if (PipeNum == CDCInterfaceInfo->Config.NotificationPipeNumber)
-               {
-                       Size            = le16_to_cpu(NotificationEndpoint->EndpointSize);
-                       EndpointAddress = NotificationEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_INTERRUPT;
-                       DoubleBanked    = CDCInterfaceInfo->Config.NotificationPipeDoubleBank;
-                       InterruptPeriod = NotificationEndpoint->PollingIntervalMS;
-
-                       CDCInterfaceInfo->State.NotificationPipeSize = NotificationEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return CDC_ENUMERROR_PipeConfigurationFailed;
-               }
-
-               if (InterruptPeriod)
-                 Pipe_SetInterruptPeriod(InterruptPeriod);
-       }
+       CDCInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       CDCInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       CDCInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       CDCInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       CDCInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       CDCInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       CDCInterfaceInfo->Config.NotificationPipe.Size = le16_to_cpu(NotificationEndpoint->EndpointSize);
+       CDCInterfaceInfo->Config.NotificationPipe.EndpointAddress = NotificationEndpoint->EndpointAddress;
+       CDCInterfaceInfo->Config.NotificationPipe.Type = EP_TYPE_INTERRUPT;
+
+       if (!(Pipe_ConfigurePipeTable(&CDCInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&CDCInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
+
+       if (!(Pipe_ConfigurePipeTable(&CDCInterfaceInfo->Config.NotificationPipe, 1)))
+         return false;
 
        CDCInterfaceInfo->State.ControlInterfaceNumber = CDCControlInterface->InterfaceNumber;
        CDCInterfaceInfo->State.ControlLineStates.HostToDevice = (CDC_CONTROL_LINE_OUT_RTS | CDC_CONTROL_LINE_OUT_DTR);
@@ -231,7 +195,7 @@ void CDC_Host_USBTask(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo)
        if ((USB_HostState != HOST_STATE_Configured) || !(CDCInterfaceInfo->State.IsActive))
          return;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.NotificationPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.NotificationPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_IsINReceived())
@@ -321,7 +285,7 @@ uint8_t CDC_Host_SendData(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo,
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipe.Address);
 
        Pipe_Unfreeze();
        ErrorCode = Pipe_Write_Stream_LE(Buffer, Length, NULL);
@@ -338,7 +302,7 @@ uint8_t CDC_Host_SendString(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo,
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipe.Address);
 
        Pipe_Unfreeze();
        ErrorCode = Pipe_Write_Stream_LE(String, strlen(String), NULL);
@@ -355,7 +319,7 @@ uint8_t CDC_Host_SendByte(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo,
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if (!(Pipe_IsReadWriteAllowed()))
@@ -377,7 +341,7 @@ uint16_t CDC_Host_BytesReceived(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo
        if ((USB_HostState != HOST_STATE_Configured) || !(CDCInterfaceInfo->State.IsActive))
          return 0;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_IsINReceived())
@@ -409,7 +373,7 @@ int16_t CDC_Host_ReceiveByte(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo)
 
        int16_t ReceivedByte = -1;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_IsINReceived())
@@ -433,7 +397,7 @@ uint8_t CDC_Host_Flush(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo)
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(CDCInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if (!(Pipe_BytesInPipe()))
index 5a8df24..4d79ed9 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the CDC interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the CDC interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the CDC interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the CDC interface's OUT data pipe should use double banking. */
-
-                                       uint8_t  NotificationPipeNumber; /**< Pipe number of the CDC interface's IN notification endpoint, if used. */
-                                       bool     NotificationPipeDoubleBank; /**< Indicates if the CDC interface's notification pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
+                                       USB_Pipe_Table_t NotificationPipe; /**< Notification IN Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
                                                        */
                                        uint8_t  ControlInterfaceNumber; /**< Interface index of the CDC-ACM control interface within the attached device. */
 
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the CDC interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the CDC interface's OUT data pipe. */
-                                       uint16_t NotificationPipeSize;  /**< Size in bytes of the CDC interface's IN notification pipe, if used. */
-
                                        struct
                                        {
                                                uint16_t HostToDevice; /**< Control line states from the host to device, as a set of \c CDC_CONTROL_LINE_OUT_*
index f51bdf7..dad6a5a 100644 (file)
@@ -94,55 +94,19 @@ uint8_t HID_Host_ConfigurePipes(USB_ClassInfo_HID_Host_t* const HIDInterfaceInfo
                  DataOUTEndpoint = EndpointData;
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               uint8_t  InterruptPeriod;
-               bool     DoubleBanked;
-
-               if (PipeNum == HIDInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_INTERRUPT;
-                       DoubleBanked    = HIDInterfaceInfo->Config.DataINPipeDoubleBank;
-                       InterruptPeriod = DataINEndpoint->PollingIntervalMS;
-
-                       HIDInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == HIDInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       if (DataOUTEndpoint == NULL)
-                         continue;
-
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_INTERRUPT;
-                       DoubleBanked    = HIDInterfaceInfo->Config.DataOUTPipeDoubleBank;
-                       InterruptPeriod = DataOUTEndpoint->PollingIntervalMS;
-
-                       HIDInterfaceInfo->State.DataOUTPipeSize   = DataOUTEndpoint->EndpointSize;
-                       HIDInterfaceInfo->State.DeviceUsesOUTPipe = true;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return HID_ENUMERROR_PipeConfigurationFailed;
-               }
-
-               if (InterruptPeriod)
-                 Pipe_SetInterruptPeriod(InterruptPeriod);
-       }
+       HIDInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       HIDInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       HIDInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_INTERRUPT;
+       
+       HIDInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       HIDInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       HIDInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_INTERRUPT;
+       
+       if (!(Pipe_ConfigurePipeTable(&HIDInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&HIDInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
 
        HIDInterfaceInfo->State.InterfaceNumber      = HIDInterface->InterfaceNumber;
        HIDInterfaceInfo->State.HIDReportSize        = LE16_TO_CPU(HIDDescriptor->HIDReportLength);
@@ -227,7 +191,7 @@ uint8_t HID_Host_ReceiveReport(USB_ClassInfo_HID_Host_t* const HIDInterfaceInfo,
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(HIDInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(HIDInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        uint16_t ReportSize;
@@ -277,7 +241,7 @@ uint8_t HID_Host_SendReportByID(USB_ClassInfo_HID_Host_t* const HIDInterfaceInfo
        {
                uint8_t ErrorCode;
 
-               Pipe_SelectPipe(HIDInterfaceInfo->Config.DataOUTPipeNumber);
+               Pipe_SelectPipe(HIDInterfaceInfo->Config.DataOUTPipe.Address);
                Pipe_Unfreeze();
 
                if (ReportID)
@@ -320,7 +284,7 @@ bool HID_Host_IsReportReceived(USB_ClassInfo_HID_Host_t* const HIDInterfaceInfo)
 
        bool ReportReceived;
 
-       Pipe_SelectPipe(HIDInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(HIDInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        ReportReceived = Pipe_IsINReceived();
index 7bdaad1..882cc31 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the HID interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the HID interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the HID interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the HID interface's OUT data pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
 
                                        uint8_t  HIDInterfaceProtocol; /**< HID interface protocol value to match against if a specific
                                                                        *   boot subclass protocol is required, a protocol value from the
                                                        */
                                        uint8_t InterfaceNumber; /**< Interface index of the HID interface within the attached device. */
 
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the HID interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the HID interface's OUT data pipe. */
-
                                        bool SupportsBootProtocol; /**< Indicates if the current interface instance supports the HID Boot
                                                                    *   Protocol when enabled via \ref HID_Host_SetBootProtocol().
                                                                    */
index 5aadbcc..1300577 100644 (file)
@@ -78,45 +78,19 @@ uint8_t MIDI_Host_ConfigurePipes(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceI
                  DataOUTEndpoint = EndpointData;
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               bool     DoubleBanked;
-
-               if (PipeNum == MIDIInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = MIDIInterfaceInfo->Config.DataINPipeDoubleBank;
-
-                       MIDIInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == MIDIInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = MIDIInterfaceInfo->Config.DataOUTPipeDoubleBank;
-
-                       MIDIInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return MIDI_ENUMERROR_PipeConfigurationFailed;
-               }
-       }
+       MIDIInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       MIDIInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       MIDIInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       MIDIInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       MIDIInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       MIDIInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       if (!(Pipe_ConfigurePipeTable(&MIDIInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&MIDIInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false; 
 
        MIDIInterfaceInfo->State.InterfaceNumber = MIDIInterface->InterfaceNumber;
        MIDIInterfaceInfo->State.IsActive = true;
@@ -181,7 +155,7 @@ uint8_t MIDI_Host_Flush(USB_ClassInfo_MIDI_Host_t* const MIDIInterfaceInfo)
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataOUTPipe.Address);
 
        if (Pipe_BytesInPipe())
        {
@@ -202,7 +176,7 @@ uint8_t MIDI_Host_SendEventPacket(USB_ClassInfo_MIDI_Host_t* const MIDIInterface
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataOUTPipe.Address);
 
        if ((ErrorCode = Pipe_Write_Stream_LE(Event, sizeof(MIDI_EventPacket_t), NULL)) != PIPE_RWSTREAM_NoError)
          return ErrorCode;
@@ -218,18 +192,27 @@ bool MIDI_Host_ReceiveEventPacket(USB_ClassInfo_MIDI_Host_t* const MIDIInterface
 {
        if ((USB_HostState != HOST_STATE_Configured) || !(MIDIInterfaceInfo->State.IsActive))
          return HOST_SENDCONTROL_DeviceDisconnected;
+         
+       bool DataReady = false;
 
-       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataINPipeNumber);
-
-       if (!(Pipe_IsReadWriteAllowed()))
-         return false;
+       Pipe_SelectPipe(MIDIInterfaceInfo->Config.DataINPipe.Address);
+       Pipe_Unfreeze();
 
-       Pipe_Read_Stream_LE(Event, sizeof(MIDI_EventPacket_t), NULL);
-
-       if (!(Pipe_IsReadWriteAllowed()))
-         Pipe_ClearIN();
+       if (Pipe_IsINReceived())
+       {
+               if (Pipe_BytesInPipe())
+               {
+                       Pipe_Read_Stream_LE(Event, sizeof(MIDI_EventPacket_t), NULL);
+                       DataReady = true;
+               }
 
-       return true;
+               if (!(Pipe_BytesInPipe()))
+                 Pipe_ClearIN();
+       }
+       
+       Pipe_Freeze();
+       
+       return DataReady;
 }
 
 #endif
index e934dda..b9e8611 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the MIDI interface's streaming IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the MIDI interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the MIDI interface's streaming OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the MIDI interface's OUT data pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
@@ -94,9 +91,6 @@
                                                            *   Configured state.
                                                            */
                                        uint8_t  InterfaceNumber; /**< Interface index of the MIDI interface within the attached device. */
-
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the MIDI Streaming Data interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the MIDI Streaming Data interface's OUT data pipe. */
                                } State; /**< State data for the USB class interface within the device. All elements in this section
                                                  *   <b>may</b> be set to initial values, but may also be ignored to default to sane values when
                                                  *   the interface is enumerated.
index 24b4edc..f145881 100644 (file)
@@ -78,45 +78,19 @@ uint8_t MS_Host_ConfigurePipes(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo,
                  DataOUTEndpoint = EndpointData;
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               bool     DoubleBanked;
-
-               if (PipeNum == MSInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = MSInterfaceInfo->Config.DataINPipeDoubleBank;
-
-                       MSInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == MSInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = MSInterfaceInfo->Config.DataOUTPipeDoubleBank;
-
-                       MSInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return MS_ENUMERROR_PipeConfigurationFailed;
-               }
-       }
+       MSInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       MSInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       MSInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       MSInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       MSInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       MSInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       if (!(Pipe_ConfigurePipeTable(&MSInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&MSInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
 
        MSInterfaceInfo->State.InterfaceNumber = MassStorageInterface->InterfaceNumber;
        MSInterfaceInfo->State.IsActive = true;
@@ -178,7 +152,7 @@ static uint8_t MS_Host_SendCommand(USB_ClassInfo_MS_Host_t* const MSInterfaceInf
        SCSICommandBlock->Signature = CPU_TO_LE32(MS_CBW_SIGNATURE);
        SCSICommandBlock->Tag       = cpu_to_le32(MSInterfaceInfo->State.TransactionTag);
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Write_Stream_LE(SCSICommandBlock, sizeof(MS_CommandBlockWrapper_t),
@@ -212,7 +186,7 @@ static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInte
        uint16_t TimeoutMSRem        = MS_COMMAND_DATA_TIMEOUT_MS;
        uint16_t PreviousFrameNumber = USB_Host_GetFrameNumber();
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        while (!(Pipe_IsINReceived()))
@@ -228,7 +202,7 @@ static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInte
                }
 
                Pipe_Freeze();
-               Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipeNumber);
+               Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipe.Address);
                Pipe_Unfreeze();
 
                if (Pipe_IsStalled())
@@ -238,7 +212,7 @@ static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInte
                }
 
                Pipe_Freeze();
-               Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+               Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
                Pipe_Unfreeze();
 
                if (Pipe_IsStalled())
@@ -251,10 +225,10 @@ static uint8_t MS_Host_WaitForDataReceived(USB_ClassInfo_MS_Host_t* const MSInte
                  return PIPE_RWSTREAM_DeviceDisconnected;
        };
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Freeze();
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Freeze();
 
        return PIPE_RWSTREAM_NoError;
@@ -275,7 +249,7 @@ static uint8_t MS_Host_SendReceiveData(USB_ClassInfo_MS_Host_t* const MSInterfac
                        return ErrorCode;
                }
 
-               Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+               Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
                Pipe_Unfreeze();
 
                if ((ErrorCode = Pipe_Read_Stream_LE(BufferPtr, BytesRem, NULL)) != PIPE_RWSTREAM_NoError)
@@ -285,7 +259,7 @@ static uint8_t MS_Host_SendReceiveData(USB_ClassInfo_MS_Host_t* const MSInterfac
        }
        else
        {
-               Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipeNumber);
+               Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipe.Address);
                Pipe_Unfreeze();
 
                if ((ErrorCode = Pipe_Write_Stream_LE(BufferPtr, BytesRem, NULL)) != PIPE_RWSTREAM_NoError)
@@ -313,7 +287,7 @@ static uint8_t MS_Host_GetReturnedStatus(USB_ClassInfo_MS_Host_t* const MSInterf
        if ((ErrorCode = MS_Host_WaitForDataReceived(MSInterfaceInfo)) != PIPE_RWSTREAM_NoError)
          return ErrorCode;
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Read_Stream_LE(SCSICommandStatus, sizeof(MS_CommandStatusWrapper_t),
@@ -349,12 +323,12 @@ uint8_t MS_Host_ResetMSInterface(USB_ClassInfo_MS_Host_t* const MSInterfaceInfo)
        if ((ErrorCode = USB_Host_SendControlRequest(NULL)) != HOST_SENDCONTROL_Successful)
          return ErrorCode;
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataINPipe.Address);
 
        if ((ErrorCode = USB_Host_ClearEndpointStall(Pipe_GetBoundEndpointAddress())) != HOST_SENDCONTROL_Successful)
          return ErrorCode;
 
-       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(MSInterfaceInfo->Config.DataOUTPipe.Address);
 
        if ((ErrorCode = USB_Host_ClearEndpointStall(Pipe_GetBoundEndpointAddress())) != HOST_SENDCONTROL_Successful)
          return ErrorCode;
index 25d7e1e..a8763dd 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the Mass Storage interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the Mass Storage interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the Mass Storage interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the Mass Storage interface's OUT data pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
@@ -99,9 +96,6 @@
                                                            */
                                        uint8_t  InterfaceNumber; /**< Interface index of the Mass Storage interface within the attached device. */
 
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the Mass Storage interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the Mass Storage interface's OUT data pipe. */
-
                                        uint32_t TransactionTag; /**< Current transaction tag for data synchronizing of packets. */
                                } State; /**< State data for the USB class interface within the device. All elements in this section
                                                  *   <b>may</b> be set to initial values, but may also be ignored to default to sane values when
index 379ccb0..dd33b11 100644 (file)
@@ -78,45 +78,19 @@ uint8_t PRNT_Host_ConfigurePipes(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceI
                  DataOUTEndpoint = EndpointData;
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               bool     DoubleBanked;
-
-               if (PipeNum == PRNTInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = PRNTInterfaceInfo->Config.DataINPipeDoubleBank;
-
-                       PRNTInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == PRNTInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = PRNTInterfaceInfo->Config.DataOUTPipeDoubleBank;
-
-                       PRNTInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return PRNT_ENUMERROR_PipeConfigurationFailed;
-               }
-       }
+       PRNTInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       PRNTInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       PRNTInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       PRNTInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       PRNTInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       PRNTInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       if (!(Pipe_ConfigurePipeTable(&PRNTInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&PRNTInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false; 
 
        PRNTInterfaceInfo->State.InterfaceNumber  = PrinterInterface->InterfaceNumber;
        PRNTInterfaceInfo->State.AlternateSetting = PrinterInterface->AlternateSetting;
@@ -229,7 +203,7 @@ uint8_t PRNT_Host_Flush(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo)
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if (!(Pipe_BytesInPipe()))
@@ -260,7 +234,7 @@ uint8_t PRNT_Host_SendByte(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo,
 
        uint8_t ErrorCode;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if (!(Pipe_IsReadWriteAllowed()))
@@ -285,7 +259,7 @@ uint8_t PRNT_Host_SendString(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo,
        if ((USB_HostState != HOST_STATE_Configured) || !(PRNTInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Write_Stream_LE(String, strlen(String), NULL)) != PIPE_RWSTREAM_NoError)
@@ -309,7 +283,7 @@ uint8_t PRNT_Host_SendData(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo,
        if ((USB_HostState != HOST_STATE_Configured) || !(PRNTInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Write_Stream_LE(Buffer, Length, NULL)) != PIPE_RWSTREAM_NoError)
@@ -329,7 +303,7 @@ uint16_t PRNT_Host_BytesReceived(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceI
        if ((USB_HostState != HOST_STATE_Configured) || !(PRNTInterfaceInfo->State.IsActive))
          return 0;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_IsINReceived())
@@ -361,7 +335,7 @@ int16_t PRNT_Host_ReceiveByte(USB_ClassInfo_PRNT_Host_t* const PRNTInterfaceInfo
 
        int16_t ReceivedByte = -1;
 
-       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(PRNTInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_IsINReceived())
index c8c997f..2587827 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the Printer interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the Printer interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the Printer interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the Printer interface's OUT data pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
@@ -95,9 +92,6 @@
                                                        */
                                        uint8_t InterfaceNumber; /**< Interface index of the Printer interface within the attached device. */
                                        uint8_t AlternateSetting; /**< Alternate setting within the Printer Interface in the attached device. */
-
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the Printer interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the Printer interface's OUT data pipe. */
                                } State; /**< State data for the USB class interface within the device. All elements in this section
                                                  *   <b>may</b> be set to initial values, but may also be ignored to default to sane values when
                                                  *   the interface is enumerated.
index a03011d..e457b5d 100644 (file)
@@ -101,62 +101,26 @@ uint8_t RNDIS_Host_ConfigurePipes(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfa
                }
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               uint8_t  InterruptPeriod;
-               bool     DoubleBanked;
-
-               if (PipeNum == RNDISInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataINEndpoint->EndpointSize);
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = RNDISInterfaceInfo->Config.DataINPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       RNDISInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == RNDISInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = le16_to_cpu(DataOUTEndpoint->EndpointSize);
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = RNDISInterfaceInfo->Config.DataOUTPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       RNDISInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else if (PipeNum == RNDISInterfaceInfo->Config.NotificationPipeNumber)
-               {
-                       Size            = le16_to_cpu(NotificationEndpoint->EndpointSize);
-                       EndpointAddress = NotificationEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_INTERRUPT;
-                       DoubleBanked    = RNDISInterfaceInfo->Config.NotificationPipeDoubleBank;
-                       InterruptPeriod = NotificationEndpoint->PollingIntervalMS;
-
-                       RNDISInterfaceInfo->State.NotificationPipeSize = NotificationEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return CDC_ENUMERROR_PipeConfigurationFailed;
-               }
+       RNDISInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       RNDISInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       RNDISInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       RNDISInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       RNDISInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       RNDISInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       RNDISInterfaceInfo->Config.NotificationPipe.Size = le16_to_cpu(NotificationEndpoint->EndpointSize);
+       RNDISInterfaceInfo->Config.NotificationPipe.EndpointAddress = NotificationEndpoint->EndpointAddress;
+       RNDISInterfaceInfo->Config.NotificationPipe.Type = EP_TYPE_INTERRUPT;
+
+       if (!(Pipe_ConfigurePipeTable(&RNDISInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&RNDISInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
 
-               if (InterruptPeriod)
-                 Pipe_SetInterruptPeriod(InterruptPeriod);
-       }
+       if (!(Pipe_ConfigurePipeTable(&RNDISInterfaceInfo->Config.NotificationPipe, 1)))
+         return false;
 
        RNDISInterfaceInfo->State.ControlInterfaceNumber = RNDISControlInterface->InterfaceNumber;
        RNDISInterfaceInfo->State.IsActive = true;
@@ -419,7 +383,7 @@ bool RNDIS_Host_IsPacketReceived(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfac
        if ((USB_HostState != HOST_STATE_Configured) || !(RNDISInterfaceInfo->State.IsActive))
          return false;
 
-       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataINPipe.Address);
 
        Pipe_Unfreeze();
        PacketWaiting = Pipe_IsINReceived();
@@ -437,7 +401,7 @@ uint8_t RNDIS_Host_ReadPacket(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceIn
        if ((USB_HostState != HOST_STATE_Configured) || !(RNDISInterfaceInfo->State.IsActive))
          return PIPE_READYWAIT_DeviceDisconnected;
 
-       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        if (!(Pipe_IsReadWriteAllowed()))
@@ -491,7 +455,7 @@ uint8_t RNDIS_Host_SendPacket(USB_ClassInfo_RNDIS_Host_t* const RNDISInterfaceIn
        DeviceMessage.DataOffset    = CPU_TO_LE32(sizeof(RNDIS_Packet_Message_t) - sizeof(RNDIS_Message_Header_t));
        DeviceMessage.DataLength    = cpu_to_le32(PacketLength);
 
-       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(RNDISInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Write_Stream_LE(&DeviceMessage, sizeof(RNDIS_Packet_Message_t),
index 085bde2..57087ed 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the RNDIS interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the RNDIS interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the RNDIS interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the RNDIS interface's OUT data pipe should use double banking. */
-
-                                       uint8_t  NotificationPipeNumber; /**< Pipe number of the RNDIS interface's IN notification endpoint, if used. */
-                                       bool     NotificationPipeDoubleBank; /**< Indicates if the RNDIS interface's notification pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
+                                       USB_Pipe_Table_t NotificationPipe; /**< Notification IN Pipe configuration table. */
 
                                        uint32_t HostMaxPacketSize; /**< Maximum size of a packet which can be buffered by the host. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                                        */
                                        uint8_t ControlInterfaceNumber; /**< Interface index of the RNDIS control interface within the attached device. */
 
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the RNDIS interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the RNDIS interface's OUT data pipe. */
-                                       uint16_t NotificationPipeSize;  /**< Size in bytes of the RNDIS interface's IN notification pipe, if used. */
-
                                        uint32_t DeviceMaxPacketSize; /**< Maximum size of a packet which can be buffered by the attached RNDIS device. */
 
                                        uint32_t RequestID; /**< Request ID counter to give a unique ID for each command/response pair. */
index 2b5514a..5c18d75 100644 (file)
@@ -87,63 +87,27 @@ uint8_t SI_Host_ConfigurePipes(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo,
                }
        }
 
-       for (uint8_t PipeNum = 1; PipeNum < PIPE_TOTAL_PIPES; PipeNum++)
-       {
-               uint16_t Size;
-               uint8_t  Type;
-               uint8_t  Token;
-               uint8_t  EndpointAddress;
-               uint8_t  InterruptPeriod;
-               bool     DoubleBanked;
-
-               if (PipeNum == SIInterfaceInfo->Config.DataINPipeNumber)
-               {
-                       Size            = DataINEndpoint->EndpointSize;
-                       EndpointAddress = DataINEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = SIInterfaceInfo->Config.DataINPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       SIInterfaceInfo->State.DataINPipeSize = DataINEndpoint->EndpointSize;
-               }
-               else if (PipeNum == SIInterfaceInfo->Config.DataOUTPipeNumber)
-               {
-                       Size            = DataOUTEndpoint->EndpointSize;
-                       EndpointAddress = DataOUTEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_OUT;
-                       Type            = EP_TYPE_BULK;
-                       DoubleBanked    = SIInterfaceInfo->Config.DataOUTPipeDoubleBank;
-                       InterruptPeriod = 0;
-
-                       SIInterfaceInfo->State.DataOUTPipeSize = DataOUTEndpoint->EndpointSize;
-               }
-               else if (PipeNum == SIInterfaceInfo->Config.EventsPipeNumber)
-               {
-                       Size            = EventsEndpoint->EndpointSize;
-                       EndpointAddress = EventsEndpoint->EndpointAddress;
-                       Token           = PIPE_TOKEN_IN;
-                       Type            = EP_TYPE_INTERRUPT;
-                       DoubleBanked    = SIInterfaceInfo->Config.EventsPipeDoubleBank;
-                       InterruptPeriod = EventsEndpoint->PollingIntervalMS;
-
-                       SIInterfaceInfo->State.EventsPipeSize = EventsEndpoint->EndpointSize;
-               }
-               else
-               {
-                       continue;
-               }
-
-               if (!(Pipe_ConfigurePipe(PipeNum, Type, Token, EndpointAddress, Size,
-                                        DoubleBanked ? PIPE_BANK_DOUBLE : PIPE_BANK_SINGLE)))
-               {
-                       return SI_ENUMERROR_PipeConfigurationFailed;
-               }
-
-               if (InterruptPeriod)
-                 Pipe_SetInterruptPeriod(InterruptPeriod);
-       }
+       SIInterfaceInfo->Config.DataINPipe.Size  = le16_to_cpu(DataINEndpoint->EndpointSize);
+       SIInterfaceInfo->Config.DataINPipe.EndpointAddress = DataINEndpoint->EndpointAddress;
+       SIInterfaceInfo->Config.DataINPipe.Type  = EP_TYPE_BULK;
+       
+       SIInterfaceInfo->Config.DataOUTPipe.Size = le16_to_cpu(DataOUTEndpoint->EndpointSize);
+       SIInterfaceInfo->Config.DataOUTPipe.EndpointAddress = DataOUTEndpoint->EndpointAddress;
+       SIInterfaceInfo->Config.DataOUTPipe.Type = EP_TYPE_BULK;
+       
+       SIInterfaceInfo->Config.EventsPipe.Size = le16_to_cpu(EventsEndpoint->EndpointSize);
+       SIInterfaceInfo->Config.EventsPipe.EndpointAddress = EventsEndpoint->EndpointAddress;
+       SIInterfaceInfo->Config.EventsPipe.Type = EP_TYPE_INTERRUPT;
+
+       if (!(Pipe_ConfigurePipeTable(&SIInterfaceInfo->Config.DataINPipe, 1)))
+         return false;
+       
+       if (!(Pipe_ConfigurePipeTable(&SIInterfaceInfo->Config.DataOUTPipe, 1)))
+         return false;
 
+       if (!(Pipe_ConfigurePipeTable(&SIInterfaceInfo->Config.EventsPipe, 1)))
+         return false;
+       
        SIInterfaceInfo->State.InterfaceNumber = StillImageInterface->InterfaceNumber;
        SIInterfaceInfo->State.IsActive = true;
 
@@ -204,7 +168,7 @@ uint8_t SI_Host_SendBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo,
        if (SIInterfaceInfo->State.IsSessionOpen)
          PIMAHeader->TransactionID = cpu_to_le32(SIInterfaceInfo->State.TransactionID++);
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        if ((ErrorCode = Pipe_Write_Stream_LE(PIMAHeader, PIMA_COMMAND_SIZE(0), NULL)) != PIPE_RWSTREAM_NoError)
@@ -233,7 +197,7 @@ uint8_t SI_Host_ReceiveBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInf
        if ((USB_HostState != HOST_STATE_Configured) || !(SIInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        while (!(Pipe_IsINReceived()))
@@ -249,7 +213,7 @@ uint8_t SI_Host_ReceiveBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInf
                }
 
                Pipe_Freeze();
-               Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipeNumber);
+               Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipe.Address);
                Pipe_Unfreeze();
 
                if (Pipe_IsStalled())
@@ -259,7 +223,7 @@ uint8_t SI_Host_ReceiveBlockHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInf
                }
 
                Pipe_Freeze();
-               Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipeNumber);
+               Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipe.Address);
                Pipe_Unfreeze();
 
                if (Pipe_IsStalled())
@@ -298,7 +262,7 @@ uint8_t SI_Host_SendData(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo,
        if ((USB_HostState != HOST_STATE_Configured) || !(SIInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.DataOUTPipe.Address);
        Pipe_Unfreeze();
 
        ErrorCode = Pipe_Write_Stream_LE(Buffer, Bytes, NULL);
@@ -318,7 +282,7 @@ uint8_t SI_Host_ReadData(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo,
        if ((USB_HostState != HOST_STATE_Configured) || !(SIInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.DataINPipe.Address);
        Pipe_Unfreeze();
 
        ErrorCode = Pipe_Read_Stream_LE(Buffer, Bytes, NULL);
@@ -335,7 +299,7 @@ bool SI_Host_IsEventReceived(USB_ClassInfo_SI_Host_t* const SIInterfaceInfo)
        if ((USB_HostState != HOST_STATE_Configured) || !(SIInterfaceInfo->State.IsActive))
          return false;
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.EventsPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.EventsPipe.Address);
        Pipe_Unfreeze();
 
        if (Pipe_BytesInPipe())
@@ -354,7 +318,7 @@ uint8_t SI_Host_ReceiveEventHeader(USB_ClassInfo_SI_Host_t* const SIInterfaceInf
        if ((USB_HostState != HOST_STATE_Configured) || !(SIInterfaceInfo->State.IsActive))
          return PIPE_RWSTREAM_DeviceDisconnected;
 
-       Pipe_SelectPipe(SIInterfaceInfo->Config.EventsPipeNumber);
+       Pipe_SelectPipe(SIInterfaceInfo->Config.EventsPipe.Address);
        Pipe_Unfreeze();
 
        ErrorCode = Pipe_Read_Stream_LE(PIMAHeader, sizeof(PIMA_Container_t), NULL);
index 4cda70d..be616b4 100644 (file)
                        {
                                struct
                                {
-                                       uint8_t  DataINPipeNumber; /**< Pipe number of the Still Image interface's IN data pipe. */
-                                       bool     DataINPipeDoubleBank; /**< Indicates if the Still Image interface's IN data pipe should use double banking. */
-
-                                       uint8_t  DataOUTPipeNumber; /**< Pipe number of the Still Image interface's OUT data pipe. */
-                                       bool     DataOUTPipeDoubleBank; /**< Indicates if the Still Image interface's OUT data pipe should use double banking. */
-
-                                       uint8_t  EventsPipeNumber; /**< Pipe number of the Still Image interface's IN events endpoint, if used. */
-                                       bool     EventsPipeDoubleBank; /**< Indicates if the Still Image interface's events data pipe should use double banking. */
+                                       USB_Pipe_Table_t DataINPipe; /**< Data IN Pipe configuration table. */
+                                       USB_Pipe_Table_t DataOUTPipe; /**< Data OUT Pipe configuration table. */
+                                       USB_Pipe_Table_t EventsPipe; /**< Event notification IN Pipe configuration table. */
                                } Config; /**< Config data for the USB class interface within the device. All elements in this section
                                           *   <b>must</b> be set or the interface will fail to enumerate and operate correctly.
                                           */
                                                            */
                                        uint8_t  InterfaceNumber; /**< Interface index of the Still Image interface within the attached device. */
 
-                                       uint16_t DataINPipeSize; /**< Size in bytes of the Still Image interface's IN data pipe. */
-                                       uint16_t DataOUTPipeSize;  /**< Size in bytes of the Still Image interface's OUT data pipe. */
-                                       uint16_t EventsPipeSize;  /**< Size in bytes of the Still Image interface's IN events pipe. */
-
                                        bool IsSessionOpen; /**< Indicates if a PIMA session is currently open with the attached device. */
                                        uint32_t TransactionID; /**< Transaction ID for the next transaction to send to the device. */
                                } State; /**< State data for the USB class interface within the device. All elements in this section
index bcf904d..4440b76 100644 (file)
 uint8_t USB_Device_ControlEndpointSize = ENDPOINT_CONTROLEP_DEFAULT_SIZE;
 #endif
 
+bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                     const uint8_t Entries)
+{
+       for (uint8_t i = 0; i < Entries; i++)
+       {
+               if (!(Table[i].Address))
+                 continue;
+       
+               if (!(Endpoint_ConfigureEndpoint(Table[i].Address, Table[i].Type, Table[i].Size, Table[i].Banks)))
+                 return false;
+       }
+       
+       return true;
+}
+
 bool Endpoint_ConfigureEndpoint_Prv(const uint8_t Number,
                                     const uint8_t UECFG0XData,
                                     const uint8_t UECFG1XData)
index 10f69a8..37ff220 100644 (file)
 
        /* Private Interface - For use in library only: */
        #if !defined(__DOXYGEN__)
-               /* Macros: */
-                       #define _ENDPOINT_GET_MAXSIZE(EPIndex)         _ENDPOINT_GET_MAXSIZE2(ENDPOINT_DETAILS_EP ## EPIndex)
-                       #define _ENDPOINT_GET_MAXSIZE2(EPDetails)      _ENDPOINT_GET_MAXSIZE3(EPDetails)
-                       #define _ENDPOINT_GET_MAXSIZE3(MaxSize, Banks) (MaxSize)
-
-                       #define _ENDPOINT_GET_BANKS(EPIndex)           _ENDPOINT_GET_BANKS2(ENDPOINT_DETAILS_EP ## EPIndex)
-                       #define _ENDPOINT_GET_BANKS2(EPDetails)        _ENDPOINT_GET_BANKS3(EPDetails)
-                       #define _ENDPOINT_GET_BANKS3(MaxSize, Banks)   (Banks)
-
-                       #if defined(USB_SERIES_4_AVR) || defined(USB_SERIES_6_AVR) || defined(USB_SERIES_7_AVR)
-                               #define ENDPOINT_DETAILS_MAXEP             7
-
-                               #define ENDPOINT_DETAILS_EP0               64,  1
-                               #define ENDPOINT_DETAILS_EP1               256, 2
-                               #define ENDPOINT_DETAILS_EP2               64,  2
-                               #define ENDPOINT_DETAILS_EP3               64,  2
-                               #define ENDPOINT_DETAILS_EP4               64,  2
-                               #define ENDPOINT_DETAILS_EP5               64,  2
-                               #define ENDPOINT_DETAILS_EP6               64,  2
-                       #else
-                               #define ENDPOINT_DETAILS_MAXEP             5
-
-                               #define ENDPOINT_DETAILS_EP0               64,  1
-                               #define ENDPOINT_DETAILS_EP1               64,  1
-                               #define ENDPOINT_DETAILS_EP2               64,  1
-                               #define ENDPOINT_DETAILS_EP3               64,  2
-                               #define ENDPOINT_DETAILS_EP4               64,  2
-                       #endif
-
                /* Inline Functions: */
                        static inline uint8_t Endpoint_BytesToEPSizeMask(const uint16_t Bytes) ATTR_WARN_UNUSED_RESULT ATTR_CONST
                                                                                               ATTR_ALWAYS_INLINE;
 
        /* Public Interface - May be used in end-application: */
                /* Macros: */
-                       /** \name Endpoint Bank Mode Masks */
-                       //@{
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have one single bank, which requires less USB FIFO memory but results
-                        *  in slower transfers as only one USB device (the AVR or the host) can access the endpoint's
-                        *  bank at the one time.
-                        */
-                       #define ENDPOINT_BANK_SINGLE                    (0 << EPBK0)
-
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have two banks, which requires more USB FIFO memory but results
-                        *  in faster transfers as one USB device (the AVR or the host) can access one bank while the other
-                        *  accesses the second bank.
-                        */
-                       #define ENDPOINT_BANK_DOUBLE                    (1 << EPBK0)
-                       //@}
-
                        #if (!defined(FIXED_CONTROL_ENDPOINT_SIZE) || defined(__DOXYGEN__))
                                /** Default size of the default control endpoint's bank, until altered by the control endpoint bank size
                                 *  value in the device descriptor. Not available if the \c FIXED_CONTROL_ENDPOINT_SIZE token is defined.
                                #define ENDPOINT_CONTROLEP_DEFAULT_SIZE     8
                        #endif
 
-                       /** Retrieves the maximum bank size in bytes of a given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_MAX_SIZE(EPIndex)              _ENDPOINT_GET_MAXSIZE(EPIndex)
-
-                       /** Retrieves the total number of banks supported by the given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_BANKS_SUPPORTED(EPIndex)       _ENDPOINT_GET_BANKS(EPIndex)
-
                        #if !defined(CONTROL_ONLY_DEVICE) || defined(__DOXYGEN__)
-                               /** Total number of endpoints (including the default control endpoint at address 0) which may
-                                *  be used in the device. Different USB AVR models support different amounts of endpoints,
-                                *  this value reflects the maximum number of endpoints for the currently selected AVR model.
-                                */
-                               #define ENDPOINT_TOTAL_ENDPOINTS            ENDPOINT_DETAILS_MAXEP
+                               #if defined(USB_SERIES_4_AVR) || defined(USB_SERIES_6_AVR) || defined(USB_SERIES_7_AVR)
+                                       #define ENDPOINT_TOTAL_ENDPOINTS        7
+                               #else
+                                       /** Total number of endpoints (including the default control endpoint at address 0) which may
+                                        *  be used in the device. Different USB AVR models support different amounts of endpoints,
+                                        *  this value reflects the maximum number of endpoints for the currently selected AVR model.
+                                        */
+                                       #define ENDPOINT_TOTAL_ENDPOINTS        5
+                               #endif
                        #else
                                #define ENDPOINT_TOTAL_ENDPOINTS            1
                        #endif
                        };
 
                /* Inline Functions: */
-                       /** Configures the specified endpoint number with the given endpoint type, direction, bank size
-                        *  and banking mode. Once configured, the endpoint may be read from or written to, depending
-                        *  on its direction.
+                       /** Configures the specified endpoint address with the given endpoint type, bank size and number of hardware
+                        *  banks. Once configured, the endpoint may be read from or written to, depending on its direction.
                         *
-                        *  \param[in] Number     Endpoint number to configure. This must be more than 0 and less than
-                        *                        \ref ENDPOINT_TOTAL_ENDPOINTS.
+                        *  \param[in] Address    Endpoint address to configure.
                         *
                         *  \param[in] Type       Type of endpoint to configure, a \c EP_TYPE_* mask. Not all endpoint types
                         *                        are available on Low Speed USB devices - refer to the USB 2.0 specification.
                         *
-                        *  \param[in] Direction  Endpoint data direction, either \ref ENDPOINT_DIR_OUT or \ref ENDPOINT_DIR_IN.
-                        *                        All endpoints (except Control type) are unidirectional - data may only be read
-                        *                        from or written to the endpoint bank based on its direction, not both.
-                        *
                         *  \param[in] Size       Size of the endpoint's bank, where packets are stored before they are transmitted
                         *                        to the USB host, or after they have been received from the USB host (depending on
                         *                        the endpoint's data direction). The bank size must indicate the maximum packet size
                         *                        that the endpoint can handle.
                         *
-                        *  \param[in] Banks      Number of banks to use for the endpoint being configured, an \c ENDPOINT_BANK_* mask.
-                        *                        More banks uses more USB DPRAM, but offers better performance. Isochronous type
-                        *                        endpoints <b>must</b> have at least two banks.
+                        *  \param[in] Banks      Number of banks to use for the endpoint being configured.
                         *
                         *  \attention When the \c ORDERED_EP_CONFIG compile time option is used, Endpoints <b>must</b> be configured in
                         *             ascending order, or bank corruption will occur.
                         *
                         *  \return Boolean \c true if the configuration succeeded, \c false otherwise.
                         */
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks) ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks)
                        {
-                               return Endpoint_ConfigureEndpoint_Prv(Number, ((Type << EPTYPE0) | (Direction ? (1 << EPDIR) : 0)),
-                                                                     ((1 << ALLOC) | Banks | Endpoint_BytesToEPSizeMask(Size)));
+                               return Endpoint_ConfigureEndpoint_Prv((Address & ENDPOINT_EPNUM_MASK),
+                                                                     ((Type << EPTYPE0) | ((Address & ENDPOINT_DIR_IN) ? (1 << EPDIR) : 0)),
+                                                                     ((1 << ALLOC) | ((Banks > 1) ? (1 << EPBK0) : 0) | Endpoint_BytesToEPSizeMask(Size)));
                        }
 
                        /** Indicates the number of bytes currently stored in the current endpoint's selected bank.
                                #endif
                        }
 
+                       /** Determines the currently selected endpoint's direction.
+                        *
+                        *  \return The currently selected endpoint's direction, as a \c ENDPOINT_DIR_* mask.
+                        */
+                       static inline uint8_t Endpoint_GetEndpointDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline uint8_t Endpoint_GetEndpointDirection(void)
+                       {
+                               return (UECFG0X & (1 << EPDIR)) ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT;
+                       }
+
                        /** Get the endpoint address of the currently selected endpoint. This is typically used to save
-                        *  the currently selected endpoint number so that it can be restored after another endpoint has
-                        *  been manipulated.
+                        *  the currently selected endpoint so that it can be restored after another endpoint has been
+                        *  manipulated.
                         *
                         *  \return Index of the currently selected endpoint.
                         */
                        static inline uint8_t Endpoint_GetCurrentEndpoint(void)
                        {
                                #if !defined(CONTROL_ONLY_DEVICE)
-                                       return (UENUM & ENDPOINT_EPNUM_MASK);
+                                       return ((UENUM & ENDPOINT_EPNUM_MASK) | Endpoint_GetEndpointDirection());
                                #else
                                        return ENDPOINT_CONTROLEP;
                                #endif
                        }
 
-                       /** Selects the given endpoint number. If the address from the device descriptors is used, the
-                        *  value should be masked with the \ref ENDPOINT_EPNUM_MASK constant to extract only the endpoint
-                        *  number (and discarding the endpoint direction bit).
+                       /** Selects the given endpoint address.
                         *
-                        *  Any endpoint operations which do not require the endpoint number to be indicated will operate on
+                        *  Any endpoint operations which do not require the endpoint address to be indicated will operate on
                         *  the currently selected endpoint.
                         *
-                        *  \param[in] EndpointNumber Endpoint number to select.
+                        *  \param[in] Address Endpoint address to select.
                         */
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address)
                        {
                                #if !defined(CONTROL_ONLY_DEVICE)
-                                       UENUM = EndpointNumber;
+                                       UENUM = (Address & ENDPOINT_EPNUM_MASK);
                                #endif
                        }
 
                        /** Resets the endpoint bank FIFO. This clears all the endpoint banks and resets the USB controller's
                         *  data In and Out pointers to the bank's contents.
                         *
-                        *  \param[in] EndpointNumber Endpoint number whose FIFO buffers are to be reset.
+                        *  \param[in] Address  Endpoint address whose FIFO buffers are to be reset.
                         */
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address)
                        {
-                               UERST = (1 << EndpointNumber);
+                               UERST = (1 << (Address & ENDPOINT_EPNUM_MASK));
                                UERST = 0;
                        }
 
                        /** Determines if the specified endpoint number has interrupted (valid only for INTERRUPT type
                         *  endpoints).
                         *
-                        *  \param[in] EndpointNumber  Index of the endpoint whose interrupt flag should be tested.
+                        *  \param[in] Address  Address of the endpoint whose interrupt flag should be tested.
                         *
                         *  \return Boolean \c true if the specified endpoint has interrupted, \c false otherwise.
                         */
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber)
+                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t Address) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t Address)
                        {
-                               return ((Endpoint_GetEndpointInterrupts() & (1 << EndpointNumber)) ? true : false);
+                               return ((Endpoint_GetEndpointInterrupts() & (1 << (Address & ENDPOINT_EPNUM_MASK))) ? true : false);
                        }
 
                        /** Determines if the selected IN endpoint is ready for a new packet to be sent to the host.
                                UECONX |= (1 << RSTDT);
                        }
 
-                       /** Determines the currently selected endpoint's direction.
-                        *
-                        *  \return The currently selected endpoint's direction, as a \c ENDPOINT_DIR_* mask.
-                        */
-                       static inline uint8_t Endpoint_GetEndpointDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline uint8_t Endpoint_GetEndpointDirection(void)
-                       {
-                               return (UECFG0X & (1 << EPDIR)) ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT;
-                       }
-
                        /** Sets the direction of the currently selected endpoint.
                         *
                         *  \param[in] DirectionMask  New endpoint direction, as a \c ENDPOINT_DIR_* mask.
                        #endif
 
                /* Function Prototypes: */
+                       /** Configures a table of endpoint descriptions, in sequence. This function can be used to configure multiple
+                        *  endpoints at the same time.
+                        *
+                        *  \note Endpoints with a zero address will be ignored, thus this function cannot be used to configure the
+                        *        control endpoint.
+                        *
+                        *  \param[in] Table    Pointer to a table of endpoint descriptions.
+                        *  \param[in] Entries  Number of entries in the endpoint table to configure.
+                        *
+                        *  \return Boolean \c true if all endpoints configured successfully, \c false otherwise.
+                        */
+                       bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                                            const uint8_t Entries);
+
                        /** Completes the status stage of a control transfer on a CONTROL type endpoint automatically,
                         *  with respect to the data direction. This is a convenience function which can be used to
                         *  simplify user control request handling.
index 3f27c76..a1e0fd3 100644 (file)
@@ -114,9 +114,7 @@ void USB_Host_ProcessNextHostState(void)
                        HOST_TASK_NONBLOCK_WAIT(200, HOST_STATE_Powered_ConfigPipe);
                        break;
                case HOST_STATE_Powered_ConfigPipe:
-                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL,
-                                                PIPE_TOKEN_SETUP, ENDPOINT_CONTROLEP,
-                                                PIPE_CONTROLPIPE_DEFAULT_SIZE, PIPE_BANK_SINGLE)))
+                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL, ENDPOINT_CONTROLEP, PIPE_CONTROLPIPE_DEFAULT_SIZE, 1)))
                        {
                                ErrorCode    = HOST_ENUMERROR_PipeConfigError;
                                SubErrorCode = 0;
@@ -151,9 +149,7 @@ void USB_Host_ProcessNextHostState(void)
                        HOST_TASK_NONBLOCK_WAIT(200, HOST_STATE_Default_PostReset);
                        break;
                case HOST_STATE_Default_PostReset:
-                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL,
-                                                PIPE_TOKEN_SETUP, ENDPOINT_CONTROLEP,
-                                                USB_Host_ControlPipeSize, PIPE_BANK_SINGLE)))
+                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL, ENDPOINT_CONTROLEP, USB_Host_ControlPipeSize, 1)))
                        {
                                ErrorCode    = HOST_ENUMERROR_PipeConfigError;
                                SubErrorCode = 0;
index 5e68cc7..1ddffb5 100644 (file)
 
 uint8_t USB_Host_ControlPipeSize = PIPE_CONTROLPIPE_DEFAULT_SIZE;
 
-bool Pipe_ConfigurePipe(const uint8_t Number,
+bool Pipe_ConfigurePipeTable(const USB_Pipe_Table_t* const Table,
+                             const uint8_t Entries)
+{
+       for (uint8_t i = 0; i < Entries; i++)
+       {
+               if (!(Table[i].Address))
+                 continue;
+       
+               if (!(Pipe_ConfigurePipe(Table[i].Address, Table[i].Type, Table[i].EndpointAddress, Table[i].Size, Table[i].Banks)))
+               {
+                       return false;
+               }
+       }
+       
+       return true;
+}
+
+bool Pipe_ConfigurePipe(const uint8_t Address,
                         const uint8_t Type,
-                        const uint8_t Token,
-                        const uint8_t EndpointNumber,
+                        const uint8_t EndpointAddress,
                         const uint16_t Size,
                         const uint8_t Banks)
 {
+       uint8_t Number = (Address & PIPE_EPNUM_MASK);
+       uint8_t Token  = (Address & PIPE_DIR_IN) ? PIPE_TOKEN_IN : PIPE_TOKEN_OUT;
+       
+       if (Type == EP_TYPE_CONTROL)
+         Token = PIPE_TOKEN_SETUP;
+
 #if defined(ORDERED_EP_CONFIG)
        Pipe_SelectPipe(Number);
        Pipe_EnablePipe();
 
        UPCFG1X = 0;
 
-       UPCFG0X = ((Type << EPTYPE0) | Token | ((EndpointNumber & PIPE_EPNUM_MASK) << PEPNUM0));
-       UPCFG1X = ((1 << ALLOC) | Banks | Pipe_BytesToEPSizeMask(Size));
+       UPCFG0X = ((Type << EPTYPE0) | Token | ((EndpointAddress & PIPE_EPNUM_MASK) << PEPNUM0));
+       UPCFG1X = ((1 << ALLOC) | ((Banks > 1) ? (1 << EPBK0) : 0) | Pipe_BytesToEPSizeMask(Size));
 
        Pipe_SetInfiniteINRequests();
 
@@ -71,7 +93,7 @@ bool Pipe_ConfigurePipe(const uint8_t Number,
 
                if (PNum == Number)
                {
-                       UPCFG0XTemp = ((Type << EPTYPE0) | Token | ((EndpointNumber & PIPE_EPNUM_MASK) << PEPNUM0));
+                       UPCFG0XTemp = ((Type << EPTYPE0) | Token | ((EndpointAddress & PIPE_EPNUM_MASK) << PEPNUM0));
                        UPCFG1XTemp = ((1 << ALLOC) | Banks | Pipe_BytesToEPSizeMask(Size));
                        UPCFG2XTemp = 0;
                        UPIENXTemp  = 0;
index 86792bf..1012fa0 100644 (file)
 
                        /** \name Pipe Token Masks */
                        //@{
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a SETUP token (for CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a SETUP token (for CONTROL type pipes),
                         *  which will trigger a control request on the attached device when data is written to the pipe.
                         */
                        #define PIPE_TOKEN_SETUP                (0 << PTOKEN0)
 
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a IN token (for non-CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a IN token (for non-CONTROL type pipes),
                         *  indicating that the pipe data will flow from device to host.
                         */
                        #define PIPE_TOKEN_IN                   (1 << PTOKEN0)
 
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a OUT token (for non-CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a OUT token (for non-CONTROL type pipes),
                         *  indicating that the pipe data will flow from host to device.
                         */
                        #define PIPE_TOKEN_OUT                  (2 << PTOKEN0)
                        //@}
 
-                       /** \name Pipe Bank Mode Masks */
-                       //@{
-                       /** Mask for the bank mode selection for the \ref Pipe_ConfigurePipe() macro. This indicates that the pipe
-                        *  should have one single bank, which requires less USB FIFO memory but results in slower transfers as
-                        *  only one USB device (the AVR or the attached device) can access the pipe's bank at the one time.
-                        */
-                       #define PIPE_BANK_SINGLE                (0 << EPBK0)
-
-                       /** Mask for the bank mode selection for the \ref Pipe_ConfigurePipe() macro. This indicates that the pipe
-                        *  should have two banks, which requires more USB FIFO memory but results in faster transfers as one
-                        *  USB device (the AVR or the attached device) can access one bank while the other accesses the second
-                        *  bank.
-                        */
-                       #define PIPE_BANK_DOUBLE                (1 << EPBK0)
-                       //@}
-
                        /** Default size of the default control pipe's bank, until altered by the Endpoint0Size value
                         *  in the device descriptor of the attached device.
                         */
                                return UPBCX;
                        }
 
+                       /** Determines the currently selected pipe's direction.
+                        *
+                        *  \return The currently selected pipe's direction, as a \c PIPE_DIR_* mask.
+                        */
+                       static inline uint8_t Pipe_GetPipeDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline uint8_t Pipe_GetPipeDirection(void)
+                       {
+                               return (UPCFG0X & (1 << EPDIR)) ? PIPE_DIR_IN : PIPE_DIR_OUT;
+                       }
+                       
                        /** Returns the pipe address of the currently selected pipe. This is typically used to save the
-                        *  currently selected pipe number so that it can be restored after another pipe has been manipulated.
+                        *  currently selected pipe address so that it can be restored after another pipe has been manipulated.
                         *
                         *  \return Index of the currently selected pipe.
                         */
                        static inline uint8_t Pipe_GetCurrentPipe(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
                        static inline uint8_t Pipe_GetCurrentPipe(void)
                        {
-                               return (UPNUM & PIPE_PIPENUM_MASK);
+                               return ((UPNUM & PIPE_PIPENUM_MASK) | Pipe_GetPipeDirection());
                        }
 
-                       /** Selects the given pipe number. Any pipe operations which do not require the pipe number to be
+                       /** Selects the given pipe address. Any pipe operations which do not require the pipe address to be
                         *  indicated will operate on the currently selected pipe.
                         *
-                        *  \param[in] PipeNumber  Index of the pipe to select.
+                        *  \param[in] Address  Address of the pipe to select.
                         */
-                       static inline void Pipe_SelectPipe(const uint8_t PipeNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Pipe_SelectPipe(const uint8_t PipeNumber)
+                       static inline void Pipe_SelectPipe(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Pipe_SelectPipe(const uint8_t Address)
                        {
-                               UPNUM = PipeNumber;
+                               UPNUM = (Address & PIPE_PIPENUM_MASK);
                        }
 
                        /** Resets the desired pipe, including the pipe banks and flags.
                         *
-                        *  \param[in] PipeNumber  Index of the pipe to reset.
+                        *  \param[in] Address  Address of the pipe to reset.
                         */
-                       static inline void Pipe_ResetPipe(const uint8_t PipeNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Pipe_ResetPipe(const uint8_t PipeNumber)
+                       static inline void Pipe_ResetPipe(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Pipe_ResetPipe(const uint8_t Address)
                        {
-                               UPRST = (1 << PipeNumber);
+                               UPRST = (1 << (Address & PIPE_PIPENUM_MASK));
                                UPRST = 0;
                        }
 
                        static inline uint8_t Pipe_GetBoundEndpointAddress(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
                        static inline uint8_t Pipe_GetBoundEndpointAddress(void)
                        {
-                               return (((UPCFG0X >> PEPNUM0) & PIPE_EPNUM_MASK) |
-                                       ((Pipe_GetPipeToken() == PIPE_TOKEN_IN) ? PIPE_EPDIR_MASK : 0));
+                               uint8_t UPCFG0X_Temp = UPCFG0X;
+                               
+                               return (((UPCFG0X_Temp >> PEPNUM0) & PIPE_EPNUM_MASK) | ((UPCFG0X_Temp & PEPNUM1) ? ENDPOINT_DIR_OUT : ENDPOINT_DIR_IN));
                        }
 
                        /** Sets the period between interrupts for an INTERRUPT type pipe to a specified number of milliseconds.
                                return UPINT;
                        }
 
-                       /** Determines if the specified pipe number has interrupted (valid only for INTERRUPT type
+                       /** Determines if the specified pipe address has interrupted (valid only for INTERRUPT type
                         *  pipes).
                         *
-                        *  \param[in] PipeNumber  Index of the pipe whose interrupt flag should be tested.
+                        *  \param[in] Address  Address of the pipe whose interrupt flag should be tested.
                         *
                         *  \return Boolean \c true if the specified pipe has interrupted, \c false otherwise.
                         */
-                       static inline bool Pipe_HasPipeInterrupted(const uint8_t PipeNumber) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline bool Pipe_HasPipeInterrupted(const uint8_t PipeNumber)
+                       static inline bool Pipe_HasPipeInterrupted(const uint8_t Address) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline bool Pipe_HasPipeInterrupted(const uint8_t Address)
                        {
-                               return ((UPINT & (1 << PipeNumber)) ? true : false);
+                               return ((UPINT & (1 << (Address & PIPE_PIPENUM_MASK))) ? true : false);
                        }
 
                        /** Unfreezes the selected pipe, allowing it to communicate with an attached device. */
                        extern uint8_t USB_Host_ControlPipeSize;
 
                /* Function Prototypes: */
-                       /** Configures the specified pipe number with the given pipe type, token, target endpoint number in the
-                        *  attached device, bank size and banking mode.
+                       /** Configures a table of pipe descriptions, in sequence. This function can be used to configure multiple
+                        *  pipes at the same time.
+                        *
+                        *  \note Pipe with a zero address will be ignored, thus this function cannot be used to configure the
+                        *        control pipe.
+                        *
+                        *  \param[in] Table    Pointer to a table of pipe descriptions.
+                        *  \param[in] Entries  Number of entries in the pipe table to configure.
+                        *
+                        *  \return Boolean \c true if all pipes configured successfully, \c false otherwise.
+                        */                     
+                       bool Pipe_ConfigurePipeTable(const USB_Pipe_Table_t* const Table,
+                                                    const uint8_t Entries);
+                                                                                
+                       /** Configures the specified pipe address with the given pipe type, endpoint address within the attached device, bank size
+                        *  and number of hardware banks.
                         *
                         *  A newly configured pipe is frozen by default, and must be unfrozen before use via the \ref Pipe_Unfreeze()
                         *  before being used. Pipes should be kept frozen unless waiting for data from a device while in IN mode, or
                         *  numbers of IN requests without automatic freezing - this can be overridden by a call to
                         *  \ref Pipe_SetFiniteINRequests().
                         *
-                        *  \param[in] Number          Pipe number to configure. This must be more than 0 and less than \ref PIPE_TOTAL_PIPES.
-                        *
-                        *  \param[in] Type            Type of pipe to configure, an \c EP_TYPE_* mask. Not all pipe types are available on Low
-                        *                             Speed USB devices - refer to the USB 2.0 specification.
+                        *  \param[in] Address          Pipe address to configure.
                         *
-                        *  \param[in] Token           Pipe data token, either \ref PIPE_TOKEN_SETUP, \ref PIPE_TOKEN_OUT or \ref PIPE_TOKEN_IN.
-                        *                             All pipes (except Control type) are unidirectional - data may only be read from or
-                        *                             written to the pipe bank based on its direction, not both.
+                        *  \param[in] Type             Type of pipe to configure, an \c EP_TYPE_* mask. Not all pipe types are available on Low
+                        *                              Speed USB devices - refer to the USB 2.0 specification.
                         *
-                        *  \param[in] EndpointNumber  Endpoint index within the attached device that the pipe should interface to.
+                        *  \param[in] EndpointAddress  Endpoint address within the attached device that the pipe should interface to.
                         *
-                        *  \param[in] Size            Size of the pipe's bank, where packets are stored before they are transmitted to
-                        *                             the USB device, or after they have been received from the USB device (depending on
-                        *                             the pipe's data direction). The bank size must indicate the maximum packet size that
-                        *                             the pipe can handle.
+                        *  \param[in] Size             Size of the pipe's bank, where packets are stored before they are transmitted to
+                        *                              the USB device, or after they have been received from the USB device (depending on
+                        *                              the pipe's data direction). The bank size must indicate the maximum packet size that
+                        *                              the pipe can handle.
                         *
-                        *  \param[in] Banks           Number of banks to use for the pipe being configured, a \c PIPE_BANK_* mask. More banks
-                        *                             uses more USB DPRAM, but offers better performance. Isochronous type pipes <b>must</b>
-                        *                             have at least two banks.
+                        *  \param[in] Banks            Number of banks to use for the pipe being configured.
                         *
                         *  \attention When the \c ORDERED_EP_CONFIG compile time option is used, Pipes <b>must</b> be configured in ascending order,
                         *             or bank corruption will occur.
                         *
                         *  \return Boolean \c true if the configuration succeeded, \c false otherwise.
                         */
-                       bool Pipe_ConfigurePipe(const uint8_t Number,
+                       bool Pipe_ConfigurePipe(const uint8_t Address,
                                                const uint8_t Type,
-                                               const uint8_t Token,
-                                               const uint8_t EndpointNumber,
+                                               const uint8_t EndpointAddress,
                                                const uint16_t Size,
                                                const uint8_t Banks);
 
index e31b88d..1f37dfd 100644 (file)
@@ -232,8 +232,7 @@ static void USB_Init_Device(void)
        #endif
 
        Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                                          ENDPOINT_BANK_SINGLE);
+                                                          USB_Device_ControlEndpointSize, 1);
 
        USB_INT_Clear(USB_INT_SUSPI);
        USB_INT_Enable(USB_INT_SUSPI);
index f63cf3e..e26c86f 100644 (file)
@@ -171,8 +171,7 @@ ISR(USB_GEN_vect, ISR_BLOCK)
                USB_INT_Enable(USB_INT_WAKEUPI);
 
                Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                          ENDPOINT_BANK_SINGLE);
+                                          USB_Device_ControlEndpointSize, 1);
 
                #if defined(INTERRUPT_CONTROL_ENDPOINT)
                USB_INT_Enable(USB_INT_RXSTPI);
index 61082cf..f5e1cca 100644 (file)
@@ -289,7 +289,6 @@ static void USB_Device_GetStatus(void)
 
        switch (USB_ControlRequest.bmRequestType)
        {
-               #if !defined(NO_DEVICE_SELF_POWER) || !defined(NO_DEVICE_REMOTE_WAKEUP)
                case (REQDIR_DEVICETOHOST | REQTYPE_STANDARD | REQREC_DEVICE):
                        #if !defined(NO_DEVICE_SELF_POWER)
                        if (USB_Device_CurrentlySelfPowered)
@@ -301,17 +300,16 @@ static void USB_Device_GetStatus(void)
                          CurrentStatus |= FEATURE_REMOTE_WAKEUP_ENABLED;
                        #endif
                        break;
-               #endif
-               #if !defined(CONTROL_ONLY_DEVICE)
                case (REQDIR_DEVICETOHOST | REQTYPE_STANDARD | REQREC_ENDPOINT):
+                       #if !defined(CONTROL_ONLY_DEVICE)
                        Endpoint_SelectEndpoint((uint8_t)USB_ControlRequest.wIndex & ENDPOINT_EPNUM_MASK);
 
                        CurrentStatus = Endpoint_IsStalled();
 
                        Endpoint_SelectEndpoint(ENDPOINT_CONTROLEP);
+                       #endif
 
                        break;
-               #endif
                default:
                        return;
        }
index 1fcc6b6..b349adf 100644 (file)
                #endif
 
        /* Public Interface - May be used in end-application: */
+               /* Type Defines: */
+                       /** Type define for a endpoint table entry, used to configure endpoints in groups via
+                        *  \ref Endpoint_ConfigureEndpointTable().
+                        */
+                       typedef struct
+                       {
+                               uint8_t  Address; /**< Address of the endpoint to configure, or zero if the table entry is to be unused. */
+                               uint16_t Size; /**< Size of the endpoint bank, in bytes. */
+                               uint8_t  Type; /**< Type of the endpoint, a \c EP_TYPE_* mask. */
+                               uint8_t  Banks; /**< Number of hardware banks to use for the endpoint. */
+                       } USB_Endpoint_Table_t;
+       
                /* Macros: */
                        /** Endpoint number mask, for masking against endpoint addresses to retrieve the endpoint's
                         *  numerical address in the device.
index bb56b81..faa803b 100644 (file)
                #endif
 
        /* Public Interface - May be used in end-application: */
+               /* Type Defines: */
+                       /** Type define for a pipe table entry, used to configure pipes in groups via
+                        *  \ref Pipe_ConfigurePipeTable().
+                        */
+                       typedef struct
+                       {
+                               uint8_t  Address; /**< Address of the pipe to configure, or zero if the table entry is to be unused. */
+                               uint16_t Size; /**< Size of the pipe bank, in bytes. */
+                               uint8_t  EndpointAddress; /** Address of the endpoint in the connected device. */
+                               uint8_t  Type; /**< Type of the endpoint, a \c EP_TYPE_* mask. */
+                               uint8_t  Banks; /**< Number of hardware banks to use for the pipe. */
+                       } USB_Pipe_Table_t;
+
                /* Macros: */
                        /** Pipe address for the default control pipe, which always resides in address 0. This is
                         *  defined for convenience to give more readable code when used with the pipe macros.
                         */
                        #define PIPE_EPNUM_MASK                 0x0F
 
-                       /** Endpoint direction mask, for masking against endpoint addresses to retrieve the endpoint's
-                        *  direction for comparing with the \c ENDPOINT_DIR_* masks.
-                        */
-                       #define PIPE_EPDIR_MASK                 0x80
-
        /* Architecture Includes: */
                #if (ARCH == ARCH_AVR8)
                        #include "AVR8/Pipe_AVR8.h"
index cee2d5e..c46129c 100644 (file)
@@ -94,8 +94,8 @@
                         *
                         *  \param[in]  x  Version number to encode as a 16-bit little-endian number, as a floating point number.
                         */
-                       #define VERSION_BCD(x)                    CPU_TO_LE16((((VERSION_TENS(x) << 4) | VERSION_ONES(x)) << 8) | \
-                                                                 ((VERSION_TENTHS(x) << 4) | VERSION_HUNDREDTHS(x)))
+                       #define VERSION_BCD(x)                    CPU_TO_LE16((VERSION_TENS(x) << 12)  | (VERSION_ONES(x) << 8) | \
+                                                                             (VERSION_TENTHS(x) << 4) | (VERSION_HUNDREDTHS(x) << 0) )
 
                        /** String language ID for the English language. Should be used in \ref USB_Descriptor_String_t descriptors
                         *  to indicate that the English language is supported by the device in its string descriptors.
        /* Private Interface - For use in library only: */
        #if !defined(__DOXYGEN__)
                /* Macros: */
-                       #define VERSION_TENS(x)                   (int)((x) / 10)
-                       #define VERSION_ONES(x)                   (int)((x) - (10 * VERSION_TENS(x)))
-                       #define VERSION_TENTHS(x)                 (int)(((x) - (int)(x)) * 10)
-                       #define VERSION_HUNDREDTHS(x)             (int)((((x) - (int)(x)) * 100) - (10 * VERSION_TENTHS(x)))
+                       #define VERSION_TENS(x)                   (int)((int)(x) / 10)
+                       #define VERSION_ONES(x)                   (int)((int)(x) % 10)
+                       #define VERSION_TENTHS(x)                 (int)(((x *  1) - ((int)(x *  1))) * 10)
+                       #define VERSION_HUNDREDTHS(x)             (int)(((x * 10) - ((int)(x * 10))) * 10)
        #endif
 
        /* Disable C linkage for C++ Compilers: */
index fc1b18a..c027585 100644 (file)
@@ -45,6 +45,23 @@ uint8_t USB_Device_ControlEndpointSize = ENDPOINT_CONTROLEP_DEFAULT_SIZE;
 volatile uint32_t USB_Endpoint_SelectedEndpoint = ENDPOINT_CONTROLEP;
 volatile uint8_t* USB_Endpoint_FIFOPos[ENDPOINT_TOTAL_ENDPOINTS];
 
+bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                     const uint8_t Entries)
+{
+       for (uint8_t i = 0; i < Entries; i++)
+       {
+               if (!(Table[i].Address))
+                 continue;
+       
+               if (!(Endpoint_ConfigureEndpoint(Table[i].Address, Table[i].Type, Table[i].Size, Table[i].Banks)))
+               {
+                       return false;
+               }
+       }
+       
+       return true;
+}
+
 bool Endpoint_ConfigureEndpoint_Prv(const uint8_t Number,
                                     const uint32_t UECFG0Data)
 {
index c919eff..84801a1 100644 (file)
        /* Private Interface - For use in library only: */
        #if !defined(__DOXYGEN__)
                /* Macros: */
-                       #define _ENDPOINT_GET_MAXSIZE(EPIndex)            _ENDPOINT_GET_MAXSIZE2(ENDPOINT_DETAILS_EP ## EPIndex)
-                       #define _ENDPOINT_GET_MAXSIZE2(EPDetails)         _ENDPOINT_GET_MAXSIZE3(EPDetails)
-                       #define _ENDPOINT_GET_MAXSIZE3(MaxSize, Banks)    (MaxSize)
-
-                       #define _ENDPOINT_GET_BANKS(EPIndex)              _ENDPOINT_GET_BANKS2(ENDPOINT_DETAILS_EP ## EPIndex)
-                       #define _ENDPOINT_GET_BANKS2(EPDetails)           _ENDPOINT_GET_BANKS3(EPDetails)
-                       #define _ENDPOINT_GET_BANKS3(MaxSize, Banks)      (Banks)
-
-                       #if defined(USB_SERIES_UC3A0_AVR32) || defined(USB_SERIES_UC3A1_AVR32)
-                               #define ENDPOINT_DETAILS_MAXEP                 7
-
-                               #define ENDPOINT_DETAILS_EP0                   64,  1
-                               #define ENDPOINT_DETAILS_EP1                   256, 2
-                               #define ENDPOINT_DETAILS_EP2                   256, 2
-                               #define ENDPOINT_DETAILS_EP3                   64,  2
-                               #define ENDPOINT_DETAILS_EP4                   64,  2
-                               #define ENDPOINT_DETAILS_EP5                   256, 2
-                               #define ENDPOINT_DETAILS_EP6                   256, 2
-                       #elif defined(USB_SERIES_UC3A3_AVR32) || defined(USB_SERIES_UC3A4_AVR32)
-                               #define ENDPOINT_DETAILS_MAXEP                 8
-
-                               #define ENDPOINT_DETAILS_EP0                   64,  1
-                               #define ENDPOINT_DETAILS_EP1                   512, 3
-                               #define ENDPOINT_DETAILS_EP2                   512, 3
-                               #define ENDPOINT_DETAILS_EP3                   512, 3
-                               #define ENDPOINT_DETAILS_EP4                   512, 3
-                               #define ENDPOINT_DETAILS_EP5                   512, 3
-                               #define ENDPOINT_DETAILS_EP6                   512, 3
-                               #define ENDPOINT_DETAILS_EP7                   512, 3
-                       #elif defined(USB_SERIES_UC3B0_AVR32) || defined(USB_SERIES_UC3B1_AVR32)
-                               #define ENDPOINT_DETAILS_MAXEP                 7
-
-                               #define ENDPOINT_DETAILS_EP0                   64,  1
-                               #define ENDPOINT_DETAILS_EP1                   64,  2
-                               #define ENDPOINT_DETAILS_EP2                   64,  2
-                               #define ENDPOINT_DETAILS_EP3                   64,  2
-                               #define ENDPOINT_DETAILS_EP4                   64,  2
-                               #define ENDPOINT_DETAILS_EP5                   256, 2
-                               #define ENDPOINT_DETAILS_EP6                   256, 2
-                       #endif
-
                        #define ENDPOINT_HSB_ADDRESS_SPACE_SIZE            (64 * 1024UL)
 
                /* Inline Functions: */
 
        /* Public Interface - May be used in end-application: */
                /* Macros: */
-                       /** \name Endpoint Bank Mode Masks */
-                       //@{
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have one single bank, which requires less USB FIFO memory but results
-                        *  in slower transfers as only one USB device (the AVR or the host) can access the endpoint's
-                        *  bank at the one time.
-                        */
-                       #define ENDPOINT_BANK_SINGLE                    AVR32_USBB_UECFG0_EPBK_SINGLE
-
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have two banks, which requires more USB FIFO memory but results
-                        *  in faster transfers as one USB device (the AVR or the host) can access one bank while the other
-                        *  accesses the second bank.
-                        */
-                       #define ENDPOINT_BANK_DOUBLE                    AVR32_USBB_UECFG0_EPBK_DOUBLE
-
-                       #if defined(USB_SERIES_UC3A3_AVR32) || defined(USB_SERIES_UC3A4_AVR32) || defined(__DOXYGEN__)
-                               /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                                *  that the endpoint should have three banks, which requires more USB FIFO memory but results
-                                *  in faster transfers as one USB device (the AVR or the host) can access one bank while the other
-                                *  accesses the remaining banks.
-                                *
-                                *  \note Not available on all AVR models.
-                                */
-                               #define ENDPOINT_BANK_TRIPLE                AVR32_USBB_UECFG0_EPBK_TRIPLE
-                       #endif
-                       //@}
-
                        #if (!defined(FIXED_CONTROL_ENDPOINT_SIZE) || defined(__DOXYGEN__))
                                /** Default size of the default control endpoint's bank, until altered by the control endpoint bank size
                                 *  value in the device descriptor. Not available if the \c FIXED_CONTROL_ENDPOINT_SIZE token is defined.
                                #define ENDPOINT_CONTROLEP_DEFAULT_SIZE     8
                        #endif
 
-                       /** Retrieves the maximum bank size in bytes of a given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_MAX_SIZE(EPIndex)              _ENDPOINT_GET_MAXSIZE(EPIndex)
-
-                       /** Retrieves the total number of banks supported by the given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_BANKS_SUPPORTED(EPIndex)       _ENDPOINT_GET_BANKS(EPIndex)
-
                        #if !defined(CONTROL_ONLY_DEVICE) || defined(__DOXYGEN__)
-                               /** Total number of endpoints (including the default control endpoint at address 0) which may
-                                *  be used in the device. Different AVR models support different amounts of endpoints,
-                                *  this value reflects the maximum number of endpoints for the currently selected AVR model.
-                                */
-                               #define ENDPOINT_TOTAL_ENDPOINTS            ENDPOINT_DETAILS_MAXEP
+                               #if defined(USB_SERIES_UC3A3_AVR32) || defined(USB_SERIES_UC3A4_AVR32)
+                                       #define ENDPOINT_TOTAL_ENDPOINTS        8
+                               #else
+                                       /** Total number of endpoints (including the default control endpoint at address 0) which may
+                                        *  be used in the device. Different AVR models support different amounts of endpoints,
+                                        *  this value reflects the maximum number of endpoints for the currently selected AVR model.
+                                        */
+                                       #define ENDPOINT_TOTAL_ENDPOINTS        7
+                               #endif
                        #else
                                #define ENDPOINT_TOTAL_ENDPOINTS            1
                        #endif
                        };
 
                /* Inline Functions: */
-                       /** Configures the specified endpoint number with the given endpoint type, direction, bank size
+                       /** Configures the specified endpoint address with the given endpoint type, direction, bank size
                         *  and banking mode. Once configured, the endpoint may be read from or written to, depending
                         *  on its direction.
                         *
-                        *  \param[in] Number     Endpoint number to configure. This must be more than 0 and less than
-                        *                        \ref ENDPOINT_TOTAL_ENDPOINTS.
+                        *  \param[in] Address    Endpoint address to configure.
                         *
                         *  \param[in] Type       Type of endpoint to configure, a \c EP_TYPE_* mask. Not all endpoint types
                         *                        are available on Low Speed USB devices - refer to the USB 2.0 specification.
                         *
-                        *  \param[in] Direction  Endpoint data direction, either \ref ENDPOINT_DIR_OUT or \ref ENDPOINT_DIR_IN.
-                        *                        All endpoints (except Control type) are unidirectional - data may only be read
-                        *                        from or written to the endpoint bank based on its direction, not both.
-                        *
                         *  \param[in] Size       Size of the endpoint's bank, where packets are stored before they are transmitted
                         *                        to the USB host, or after they have been received from the USB host (depending on
                         *                        the endpoint's data direction). The bank size must indicate the maximum packet size
                         *                        that the endpoint can handle.
                         *
-                        *  \param[in] Banks      Number of banks to use for the endpoint being configured, an \c ENDPOINT_BANK_* mask.
-                        *                        More banks uses more USB DPRAM, but offers better performance. Isochronous type
-                        *                        endpoints <b>must</b> have at least two banks.
+                        *  \param[in] Banks      Number of hardware banks to use for the endpoint being configured.
                         *
                         *  \attention When the \c ORDERED_EP_CONFIG compile time option is used, Endpoints <b>must</b> be configured in
                         *             ascending order, or bank corruption will occur.
                         *
                         *  \return Boolean \c true if the configuration succeeded, \c false otherwise.
                         */
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks) ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks)
                        {
-                               return Endpoint_ConfigureEndpoint_Prv(Number, (AVR32_USBB_ALLOC_MASK |
-                                                                              ((uint32_t)Type      << AVR32_USBB_EPTYPE_OFFSET) |
-                                                                              ((uint32_t)(Direction ? AVR32_USBB_UECFG0_EPDIR_MASK : 0) |
-                                                                              ((uint32_t)Banks     << AVR32_USBB_EPBK_OFFSET)   |
-                                                                              Endpoint_BytesToEPSizeMask(Size))));
+                               return Endpoint_ConfigureEndpoint_Prv((Address & ENDPOINT_EPNUM_MASK),
+                                                                     (AVR32_USBB_ALLOC_MASK |
+                                                                      ((uint32_t)Type      << AVR32_USBB_EPTYPE_OFFSET) |
+                                                                      ((uint32_t)(Address & ENDPOINT_DIR_IN) ? AVR32_USBB_UECFG0_EPDIR_MASK : 0) |
+                                                                      ((uint32_t)Banks     << AVR32_USBB_EPBK_OFFSET)   |
+                                                                      Endpoint_BytesToEPSizeMask(Size)));
                        }
 
                        /** Indicates the number of bytes currently stored in the current endpoint's selected bank.
                                return (&AVR32_USBB.UESTA0)[USB_Endpoint_SelectedEndpoint].byct;
                        }
 
+                       /** Determines the currently selected endpoint's direction.
+                        *
+                        *  \return The currently selected endpoint's direction, as a \c ENDPOINT_DIR_* mask.
+                        */
+                       static inline uint32_t Endpoint_GetEndpointDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline uint32_t Endpoint_GetEndpointDirection(void)
+                       {
+                               return ((&AVR32_USBB.UECFG0)[USB_Endpoint_SelectedEndpoint].epdir ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT);
+                       }
+
                        /** Get the endpoint address of the currently selected endpoint. This is typically used to save
-                        *  the currently selected endpoint number so that it can be restored after another endpoint has
-                        *  been manipulated.
+                        *  the currently selected endpoint so that it can be restored after another endpoint has been
+                        *  manipulated.
                         *
                         *  \return Index of the currently selected endpoint.
                         */
                        static inline uint8_t Endpoint_GetCurrentEndpoint(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
                        static inline uint8_t Endpoint_GetCurrentEndpoint(void)
                        {
-                               return USB_Endpoint_SelectedEndpoint;
+                               return (USB_Endpoint_SelectedEndpoint | Endpoint_GetEndpointDirection());
                        }
 
-                       /** Selects the given endpoint number. If the address from the device descriptors is used, the
-                        *  value should be masked with the \ref ENDPOINT_EPNUM_MASK constant to extract only the endpoint
-                        *  number (and discarding the endpoint direction bit).
+                       /** Selects the given endpoint address.
                         *
-                        *  Any endpoint operations which do not require the endpoint number to be indicated will operate on
+                        *  Any endpoint operations which do not require the endpoint address to be indicated will operate on
                         *  the currently selected endpoint.
                         *
-                        *  \param[in] EndpointNumber Endpoint number to select.
+                        *  \param[in] Address  Endpoint address to select.
                         */
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address)
                        {
-                               USB_Endpoint_SelectedEndpoint = EndpointNumber;
+                               USB_Endpoint_SelectedEndpoint = (Address & ENDPOINT_EPNUM_MASK);
                        }
 
                        /** Resets the endpoint bank FIFO. This clears all the endpoint banks and resets the USB controller's
                         *  data In and Out pointers to the bank's contents.
                         *
-                        *  \param[in] EndpointNumber Endpoint number whose FIFO buffers are to be reset.
+                        *  \param[in] Address  Endpoint number whose FIFO buffers are to be reset.
                         */
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address)
                        {
+                               uint32_t EndpointNumber = (Address & ENDPOINT_EPNUM_MASK);
+                       
                                AVR32_USBB.uerst |=  (AVR32_USBB_EPRST0_MASK << EndpointNumber);
                                AVR32_USBB.uerst &= ~(AVR32_USBB_EPRST0_MASK << EndpointNumber);
                                USB_Endpoint_FIFOPos[EndpointNumber] = &AVR32_USBB_SLAVE[EndpointNumber * ENDPOINT_HSB_ADDRESS_SPACE_SIZE];
                         *
                         *  \return Mask whose bits indicate which endpoints have interrupted.
                         */
-                       static inline uint8_t Endpoint_GetEndpointInterrupts(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline uint8_t Endpoint_GetEndpointInterrupts(void)
+                       static inline uint32_t Endpoint_GetEndpointInterrupts(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline uint32_t Endpoint_GetEndpointInterrupts(void)
                        {
                                return ((AVR32_USBB.udint & (AVR32_USBB_EP6INT_MASK | AVR32_USBB_EP5INT_MASK |
                                                             AVR32_USBB_EP4INT_MASK | AVR32_USBB_EP3INT_MASK |
                        /** Determines if the specified endpoint number has interrupted (valid only for INTERRUPT type
                         *  endpoints).
                         *
-                        *  \param[in] EndpointNumber  Index of the endpoint whose interrupt flag should be tested.
+                        *  \param[in] Address  Address of the endpoint whose interrupt flag should be tested.
                         *
                         *  \return Boolean \c true if the specified endpoint has interrupted, \c false otherwise.
                         */
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber)
+                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t Address) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t Address)
                        {
-                               return ((Endpoint_GetEndpointInterrupts() & (AVR32_USBB_EP0INT_MASK << EndpointNumber)) ? true : false);
+                               return ((Endpoint_GetEndpointInterrupts() & (AVR32_USBB_EP0INT_MASK << (Address & ENDPOINT_EPNUM_MASK))) ? true : false);
                        }
 
                        /** Determines if the selected IN endpoint is ready for a new packet to be sent to the host.
                                (&AVR32_USBB.UECON0SET)[USB_Endpoint_SelectedEndpoint].rstdts = true;
                        }
 
-                       /** Determines the currently selected endpoint's direction.
-                        *
-                        *  \return The currently selected endpoint's direction, as a \c ENDPOINT_DIR_* mask.
-                        */
-                       static inline uint32_t Endpoint_GetEndpointDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline uint32_t Endpoint_GetEndpointDirection(void)
-                       {
-                               return ((&AVR32_USBB.UECFG0)[USB_Endpoint_SelectedEndpoint].epdir ? ENDPOINT_DIR_IN : ENDPOINT_DIR_OUT);
-                       }
-
                        /** Sets the direction of the currently selected endpoint.
                         *
                         *  \param[in] DirectionMask  New endpoint direction, as a \c ENDPOINT_DIR_* mask.
                        #endif
 
                /* Function Prototypes: */
+                       /** Configures a table of endpoint descriptions, in sequence. This function can be used to configure multiple
+                        *  endpoints at the same time.
+                        *
+                        *  \note Endpoints with a zero address will be ignored, thus this function cannot be used to configure the
+                        *        control endpoint.
+                        *
+                        *  \param[in] Table    Pointer to a table of endpoint descriptions.
+                        *  \param[in] Entries  Number of entries in the endpoint table to configure.
+                        *
+                        *  \return Boolean \c true if all endpoints configured successfully, \c false otherwise.
+                        */
+                       bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                                            const uint8_t Entries);
+
                        /** Completes the status stage of a control transfer on a CONTROL type endpoint automatically,
                         *  with respect to the data direction. This is a convenience function which can be used to
                         *  simplify user control request handling.
index 49d43f9..932381a 100644 (file)
@@ -114,9 +114,7 @@ void USB_Host_ProcessNextHostState(void)
                        HOST_TASK_NONBLOCK_WAIT(200, HOST_STATE_Powered_ConfigPipe);
                        break;
                case HOST_STATE_Powered_ConfigPipe:
-                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL,
-                                                                PIPE_TOKEN_SETUP, ENDPOINT_CONTROLEP,
-                                                                PIPE_CONTROLPIPE_DEFAULT_SIZE, PIPE_BANK_SINGLE)))
+                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL, ENDPOINT_CONTROLEP, PIPE_CONTROLPIPE_DEFAULT_SIZE, 1)))
                        {
                                ErrorCode    = HOST_ENUMERROR_PipeConfigError;
                                SubErrorCode = 0;
@@ -151,9 +149,7 @@ void USB_Host_ProcessNextHostState(void)
                        HOST_TASK_NONBLOCK_WAIT(200, HOST_STATE_Default_PostReset);
                        break;
                case HOST_STATE_Default_PostReset:
-                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL,
-                                                PIPE_TOKEN_SETUP, ENDPOINT_CONTROLEP,
-                                                USB_Host_ControlPipeSize, PIPE_BANK_SINGLE)))
+                       if (!(Pipe_ConfigurePipe(PIPE_CONTROLPIPE, EP_TYPE_CONTROL, ENDPOINT_CONTROLEP, USB_Host_ControlPipeSize, 1)))
                        {
                                ErrorCode    = HOST_ENUMERROR_PipeConfigError;
                                SubErrorCode = 0;
index 4e77a28..787244b 100644 (file)
@@ -43,13 +43,35 @@ uint8_t USB_Host_ControlPipeSize = PIPE_CONTROLPIPE_DEFAULT_SIZE;
 volatile uint32_t USB_Pipe_SelectedPipe = PIPE_CONTROLPIPE;
 volatile uint8_t* USB_Pipe_FIFOPos[PIPE_TOTAL_PIPES];
 
-bool Pipe_ConfigurePipe(const uint8_t Number,
+bool Pipe_ConfigurePipeTable(const USB_Pipe_Table_t* const Table,
+                             const uint8_t Entries)
+{
+       for (uint8_t i = 0; i < Entries; i++)
+       {
+               if (!(Table[i].Address))
+                 continue;
+       
+               if (!(Pipe_ConfigurePipe(Table[i].Address, Table[i].Type, Table[i].EndpointAddress, Table[i].Size, Table[i].Banks)))
+               {
+                       return false;
+               }
+       }
+       
+       return true;
+}
+
+bool Pipe_ConfigurePipe(const uint8_t Address,
                         const uint8_t Type,
-                        const uint8_t Token,
-                        const uint8_t EndpointNumber,
+                        const uint8_t EndpointAddress,
                         const uint16_t Size,
                         const uint8_t Banks)
 {
+       uint8_t Number = (Address & PIPE_EPNUM_MASK);
+       uint8_t Token  = (Address & PIPE_DIR_IN) ? PIPE_TOKEN_IN : PIPE_TOKEN_OUT;
+       
+       if (Type == EP_TYPE_CONTROL)
+         Token = PIPE_TOKEN_SETUP;
+
        USB_Pipe_FIFOPos[Number]     = &AVR32_USBB_SLAVE[Number * 0x10000];
 
 #if defined(ORDERED_EP_CONFIG)
@@ -60,7 +82,7 @@ bool Pipe_ConfigurePipe(const uint8_t Number,
        (&AVR32_USBB.upcfg0)[Number] = (AVR32_USBB_ALLOC_MASK |
                                        ((uint32_t)Type  << AVR32_USBB_PTYPE_OFFSET)  |
                                        ((uint32_t)Token << AVR32_USBB_PTOKEN_OFFSET) |
-                                       ((uint32_t)Banks << AVR32_USBB_PBK_OFFSET)    |
+                                       ((Banks > 1) ? AVR32_USBB_PBK_MASK : 0)       |
                                        Pipe_BytesToEPSizeMask(Size) |
                                        ((EndpointNumber & PIPE_EPNUM_MASK) << AVR32_USBB_PEPNUM_OFFSET));
 
@@ -79,9 +101,9 @@ bool Pipe_ConfigurePipe(const uint8_t Number,
                        UPCFG0Temp = (AVR32_USBB_ALLOC_MASK |
                                      ((uint32_t)Type  << AVR32_USBB_PTYPE_OFFSET)  |
                                      ((uint32_t)Token << AVR32_USBB_PTOKEN_OFFSET) |
-                                     ((uint32_t)Banks << AVR32_USBB_PBK_OFFSET)    |
+                                     ((Banks > 1) ? AVR32_USBB_PBK_MASK : 0)       |
                                      Pipe_BytesToEPSizeMask(Size) |
-                                     ((EndpointNumber & PIPE_EPNUM_MASK) << AVR32_USBB_PEPNUM_OFFSET));
+                                     ((EndpointAddress & PIPE_EPNUM_MASK) << AVR32_USBB_PEPNUM_OFFSET));
                }
                else
                {
index f17fa53..837afe8 100644 (file)
 
                        /** \name Pipe Token Masks */
                        //@{
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a SETUP token (for CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a SETUP token (for CONTROL type pipes),
                         *  which will trigger a control request on the attached device when data is written to the pipe.
                         */
                        #define PIPE_TOKEN_SETUP                AVR32_USBB_UPCFG0_PTOKEN_SETUP
 
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a IN token (for non-CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a IN token (for non-CONTROL type pipes),
                         *  indicating that the pipe data will flow from device to host.
                         */
                        #define PIPE_TOKEN_IN                   AVR32_USBB_UPCFG0_PTOKEN_IN
 
-                       /** Token mask for \ref Pipe_ConfigurePipe(). This sets the pipe as a OUT token (for non-CONTROL type pipes),
+                       /** Token mask for \ref Pipe_SetPipeToken() and \ref Pipe_GetPipeToken(). This sets the pipe as a OUT token (for non-CONTROL type pipes),
                         *  indicating that the pipe data will flow from host to device.
                         */
                        #define PIPE_TOKEN_OUT                  AVR32_USBB_UPCFG0_PTOKEN_OUT
                        //@}
 
-                       /** \name Pipe Bank Mode Masks */
-                       //@{
-                       /** Mask for the bank mode selection for the \ref Pipe_ConfigurePipe() macro. This indicates that the pipe
-                        *  should have one single bank, which requires less USB FIFO memory but results in slower transfers as
-                        *  only one USB device (the AVR or the attached device) can access the pipe's bank at the one time.
-                        */
-                       #define PIPE_BANK_SINGLE                AVR32_USBB_UPCFG0_PBK_SINGLE
-
-                       /** Mask for the bank mode selection for the \ref Pipe_ConfigurePipe() macro. This indicates that the pipe
-                        *  should have two banks, which requires more USB FIFO memory but results in faster transfers as one
-                        *  USB device (the AVR or the attached device) can access one bank while the other accesses the second
-                        *  bank.
-                        */
-                       #define PIPE_BANK_DOUBLE                AVR32_USBB_UPCFG0_PBK_DOUBLE
-
-                       #if defined(USB_SERIES_UC3A3_AVR32) || defined(USB_SERIES_UC3A4_AVR32) || defined(__DOXYGEN__)
-                               /** Mask for the bank mode selection for the \ref Pipe_ConfigurePipe() macro. This indicates that the
-                                *  pipe should have three banks, which requires more USB FIFO memory but results in faster transfers
-                                *  as one USB device (the AVR or the attached device) can access one bank while the other accesses the
-                                *  remaining banks.
-                                *
-                                *  \note Not available on all AVR models.
-                                */
-                               #define PIPE_BANK_TRIPLE           AVR32_USBB_UPCFG0_PBK_TRIPLE
-                       #endif
-                       //@}
-
                        /** Default size of the default control pipe's bank, until altered by the Endpoint0Size value
                         *  in the device descriptor of the attached device.
                         */
                                return (&AVR32_USBB.UPSTA0)[USB_Pipe_SelectedPipe].pbyct;
                        }
 
+                       /** Determines the currently selected pipe's direction.
+                        *
+                        *  \return The currently selected pipe's direction, as a \c PIPE_DIR_* mask.
+                        */
+                       static inline uint8_t Pipe_GetPipeDirection(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline uint8_t Pipe_GetPipeDirection(void)
+                       {
+                               return (((&AVR32_USBB.UPCFG0)[USB_Endpoint_SelectedEndpoint].ptoken == PIPE_TOKEN_OUT) ? PIPE_DIR_OUT : PIPE_DIR_IN);
+                       }
+                       
                        /** Returns the pipe address of the currently selected pipe. This is typically used to save the
                         *  currently selected pipe number so that it can be restored after another pipe has been manipulated.
                         *
                        static inline uint8_t Pipe_GetCurrentPipe(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
                        static inline uint8_t Pipe_GetCurrentPipe(void)
                        {
-                               return USB_Pipe_SelectedPipe;
+                               return (USB_Pipe_SelectedPipe | Pipe_GetPipeDirection());
                        }
 
-                       /** Selects the given pipe number. Any pipe operations which do not require the pipe number to be
+                       /** Selects the given pipe address. Any pipe operations which do not require the pipe address to be
                         *  indicated will operate on the currently selected pipe.
                         *
-                        *  \param[in] PipeNumber  Index of the pipe to select.
+                        *  \param[in] Address  Address of the pipe to select.
                         */
-                       static inline void Pipe_SelectPipe(const uint8_t PipeNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Pipe_SelectPipe(const uint8_t PipeNumber)
+                       static inline void Pipe_SelectPipe(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Pipe_SelectPipe(const uint8_t Address)
                        {
-                               USB_Pipe_SelectedPipe = PipeNumber;
+                               USB_Pipe_SelectedPipe = (Address & PIPE_EPNUM_MASK);
                        }
 
                        /** Resets the desired pipe, including the pipe banks and flags.
                         *
-                        *  \param[in] PipeNumber  Index of the pipe to reset.
+                        *  \param[in] Address  Index of the pipe to reset.
                         */
-                       static inline void Pipe_ResetPipe(const uint8_t PipeNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Pipe_ResetPipe(const uint8_t PipeNumber)
+                       static inline void Pipe_ResetPipe(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Pipe_ResetPipe(const uint8_t Address)
                        {
+                               uint32_t PipeNumber = (Address & PIPE_EPNUM_MASK);
+
                                AVR32_USBB.uprst |=  (AVR32_USBB_PRST0_MASK << PipeNumber);
                                AVR32_USBB.uprst &= ~(AVR32_USBB_PRST0_MASK << PipeNumber);
-                               USB_Pipe_FIFOPos[USB_Pipe_SelectedPipe] = &AVR32_USBB_SLAVE[USB_Pipe_SelectedPipe * PIPE_HSB_ADDRESS_SPACE_SIZE];
+                               USB_Pipe_FIFOPos[PipeNumber] = &AVR32_USBB_SLAVE[PipeNumber * PIPE_HSB_ADDRESS_SPACE_SIZE];
                        }
 
                        /** Enables the currently selected pipe so that data can be sent and received through it to and from
                        static inline uint8_t Pipe_GetBoundEndpointAddress(void)
                        {
                                return ((&AVR32_USBB.UPCFG0)[USB_Pipe_SelectedPipe].pepnum |
-                                       ((Pipe_GetPipeToken() == PIPE_TOKEN_IN) ? PIPE_EPDIR_MASK : 0));
+                                       ((Pipe_GetPipeToken() == PIPE_TOKEN_IN) ? PIPE_DIR_IN : PIPE_DIR_OUT));
                        }
 
                        /** Sets the period between interrupts for an INTERRUPT type pipe to a specified number of milliseconds.
                                                             AVR32_USBB_P0INT_MASK)) >> AVR32_USBB_P0INT_OFFSET);
                        }
 
-                       /** Determines if the specified pipe number has interrupted (valid only for INTERRUPT type
+                       /** Determines if the specified pipe address has interrupted (valid only for INTERRUPT type
                         *  pipes).
                         *
-                        *  \param[in] PipeNumber  Index of the pipe whose interrupt flag should be tested.
+                        *  \param[in] Address  Address of the pipe whose interrupt flag should be tested.
                         *
                         *  \return Boolean \c true if the specified pipe has interrupted, \c false otherwise.
                         */
-                       static inline bool Pipe_HasPipeInterrupted(const uint8_t PipeNumber) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline bool Pipe_HasPipeInterrupted(const uint8_t PipeNumber)
+                       static inline bool Pipe_HasPipeInterrupted(const uint8_t Address) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
+                       static inline bool Pipe_HasPipeInterrupted(const uint8_t Address)
                        {
-                               return ((AVR32_USBB.uhint & (AVR32_USBB_P0INTES_MASK << PipeNumber)) ? true : false);
+                               return ((AVR32_USBB.uhint & (AVR32_USBB_P0INTES_MASK << (Address & PIPE_EPNUM_MASK))) ? true : false);
                        }
 
                        /** Unfreezes the selected pipe, allowing it to communicate with an attached device. */
                        extern uint8_t USB_Host_ControlPipeSize;
 
                /* Function Prototypes: */
-                       /** Configures the specified pipe number with the given pipe type, token, target endpoint number in the
-                        *  attached device, bank size and banking mode.
+                       /** Configures a table of pipe descriptions, in sequence. This function can be used to configure multiple
+                        *  pipes at the same time.
+                        *
+                        *  \note Pipe with a zero address will be ignored, thus this function cannot be used to configure the
+                        *        control pipe.
+                        *
+                        *  \param[in] Table    Pointer to a table of pipe descriptions.
+                        *  \param[in] Entries  Number of entries in the pipe table to configure.
+                        *
+                        *  \return Boolean \c true if all pipes configured successfully, \c false otherwise.
+                        */                     
+                       bool Pipe_ConfigurePipeTable(const USB_Pipe_Table_t* const Table,
+                                                    const uint8_t Entries);
+
+                       /** Configures the specified pipe address with the given pipe type, endpoint address within the attached device, bank size
+                        *  and number of hardware banks.
                         *
                         *  A newly configured pipe is frozen by default, and must be unfrozen before use via the \ref Pipe_Unfreeze()
                         *  before being used. Pipes should be kept frozen unless waiting for data from a device while in IN mode, or
                         *  numbers of IN requests without automatic freezing - this can be overridden by a call to
                         *  \ref Pipe_SetFiniteINRequests().
                         *
-                        *  \param[in] Number          Pipe number to configure. This must be more than 0 and less than \ref PIPE_TOTAL_PIPES.
-                        *
-                        *  \param[in] Type            Type of pipe to configure, an \c EP_TYPE_* mask. Not all pipe types are available on Low
-                        *                             Speed USB devices - refer to the USB 2.0 specification.
+                        *  \param[in] Address          Pipe address to configure.
                         *
-                        *  \param[in] Token           Pipe data token, either \ref PIPE_TOKEN_SETUP, \ref PIPE_TOKEN_OUT or \ref PIPE_TOKEN_IN.
-                        *                             All pipes (except Control type) are unidirectional - data may only be read from or
-                        *                             written to the pipe bank based on its direction, not both.
+                        *  \param[in] Type             Type of pipe to configure, an \c EP_TYPE_* mask. Not all pipe types are available on Low
+                        *                              Speed USB devices - refer to the USB 2.0 specification.
                         *
-                        *  \param[in] EndpointNumber  Endpoint index within the attached device that the pipe should interface to.
+                        *  \param[in] EndpointAddress  Endpoint address within the attached device that the pipe should interface to.
                         *
-                        *  \param[in] Size            Size of the pipe's bank, where packets are stored before they are transmitted to
-                        *                             the USB device, or after they have been received from the USB device (depending on
-                        *                             the pipe's data direction). The bank size must indicate the maximum packet size that
-                        *                             the pipe can handle.
+                        *  \param[in] Size             Size of the pipe's bank, where packets are stored before they are transmitted to
+                        *                              the USB device, or after they have been received from the USB device (depending on
+                        *                              the pipe's data direction). The bank size must indicate the maximum packet size that
+                        *                              the pipe can handle.
                         *
-                        *  \param[in] Banks           Number of banks to use for the pipe being configured, a \c PIPE_BANK_* mask. More banks
-                        *                             uses more USB DPRAM, but offers better performance. Isochronous type pipes <b>must</b>
-                        *                             have at least two banks.
+                        *  \param[in] Banks            Number of banks to use for the pipe being configured.
                         *
                         *  \note When the \c ORDERED_EP_CONFIG compile time option is used, Pipes <b>must</b> be configured in ascending order,
                         *        or bank corruption will occur.
                         *
                         *  \return Boolean \c true if the configuration succeeded, \c false otherwise.
                         */
-                       bool Pipe_ConfigurePipe(const uint8_t Number,
+                       bool Pipe_ConfigurePipe(const uint8_t Address,
                                                const uint8_t Type,
-                                               const uint8_t Token,
-                                               const uint8_t EndpointNumber,
+                                               const uint8_t EndpointAddress,
                                                const uint16_t Size,
                                                const uint8_t Banks);
 
index 95ca7d9..3277244 100644 (file)
@@ -191,8 +191,7 @@ static void USB_Init_Device(void)
        USB_INT_Enable(USB_INT_VBUSTI);
 
        Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                                          ENDPOINT_BANK_SINGLE);
+                                                          USB_Device_ControlEndpointSize, 1);
 
        USB_INT_Clear(USB_INT_SUSPI);
        USB_INT_Enable(USB_INT_SUSPI);
index d411a93..a2a5c4a 100644 (file)
@@ -121,8 +121,7 @@ ISR(USB_GEN_vect)
 
                USB_Device_SetDeviceAddress(0);
                Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                          ENDPOINT_BANK_SINGLE);
+                                          USB_Device_ControlEndpointSize, 1);
 
                #if defined(INTERRUPT_CONTROL_ENDPOINT)
                USB_INT_Enable(USB_INT_RXSTPI);
index a91e18c..44a10e3 100644 (file)
                #define ENDPOINT_DIR_IN                    0x80
                //@}
 
+               /** \name Pipe Direction Masks */
+               //@{
+               /** Pipe direction mask, for masking against pipe addresses to retrieve the pipe's
+                *  direction for comparing with the \c PIPE_DIR_* masks.
+                */
+               #define PIPE_DIR_MASK                      0x80
+
+               /** Endpoint address direction mask for an OUT direction (Host to Device) endpoint. This may be ORed with
+                *  the index of the address within a device to obtain the full endpoint address.
+                */
+               #define PIPE_DIR_OUT                       0x00
+
+               /** Endpoint address direction mask for an IN direction (Device to Host) endpoint. This may be ORed with
+                *  the index of the address within a device to obtain the full endpoint address.
+                */
+               #define PIPE_DIR_IN                        0x80
+               //@}
+
                /** \name Endpoint/Pipe Type Masks */
                //@{
                /** Mask for determining the type of an endpoint from an endpoint descriptor. This should then be compared
index bc2f86d..f62c8c1 100644 (file)
                 */
                #define USB_SERIES_B3_XMEGA
 
+               /** Indicates that the target AVR microcontroller belongs to the XMEGA C3 Series USB controller
+                *  (i.e. ATXMEGA*C3) when defined.
+                */
+               #define USB_SERIES_C3_XMEGA
+
+               /** Indicates that the target AVR microcontroller belongs to the XMEGA C4 Series USB controller
+                *  (i.e. ATXMEGA*C4) when defined.
+                */
+               #define USB_SERIES_C4_XMEGA
+
                /** Indicates that the target microcontroller and compilation settings allow for the
                 *  target to be configured in USB Device mode when defined.
                 */
                        #elif (defined(__AVR_ATxmega128B3__) || defined(__AVR_ATxmega64B3__))
                                #define USB_SERIES_B3_XMEGA
                                #define USB_CAN_BE_DEVICE
+                       #elif (defined(__AVR_ATxmega128C3__) || defined(__AVR_ATxmega64C3__) || \
+                              defined(__AVR_ATxmega192C3__) || defined(__AVR_ATxmega256C3__) || \
+                                  defined(__AVR_ATxmega384C3__))
+                               #define USB_SERIES_C3_XMEGA
+                               #define USB_CAN_BE_DEVICE
+                       #elif (defined(__AVR_ATxmega16C4__) || defined(__AVR_ATxmega32C4__))
+                               #define USB_SERIES_C4_XMEGA
+                               #define USB_CAN_BE_DEVICE
                        #endif
 
                        #if (defined(USB_CAN_BE_DEVICE) && defined(USB_CAN_BE_HOST))
index 85be0f1..4d75cc2 100644 (file)
                         */
                        #define USB_DEVICE_OPT_LOWSPEED        (1 << 0)
 
-                       /** Mask for the Options parameter of the \ref USB_Init() function. This indicates that the
-                        *  USB interface should be initialized in full speed (12Mb/s) mode.
-                        */
-                       #define USB_DEVICE_OPT_FULLSPEED       (0 << 0)
+                       #if (F_USB > 6000000)
+                               /** Mask for the Options parameter of the \ref USB_Init() function. This indicates that the
+                                *  USB interface should be initialized in full speed (12Mb/s) mode.
+                                */
+                               #define USB_DEVICE_OPT_FULLSPEED   (0 << 0)
+                       #endif
                        //@}
 
                        #if (!defined(NO_INTERNAL_SERIAL) || defined(__DOXYGEN__))
                        static inline uint16_t USB_Device_GetFrameNumber(void) ATTR_ALWAYS_INLINE ATTR_WARN_UNUSED_RESULT;
                        static inline uint16_t USB_Device_GetFrameNumber(void)
                        {
-                               return USB_EndpointTable.FrameNum;
+                               return ((USB_EndpointTable_t*)USB.EPPTR)->FrameNum;
                        }
 
                        #if !defined(NO_SOF_EVENTS)
index 98e35e5..1aeb985 100644 (file)
@@ -48,20 +48,36 @@ volatile uint8_t          USB_Endpoint_SelectedEndpoint;
 volatile USB_EP_t*        USB_Endpoint_SelectedHandle;
 volatile Endpoint_FIFO_t* USB_Endpoint_SelectedFIFO;
 
-bool Endpoint_ConfigureEndpoint_PRV(const uint8_t Number,
-                                    const uint8_t Direction,
+bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                     const uint8_t Entries)
+{
+       for (uint8_t i = 0; i < Entries; i++)
+       {
+               if (!(Table[i].Address))
+                 continue;
+       
+               if (!(Endpoint_ConfigureEndpoint(Table[i].Address, Table[i].Type, Table[i].Size, Table[i].Banks)))
+               {
+                       return false;
+               }
+       }
+       
+       return true;
+}
+
+bool Endpoint_ConfigureEndpoint_PRV(const uint8_t Address,
                                     const uint8_t Config,
                                     const uint8_t Size)
 {
-       Endpoint_SelectEndpoint(Number | Direction);
+       Endpoint_SelectEndpoint(Address);
 
        USB_Endpoint_SelectedHandle->CTRL    = 0;
-       USB_Endpoint_SelectedHandle->STATUS  = (Direction == ENDPOINT_DIR_IN) ? USB_EP_BUSNACK0_bm : 0;
+       USB_Endpoint_SelectedHandle->STATUS  = (Address & ENDPOINT_DIR_IN) ? USB_EP_BUSNACK0_bm : 0;
        USB_Endpoint_SelectedHandle->CTRL    = Config;
        USB_Endpoint_SelectedHandle->CNT     = 0;
        USB_Endpoint_SelectedHandle->DATAPTR = (intptr_t)USB_Endpoint_SelectedFIFO->Data;
 
-       USB_Endpoint_SelectedFIFO->Length    = (Direction == ENDPOINT_DIR_IN) ? Size : 0;
+       USB_Endpoint_SelectedFIFO->Length    = (Address & ENDPOINT_DIR_IN) ? Size : 0;
        USB_Endpoint_SelectedFIFO->Position  = 0;
 
        return true;
@@ -71,8 +87,8 @@ void Endpoint_ClearEndpoints(void)
 {
        for (uint8_t EPNum = 0; EPNum < ENDPOINT_TOTAL_ENDPOINTS; EPNum++)
        {
-               USB_EndpointTable.Endpoints[EPNum].IN.CTRL  = 0;
-               USB_EndpointTable.Endpoints[EPNum].OUT.CTRL = 0;
+               ((USB_EndpointTable_t*)USB.EPPTR)->Endpoints[EPNum].IN.CTRL  = 0;
+               ((USB_EndpointTable_t*)USB.EPPTR)->Endpoints[EPNum].OUT.CTRL = 0;
        }
 }
 
index 7828f30..720b5f3 100644 (file)
                        #error Do not include this file directly. Include LUFA/Drivers/USB/USB.h instead.
                #endif
 
-       /* Private Interface - For use in library only: */
-       #if !defined(__DOXYGEN__)
+       /* Public Interface - May be used in end-application: */
                /* Macros: */
-                       #define _ENDPOINT_GET_MAXSIZE(EPIndex)         1023
-                       #define _ENDPOINT_GET_BANKS(EPIndex)           2
-
-                       #define ENDPOINT_DETAILS_MAXEP                 16
+                       #if !defined(CONTROL_ONLY_DEVICE) || defined(__DOXYGEN__)
+                               /** Total number of endpoints (including the default control endpoint at address 0) which may
+                                *  be used in the device. Different USB AVR models support different amounts of endpoints,
+                                *  this value reflects the maximum number of endpoints for the currently selected AVR model.
+                                */
+                               #define ENDPOINT_TOTAL_ENDPOINTS            16
+                       #else
+                               #define ENDPOINT_TOTAL_ENDPOINTS            1
+                       #endif
 
+       /* Private Interface - For use in library only: */
+       #if !defined(__DOXYGEN__)
                /* Type Defines: */
                        typedef struct
                        {
                        } Endpoint_FIFOPair_t;
 
                /* External Variables: */
-                       extern Endpoint_FIFOPair_t       USB_Endpoint_FIFOs[ENDPOINT_DETAILS_MAXEP];
+                       extern Endpoint_FIFOPair_t       USB_Endpoint_FIFOs[ENDPOINT_TOTAL_ENDPOINTS];
                        extern volatile uint8_t          USB_Endpoint_SelectedEndpoint;
                        extern volatile USB_EP_t*        USB_Endpoint_SelectedHandle;
                        extern volatile Endpoint_FIFO_t* USB_Endpoint_SelectedFIFO;
                        }
 
                /* Function Prototypes: */
-                       bool Endpoint_ConfigureEndpoint_PRV(const uint8_t Number,
-                                                           const uint8_t Direction,
+                       bool Endpoint_ConfigureEndpoint_PRV(const uint8_t Address,
                                                            const uint8_t Config,
                                                            const uint8_t Size);
                        void Endpoint_ClearEndpoints(void);
 
        /* Public Interface - May be used in end-application: */
                /* Macros: */
-                       /** \name Endpoint Bank Mode Masks */
-                       //@{
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have one single bank, which requires less USB FIFO memory but results
-                        *  in slower transfers as only one USB device (the AVR or the host) can access the endpoint's
-                        *  bank at the one time.
-                        */
-                       #define ENDPOINT_BANK_SINGLE                    0
-
-                       /** Mask for the bank mode selection for the \ref Endpoint_ConfigureEndpoint() macro. This indicates
-                        *  that the endpoint should have two banks, which requires more USB FIFO memory but results
-                        *  in faster transfers as one USB device (the AVR or the host) can access one bank while the other
-                        *  accesses the second bank.
-                        */
-                       #define ENDPOINT_BANK_DOUBLE                    USB_EP_PINGPONG_bm
-                       //@}
-
                        #if (!defined(FIXED_CONTROL_ENDPOINT_SIZE) || defined(__DOXYGEN__))
                                /** Default size of the default control endpoint's bank, until altered by the control endpoint bank size
                                 *  value in the device descriptor. Not available if the \c FIXED_CONTROL_ENDPOINT_SIZE token is defined.
                                #define ENDPOINT_CONTROLEP_DEFAULT_SIZE     8
                        #endif
 
-                       /** Retrieves the maximum bank size in bytes of a given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_MAX_SIZE(EPIndex)              _ENDPOINT_GET_MAXSIZE(EPIndex)
-
-                       /** Retrieves the total number of banks supported by the given endpoint.
-                        *
-                        *  \attention This macro will only work correctly on endpoint indexes that are compile-time constants
-                        *             defined by the preprocessor.
-                        *
-                        *  \param[in] EPIndex  Endpoint number, a value between 0 and (\ref ENDPOINT_TOTAL_ENDPOINTS - 1)
-                        */
-                       #define ENDPOINT_BANKS_SUPPORTED(EPIndex)       _ENDPOINT_GET_BANKS(EPIndex)
-
-                       #if !defined(CONTROL_ONLY_DEVICE) || defined(__DOXYGEN__)
-                               /** Total number of endpoints (including the default control endpoint at address 0) which may
-                                *  be used in the device. Different USB AVR models support different amounts of endpoints,
-                                *  this value reflects the maximum number of endpoints for the currently selected AVR model.
-                                */
-                               #define ENDPOINT_TOTAL_ENDPOINTS            ENDPOINT_DETAILS_MAXEP
-                       #else
-                               #define ENDPOINT_TOTAL_ENDPOINTS            1
-                       #endif
-
                /* Enums: */
                        /** Enum for the possible error return codes of the \ref Endpoint_WaitUntilReady() function.
                         *
                        };
 
                /* Inline Functions: */
-                       /** Selects the given endpoint number. If the address from the device descriptors is used, the
-                        *  value should be masked with the \ref ENDPOINT_EPNUM_MASK constant to extract only the endpoint
-                        *  number (and discarding the endpoint direction bit).
+                       /** Selects the given endpoint address.
                         *
-                        *  Any endpoint operations which do not require the endpoint number to be indicated will operate on
+                        *  Any endpoint operations which do not require the endpoint address to be indicated will operate on
                         *  the currently selected endpoint.
                         *
-                        *  \param[in] EndpointNumber Endpoint number to select.
+                        *  \param[in] Address  Endpoint address to select.
                         */
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber);
-                       static inline void Endpoint_SelectEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address);
+                       static inline void Endpoint_SelectEndpoint(const uint8_t Address)
                        {
-                               USB_Endpoint_SelectedEndpoint   = EndpointNumber;
+                               uint8_t EndpointNumber = (Address & ENDPOINT_EPNUM_MASK);
+
+                               USB_Endpoint_SelectedEndpoint = Address;
 
-                               if (EndpointNumber & ENDPOINT_DIR_IN)
+                               if (Address & ENDPOINT_DIR_IN)
                                {
-                                       USB_Endpoint_SelectedFIFO   = &USB_Endpoint_FIFOs[EndpointNumber & ENDPOINT_EPNUM_MASK].IN;
-                                       USB_Endpoint_SelectedHandle = &USB_EndpointTable.Endpoints[EndpointNumber & ENDPOINT_EPNUM_MASK].IN;
+                                       USB_Endpoint_SelectedFIFO   = &USB_Endpoint_FIFOs[EndpointNumber].IN;
+                                       USB_Endpoint_SelectedHandle = &((USB_EndpointTable_t*)USB.EPPTR)->Endpoints[EndpointNumber].IN;
                                }
                                else
                                {
-                                       USB_Endpoint_SelectedFIFO   = &USB_Endpoint_FIFOs[EndpointNumber & ENDPOINT_EPNUM_MASK].OUT;
-                                       USB_Endpoint_SelectedHandle = &USB_EndpointTable.Endpoints[EndpointNumber & ENDPOINT_EPNUM_MASK].OUT;
+                                       USB_Endpoint_SelectedFIFO   = &USB_Endpoint_FIFOs[EndpointNumber].OUT;
+                                       USB_Endpoint_SelectedHandle = &((USB_EndpointTable_t*)USB.EPPTR)->Endpoints[EndpointNumber].OUT;
                                }
                        }
 
-                       /** Configures the specified endpoint number with the given endpoint type, direction, bank size
+                       /** Configures the specified endpoint address with the given endpoint type, direction, bank size
                         *  and banking mode. Once configured, the endpoint may be read from or written to, depending
                         *  on its direction.
                         *
-                        *  \param[in] Number     Endpoint number to configure. This must be more than 0 and less than
-                        *                        \ref ENDPOINT_TOTAL_ENDPOINTS.
+                        *  \param[in] Address    Endpoint address to configure.
                         *
                         *  \param[in] Type       Type of endpoint to configure, a \c EP_TYPE_* mask. Not all endpoint types
                         *                        are available on Low Speed USB devices - refer to the USB 2.0 specification.
                         *
-                        *  \param[in] Direction  Endpoint data direction, either \ref ENDPOINT_DIR_OUT or \ref ENDPOINT_DIR_IN.
-                        *                        All endpoints (except Control type) are unidirectional - data may only be read
-                        *                        from or written to the endpoint bank based on its direction, not both.
-                        *
                         *  \param[in] Size       Size of the endpoint's bank, where packets are stored before they are transmitted
                         *                        to the USB host, or after they have been received from the USB host (depending on
                         *                        the endpoint's data direction). The bank size must indicate the maximum packet size
                         *                        that the endpoint can handle.
                         *
-                        *  \param[in] Banks      Number of banks to use for the endpoint being configured, an \c ENDPOINT_BANK_* mask.
-                        *                        More banks uses more USB DPRAM, but offers better performance. Isochronous type
-                        *                        endpoints <b>must</b> have at least two banks.
+                        *  \param[in] Banks      Number of hardware banks to use for the endpoint being configured.
                         *
                         *  \note The default control endpoint should not be manually configured by the user application, as
                         *        it is automatically configured by the library internally.
                         *
                         *  \return Boolean \c true if the configuration succeeded, \c false otherwise.
                         */
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks) ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Number,
+                       static inline bool Endpoint_ConfigureEndpoint(const uint8_t Address,
                                                                      const uint8_t Type,
-                                                                     const uint8_t Direction,
                                                                      const uint16_t Size,
                                                                      const uint8_t Banks)
                        {
-                               uint8_t EPConfigMask = (USB_EP_INTDSBL_bm | Banks | Endpoint_BytesToEPSizeMask(Size));
+                               uint8_t EPConfigMask = (USB_EP_INTDSBL_bm | ((Banks > 1) ? USB_EP_PINGPONG_bm : 0) | Endpoint_BytesToEPSizeMask(Size));
 
                                // TODO - Fix once limitations are lifted
-                               if ((Banks != ENDPOINT_BANK_SINGLE) || (Size > 64))
+                               if ((Banks > 1) || (Size > 64))
                                  return false;
 
                                switch (Type)
                                }
 
                                if (Type == EP_TYPE_CONTROL)
-                                 Endpoint_ConfigureEndpoint_PRV(Number, (Direction ^ ENDPOINT_DIR_IN), EPConfigMask, Size);
+                                 Endpoint_ConfigureEndpoint_PRV(Address ^ ENDPOINT_DIR_IN, EPConfigMask, Size);
 
-                               return Endpoint_ConfigureEndpoint_PRV(Number, Direction, EPConfigMask, Size);
+                               return Endpoint_ConfigureEndpoint_PRV(Address, EPConfigMask, Size);
                        }
 
                        /** Indicates the number of bytes currently stored in the current endpoint's selected bank.
                        }
 
                        /** Get the endpoint address of the currently selected endpoint. This is typically used to save
-                        *  the currently selected endpoint number so that it can be restored after another endpoint has
-                        *  been manipulated.
+                        *  the currently selected endpoint so that it can be restored after another endpoint has been
+                        *  manipulated.
                         *
                         *  \return Index of the currently selected endpoint.
                         */
                        /** Resets the endpoint bank FIFO. This clears all the endpoint banks and resets the USB controller's
                         *  data In and Out pointers to the bank's contents.
                         *
-                        *  \param[in] EndpointNumber Endpoint number whose FIFO buffers are to be reset.
+                        *  \param[in] Address  Endpoint address whose FIFO buffers are to be reset.
                         */
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber) ATTR_ALWAYS_INLINE;
-                       static inline void Endpoint_ResetEndpoint(const uint8_t EndpointNumber)
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address) ATTR_ALWAYS_INLINE;
+                       static inline void Endpoint_ResetEndpoint(const uint8_t Address)
                        {
-                               if (EndpointNumber & ENDPOINT_DIR_IN)
-                                 USB_Endpoint_FIFOs[EndpointNumber & ENDPOINT_EPNUM_MASK].IN.Position  = 0;
+                               if (Address & ENDPOINT_DIR_IN)
+                                 USB_Endpoint_FIFOs[Address & ENDPOINT_EPNUM_MASK].IN.Position  = 0;
                                else
-                                 USB_Endpoint_FIFOs[EndpointNumber & ENDPOINT_EPNUM_MASK].OUT.Position = 0;
+                                 USB_Endpoint_FIFOs[Address & ENDPOINT_EPNUM_MASK].OUT.Position = 0;
                        }
 
                        /** Determines if the currently selected endpoint is enabled, but not necessarily configured.
                        static inline bool Endpoint_IsReadWriteAllowed(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
                        static inline bool Endpoint_IsReadWriteAllowed(void)
                        {
-                               if (USB_Endpoint_SelectedEndpoint & ENDPOINT_DIR_IN)
-                                 return (USB_Endpoint_SelectedFIFO->Position < USB_Endpoint_SelectedFIFO->Length);
-                               else
-                                 return (USB_Endpoint_SelectedFIFO->Position > 0);
+                               return (USB_Endpoint_SelectedFIFO->Position < USB_Endpoint_SelectedFIFO->Length);
                        }
 
                        /** Determines if the currently selected endpoint is configured.
                                return ((USB_Endpoint_SelectedHandle->CTRL & USB_EP_TYPE_gm) ? true : false);
                        }
 
-                       /** Returns a mask indicating which INTERRUPT type endpoints have interrupted - i.e. their
-                        *  interrupt duration has elapsed. Which endpoints have interrupted can be determined by
-                        *  masking the return value against <tt>(1 << <i>{Endpoint Number}</i>)</tt>.
-                        *
-                        *  \return Mask whose bits indicate which endpoints have interrupted.
-                        */
-                       static inline uint8_t Endpoint_GetEndpointInterrupts(void) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline uint8_t Endpoint_GetEndpointInterrupts(void)
-                       {
-                               return 0; // TODO
-                       }
-
-                       /** Determines if the specified endpoint number has interrupted (valid only for INTERRUPT type
-                        *  endpoints).
-                        *
-                        *  \param[in] EndpointNumber  Index of the endpoint whose interrupt flag should be tested.
-                        *
-                        *  \return Boolean \c true if the specified endpoint has interrupted, \c false otherwise.
-                        */
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber) ATTR_WARN_UNUSED_RESULT ATTR_ALWAYS_INLINE;
-                       static inline bool Endpoint_HasEndpointInterrupted(const uint8_t EndpointNumber)
-                       {
-                               (void)EndpointNumber;
-                               return 0; // TODO
-                       }
-
                        /** Determines if the selected IN endpoint is ready for a new packet to be sent to the host.
                         *
                         *  \ingroup Group_EndpointPacketManagement_XMEGA
                        #endif
 
                /* Function Prototypes: */
+                       /** Configures a table of endpoint descriptions, in sequence. This function can be used to configure multiple
+                        *  endpoints at the same time.
+                        *
+                        *  \note Endpoints with a zero address will be ignored, thus this function cannot be used to configure the
+                        *        control endpoint.
+                        *
+                        *  \param[in] Table    Pointer to a table of endpoint descriptions.
+                        *  \param[in] Entries  Number of entries in the endpoint table to configure.
+                        *
+                        *  \return Boolean \c true if all endpoints configured successfully, \c false otherwise.
+                        */
+                       bool Endpoint_ConfigureEndpointTable(const USB_Endpoint_Table_t* const Table,
+                                                            const uint8_t Entries);
+
                        /** Completes the status stage of a control transfer on a CONTROL type endpoint automatically,
                         *  with respect to the data direction. This is a convenience function which can be used to
                         *  simplify user control request handling.
index 387e8e4..844ef65 100644 (file)
@@ -43,7 +43,8 @@ volatile uint8_t USB_CurrentMode = USB_MODE_None;
 volatile uint8_t USB_Options;
 #endif
 
-USB_EndpointTable_t USB_EndpointTable ATTR_ALIGNED(4);
+/* Ugly workaround to ensure an aligned table, since __BIGGEST_ALIGNMENT__ == 1 for 8-bit AVR-GCC */
+uint8_t USB_EndpointTable[sizeof(USB_EndpointTable_t) + 1];
 
 void USB_Init(
                #if defined(USB_CAN_BE_BOTH)
@@ -75,8 +76,9 @@ void USB_Init(
        USB.CAL1 = pgm_read_byte(offsetof(NVM_PROD_SIGNATURES_t, USBCAL1));
        NVM.CMD  = 0;
 
-       USB.EPPTR = (intptr_t)&USB_EndpointTable;
-       USB.CTRLA = (USB_STFRNUM_bm | USB_MAXEP_gm);
+       /* Ugly workaround to ensure an aligned table, since __BIGGEST_ALIGNMENT__ == 1 for 8-bit AVR-GCC */
+       USB.EPPTR = ((intptr_t)&USB_EndpointTable[1] & ~(1 << 0));
+       USB.CTRLA = (USB_STFRNUM_bm | ((ENDPOINT_TOTAL_ENDPOINTS - 1) << USB_MAXEP_gp));
 
        if ((USB_Options & USB_OPT_BUSEVENT_PRIHIGH) == USB_OPT_BUSEVENT_PRIHIGH)
          USB.INTCTRLA = (3 << USB_INTLVL_gp);
@@ -103,13 +105,17 @@ void USB_Disable(void)
 
 void USB_ResetInterface(void)
 {
+       #if defined(USB_DEVICE_OPT_FULLSPEED)
        if (USB_Options & USB_DEVICE_OPT_LOWSPEED)
          CLK.USBCTRL = (((F_USB / 6000000) - 1) << CLK_USBPSDIV_gp);
        else
          CLK.USBCTRL = (((F_USB / 48000000) - 1) << CLK_USBPSDIV_gp);
-
+       #else
+       CLK.USBCTRL = (((F_USB / 6000000) - 1) << CLK_USBPSDIV_gp);
+       #endif
+       
        if (USB_Options & USB_OPT_PLLCLKSRC)
-         CLK.USBCTRL |= (CLK_USBSRC_PLL_gc | CLK_USBSEN_bm);
+         CLK.USBCTRL |= (CLK_USBSRC_PLL_gc   | CLK_USBSEN_bm);
        else
          CLK.USBCTRL |= (CLK_USBSRC_RC32M_gc | CLK_USBSEN_bm);
 
@@ -172,8 +178,7 @@ static void USB_Init_Device(void)
          USB_Device_SetFullSpeed();
 
        Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                                          ENDPOINT_BANK_SINGLE);
+                                                          USB_Device_ControlEndpointSize, 1);
 
        USB_INT_Enable(USB_INT_BUSEVENTI);
 
index 2f14f75..25402e8 100644 (file)
@@ -69,7 +69,7 @@
                        } ATTR_PACKED USB_EndpointTable_t;
 
                /* External Variables: */
-                       extern USB_EndpointTable_t USB_EndpointTable;
+                       extern uint8_t USB_EndpointTable[];
 
        #endif
 
@@ -95,7 +95,7 @@
                        #error F_USB is not defined. You must define F_USB to the frequency of the unprescaled USB controller clock in your project makefile.
                #endif
 
-               #if (F_USB % 6000000)
+               #if ((F_USB % 6000000) || (F_USB < 6000000))
                        #error Invalid F_USB specified. F_USB must be a multiple of 6MHz for USB Low Speed operation, and a multiple of 48MHz for Full Speed operation.
                #endif
 
index b0e52d0..3554165 100644 (file)
@@ -97,8 +97,7 @@ ISR(USB_BUSEVENT_vect)
 
                Endpoint_ClearEndpoints();
                Endpoint_ConfigureEndpoint(ENDPOINT_CONTROLEP, EP_TYPE_CONTROL,
-                                          ENDPOINT_DIR_OUT, USB_Device_ControlEndpointSize,
-                                          ENDPOINT_BANK_SINGLE);
+                                          USB_Device_ControlEndpointSize, 1);
 
                EVENT_USB_Device_Reset();
        }
index 35b285c..c99c1d2 100644 (file)
  *      .Config =
  *          {
  *              .StreamingInterfaceNumber = 1,
- *
- *              .DataINEndpointNumber     = 1,
- *              .DataINEndpointSize       = 256,
+ *              .DataINEndpoint           =
+ *                  {
+ *                      .Address          = (ENDPOINT_DIR_IN | 1),
+ *                      .Size             = 64,
+ *                      .Banks            = 1,
+ *                  },
  *          },
  *  };
  *  \endcode
  *  {
  *      .Config =
  *          {
- *              .DataINPipeNumber       = 1,
- *              .DataINPipeDoubleBank   = false,
- *
- *              .DataOUTPipeNumber      = 2,
- *              .DataOUTPipeDoubleBank  = false,
+ *              .DataINPipe             =
+ *                  {
+ *                      .Address        = (PIPE_DIR_IN  | 1),
+ *                      .Size           = 64,
+ *                      .Banks          = 1,
+ *                  },
+ *              .DataOUTPipe            =
+ *                  {
+ *                      .Address        = (PIPE_DIR_OUT | 2),
+ *                      .Size           = 64,
+ *                      .Banks          = 1,
+ *                  },
  *          },
  *  };
  *  \endcode
index dcde7dc..9b3b562 100644 (file)
  *
  *     void main(void)
  *     {
- *             // Start the PLL to multiply the 2MHz RC oscillator to 32MHz and switch the CPU core to run from it
- *             XMEGACLK_StartPLL(CLOCK_SRC_INT_RC2MHZ, 2000000, 32000000);
- *             XMEGACLK_SetCPUClockSource(CLOCK_SRC_PLL, F_CPU);
+ *             // Start the PLL to multiply the 2MHz RC oscillator to F_CPU and switch the CPU core to run from it
+ *             XMEGACLK_StartPLL(CLOCK_SRC_INT_RC2MHZ, 2000000, F_CPU);
+ *             XMEGACLK_SetCPUClockSource(CLOCK_SRC_PLL);
  *
- *             // Start the 32MHz internal RC oscillator and start the DFLL to increase it to 48MHz using the USB SOF as a reference
+ *             // Start the 32MHz internal RC oscillator and start the DFLL to increase it to F_USB using the USB SOF as a reference
  *             XMEGACLK_StartInternalOscillator(CLOCK_SRC_INT_RC32MHZ);
- *             XMEGACLK_StartDFLL(CLOCK_SRC_INT_RC32MHZ, DFLL_REF_INT_USBSOF, 48000000);
+ *             XMEGACLK_StartDFLL(CLOCK_SRC_INT_RC32MHZ, DFLL_REF_INT_USBSOF, F_USB);
  *     }
  *  \endcode
  *
                        };
 
                /* Inline Functions: */
+                       /** Write a value to a location protected by the XMEGA CCP protection mechanism. This function uses inline assembly to ensure that
+                        *  the protected address is written to within four clock cycles of the CCP key being written.
+                        *
+                        *  \param[in] Address  Address to write to, a memory address protected by the CCP mechanism
+                        *  \param[in] Value    Value to write to the protected location
+                        */
+                       static inline void XMEGACLK_CCP_Write(volatile void* Address, const uint8_t Value) ATTR_ALWAYS_INLINE;
+                       static inline void XMEGACLK_CCP_Write(volatile void* Address, const uint8_t Value)
+                       {
+                               __asm__ __volatile__ (
+                                       "out %0, __zero_reg__" "\n\t" /* Zero RAMPZ using fixed zero value register */
+                                       "movw r30, %1"         "\n\t" /* Copy address to Z register pair */
+                                       "out %2, %3"           "\n\t" /* Write key to CCP register */
+                                       "st Z, %4"             "\n\t" /* Indirectly write value to address */
+                                       : /* No output operands */
+                                       : /* Input operands: */ "m" (RAMPZ), "e" (Address), "m" (CCP), "r" (CCP_IOREG_gc), "r" (Value)
+                                       : /* Clobbered registers: */ "r30", "r31"
+                               ); 
+                       }
+
                        /** Starts the external oscillator of the XMEGA microcontroller, with the given options. This routine blocks until
                         *  the oscillator is ready for use.
                         *
 
                                if (SourceFreq > Frequency)
                                  return false;
+                                 
+                               if (MulFactor > 31)
+                                 return false;
 
                                switch (Source)
                                {
                                uint_reg_t CurrentGlobalInt = GetGlobalInterruptMask();
                                GlobalInterruptDisable();
 
-                               CCP      = CCP_IOREG_gc;
-                               CLK_CTRL = ClockSourceMask;
+                               XMEGACLK_CCP_Write(&CLK.CTRL, ClockSourceMask);
 
                                SetGlobalInterruptMask(CurrentGlobalInt);
 
index 5cce2bf..8daf9c1 100644 (file)
@@ -8,11 +8,12 @@
 \r
 # Maintenance scripts not required by general LUFA users, used for project development purposes.\r
 \r
+\r
+# Path to the root of the LUFA tree\r
 LUFA_ROOT = ../\r
 \r
 all:\r
 \r
-\r
 # Update all Doxygen configuration files to the latest Doxygen version - force Markdown support to be disabled\r
 upgrade-doxygen:\r
        @echo Upgrading Doxygen.conf files...\r
@@ -36,13 +37,6 @@ check-documentation-placeholders:
        fi;\r
        @echo Done.\r
 \r
-# Test all generated documentation for any bad links\r
-check-documentation-links:\r
-       @for html_file in `find $(LUFA_ROOT) -name *.html`; do \\r
-               echo Checking $$html_file...; \\r
-               cat $$html_file | grep -v "doxygen.org" | grep -v "fourwalledcubicle.com" | wget -nv --referer=www.lufa-lib.org --user-agent="lufa-link-check-script" -B $(dir $$html_file) --spider --force-html --input-file=-; \\r
-       done;\r
-\r
 # Validate the working branch - compile all documentation, demos/projects/examples and run build tests\r
 validate-branch:\r
        make -s -C $(LUFA_ROOT) doxygen\r
index 760193a..eaf04cb 100644 (file)
@@ -93,12 +93,10 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        bool ConfigSuccess = true;
 
        /* Setup AVRISP Data Endpoint(s) */
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                   AVRISP_DATA_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_OUT_EPADDR, EP_TYPE_BULK, AVRISP_DATA_EPSIZE, 1);
 
        #if defined(LIBUSB_DRIVER_COMPAT)
-       ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_IN_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                   AVRISP_DATA_EPSIZE, ENDPOINT_BANK_SINGLE);
+       ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_IN_EPADDR, EP_TYPE_BULK, AVRISP_DATA_EPSIZE, 1);
        #endif
 
        /* Indicate endpoint configuration success or failure */
@@ -114,7 +112,7 @@ void AVRISP_Task(void)
 
        V2Params_UpdateParamValues();
 
-       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPADDR);
 
        /* Check to see if a V2 Protocol command has been received */
        if (Endpoint_IsOUTReceived())
index 12f44f9..da57b71 100644 (file)
@@ -106,7 +106,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | AVRISP_DATA_IN_EPNUM),
+                       .EndpointAddress        = AVRISP_DATA_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = AVRISP_DATA_EPSIZE,
                        .PollingIntervalMS      = 0x0A
@@ -116,7 +116,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | AVRISP_DATA_OUT_EPNUM),
+                       .EndpointAddress        = AVRISP_DATA_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = AVRISP_DATA_EPSIZE,
                        .PollingIntervalMS      = 0x0A
index 5a994ba..1b140f3 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               #if !defined(LIBUSB_DRIVER_COMPAT)
-                       /** Endpoint number of the AVRISP data OUT endpoint. */
-                       #define AVRISP_DATA_OUT_EPNUM      2
+               #if !defined(LIBUSB_DRIVER_COMPAT) || defined(__DOXYGEN__)
+                       /** Endpoint address of the AVRISP data OUT endpoint. */
+                       #define AVRISP_DATA_OUT_EPADDR     (ENDPOINT_DIR_OUT | 2)
 
-                       /** Endpoint number of the AVRISP data IN endpoint. */
-                       #define AVRISP_DATA_IN_EPNUM       2
+                       /** Endpoint address of the AVRISP data IN endpoint. */
+                       #define AVRISP_DATA_IN_EPADDR      (ENDPOINT_DIR_IN  | 2)
                #else
-                       /** Endpoint number of the AVRISP data OUT endpoint. */
-                       #define AVRISP_DATA_OUT_EPNUM      2
-
-                       /** Endpoint number of the AVRISP data IN endpoint. */
-                       #define AVRISP_DATA_IN_EPNUM       3
+                       #define AVRISP_DATA_OUT_EPADDR     (ENDPOINT_DIR_OUT | 2)
+                       #define AVRISP_DATA_IN_EPADDR      (ENDPOINT_DIR_IN  | 3)
                #endif
 
                /** Size in bytes of the AVRISP data endpoint. */
index f757ac1..445e088 100644 (file)
@@ -57,7 +57,7 @@ void ISPProtocol_EnterISPMode(void)
        Endpoint_Read_Stream_LE(&Enter_ISP_Params, sizeof(Enter_ISP_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t ResponseStatus = STATUS_CMD_FAILED;
@@ -115,7 +115,7 @@ void ISPProtocol_LeaveISPMode(void)
        Endpoint_Read_Stream_LE(&Leave_ISP_Params, sizeof(Leave_ISP_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        /* Perform pre-exit delay, release the target /RESET, disable the SPI bus and perform the post-exit delay */
@@ -154,7 +154,7 @@ void ISPProtocol_ProgramMemory(uint8_t V2Command)
        if (Write_Memory_Params.BytesToWrite > sizeof(Write_Memory_Params.ProgData))
        {
                Endpoint_ClearOUT();
-               Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+               Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
                Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
                Endpoint_Write_8(V2Command);
@@ -175,7 +175,7 @@ void ISPProtocol_ProgramMemory(uint8_t V2Command)
        }
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t  ProgrammingStatus = STATUS_CMD_OK;
@@ -295,7 +295,7 @@ void ISPProtocol_ReadMemory(uint8_t V2Command)
        Read_Memory_Params.BytesToRead = SwapEndian_16(Read_Memory_Params.BytesToRead);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(V2Command);
@@ -368,7 +368,7 @@ void ISPProtocol_ChipErase(void)
        Endpoint_Read_Stream_LE(&Erase_Chip_Params, sizeof(Erase_Chip_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t ResponseStatus = STATUS_CMD_OK;
@@ -404,7 +404,7 @@ void ISPProtocol_ReadFuseLockSigOSCCAL(uint8_t V2Command)
        Endpoint_Read_Stream_LE(&Read_FuseLockSigOSCCAL_Params, sizeof(Read_FuseLockSigOSCCAL_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t ResponseBytes[4];
@@ -435,7 +435,7 @@ void ISPProtocol_WriteFuseLock(uint8_t V2Command)
        Endpoint_Read_Stream_LE(&Write_FuseLockSig_Params, sizeof(Write_FuseLockSig_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        /* Send the Fuse or Lock byte program commands as given by the host to the device */
@@ -463,7 +463,7 @@ void ISPProtocol_SPIMulti(void)
        Endpoint_Read_Stream_LE(&SPI_Multi_Params.TxData, SPI_Multi_Params.TxBytes, NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(CMD_SPI_MULTI);
index f485810..e7c43cd 100644 (file)
@@ -150,7 +150,7 @@ void V2Protocol_ProcessCommand(void)
        TCCR0B = 0;
 
        Endpoint_WaitUntilReady();
-       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_OUT);
 }
 
@@ -169,7 +169,7 @@ static void V2Protocol_UnknownCommand(const uint8_t V2Command)
        }
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(V2Command);
@@ -181,7 +181,7 @@ static void V2Protocol_UnknownCommand(const uint8_t V2Command)
 static void V2Protocol_SignOn(void)
 {
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(CMD_SIGN_ON);
@@ -197,7 +197,7 @@ static void V2Protocol_SignOn(void)
 static void V2Protocol_ResetProtection(void)
 {
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(CMD_RESET_PROTECTION);
@@ -220,7 +220,7 @@ static void V2Protocol_GetSetParam(const uint8_t V2Command)
          ParamValue = Endpoint_Read_8();
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(V2Command);
@@ -254,7 +254,7 @@ static void V2Protocol_LoadAddress(void)
        Endpoint_Read_Stream_BE(&CurrentAddress, sizeof(CurrentAddress), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        if (CurrentAddress & (1UL << 31))
index 1ec2b04..2c5ac3f 100644 (file)
@@ -37,7 +37,7 @@
 #include "V2ProtocolParams.h"
 
 /* Non-Volatile Parameter Values for EEPROM storage */
-static uint8_t EEMEM EEPROM_Reset_Polarity = 0x00;
+static uint8_t EEMEM EEPROM_Reset_Polarity = 0x01;
 
 /* Volatile Parameter Values for RAM storage */
 static ParameterItem_t ParameterTable[] =
index 97154ea..b782475 100644 (file)
@@ -174,6 +174,8 @@ void XMEGANVM_DisablePDI(void)
  */
 bool XMEGANVM_GetMemoryCRC(const uint8_t CRCCommand, uint32_t* const CRCDest)
 {
+       *CRCDest = 0;
+
        /* Wait until the NVM controller is no longer busy */
        if (!(XMEGANVM_WaitWhileNVMControllerBusy()))
          return false;
index d342730..ad8cd53 100644 (file)
@@ -65,7 +65,7 @@ void XPROGProtocol_SetMode(void)
        Endpoint_Read_Stream_LE(&SetMode_XPROG_Params, sizeof(SetMode_XPROG_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        XPROG_SelectedProtocol = SetMode_XPROG_Params.Protocol;
@@ -112,7 +112,7 @@ void XPROGProtocol_Command(void)
 static void XPROGProtocol_EnterXPROGMode(void)
 {
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        bool NVMBusEnabled = false;
@@ -134,7 +134,7 @@ static void XPROGProtocol_EnterXPROGMode(void)
 static void XPROGProtocol_LeaveXPROGMode(void)
 {
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        if (XPROG_SelectedProtocol == XPRG_PROTOCOL_PDI)
@@ -169,7 +169,7 @@ static void XPROGProtocol_Erase(void)
        Erase_XPROG_Params.Address = SwapEndian_32(Erase_XPROG_Params.Address);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t EraseCommand;
@@ -260,7 +260,7 @@ static void XPROGProtocol_WriteMemory(void)
        }
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        if (XPROG_SelectedProtocol == XPRG_PROTOCOL_PDI)
@@ -342,7 +342,7 @@ static void XPROGProtocol_ReadMemory(void)
        ReadMemory_XPROG_Params.Length  = SwapEndian_16(ReadMemory_XPROG_Params.Length);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint8_t ReadBuffer[256];
@@ -385,7 +385,7 @@ static void XPROGProtocol_ReadCRC(void)
        Endpoint_Read_Stream_LE(&ReadCRC_XPROG_Params, sizeof(ReadCRC_XPROG_Params), NULL);
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        uint32_t MemoryCRC;
@@ -467,7 +467,7 @@ static void XPROGProtocol_SetParam(void)
        }
 
        Endpoint_ClearOUT();
-       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_IN_EPADDR);
        Endpoint_SetEndpointDirection(ENDPOINT_DIR_IN);
 
        Endpoint_Write_8(CMD_XPROG);
index 523fc15..6056535 100644 (file)
@@ -51,7 +51,7 @@
                #if ((BOARD == BOARD_XPLAIN) || (BOARD == BOARD_XPLAIN_REV1))
                        /* On the XPLAIN board, we only need PDI programming
                           for the ATXMEGA128A1 - disable ISP to prevent hardware
-                          damage.
+                          damage and force-enable XPROG.
                         */
                        #undef ENABLE_ISP_PROTOCOL
 
index b2f5552..5ea9404 100644 (file)
@@ -78,7 +78,7 @@ void XPROGTarget_EnableTargetTPI(void)
        DDRD |=  (1 << 5) | (1 << 3);
        DDRD &= ~(1 << 2);
 
-       /* Set up the synchronous USART for TINY communications - 8 data bits, even parity, 2 stop bits */
+       /* Set up the synchronous USART for TPI communications - 8 data bits, even parity, 2 stop bits */
        UBRR1  = ((F_CPU / 2 / XPROG_HARDWARE_SPEED) - 1);
        UCSR1B = (1 << TXEN1);
        UCSR1C = (1 << UMSEL10) | (1 << UPM11) | (1 << USBS1) | (1 << UCSZ11) | (1 << UCSZ10) | (1 << UCPOL1);
index 8d9ac53..d68cee3 100644 (file)
@@ -62,19 +62,25 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
        {
                .Config =
                        {
-                               .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .ControlInterfaceNumber   = 0,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
index 86d8c4d..ea73dfe 100644 (file)
@@ -131,7 +131,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -157,20 +157,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 03f4e5e..e481793 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index c0cc11f..fa44c08 100644 (file)
@@ -47,14 +47,17 @@ USB_ClassInfo_HID_Host_t Device_HID_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
-
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                                .HIDInterfaceProtocol   = HID_CSCP_NonBootProtocol,
-
                                .HIDParserData          = &HIDReportInfo
                        },
        };
index a3319e4..61176e6 100644 (file)
@@ -120,20 +120,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 250fcf7..c0e8f46 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         5
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 5)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   1
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   2
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 2)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
                /** Size in bytes of the CDC data IN and OUT endpoints. */
                #define CDC_TXRX_EPSIZE                16
 
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
index bc70910..73bf554 100644 (file)
@@ -40,15 +40,18 @@ USB_ClassInfo_MS_Device_t DiskDevice_MS_Interface =
                .Config =
                        {
                                .InterfaceNumber           = 0,
-
-                               .DataINEndpointNumber      = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize        = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
-
+                               .DataINEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_IN_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
+                               .DataOUTEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_OUT_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
                                .TotalLUNs                 = 1,
                        },
        };
index 1dafda4..c93029c 100644 (file)
@@ -39,11 +39,16 @@ USB_ClassInfo_MS_Host_t DiskHost_MS_Interface =
        {
                .Config =
                        {
-                               .DataINPipeNumber       = 1,
-                               .DataINPipeDoubleBank   = false,
-
-                               .DataOUTPipeNumber      = 2,
-                               .DataOUTPipeDoubleBank  = false,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
                        },
        };
 
index cac0bd9..d953875 100644 (file)
@@ -5,7 +5,7 @@
 #include "diskio.h"
 
 #include <string.h>
-#include <LUFA/Drivers/USB/Class/MassStorage.h>
+#include <LUFA/Drivers/USB/USB.h>
 #include "../DataflashManager.h"
 #include "../../DiskHost.h"
 
index e362857..d5bc6fa 100644 (file)
@@ -143,7 +143,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -169,20 +169,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 03f4e5e..e481793 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 34f29e1..dd3a8ae 100644 (file)
@@ -44,19 +44,25 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
        {
                .Config =
                        {
-                               .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .ControlInterfaceNumber   = 0,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
index 9ad0e86..44db1ee 100644 (file)
@@ -199,10 +199,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_OUT | MIDI_STREAM_OUT_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_OUT_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
@@ -224,10 +224,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                                {
                                        .Header              = {.Size = sizeof(USB_Audio_Descriptor_StreamEndpoint_Std_t), .Type = DTYPE_Endpoint},
 
-                                       .EndpointAddress     = (ENDPOINT_DIR_IN | MIDI_STREAM_IN_EPNUM),
+                                       .EndpointAddress     = MIDI_STREAM_IN_EPADDR,
                                        .Attributes          = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                                        .EndpointSize        = MIDI_STREAM_EPSIZE,
-                                       .PollingIntervalMS   = 0x01
+                                       .PollingIntervalMS   = 0x05
                                },
 
                        .Refresh                  = 0,
index c5dc2e2..8384444 100644 (file)
                #include <avr/pgmspace.h>
 
        /* Macros: */
-               /** Endpoint number of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
-               #define MIDI_STREAM_IN_EPNUM        2
+               /** Endpoint address of the MIDI streaming data IN endpoint, for device-to-host data transfers. */
+               #define MIDI_STREAM_IN_EPADDR       (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
-               #define MIDI_STREAM_OUT_EPNUM       1
+               /** Endpoint address of the MIDI streaming data OUT endpoint, for host-to-device data transfers. */
+               #define MIDI_STREAM_OUT_EPADDR      (ENDPOINT_DIR_OUT | 1)
 
                /** Endpoint size in bytes of the Audio isochronous streaming data IN and OUT endpoints. */
                #define MIDI_STREAM_EPSIZE          64
index 4062bff..5f17fdd 100644 (file)
@@ -45,14 +45,18 @@ USB_ClassInfo_MIDI_Device_t Keyboard_MIDI_Interface =
                .Config =
                        {
                                .StreamingInterfaceNumber = 1,
-
-                               .DataINEndpointNumber      = MIDI_STREAM_IN_EPNUM,
-                               .DataINEndpointSize        = MIDI_STREAM_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MIDI_STREAM_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MIDI_STREAM_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = MIDI_STREAM_IN_EPADDR,
+                                               .Size             = MIDI_STREAM_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint           =
+                                       {
+                                               .Address          = MIDI_STREAM_OUT_EPADDR,
+                                               .Size             = MIDI_STREAM_EPSIZE,
+                                               .Banks            = 1,
+                                       },
                        },
        };
 
@@ -96,7 +100,7 @@ int main(void)
                MIDI_EventPacket_t ReceivedMIDIEvent;
                if (MIDI_Device_ReceiveEventPacket(&Keyboard_MIDI_Interface, &ReceivedMIDIEvent))
                {
-                       if ((ReceivedMIDIEvent.Command == (MIDI_COMMAND_NOTE_ON >> 4)) && ((ReceivedMIDIEvent.Data1 & 0x0F) == 0))
+                       if ((ReceivedMIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_ON)) && ((ReceivedMIDIEvent.Data1 & 0x0F) == 0))
                        {
                                DDSNoteData* LRUNoteStruct = &NoteData[0];
 
@@ -130,7 +134,7 @@ int main(void)
                                /* Turn on indicator LED to indicate note generation activity */
                                LEDs_SetAllLEDs(LEDS_LED1);
                        }
-                       else if ((ReceivedMIDIEvent.Command == (MIDI_COMMAND_NOTE_OFF >> 4)) && ((ReceivedMIDIEvent.Data1 & 0x0F) == 0))
+                       else if ((ReceivedMIDIEvent.Event == MIDI_EVENT(0, MIDI_COMMAND_NOTE_OFF)) && ((ReceivedMIDIEvent.Data1 & 0x0F) == 0))
                        {
                                bool FoundActiveNote = false;
 
index aec8b88..3784609 100644 (file)
@@ -132,10 +132,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | KEYBOARD_EPNUM),
+                       .EndpointAddress        = KEYBOARD_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = KEYBOARD_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index 27ea9a1..f90816a 100644 (file)
@@ -58,8 +58,8 @@
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the keyboard key press reporting endpoint. */
-               #define KEYBOARD_EPNUM               1
+               /** Endpoint address of the keyboard key press reporting endpoint. */
+               #define KEYBOARD_EPADDR              (ENDPOINT_DIR_IN | 1)
 
                /** Size of the keyboard report endpoints, in bytes. */
                #define KEYBOARD_EPSIZE              8
index 6e41ce6..ecdf68b 100644 (file)
@@ -57,11 +57,12 @@ USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber            = 0,
-
-                               .ReportINEndpointNumber     = KEYBOARD_EPNUM,
-                               .ReportINEndpointSize       = KEYBOARD_EPSIZE,
-                               .ReportINEndpointDoubleBank = KEYBOARD_EPSIZE,
-
+                               .ReportINEndpoint           =
+                                       {
+                                               .Address            = KEYBOARD_EPADDR,
+                                               .Size               = KEYBOARD_EPSIZE,
+                                               .Banks              = 1,
+                                       },
                                .PrevReportINBuffer         = PrevKeyboardHIDReportBuffer,
                                .PrevReportINBufferSize     = sizeof(PrevKeyboardHIDReportBuffer),
                        },
index fc862aa..b2b583c 100644 (file)
@@ -149,10 +149,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MEDIACONTROL_HID_EPNUM),
+                       .EndpointAddress        = MEDIACONTROL_HID_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MEDIACONTROL_HID_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index ec9b330..3844e31 100644 (file)
                } USB_Descriptor_Configuration_t;
 
        /* Macros: */
-               /** Endpoint number of the Media Control HID reporting IN endpoint. */
-               #define MEDIACONTROL_HID_EPNUM               1
+               /** Endpoint address of the Media Control HID reporting IN endpoint. */
+               #define MEDIACONTROL_HID_EPADDR           (ENDPOINT_DIR_IN | 1)
 
-               /** Size in bytes of the Media Control HID reporting IN and OUT endpoints. */
-               #define MEDIACONTROL_HID_EPSIZE              8
+               /** Size in bytes of the Media Control HID reporting IN endpoint. */
+               #define MEDIACONTROL_HID_EPSIZE           8
 
        /* Function Prototypes: */
                uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
index 0140527..24f0258 100644 (file)
@@ -48,11 +48,12 @@ USB_ClassInfo_HID_Device_t MediaControl_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 0,
-
-                               .ReportINEndpointNumber       = MEDIACONTROL_HID_EPNUM,
-                               .ReportINEndpointSize         = MEDIACONTROL_HID_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = MEDIACONTROL_HID_EPADDR,
+                                               .Size                 = MEDIACONTROL_HID_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevMediaControlHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevMediaControlHIDReportBuffer),
                        },
index efcd2be..e287d78 100644 (file)
@@ -109,16 +109,14 @@ uint8_t ProcessConfigurationDescriptor(void)
        }
 
        /* Configure the HID data IN pipe */
-       Pipe_ConfigurePipe(HID_DATA_IN_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_IN,
-                          DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+       Pipe_ConfigurePipe(HID_DATA_IN_PIPE, EP_TYPE_INTERRUPT, DataINEndpoint->EndpointAddress, DataINEndpoint->EndpointSize, 1);
        Pipe_SetInterruptPeriod(DataINEndpoint->PollingIntervalMS);
 
        /* Check if the HID interface contained an optional OUT data endpoint */
        if (DataOUTEndpoint)
        {
                /* Configure the HID data OUT pipe */
-               Pipe_ConfigurePipe(HID_DATA_OUT_PIPE, EP_TYPE_INTERRUPT, PIPE_TOKEN_OUT,
-                                                  DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, PIPE_BANK_SINGLE);
+               Pipe_ConfigurePipe(HID_DATA_OUT_PIPE, EP_TYPE_INTERRUPT, DataOUTEndpoint->EndpointAddress, DataOUTEndpoint->EndpointSize, 1);
        }
 
        /* Valid data found, return success */
index b05f7ef..c857bf7 100644 (file)
                /** Interface Class value for the Human Interface Device class. */
                #define HID_CLASS                 0x03
 
-               /** Pipe number for the HID data IN pipe. */
-               #define HID_DATA_IN_PIPE          1
+               /** Pipe address for the HID data IN pipe. */
+               #define HID_DATA_IN_PIPE          (PIPE_DIR_IN  | 1)
 
-               /** Pipe number for the HID data OUT pipe. */
-               #define HID_DATA_OUT_PIPE         2
+               /** Pipe address for the HID data OUT pipe. */
+               #define HID_DATA_OUT_PIPE         (PIPE_DIR_OUT | 2)
 
        /* Enums: */
                /** Enum for the possible return codes of the \ref ProcessConfigurationDescriptor() function. */
index 953c2af..7dc0279 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "OB's Dual-Relay outlet control using a Teensy2++"
+PROJECT_NAME           = "OB's Dual-Relay Outlet Control Project"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
diff --git a/Projects/SerialToLCD/Descriptors.c b/Projects/SerialToLCD/Descriptors.c
new file mode 100644 (file)
index 0000000..ea8ce8c
--- /dev/null
@@ -0,0 +1,272 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *
+ *  USB Device Descriptors, for library use when in USB device mode. Descriptors are special
+ *  computer-readable structures which the host requests upon device enumeration, to determine
+ *  the device's capabilities and functions.
+ */
+
+#include "Descriptors.h"
+
+/* On some devices, there is a factory set internal serial number which can be automatically sent to the host as
+ * the device's serial number when the Device Descriptor's .SerialNumStrIndex entry is set to USE_INTERNAL_SERIAL.
+ * This allows the host to track a device across insertions on different ports, allowing them to retain allocated
+ * resources like COM port numbers and drivers. On demos using this feature, give a warning on unsupported devices
+ * so that the user can supply their own serial number descriptor instead or remove the USE_INTERNAL_SERIAL value
+ * from the Device Descriptor (forcing the host to generate a serial number for each device from the VID, PID and
+ * port location).
+ */
+#if (USE_INTERNAL_SERIAL == NO_DESCRIPTOR)
+       #warning USE_INTERNAL_SERIAL is not available on this AVR - please manually construct a device serial descriptor.
+#endif
+
+/** Device descriptor structure. This descriptor, located in FLASH memory, describes the overall
+ *  device characteristics, including the supported USB version, control endpoint size and the
+ *  number of device configurations. The descriptor is read out by the USB host when the enumeration
+ *  process begins.
+ */
+const USB_Descriptor_Device_t PROGMEM DeviceDescriptor =
+{
+       .Header                 = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device},
+
+       .USBSpecification       = VERSION_BCD(01.10),
+       .Class                  = CDC_CSCP_CDCClass,
+       .SubClass               = CDC_CSCP_NoSpecificSubclass,
+       .Protocol               = CDC_CSCP_NoSpecificProtocol,
+
+       .Endpoint0Size          = FIXED_CONTROL_ENDPOINT_SIZE,
+
+       .VendorID               = 0x03EB,
+       .ProductID              = 0x204B,
+       .ReleaseNumber          = VERSION_BCD(00.01),
+
+       .ManufacturerStrIndex   = 0x01,
+       .ProductStrIndex        = 0x02,
+       .SerialNumStrIndex      = USE_INTERNAL_SERIAL,
+
+       .NumberOfConfigurations = FIXED_NUM_CONFIGURATIONS
+};
+
+/** Configuration descriptor structure. This descriptor, located in FLASH memory, describes the usage
+ *  of the device in one of its supported configurations, including information about any device interfaces
+ *  and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting
+ *  a configuration so that the host may correctly communicate with the USB device.
+ */
+const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
+{
+       .Config =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Configuration_Header_t), .Type = DTYPE_Configuration},
+
+                       .TotalConfigurationSize = sizeof(USB_Descriptor_Configuration_t),
+                       .TotalInterfaces        = 2,
+
+                       .ConfigurationNumber    = 1,
+                       .ConfigurationStrIndex  = NO_DESCRIPTOR,
+
+                       .ConfigAttributes       = (USB_CONFIG_ATTR_RESERVED | USB_CONFIG_ATTR_SELFPOWERED),
+
+                       .MaxPowerConsumption    = USB_CONFIG_POWER_MA(100)
+               },
+
+       .CDC_CCI_Interface =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Interface_t), .Type = DTYPE_Interface},
+
+                       .InterfaceNumber        = 0,
+                       .AlternateSetting       = 0,
+
+                       .TotalEndpoints         = 1,
+
+                       .Class                  = CDC_CSCP_CDCClass,
+                       .SubClass               = CDC_CSCP_ACMSubclass,
+                       .Protocol               = CDC_CSCP_ATCommandProtocol,
+
+                       .InterfaceStrIndex      = NO_DESCRIPTOR
+               },
+
+       .CDC_Functional_Header =
+               {
+                       .Header                 = {.Size = sizeof(USB_CDC_Descriptor_FunctionalHeader_t), .Type = DTYPE_CSInterface},
+                       .Subtype                = CDC_DSUBTYPE_CSInterface_Header,
+
+                       .CDCSpecification       = VERSION_BCD(01.10),
+               },
+
+       .CDC_Functional_ACM =
+               {
+                       .Header                 = {.Size = sizeof(USB_CDC_Descriptor_FunctionalACM_t), .Type = DTYPE_CSInterface},
+                       .Subtype                = CDC_DSUBTYPE_CSInterface_ACM,
+
+                       .Capabilities           = 0x06,
+               },
+
+       .CDC_Functional_Union =
+               {
+                       .Header                 = {.Size = sizeof(USB_CDC_Descriptor_FunctionalUnion_t), .Type = DTYPE_CSInterface},
+                       .Subtype                = CDC_DSUBTYPE_CSInterface_Union,
+
+                       .MasterInterfaceNumber  = 0,
+                       .SlaveInterfaceNumber   = 1,
+               },
+
+       .CDC_NotificationEndpoint =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
+
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
+                       .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
+                       .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
+                       .PollingIntervalMS      = 0xFF
+               },
+
+       .CDC_DCI_Interface =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Interface_t), .Type = DTYPE_Interface},
+
+                       .InterfaceNumber        = 1,
+                       .AlternateSetting       = 0,
+
+                       .TotalEndpoints         = 2,
+
+                       .Class                  = CDC_CSCP_CDCDataClass,
+                       .SubClass               = CDC_CSCP_NoDataSubclass,
+                       .Protocol               = CDC_CSCP_NoDataProtocol,
+
+                       .InterfaceStrIndex      = NO_DESCRIPTOR
+               },
+
+       .CDC_DataOutEndpoint =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
+
+                       .EndpointAddress        = CDC_RX_EPADDR,
+                       .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
+                       .EndpointSize           = CDC_TXRX_EPSIZE,
+                       .PollingIntervalMS      = 0x05
+               },
+
+       .CDC_DataInEndpoint =
+               {
+                       .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
+
+                       .EndpointAddress        = CDC_TX_EPADDR,
+                       .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
+                       .EndpointSize           = CDC_TXRX_EPSIZE,
+                       .PollingIntervalMS      = 0x05
+               }
+};
+
+/** Language descriptor structure. This descriptor, located in FLASH memory, is returned when the host requests
+ *  the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate
+ *  via the language ID table available at USB.org what languages the device supports for its string descriptors.
+ */
+const USB_Descriptor_String_t PROGMEM LanguageString =
+{
+       .Header                 = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String},
+
+       .UnicodeString          = {LANGUAGE_ID_ENG}
+};
+
+/** Manufacturer descriptor string. This is a Unicode string containing the manufacturer's details in human readable
+ *  form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device
+ *  Descriptor.
+ */
+const USB_Descriptor_String_t PROGMEM ManufacturerString =
+{
+       .Header                 = {.Size = USB_STRING_LEN(12), .Type = DTYPE_String},
+
+       .UnicodeString          = L"Simon Foster"
+};
+
+/** Product descriptor string. This is a Unicode string containing the product's details in human readable form,
+ *  and is read out upon request by the host when the appropriate string ID is requested, listed in the Device
+ *  Descriptor.
+ */
+const USB_Descriptor_String_t PROGMEM ProductString =
+{
+       .Header                 = {.Size = USB_STRING_LEN(19), .Type = DTYPE_String},
+
+       .UnicodeString          = L"USB-HD44780 Adapter"
+};
+
+/** This function is called by the library when in device mode, and must be overridden (see library "USB Descriptors"
+ *  documentation) by the application code so that the address and size of a requested descriptor can be given
+ *  to the USB library. When the device receives a Get Descriptor request on the control endpoint, this function
+ *  is called so that the descriptor details can be passed back and the appropriate descriptor sent back to the
+ *  USB host.
+ */
+uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
+                                    const uint8_t wIndex,
+                                    const void** const DescriptorAddress)
+{
+       const uint8_t  DescriptorType   = (wValue >> 8);
+       const uint8_t  DescriptorNumber = (wValue & 0xFF);
+
+       const void* Address = NULL;
+       uint16_t    Size    = NO_DESCRIPTOR;
+
+       switch (DescriptorType)
+       {
+               case DTYPE_Device:
+                       Address = &DeviceDescriptor;
+                       Size    = sizeof(USB_Descriptor_Device_t);
+                       break;
+               case DTYPE_Configuration:
+                       Address = &ConfigurationDescriptor;
+                       Size    = sizeof(USB_Descriptor_Configuration_t);
+                       break;
+               case DTYPE_String:
+                       switch (DescriptorNumber)
+                       {
+                               case 0x00:
+                                       Address = &LanguageString;
+                                       Size    = pgm_read_byte(&LanguageString.Header.Size);
+                                       break;
+                               case 0x01:
+                                       Address = &ManufacturerString;
+                                       Size    = pgm_read_byte(&ManufacturerString.Header.Size);
+                                       break;
+                               case 0x02:
+                                       Address = &ProductString;
+                                       Size    = pgm_read_byte(&ProductString.Header.Size);
+                                       break;
+                       }
+
+                       break;
+       }
+
+       *DescriptorAddress = Address;
+       return Size;
+}
+
diff --git a/Projects/SerialToLCD/Descriptors.h b/Projects/SerialToLCD/Descriptors.h
new file mode 100644 (file)
index 0000000..5a316a2
--- /dev/null
@@ -0,0 +1,90 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *
+ *  Header file for Descriptors.c.
+ */
+
+#ifndef _DESCRIPTORS_H_
+#define _DESCRIPTORS_H_
+
+       /* Includes: */
+               #include <avr/pgmspace.h>
+
+               #include <LUFA/Drivers/USB/USB.h>
+
+       /* Macros: */
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
+
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
+
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
+
+               /** Size in bytes of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPSIZE        8
+
+               /** Size in bytes of the CDC data IN and OUT endpoints. */
+               #define CDC_TXRX_EPSIZE                16
+
+       /* Type Defines: */
+               /** Type define for the device configuration descriptor structure. This must be defined in the
+                *  application code, as the configuration descriptor contains several sub-descriptors which
+                *  vary between devices, and which describe the device's usage to the host.
+                */
+               typedef struct
+               {
+                       USB_Descriptor_Configuration_Header_t    Config;
+
+                       // CDC Command Interface
+                       USB_Descriptor_Interface_t               CDC_CCI_Interface;
+                       USB_CDC_Descriptor_FunctionalHeader_t    CDC_Functional_Header;
+                       USB_CDC_Descriptor_FunctionalACM_t       CDC_Functional_ACM;
+                       USB_CDC_Descriptor_FunctionalUnion_t     CDC_Functional_Union;
+                       USB_Descriptor_Endpoint_t                CDC_NotificationEndpoint;
+
+                       // CDC Data Interface
+                       USB_Descriptor_Interface_t               CDC_DCI_Interface;
+                       USB_Descriptor_Endpoint_t                CDC_DataOutEndpoint;
+                       USB_Descriptor_Endpoint_t                CDC_DataInEndpoint;
+               } USB_Descriptor_Configuration_t;
+
+       /* Function Prototypes: */
+               uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue,
+                                                   const uint8_t wIndex,
+                                                   const void** const DescriptorAddress)
+                                                   ATTR_WARN_UNUSED_RESULT ATTR_NON_NULL_PTR_ARG(3);
+
+#endif
+
diff --git a/Projects/SerialToLCD/Doxygen.conf b/Projects/SerialToLCD/Doxygen.conf
new file mode 100644 (file)
index 0000000..af2e82e
--- /dev/null
@@ -0,0 +1,1814 @@
+# Doxyfile 1.8.0\r
+\r
+# This file describes the settings to be used by the documentation system\r
+# doxygen (www.doxygen.org) for a project.\r
+#\r
+# All text after a hash (#) is considered a comment and will be ignored.\r
+# The format is:\r
+#       TAG = value [value, ...]\r
+# For lists items can also be appended using:\r
+#       TAG += value [value, ...]\r
+# Values that contain spaces should be placed between quotes (" ").\r
+\r
+#---------------------------------------------------------------------------\r
+# Project related configuration options\r
+#---------------------------------------------------------------------------\r
+\r
+# This tag specifies the encoding used for all characters in the config file\r
+# that follow. The default is UTF-8 which is also the encoding used for all\r
+# text before the first occurrence of this tag. Doxygen uses libiconv (or the\r
+# iconv built into libc) for the transcoding. See\r
+# http://www.gnu.org/software/libiconv for the list of possible encodings.\r
+\r
+DOXYFILE_ENCODING      = UTF-8\r
+\r
+# The PROJECT_NAME tag is a single word (or sequence of words) that should\r
+# identify the project. Note that if you do not use Doxywizard you need\r
+# to put quotes around the project name if it contains spaces.\r
+\r
+PROJECT_NAME           = "Simon Foster's USB Serial to HD44780 LCD Project"\r
+\r
+# The PROJECT_NUMBER tag can be used to enter a project or revision number.\r
+# This could be handy for archiving the generated documentation or\r
+# if some version control system is used.\r
+\r
+PROJECT_NUMBER         = 0.0.0\r
+\r
+# Using the PROJECT_BRIEF tag one can provide an optional one line description\r
+# for a project that appears at the top of each page and should give viewer\r
+# a quick idea about the purpose of the project. Keep the description short.\r
+\r
+PROJECT_BRIEF          =\r
+\r
+# With the PROJECT_LOGO tag one can specify an logo or icon that is\r
+# included in the documentation. The maximum height of the logo should not\r
+# exceed 55 pixels and the maximum width should not exceed 200 pixels.\r
+# Doxygen will copy the logo to the output directory.\r
+\r
+PROJECT_LOGO           =\r
+\r
+# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)\r
+# base path where the generated documentation will be put.\r
+# If a relative path is entered, it will be relative to the location\r
+# where doxygen was started. If left blank the current directory will be used.\r
+\r
+OUTPUT_DIRECTORY       = ./Documentation/\r
+\r
+# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create\r
+# 4096 sub-directories (in 2 levels) under the output directory of each output\r
+# format and will distribute the generated files over these directories.\r
+# Enabling this option can be useful when feeding doxygen a huge amount of\r
+# source files, where putting all generated files in the same directory would\r
+# otherwise cause performance problems for the file system.\r
+\r
+CREATE_SUBDIRS         = NO\r
+\r
+# The OUTPUT_LANGUAGE tag is used to specify the language in which all\r
+# documentation generated by doxygen is written. Doxygen will use this\r
+# information to generate all constant output in the proper language.\r
+# The default language is English, other supported languages are:\r
+# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional,\r
+# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German,\r
+# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English\r
+# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian,\r
+# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrillic, Slovak,\r
+# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese.\r
+\r
+OUTPUT_LANGUAGE        = English\r
+\r
+# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will\r
+# include brief member descriptions after the members that are listed in\r
+# the file and class documentation (similar to JavaDoc).\r
+# Set to NO to disable this.\r
+\r
+BRIEF_MEMBER_DESC      = YES\r
+\r
+# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend\r
+# the brief description of a member or function before the detailed description.\r
+# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the\r
+# brief descriptions will be completely suppressed.\r
+\r
+REPEAT_BRIEF           = YES\r
+\r
+# This tag implements a quasi-intelligent brief description abbreviator\r
+# that is used to form the text in various listings. Each string\r
+# in this list, if found as the leading text of the brief description, will be\r
+# stripped from the text and the result after processing the whole list, is\r
+# used as the annotated text. Otherwise, the brief description is used as-is.\r
+# If left blank, the following values are used ("$name" is automatically\r
+# replaced with the name of the entity): "The $name class" "The $name widget"\r
+# "The $name file" "is" "provides" "specifies" "contains"\r
+# "represents" "a" "an" "the"\r
+\r
+ABBREVIATE_BRIEF       = "The $name class" \\r
+                         "The $name widget" \\r
+                         "The $name file" \\r
+                         is \\r
+                         provides \\r
+                         specifies \\r
+                         contains \\r
+                         represents \\r
+                         a \\r
+                         an \\r
+                         the\r
+\r
+# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then\r
+# Doxygen will generate a detailed section even if there is only a brief\r
+# description.\r
+\r
+ALWAYS_DETAILED_SEC    = NO\r
+\r
+# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all\r
+# inherited members of a class in the documentation of that class as if those\r
+# members were ordinary class members. Constructors, destructors and assignment\r
+# operators of the base classes will not be shown.\r
+\r
+INLINE_INHERITED_MEMB  = NO\r
+\r
+# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full\r
+# path before files name in the file list and in the header files. If set\r
+# to NO the shortest path that makes the file name unique will be used.\r
+\r
+FULL_PATH_NAMES        = YES\r
+\r
+# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag\r
+# can be used to strip a user-defined part of the path. Stripping is\r
+# only done if one of the specified strings matches the left-hand part of\r
+# the path. The tag can be used to show relative paths in the file list.\r
+# If left blank the directory from which doxygen is run is used as the\r
+# path to strip.\r
+\r
+STRIP_FROM_PATH        =\r
+\r
+# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of\r
+# the path mentioned in the documentation of a class, which tells\r
+# the reader which header file to include in order to use a class.\r
+# If left blank only the name of the header file containing the class\r
+# definition is used. Otherwise one should specify the include paths that\r
+# are normally passed to the compiler using the -I flag.\r
+\r
+STRIP_FROM_INC_PATH    =\r
+\r
+# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter\r
+# (but less readable) file names. This can be useful if your file system\r
+# doesn't support long names like on DOS, Mac, or CD-ROM.\r
+\r
+SHORT_NAMES            = YES\r
+\r
+# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen\r
+# will interpret the first line (until the first dot) of a JavaDoc-style\r
+# comment as the brief description. If set to NO, the JavaDoc\r
+# comments will behave just like regular Qt-style comments\r
+# (thus requiring an explicit @brief command for a brief description.)\r
+\r
+JAVADOC_AUTOBRIEF      = NO\r
+\r
+# If the QT_AUTOBRIEF tag is set to YES then Doxygen will\r
+# interpret the first line (until the first dot) of a Qt-style\r
+# comment as the brief description. If set to NO, the comments\r
+# will behave just like regular Qt-style comments (thus requiring\r
+# an explicit \brief command for a brief description.)\r
+\r
+QT_AUTOBRIEF           = NO\r
+\r
+# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen\r
+# treat a multi-line C++ special comment block (i.e. a block of //! or ///\r
+# comments) as a brief description. This used to be the default behaviour.\r
+# The new default is to treat a multi-line C++ comment block as a detailed\r
+# description. Set this tag to YES if you prefer the old behaviour instead.\r
+\r
+MULTILINE_CPP_IS_BRIEF = NO\r
+\r
+# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented\r
+# member inherits the documentation from any documented member that it\r
+# re-implements.\r
+\r
+INHERIT_DOCS           = YES\r
+\r
+# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce\r
+# a new page for each member. If set to NO, the documentation of a member will\r
+# be part of the file/class/namespace that contains it.\r
+\r
+SEPARATE_MEMBER_PAGES  = NO\r
+\r
+# The TAB_SIZE tag can be used to set the number of spaces in a tab.\r
+# Doxygen uses this value to replace tabs by spaces in code fragments.\r
+\r
+TAB_SIZE               = 4\r
+\r
+# This tag can be used to specify a number of aliases that acts\r
+# as commands in the documentation. An alias has the form "name=value".\r
+# For example adding "sideeffect=\par Side Effects:\n" will allow you to\r
+# put the command \sideeffect (or @sideeffect) in the documentation, which\r
+# will result in a user-defined paragraph with heading "Side Effects:".\r
+# You can put \n's in the value part of an alias to insert newlines.\r
+\r
+ALIASES                =\r
+\r
+# This tag can be used to specify a number of word-keyword mappings (TCL only).\r
+# A mapping has the form "name=value". For example adding\r
+# "class=itcl::class" will allow you to use the command class in the\r
+# itcl::class meaning.\r
+\r
+TCL_SUBST              =\r
+\r
+# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C\r
+# sources only. Doxygen will then generate output that is more tailored for C.\r
+# For instance, some of the names that are used will be different. The list\r
+# of all members will be omitted, etc.\r
+\r
+OPTIMIZE_OUTPUT_FOR_C  = YES\r
+\r
+# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java\r
+# sources only. Doxygen will then generate output that is more tailored for\r
+# Java. For instance, namespaces will be presented as packages, qualified\r
+# scopes will look different, etc.\r
+\r
+OPTIMIZE_OUTPUT_JAVA   = NO\r
+\r
+# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran\r
+# sources only. Doxygen will then generate output that is more tailored for\r
+# Fortran.\r
+\r
+OPTIMIZE_FOR_FORTRAN   = NO\r
+\r
+# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL\r
+# sources. Doxygen will then generate output that is tailored for\r
+# VHDL.\r
+\r
+OPTIMIZE_OUTPUT_VHDL   = NO\r
+\r
+# Doxygen selects the parser to use depending on the extension of the files it\r
+# parses. With this tag you can assign which parser to use for a given extension.\r
+# Doxygen has a built-in mapping, but you can override or extend it using this\r
+# tag. The format is ext=language, where ext is a file extension, and language\r
+# is one of the parsers supported by doxygen: IDL, Java, Javascript, CSharp, C,\r
+# C++, D, PHP, Objective-C, Python, Fortran, VHDL, C, C++. For instance to make\r
+# doxygen treat .inc files as Fortran files (default is PHP), and .f files as C\r
+# (default is Fortran), use: inc=Fortran f=C. Note that for custom extensions\r
+# you also need to set FILE_PATTERNS otherwise the files are not read by doxygen.\r
+\r
+EXTENSION_MAPPING      =\r
+\r
+# If MARKDOWN_SUPPORT is enabled (the default) then doxygen pre-processes all\r
+# comments according to the Markdown format, which allows for more readable\r
+# documentation. See http://daringfireball.net/projects/markdown/ for details.\r
+# The output of markdown processing is further processed by doxygen, so you\r
+# can mix doxygen, HTML, and XML commands with Markdown formatting.\r
+# Disable only in case of backward compatibilities issues.\r
+\r
+MARKDOWN_SUPPORT       = NO\r
+\r
+# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want\r
+# to include (a tag file for) the STL sources as input, then you should\r
+# set this tag to YES in order to let doxygen match functions declarations and\r
+# definitions whose arguments contain STL classes (e.g. func(std::string); v.s.\r
+# func(std::string) {}). This also makes the inheritance and collaboration\r
+# diagrams that involve STL classes more complete and accurate.\r
+\r
+BUILTIN_STL_SUPPORT    = NO\r
+\r
+# If you use Microsoft's C++/CLI language, you should set this option to YES to\r
+# enable parsing support.\r
+\r
+CPP_CLI_SUPPORT        = NO\r
+\r
+# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only.\r
+# Doxygen will parse them like normal C++ but will assume all classes use public\r
+# instead of private inheritance when no explicit protection keyword is present.\r
+\r
+SIP_SUPPORT            = NO\r
+\r
+# For Microsoft's IDL there are propget and propput attributes to indicate getter\r
+# and setter methods for a property. Setting this option to YES (the default)\r
+# will make doxygen replace the get and set methods by a property in the\r
+# documentation. This will only work if the methods are indeed getting or\r
+# setting a simple type. If this is not the case, or you want to show the\r
+# methods anyway, you should set this option to NO.\r
+\r
+IDL_PROPERTY_SUPPORT   = YES\r
+\r
+# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC\r
+# tag is set to YES, then doxygen will reuse the documentation of the first\r
+# member in the group (if any) for the other members of the group. By default\r
+# all members of a group must be documented explicitly.\r
+\r
+DISTRIBUTE_GROUP_DOC   = NO\r
+\r
+# Set the SUBGROUPING tag to YES (the default) to allow class member groups of\r
+# the same type (for instance a group of public functions) to be put as a\r
+# subgroup of that type (e.g. under the Public Functions section). Set it to\r
+# NO to prevent subgrouping. Alternatively, this can be done per class using\r
+# the \nosubgrouping command.\r
+\r
+SUBGROUPING            = YES\r
+\r
+# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and\r
+# unions are shown inside the group in which they are included (e.g. using\r
+# @ingroup) instead of on a separate page (for HTML and Man pages) or\r
+# section (for LaTeX and RTF).\r
+\r
+INLINE_GROUPED_CLASSES = NO\r
+\r
+# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and\r
+# unions with only public data fields will be shown inline in the documentation\r
+# of the scope in which they are defined (i.e. file, namespace, or group\r
+# documentation), provided this scope is documented. If set to NO (the default),\r
+# structs, classes, and unions are shown on a separate page (for HTML and Man\r
+# pages) or section (for LaTeX and RTF).\r
+\r
+INLINE_SIMPLE_STRUCTS  = NO\r
+\r
+# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum\r
+# is documented as struct, union, or enum with the name of the typedef. So\r
+# typedef struct TypeS {} TypeT, will appear in the documentation as a struct\r
+# with name TypeT. When disabled the typedef will appear as a member of a file,\r
+# namespace, or class. And the struct will be named TypeS. This can typically\r
+# be useful for C code in case the coding convention dictates that all compound\r
+# types are typedef'ed and only the typedef is referenced, never the tag name.\r
+\r
+TYPEDEF_HIDES_STRUCT   = NO\r
+\r
+# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to\r
+# determine which symbols to keep in memory and which to flush to disk.\r
+# When the cache is full, less often used symbols will be written to disk.\r
+# For small to medium size projects (<1000 input files) the default value is\r
+# probably good enough. For larger projects a too small cache size can cause\r
+# doxygen to be busy swapping symbols to and from disk most of the time\r
+# causing a significant performance penalty.\r
+# If the system has enough physical memory increasing the cache will improve the\r
+# performance by keeping more symbols in memory. Note that the value works on\r
+# a logarithmic scale so increasing the size by one will roughly double the\r
+# memory usage. The cache size is given by this formula:\r
+# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0,\r
+# corresponding to a cache size of 2^16 = 65536 symbols.\r
+\r
+SYMBOL_CACHE_SIZE      = 0\r
+\r
+# Similar to the SYMBOL_CACHE_SIZE the size of the symbol lookup cache can be\r
+# set using LOOKUP_CACHE_SIZE. This cache is used to resolve symbols given\r
+# their name and scope. Since this can be an expensive process and often the\r
+# same symbol appear multiple times in the code, doxygen keeps a cache of\r
+# pre-resolved symbols. If the cache is too small doxygen will become slower.\r
+# If the cache is too large, memory is wasted. The cache size is given by this\r
+# formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range is 0..9, the default is 0,\r
+# corresponding to a cache size of 2^16 = 65536 symbols.\r
+\r
+LOOKUP_CACHE_SIZE      = 0\r
+\r
+#---------------------------------------------------------------------------\r
+# Build related configuration options\r
+#---------------------------------------------------------------------------\r
+\r
+# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in\r
+# documentation are documented, even if no documentation was available.\r
+# Private class members and static file members will be hidden unless\r
+# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES\r
+\r
+EXTRACT_ALL            = YES\r
+\r
+# If the EXTRACT_PRIVATE tag is set to YES all private members of a class\r
+# will be included in the documentation.\r
+\r
+EXTRACT_PRIVATE        = YES\r
+\r
+# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal scope will be included in the documentation.\r
+\r
+EXTRACT_PACKAGE        = NO\r
+\r
+# If the EXTRACT_STATIC tag is set to YES all static members of a file\r
+# will be included in the documentation.\r
+\r
+EXTRACT_STATIC         = YES\r
+\r
+# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs)\r
+# defined locally in source files will be included in the documentation.\r
+# If set to NO only classes defined in header files are included.\r
+\r
+EXTRACT_LOCAL_CLASSES  = YES\r
+\r
+# This flag is only useful for Objective-C code. When set to YES local\r
+# methods, which are defined in the implementation section but not in\r
+# the interface are included in the documentation.\r
+# If set to NO (the default) only methods in the interface are included.\r
+\r
+EXTRACT_LOCAL_METHODS  = NO\r
+\r
+# If this flag is set to YES, the members of anonymous namespaces will be\r
+# extracted and appear in the documentation as a namespace called\r
+# 'anonymous_namespace{file}', where file will be replaced with the base\r
+# name of the file that contains the anonymous namespace. By default\r
+# anonymous namespaces are hidden.\r
+\r
+EXTRACT_ANON_NSPACES   = NO\r
+\r
+# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all\r
+# undocumented members of documented classes, files or namespaces.\r
+# If set to NO (the default) these members will be included in the\r
+# various overviews, but no documentation section is generated.\r
+# This option has no effect if EXTRACT_ALL is enabled.\r
+\r
+HIDE_UNDOC_MEMBERS     = NO\r
+\r
+# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all\r
+# undocumented classes that are normally visible in the class hierarchy.\r
+# If set to NO (the default) these classes will be included in the various\r
+# overviews. This option has no effect if EXTRACT_ALL is enabled.\r
+\r
+HIDE_UNDOC_CLASSES     = NO\r
+\r
+# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all\r
+# friend (class|struct|union) declarations.\r
+# If set to NO (the default) these declarations will be included in the\r
+# documentation.\r
+\r
+HIDE_FRIEND_COMPOUNDS  = NO\r
+\r
+# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any\r
+# documentation blocks found inside the body of a function.\r
+# If set to NO (the default) these blocks will be appended to the\r
+# function's detailed documentation block.\r
+\r
+HIDE_IN_BODY_DOCS      = NO\r
+\r
+# The INTERNAL_DOCS tag determines if documentation\r
+# that is typed after a \internal command is included. If the tag is set\r
+# to NO (the default) then the documentation will be excluded.\r
+# Set it to YES to include the internal documentation.\r
+\r
+INTERNAL_DOCS          = NO\r
+\r
+# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate\r
+# file names in lower-case letters. If set to YES upper-case letters are also\r
+# allowed. This is useful if you have classes or files whose names only differ\r
+# in case and if your file system supports case sensitive file names. Windows\r
+# and Mac users are advised to set this option to NO.\r
+\r
+CASE_SENSE_NAMES       = NO\r
+\r
+# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen\r
+# will show members with their full class and namespace scopes in the\r
+# documentation. If set to YES the scope will be hidden.\r
+\r
+HIDE_SCOPE_NAMES       = NO\r
+\r
+# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen\r
+# will put a list of the files that are included by a file in the documentation\r
+# of that file.\r
+\r
+SHOW_INCLUDE_FILES     = YES\r
+\r
+# If the FORCE_LOCAL_INCLUDES tag is set to YES then Doxygen\r
+# will list include files with double quotes in the documentation\r
+# rather than with sharp brackets.\r
+\r
+FORCE_LOCAL_INCLUDES   = NO\r
+\r
+# If the INLINE_INFO tag is set to YES (the default) then a tag [inline]\r
+# is inserted in the documentation for inline members.\r
+\r
+INLINE_INFO            = YES\r
+\r
+# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen\r
+# will sort the (detailed) documentation of file and class members\r
+# alphabetically by member name. If set to NO the members will appear in\r
+# declaration order.\r
+\r
+SORT_MEMBER_DOCS       = YES\r
+\r
+# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the\r
+# brief documentation of file, namespace and class members alphabetically\r
+# by member name. If set to NO (the default) the members will appear in\r
+# declaration order.\r
+\r
+SORT_BRIEF_DOCS        = NO\r
+\r
+# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen\r
+# will sort the (brief and detailed) documentation of class members so that\r
+# constructors and destructors are listed first. If set to NO (the default)\r
+# the constructors will appear in the respective orders defined by\r
+# SORT_MEMBER_DOCS and SORT_BRIEF_DOCS.\r
+# This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO\r
+# and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO.\r
+\r
+SORT_MEMBERS_CTORS_1ST = NO\r
+\r
+# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the\r
+# hierarchy of group names into alphabetical order. If set to NO (the default)\r
+# the group names will appear in their defined order.\r
+\r
+SORT_GROUP_NAMES       = NO\r
+\r
+# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be\r
+# sorted by fully-qualified names, including namespaces. If set to\r
+# NO (the default), the class list will be sorted only by class name,\r
+# not including the namespace part.\r
+# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES.\r
+# Note: This option applies only to the class list, not to the\r
+# alphabetical list.\r
+\r
+SORT_BY_SCOPE_NAME     = NO\r
+\r
+# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to\r
+# do proper type resolution of all parameters of a function it will reject a\r
+# match between the prototype and the implementation of a member function even\r
+# if there is only one candidate or it is obvious which candidate to choose\r
+# by doing a simple string match. By disabling STRICT_PROTO_MATCHING doxygen\r
+# will still accept a match between prototype and implementation in such cases.\r
+\r
+STRICT_PROTO_MATCHING  = NO\r
+\r
+# The GENERATE_TODOLIST tag can be used to enable (YES) or\r
+# disable (NO) the todo list. This list is created by putting \todo\r
+# commands in the documentation.\r
+\r
+GENERATE_TODOLIST      = NO\r
+\r
+# The GENERATE_TESTLIST tag can be used to enable (YES) or\r
+# disable (NO) the test list. This list is created by putting \test\r
+# commands in the documentation.\r
+\r
+GENERATE_TESTLIST      = NO\r
+\r
+# The GENERATE_BUGLIST tag can be used to enable (YES) or\r
+# disable (NO) the bug list. This list is created by putting \bug\r
+# commands in the documentation.\r
+\r
+GENERATE_BUGLIST       = NO\r
+\r
+# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or\r
+# disable (NO) the deprecated list. This list is created by putting\r
+# \deprecated commands in the documentation.\r
+\r
+GENERATE_DEPRECATEDLIST= YES\r
+\r
+# The ENABLED_SECTIONS tag can be used to enable conditional\r
+# documentation sections, marked by \if sectionname ... \endif.\r
+\r
+ENABLED_SECTIONS       =\r
+\r
+# The MAX_INITIALIZER_LINES tag determines the maximum number of lines\r
+# the initial value of a variable or macro consists of for it to appear in\r
+# the documentation. If the initializer consists of more lines than specified\r
+# here it will be hidden. Use a value of 0 to hide initializers completely.\r
+# The appearance of the initializer of individual variables and macros in the\r
+# documentation can be controlled using \showinitializer or \hideinitializer\r
+# command in the documentation regardless of this setting.\r
+\r
+MAX_INITIALIZER_LINES  = 30\r
+\r
+# Set the SHOW_USED_FILES tag to NO to disable the list of files generated\r
+# at the bottom of the documentation of classes and structs. If set to YES the\r
+# list will mention the files that were used to generate the documentation.\r
+\r
+SHOW_USED_FILES        = YES\r
+\r
+# If the sources in your project are distributed over multiple directories\r
+# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy\r
+# in the documentation. The default is NO.\r
+\r
+SHOW_DIRECTORIES       = YES\r
+\r
+# Set the SHOW_FILES tag to NO to disable the generation of the Files page.\r
+# This will remove the Files entry from the Quick Index and from the\r
+# Folder Tree View (if specified). The default is YES.\r
+\r
+SHOW_FILES             = YES\r
+\r
+# Set the SHOW_NAMESPACES tag to NO to disable the generation of the\r
+# Namespaces page.\r
+# This will remove the Namespaces entry from the Quick Index\r
+# and from the Folder Tree View (if specified). The default is YES.\r
+\r
+SHOW_NAMESPACES        = YES\r
+\r
+# The FILE_VERSION_FILTER tag can be used to specify a program or script that\r
+# doxygen should invoke to get the current version for each file (typically from\r
+# the version control system). Doxygen will invoke the program by executing (via\r
+# popen()) the command <command> <input-file>, where <command> is the value of\r
+# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file\r
+# provided by doxygen. Whatever the program writes to standard output\r
+# is used as the file version. See the manual for examples.\r
+\r
+FILE_VERSION_FILTER    =\r
+\r
+# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed\r
+# by doxygen. The layout file controls the global structure of the generated\r
+# output files in an output format independent way. The create the layout file\r
+# that represents doxygen's defaults, run doxygen with the -l option.\r
+# You can optionally specify a file name after the option, if omitted\r
+# DoxygenLayout.xml will be used as the name of the layout file.\r
+\r
+LAYOUT_FILE            =\r
+\r
+# The CITE_BIB_FILES tag can be used to specify one or more bib files\r
+# containing the references data. This must be a list of .bib files. The\r
+# .bib extension is automatically appended if omitted. Using this command\r
+# requires the bibtex tool to be installed. See also\r
+# http://en.wikipedia.org/wiki/BibTeX for more info. For LaTeX the style\r
+# of the bibliography can be controlled using LATEX_BIB_STYLE. To use this\r
+# feature you need bibtex and perl available in the search path.\r
+\r
+CITE_BIB_FILES         =\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to warning and progress messages\r
+#---------------------------------------------------------------------------\r
+\r
+# The QUIET tag can be used to turn on/off the messages that are generated\r
+# by doxygen. Possible values are YES and NO. If left blank NO is used.\r
+\r
+QUIET                  = YES\r
+\r
+# The WARNINGS tag can be used to turn on/off the warning messages that are\r
+# generated by doxygen. Possible values are YES and NO. If left blank\r
+# NO is used.\r
+\r
+WARNINGS               = YES\r
+\r
+# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings\r
+# for undocumented members. If EXTRACT_ALL is set to YES then this flag will\r
+# automatically be disabled.\r
+\r
+WARN_IF_UNDOCUMENTED   = YES\r
+\r
+# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for\r
+# potential errors in the documentation, such as not documenting some\r
+# parameters in a documented function, or documenting parameters that\r
+# don't exist or using markup commands wrongly.\r
+\r
+WARN_IF_DOC_ERROR      = YES\r
+\r
+# The WARN_NO_PARAMDOC option can be enabled to get warnings for\r
+# functions that are documented, but have no documentation for their parameters\r
+# or return value. If set to NO (the default) doxygen will only warn about\r
+# wrong or incomplete parameter documentation, but not about the absence of\r
+# documentation.\r
+\r
+WARN_NO_PARAMDOC       = YES\r
+\r
+# The WARN_FORMAT tag determines the format of the warning messages that\r
+# doxygen can produce. The string should contain the $file, $line, and $text\r
+# tags, which will be replaced by the file and line number from which the\r
+# warning originated and the warning text. Optionally the format may contain\r
+# $version, which will be replaced by the version of the file (if it could\r
+# be obtained via FILE_VERSION_FILTER)\r
+\r
+WARN_FORMAT            = "$file:$line: $text"\r
+\r
+# The WARN_LOGFILE tag can be used to specify a file to which warning\r
+# and error messages should be written. If left blank the output is written\r
+# to stderr.\r
+\r
+WARN_LOGFILE           =\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the input files\r
+#---------------------------------------------------------------------------\r
+\r
+# The INPUT tag can be used to specify the files and/or directories that contain\r
+# documented source files. You may enter file names like "myfile.cpp" or\r
+# directories like "/usr/src/myproject". Separate the files or directories\r
+# with spaces.\r
+\r
+INPUT                  = ./\r
+\r
+# This tag can be used to specify the character encoding of the source files\r
+# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is\r
+# also the default input encoding. Doxygen uses libiconv (or the iconv built\r
+# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for\r
+# the list of possible encodings.\r
+\r
+INPUT_ENCODING         = UTF-8\r
+\r
+# If the value of the INPUT tag contains directories, you can use the\r
+# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp\r
+# and *.h) to filter out the source-files in the directories. If left\r
+# blank the following patterns are tested:\r
+# *.c *.cc *.cxx *.cpp *.c++ *.d *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh\r
+# *.hxx *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.dox *.py\r
+# *.f90 *.f *.for *.vhd *.vhdl\r
+\r
+FILE_PATTERNS          = *.h \\r
+                         *.c \\r
+                         *.txt\r
+\r
+# The RECURSIVE tag can be used to turn specify whether or not subdirectories\r
+# should be searched for input files as well. Possible values are YES and NO.\r
+# If left blank NO is used.\r
+\r
+RECURSIVE              = YES\r
+\r
+# The EXCLUDE tag can be used to specify files and/or directories that should be\r
+# excluded from the INPUT source files. This way you can easily exclude a\r
+# subdirectory from a directory tree whose root is specified with the INPUT tag.\r
+# Note that relative paths are relative to the directory from which doxygen is\r
+# run.\r
+\r
+EXCLUDE                = Documentation/\r
+\r
+# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or\r
+# directories that are symbolic links (a Unix file system feature) are excluded\r
+# from the input.\r
+\r
+EXCLUDE_SYMLINKS       = NO\r
+\r
+# If the value of the INPUT tag contains directories, you can use the\r
+# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude\r
+# certain files from those directories. Note that the wildcards are matched\r
+# against the file with absolute path, so to exclude all test directories\r
+# for example use the pattern */test/*\r
+\r
+EXCLUDE_PATTERNS       =\r
+\r
+# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names\r
+# (namespaces, classes, functions, etc.) that should be excluded from the\r
+# output. The symbol name can be a fully qualified name, a word, or if the\r
+# wildcard * is used, a substring. Examples: ANamespace, AClass,\r
+# AClass::ANamespace, ANamespace::*Test\r
+\r
+EXCLUDE_SYMBOLS        = __* \\r
+                         INCLUDE_FROM_*\r
+\r
+# The EXAMPLE_PATH tag can be used to specify one or more files or\r
+# directories that contain example code fragments that are included (see\r
+# the \include command).\r
+\r
+EXAMPLE_PATH           =\r
+\r
+# If the value of the EXAMPLE_PATH tag contains directories, you can use the\r
+# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp\r
+# and *.h) to filter out the source-files in the directories. If left\r
+# blank all files are included.\r
+\r
+EXAMPLE_PATTERNS       = *\r
+\r
+# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be\r
+# searched for input files to be used with the \include or \dontinclude\r
+# commands irrespective of the value of the RECURSIVE tag.\r
+# Possible values are YES and NO. If left blank NO is used.\r
+\r
+EXAMPLE_RECURSIVE      = NO\r
+\r
+# The IMAGE_PATH tag can be used to specify one or more files or\r
+# directories that contain image that are included in the documentation (see\r
+# the \image command).\r
+\r
+IMAGE_PATH             =\r
+\r
+# The INPUT_FILTER tag can be used to specify a program that doxygen should\r
+# invoke to filter for each input file. Doxygen will invoke the filter program\r
+# by executing (via popen()) the command <filter> <input-file>, where <filter>\r
+# is the value of the INPUT_FILTER tag, and <input-file> is the name of an\r
+# input file. Doxygen will then use the output that the filter program writes\r
+# to standard output.\r
+# If FILTER_PATTERNS is specified, this tag will be\r
+# ignored.\r
+\r
+INPUT_FILTER           =\r
+\r
+# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern\r
+# basis.\r
+# Doxygen will compare the file name with each pattern and apply the\r
+# filter if there is a match.\r
+# The filters are a list of the form:\r
+# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further\r
+# info on how filters are used. If FILTER_PATTERNS is empty or if\r
+# non of the patterns match the file name, INPUT_FILTER is applied.\r
+\r
+FILTER_PATTERNS        =\r
+\r
+# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using\r
+# INPUT_FILTER) will be used to filter the input files when producing source\r
+# files to browse (i.e. when SOURCE_BROWSER is set to YES).\r
+\r
+FILTER_SOURCE_FILES    = NO\r
+\r
+# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file\r
+# pattern. A pattern will override the setting for FILTER_PATTERN (if any)\r
+# and it is also possible to disable source filtering for a specific pattern\r
+# using *.ext= (so without naming a filter). This option only has effect when\r
+# FILTER_SOURCE_FILES is enabled.\r
+\r
+FILTER_SOURCE_PATTERNS =\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to source browsing\r
+#---------------------------------------------------------------------------\r
+\r
+# If the SOURCE_BROWSER tag is set to YES then a list of source files will\r
+# be generated. Documented entities will be cross-referenced with these sources.\r
+# Note: To get rid of all source code in the generated output, make sure also\r
+# VERBATIM_HEADERS is set to NO.\r
+\r
+SOURCE_BROWSER         = NO\r
+\r
+# Setting the INLINE_SOURCES tag to YES will include the body\r
+# of functions and classes directly in the documentation.\r
+\r
+INLINE_SOURCES         = NO\r
+\r
+# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct\r
+# doxygen to hide any special comment blocks from generated source code\r
+# fragments. Normal C and C++ comments will always remain visible.\r
+\r
+STRIP_CODE_COMMENTS    = YES\r
+\r
+# If the REFERENCED_BY_RELATION tag is set to YES\r
+# then for each documented function all documented\r
+# functions referencing it will be listed.\r
+\r
+REFERENCED_BY_RELATION = NO\r
+\r
+# If the REFERENCES_RELATION tag is set to YES\r
+# then for each documented function all documented entities\r
+# called/used by that function will be listed.\r
+\r
+REFERENCES_RELATION    = NO\r
+\r
+# If the REFERENCES_LINK_SOURCE tag is set to YES (the default)\r
+# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from\r
+# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will\r
+# link to the source code.\r
+# Otherwise they will link to the documentation.\r
+\r
+REFERENCES_LINK_SOURCE = NO\r
+\r
+# If the USE_HTAGS tag is set to YES then the references to source code\r
+# will point to the HTML generated by the htags(1) tool instead of doxygen\r
+# built-in source browser. The htags tool is part of GNU's global source\r
+# tagging system (see http://www.gnu.org/software/global/global.html). You\r
+# will need version 4.8.6 or higher.\r
+\r
+USE_HTAGS              = NO\r
+\r
+# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen\r
+# will generate a verbatim copy of the header file for each class for\r
+# which an include is specified. Set to NO to disable this.\r
+\r
+VERBATIM_HEADERS       = NO\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the alphabetical class index\r
+#---------------------------------------------------------------------------\r
+\r
+# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index\r
+# of all compounds will be generated. Enable this if the project\r
+# contains a lot of classes, structs, unions or interfaces.\r
+\r
+ALPHABETICAL_INDEX     = YES\r
+\r
+# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then\r
+# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns\r
+# in which this list will be split (can be a number in the range [1..20])\r
+\r
+COLS_IN_ALPHA_INDEX    = 5\r
+\r
+# In case all classes in a project start with a common prefix, all\r
+# classes will be put under the same header in the alphabetical index.\r
+# The IGNORE_PREFIX tag can be used to specify one or more prefixes that\r
+# should be ignored while generating the index headers.\r
+\r
+IGNORE_PREFIX          =\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the HTML output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_HTML tag is set to YES (the default) Doxygen will\r
+# generate HTML output.\r
+\r
+GENERATE_HTML          = YES\r
+\r
+# The HTML_OUTPUT tag is used to specify where the HTML docs will be put.\r
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be\r
+# put in front of it. If left blank `html' will be used as the default path.\r
+\r
+HTML_OUTPUT            = html\r
+\r
+# The HTML_FILE_EXTENSION tag can be used to specify the file extension for\r
+# each generated HTML page (for example: .htm,.php,.asp). If it is left blank\r
+# doxygen will generate files with .html extension.\r
+\r
+HTML_FILE_EXTENSION    = .html\r
+\r
+# The HTML_HEADER tag can be used to specify a personal HTML header for\r
+# each generated HTML page. If it is left blank doxygen will generate a\r
+# standard header. Note that when using a custom header you are responsible\r
+#  for the proper inclusion of any scripts and style sheets that doxygen\r
+# needs, which is dependent on the configuration options used.\r
+# It is advised to generate a default header using "doxygen -w html\r
+# header.html footer.html stylesheet.css YourConfigFile" and then modify\r
+# that header. Note that the header is subject to change so you typically\r
+# have to redo this when upgrading to a newer version of doxygen or when\r
+# changing the value of configuration settings such as GENERATE_TREEVIEW!\r
+\r
+HTML_HEADER            =\r
+\r
+# The HTML_FOOTER tag can be used to specify a personal HTML footer for\r
+# each generated HTML page. If it is left blank doxygen will generate a\r
+# standard footer.\r
+\r
+HTML_FOOTER            =\r
+\r
+# The HTML_STYLESHEET tag can be used to specify a user-defined cascading\r
+# style sheet that is used by each HTML page. It can be used to\r
+# fine-tune the look of the HTML output. If the tag is left blank doxygen\r
+# will generate a default style sheet. Note that doxygen will try to copy\r
+# the style sheet file to the HTML output directory, so don't put your own\r
+# style sheet in the HTML output directory as well, or it will be erased!\r
+\r
+HTML_STYLESHEET        =\r
+\r
+# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or\r
+# other source files which should be copied to the HTML output directory. Note\r
+# that these files will be copied to the base HTML output directory. Use the\r
+# $relpath$ marker in the HTML_HEADER and/or HTML_FOOTER files to load these\r
+# files. In the HTML_STYLESHEET file, use the file name only. Also note that\r
+# the files will be copied as-is; there are no commands or markers available.\r
+\r
+HTML_EXTRA_FILES       =\r
+\r
+# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output.\r
+# Doxygen will adjust the colors in the style sheet and background images\r
+# according to this color. Hue is specified as an angle on a colorwheel,\r
+# see http://en.wikipedia.org/wiki/Hue for more information.\r
+# For instance the value 0 represents red, 60 is yellow, 120 is green,\r
+# 180 is cyan, 240 is blue, 300 purple, and 360 is red again.\r
+# The allowed range is 0 to 359.\r
+\r
+HTML_COLORSTYLE_HUE    = 220\r
+\r
+# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of\r
+# the colors in the HTML output. For a value of 0 the output will use\r
+# grayscales only. A value of 255 will produce the most vivid colors.\r
+\r
+HTML_COLORSTYLE_SAT    = 100\r
+\r
+# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to\r
+# the luminance component of the colors in the HTML output. Values below\r
+# 100 gradually make the output lighter, whereas values above 100 make\r
+# the output darker. The value divided by 100 is the actual gamma applied,\r
+# so 80 represents a gamma of 0.8, The value 220 represents a gamma of 2.2,\r
+# and 100 does not change the gamma.\r
+\r
+HTML_COLORSTYLE_GAMMA  = 80\r
+\r
+# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML\r
+# page will contain the date and time when the page was generated. Setting\r
+# this to NO can help when comparing the output of multiple runs.\r
+\r
+HTML_TIMESTAMP         = NO\r
+\r
+# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes,\r
+# files or namespaces will be aligned in HTML using tables. If set to\r
+# NO a bullet list will be used.\r
+\r
+HTML_ALIGN_MEMBERS     = YES\r
+\r
+# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML\r
+# documentation will contain sections that can be hidden and shown after the\r
+# page has loaded. For this to work a browser that supports\r
+# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox\r
+# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari).\r
+\r
+HTML_DYNAMIC_SECTIONS  = YES\r
+\r
+# If the GENERATE_DOCSET tag is set to YES, additional index files\r
+# will be generated that can be used as input for Apple's Xcode 3\r
+# integrated development environment, introduced with OSX 10.5 (Leopard).\r
+# To create a documentation set, doxygen will generate a Makefile in the\r
+# HTML output directory. Running make will produce the docset in that\r
+# directory and running "make install" will install the docset in\r
+# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find\r
+# it at startup.\r
+# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html\r
+# for more information.\r
+\r
+GENERATE_DOCSET        = NO\r
+\r
+# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the\r
+# feed. A documentation feed provides an umbrella under which multiple\r
+# documentation sets from a single provider (such as a company or product suite)\r
+# can be grouped.\r
+\r
+DOCSET_FEEDNAME        = "Doxygen generated docs"\r
+\r
+# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that\r
+# should uniquely identify the documentation set bundle. This should be a\r
+# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen\r
+# will append .docset to the name.\r
+\r
+DOCSET_BUNDLE_ID       = org.doxygen.Project\r
+\r
+# When GENERATE_PUBLISHER_ID tag specifies a string that should uniquely identify\r
+# the documentation publisher. This should be a reverse domain-name style\r
+# string, e.g. com.mycompany.MyDocSet.documentation.\r
+\r
+DOCSET_PUBLISHER_ID    = org.doxygen.Publisher\r
+\r
+# The GENERATE_PUBLISHER_NAME tag identifies the documentation publisher.\r
+\r
+DOCSET_PUBLISHER_NAME  = Publisher\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, additional index files\r
+# will be generated that can be used as input for tools like the\r
+# Microsoft HTML help workshop to generate a compiled HTML help file (.chm)\r
+# of the generated HTML documentation.\r
+\r
+GENERATE_HTMLHELP      = NO\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can\r
+# be used to specify the file name of the resulting .chm file. You\r
+# can add a path in front of the file if the result should not be\r
+# written to the html output directory.\r
+\r
+CHM_FILE               =\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can\r
+# be used to specify the location (absolute path including file name) of\r
+# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run\r
+# the HTML help compiler on the generated index.hhp.\r
+\r
+HHC_LOCATION           =\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag\r
+# controls if a separate .chi index file is generated (YES) or that\r
+# it should be included in the master .chm file (NO).\r
+\r
+GENERATE_CHI           = NO\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING\r
+# is used to encode HtmlHelp index (hhk), content (hhc) and project file\r
+# content.\r
+\r
+CHM_INDEX_ENCODING     =\r
+\r
+# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag\r
+# controls whether a binary table of contents is generated (YES) or a\r
+# normal table of contents (NO) in the .chm file.\r
+\r
+BINARY_TOC             = NO\r
+\r
+# The TOC_EXPAND flag can be set to YES to add extra items for group members\r
+# to the contents of the HTML help documentation and to the tree view.\r
+\r
+TOC_EXPAND             = YES\r
+\r
+# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and\r
+# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated\r
+# that can be used as input for Qt's qhelpgenerator to generate a\r
+# Qt Compressed Help (.qch) of the generated HTML documentation.\r
+\r
+GENERATE_QHP           = NO\r
+\r
+# If the QHG_LOCATION tag is specified, the QCH_FILE tag can\r
+# be used to specify the file name of the resulting .qch file.\r
+# The path specified is relative to the HTML output folder.\r
+\r
+QCH_FILE               =\r
+\r
+# The QHP_NAMESPACE tag specifies the namespace to use when generating\r
+# Qt Help Project output. For more information please see\r
+# http://doc.trolltech.com/qthelpproject.html#namespace\r
+\r
+QHP_NAMESPACE          = org.doxygen.Project\r
+\r
+# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating\r
+# Qt Help Project output. For more information please see\r
+# http://doc.trolltech.com/qthelpproject.html#virtual-folders\r
+\r
+QHP_VIRTUAL_FOLDER     = doc\r
+\r
+# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to\r
+# add. For more information please see\r
+# http://doc.trolltech.com/qthelpproject.html#custom-filters\r
+\r
+QHP_CUST_FILTER_NAME   =\r
+\r
+# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the\r
+# custom filter to add. For more information please see\r
+# <a href="http://doc.trolltech.com/qthelpproject.html#custom-filters">\r
+# Qt Help Project / Custom Filters</a>.\r
+\r
+QHP_CUST_FILTER_ATTRS  =\r
+\r
+# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this\r
+# project's\r
+# filter section matches.\r
+# <a href="http://doc.trolltech.com/qthelpproject.html#filter-attributes">\r
+# Qt Help Project / Filter Attributes</a>.\r
+\r
+QHP_SECT_FILTER_ATTRS  =\r
+\r
+# If the GENERATE_QHP tag is set to YES, the QHG_LOCATION tag can\r
+# be used to specify the location of Qt's qhelpgenerator.\r
+# If non-empty doxygen will try to run qhelpgenerator on the generated\r
+# .qhp file.\r
+\r
+QHG_LOCATION           =\r
+\r
+# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files\r
+#  will be generated, which together with the HTML files, form an Eclipse help\r
+# plugin. To install this plugin and make it available under the help contents\r
+# menu in Eclipse, the contents of the directory containing the HTML and XML\r
+# files needs to be copied into the plugins directory of eclipse. The name of\r
+# the directory within the plugins directory should be the same as\r
+# the ECLIPSE_DOC_ID value. After copying Eclipse needs to be restarted before\r
+# the help appears.\r
+\r
+GENERATE_ECLIPSEHELP   = NO\r
+\r
+# A unique identifier for the eclipse help plugin. When installing the plugin\r
+# the directory name containing the HTML and XML files should also have\r
+# this name.\r
+\r
+ECLIPSE_DOC_ID         = org.doxygen.Project\r
+\r
+# The DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs)\r
+# at top of each HTML page. The value NO (the default) enables the index and\r
+# the value YES disables it. Since the tabs have the same information as the\r
+# navigation tree you can set this option to NO if you already set\r
+# GENERATE_TREEVIEW to YES.\r
+\r
+DISABLE_INDEX          = NO\r
+\r
+# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index\r
+# structure should be generated to display hierarchical information.\r
+# If the tag value is set to YES, a side panel will be generated\r
+# containing a tree-like index structure (just like the one that\r
+# is generated for HTML Help). For this to work a browser that supports\r
+# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser).\r
+# Windows users are probably better off using the HTML help feature.\r
+# Since the tree basically has the same information as the tab index you\r
+# could consider to set DISABLE_INDEX to NO when enabling this option.\r
+\r
+GENERATE_TREEVIEW      = YES\r
+\r
+# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values\r
+# (range [0,1..20]) that doxygen will group on one line in the generated HTML\r
+# documentation. Note that a value of 0 will completely suppress the enum\r
+# values from appearing in the overview section.\r
+\r
+ENUM_VALUES_PER_LINE   = 1\r
+\r
+# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories,\r
+# and Class Hierarchy pages using a tree view instead of an ordered list.\r
+\r
+USE_INLINE_TREES       = NO\r
+\r
+# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be\r
+# used to set the initial width (in pixels) of the frame in which the tree\r
+# is shown.\r
+\r
+TREEVIEW_WIDTH         = 250\r
+\r
+# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open\r
+# links to external symbols imported via tag files in a separate window.\r
+\r
+EXT_LINKS_IN_WINDOW    = NO\r
+\r
+# Use this tag to change the font size of Latex formulas included\r
+# as images in the HTML documentation. The default is 10. Note that\r
+# when you change the font size after a successful doxygen run you need\r
+# to manually remove any form_*.png images from the HTML output directory\r
+# to force them to be regenerated.\r
+\r
+FORMULA_FONTSIZE       = 10\r
+\r
+# Use the FORMULA_TRANPARENT tag to determine whether or not the images\r
+# generated for formulas are transparent PNGs. Transparent PNGs are\r
+# not supported properly for IE 6.0, but are supported on all modern browsers.\r
+# Note that when changing this option you need to delete any form_*.png files\r
+# in the HTML output before the changes have effect.\r
+\r
+FORMULA_TRANSPARENT    = YES\r
+\r
+# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax\r
+# (see http://www.mathjax.org) which uses client side Javascript for the\r
+# rendering instead of using prerendered bitmaps. Use this if you do not\r
+# have LaTeX installed or if you want to formulas look prettier in the HTML\r
+# output. When enabled you may also need to install MathJax separately and\r
+# configure the path to it using the MATHJAX_RELPATH option.\r
+\r
+USE_MATHJAX            = NO\r
+\r
+# When MathJax is enabled you need to specify the location relative to the\r
+# HTML output directory using the MATHJAX_RELPATH option. The destination\r
+# directory should contain the MathJax.js script. For instance, if the mathjax\r
+# directory is located at the same level as the HTML output directory, then\r
+# MATHJAX_RELPATH should be ../mathjax. The default value points to\r
+# the MathJax Content Delivery Network so you can quickly see the result without\r
+# installing MathJax.\r
+# However, it is strongly recommended to install a local\r
+# copy of MathJax from http://www.mathjax.org before deployment.\r
+\r
+MATHJAX_RELPATH        = http://cdn.mathjax.org/mathjax/latest\r
+\r
+# The MATHJAX_EXTENSIONS tag can be used to specify one or MathJax extension\r
+# names that should be enabled during MathJax rendering.\r
+\r
+MATHJAX_EXTENSIONS     =\r
+\r
+# When the SEARCHENGINE tag is enabled doxygen will generate a search box\r
+# for the HTML output. The underlying search engine uses javascript\r
+# and DHTML and should work on any modern browser. Note that when using\r
+# HTML help (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets\r
+# (GENERATE_DOCSET) there is already a search function so this one should\r
+# typically be disabled. For large projects the javascript based search engine\r
+# can be slow, then enabling SERVER_BASED_SEARCH may provide a better solution.\r
+\r
+SEARCHENGINE           = NO\r
+\r
+# When the SERVER_BASED_SEARCH tag is enabled the search engine will be\r
+# implemented using a PHP enabled web server instead of at the web client\r
+# using Javascript. Doxygen will generate the search PHP script and index\r
+# file to put on the web server. The advantage of the server\r
+# based approach is that it scales better to large projects and allows\r
+# full text search. The disadvantages are that it is more difficult to setup\r
+# and does not have live searching capabilities.\r
+\r
+SERVER_BASED_SEARCH    = NO\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the LaTeX output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will\r
+# generate Latex output.\r
+\r
+GENERATE_LATEX         = NO\r
+\r
+# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.\r
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be\r
+# put in front of it. If left blank `latex' will be used as the default path.\r
+\r
+LATEX_OUTPUT           = latex\r
+\r
+# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be\r
+# invoked. If left blank `latex' will be used as the default command name.\r
+# Note that when enabling USE_PDFLATEX this option is only used for\r
+# generating bitmaps for formulas in the HTML output, but not in the\r
+# Makefile that is written to the output directory.\r
+\r
+LATEX_CMD_NAME         = latex\r
+\r
+# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to\r
+# generate index for LaTeX. If left blank `makeindex' will be used as the\r
+# default command name.\r
+\r
+MAKEINDEX_CMD_NAME     = makeindex\r
+\r
+# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact\r
+# LaTeX documents. This may be useful for small projects and may help to\r
+# save some trees in general.\r
+\r
+COMPACT_LATEX          = NO\r
+\r
+# The PAPER_TYPE tag can be used to set the paper type that is used\r
+# by the printer. Possible values are: a4, letter, legal and\r
+# executive. If left blank a4wide will be used.\r
+\r
+PAPER_TYPE             = a4wide\r
+\r
+# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX\r
+# packages that should be included in the LaTeX output.\r
+\r
+EXTRA_PACKAGES         =\r
+\r
+# The LATEX_HEADER tag can be used to specify a personal LaTeX header for\r
+# the generated latex document. The header should contain everything until\r
+# the first chapter. If it is left blank doxygen will generate a\r
+# standard header. Notice: only use this tag if you know what you are doing!\r
+\r
+LATEX_HEADER           =\r
+\r
+# The LATEX_FOOTER tag can be used to specify a personal LaTeX footer for\r
+# the generated latex document. The footer should contain everything after\r
+# the last chapter. If it is left blank doxygen will generate a\r
+# standard footer. Notice: only use this tag if you know what you are doing!\r
+\r
+LATEX_FOOTER           =\r
+\r
+# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated\r
+# is prepared for conversion to pdf (using ps2pdf). The pdf file will\r
+# contain links (just like the HTML output) instead of page references\r
+# This makes the output suitable for online browsing using a pdf viewer.\r
+\r
+PDF_HYPERLINKS         = YES\r
+\r
+# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of\r
+# plain latex in the generated Makefile. Set this option to YES to get a\r
+# higher quality PDF documentation.\r
+\r
+USE_PDFLATEX           = YES\r
+\r
+# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode.\r
+# command to the generated LaTeX files. This will instruct LaTeX to keep\r
+# running if errors occur, instead of asking the user for help.\r
+# This option is also used when generating formulas in HTML.\r
+\r
+LATEX_BATCHMODE        = NO\r
+\r
+# If LATEX_HIDE_INDICES is set to YES then doxygen will not\r
+# include the index chapters (such as File Index, Compound Index, etc.)\r
+# in the output.\r
+\r
+LATEX_HIDE_INDICES     = NO\r
+\r
+# If LATEX_SOURCE_CODE is set to YES then doxygen will include\r
+# source code with syntax highlighting in the LaTeX output.\r
+# Note that which sources are shown also depends on other settings\r
+# such as SOURCE_BROWSER.\r
+\r
+LATEX_SOURCE_CODE      = NO\r
+\r
+# The LATEX_BIB_STYLE tag can be used to specify the style to use for the\r
+# bibliography, e.g. plainnat, or ieeetr. The default style is "plain". See\r
+# http://en.wikipedia.org/wiki/BibTeX for more info.\r
+\r
+LATEX_BIB_STYLE        = plain\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the RTF output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output\r
+# The RTF output is optimized for Word 97 and may not look very pretty with\r
+# other RTF readers or editors.\r
+\r
+GENERATE_RTF           = NO\r
+\r
+# The RTF_OUTPUT tag is used to specify where the RTF docs will be put.\r
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be\r
+# put in front of it. If left blank `rtf' will be used as the default path.\r
+\r
+RTF_OUTPUT             = rtf\r
+\r
+# If the COMPACT_RTF tag is set to YES Doxygen generates more compact\r
+# RTF documents. This may be useful for small projects and may help to\r
+# save some trees in general.\r
+\r
+COMPACT_RTF            = NO\r
+\r
+# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated\r
+# will contain hyperlink fields. The RTF file will\r
+# contain links (just like the HTML output) instead of page references.\r
+# This makes the output suitable for online browsing using WORD or other\r
+# programs which support those fields.\r
+# Note: wordpad (write) and others do not support links.\r
+\r
+RTF_HYPERLINKS         = NO\r
+\r
+# Load style sheet definitions from file. Syntax is similar to doxygen's\r
+# config file, i.e. a series of assignments. You only have to provide\r
+# replacements, missing definitions are set to their default value.\r
+\r
+RTF_STYLESHEET_FILE    =\r
+\r
+# Set optional variables used in the generation of an rtf document.\r
+# Syntax is similar to doxygen's config file.\r
+\r
+RTF_EXTENSIONS_FILE    =\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the man page output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_MAN tag is set to YES (the default) Doxygen will\r
+# generate man pages\r
+\r
+GENERATE_MAN           = NO\r
+\r
+# The MAN_OUTPUT tag is used to specify where the man pages will be put.\r
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be\r
+# put in front of it. If left blank `man' will be used as the default path.\r
+\r
+MAN_OUTPUT             = man\r
+\r
+# The MAN_EXTENSION tag determines the extension that is added to\r
+# the generated man pages (default is the subroutine's section .3)\r
+\r
+MAN_EXTENSION          = .3\r
+\r
+# If the MAN_LINKS tag is set to YES and Doxygen generates man output,\r
+# then it will generate one additional man file for each entity\r
+# documented in the real man page(s). These additional files\r
+# only source the real man page, but without them the man command\r
+# would be unable to find the correct page. The default is NO.\r
+\r
+MAN_LINKS              = NO\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the XML output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_XML tag is set to YES Doxygen will\r
+# generate an XML file that captures the structure of\r
+# the code including all documentation.\r
+\r
+GENERATE_XML           = NO\r
+\r
+# The XML_OUTPUT tag is used to specify where the XML pages will be put.\r
+# If a relative path is entered the value of OUTPUT_DIRECTORY will be\r
+# put in front of it. If left blank `xml' will be used as the default path.\r
+\r
+XML_OUTPUT             = xml\r
+\r
+# The XML_SCHEMA tag can be used to specify an XML schema,\r
+# which can be used by a validating XML parser to check the\r
+# syntax of the XML files.\r
+\r
+XML_SCHEMA             =\r
+\r
+# The XML_DTD tag can be used to specify an XML DTD,\r
+# which can be used by a validating XML parser to check the\r
+# syntax of the XML files.\r
+\r
+XML_DTD                =\r
+\r
+# If the XML_PROGRAMLISTING tag is set to YES Doxygen will\r
+# dump the program listings (including syntax highlighting\r
+# and cross-referencing information) to the XML output. Note that\r
+# enabling this will significantly increase the size of the XML output.\r
+\r
+XML_PROGRAMLISTING     = YES\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options for the AutoGen Definitions output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will\r
+# generate an AutoGen Definitions (see autogen.sf.net) file\r
+# that captures the structure of the code including all\r
+# documentation. Note that this feature is still experimental\r
+# and incomplete at the moment.\r
+\r
+GENERATE_AUTOGEN_DEF   = NO\r
+\r
+#---------------------------------------------------------------------------\r
+# configuration options related to the Perl module output\r
+#---------------------------------------------------------------------------\r
+\r
+# If the GENERATE_PERLMOD tag is set to YES Doxygen will\r
+# generate a Perl module file that captures the structure of\r
+# the code including all documentation. Note that this\r
+# feature is still experimental and incomplete at the\r
+# moment.\r
+\r
+GENERATE_PERLMOD       = NO\r
+\r
+# If the PERLMOD_LATEX tag is set to YES Doxygen will generate\r
+# the necessary Makefile rules, Perl scripts and LaTeX code to be able\r
+# to generate PDF and DVI output from the Perl module output.\r
+\r
+PERLMOD_LATEX          = NO\r
+\r
+# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be\r
+# nicely formatted so it can be parsed by a human reader.\r
+# This is useful\r
+# if you want to understand what is going on.\r
+# On the other hand, if this\r
+# tag is set to NO the size of the Perl module output will be much smaller\r
+# and Perl will parse it just the same.\r
+\r
+PERLMOD_PRETTY         = YES\r
+\r
+# The names of the make variables in the generated doxyrules.make file\r
+# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX.\r
+# This is useful so different doxyrules.make files included by the same\r
+# Makefile don't overwrite each other's variables.\r
+\r
+PERLMOD_MAKEVAR_PREFIX =\r
+\r
+#---------------------------------------------------------------------------\r
+# Configuration options related to the preprocessor\r
+#---------------------------------------------------------------------------\r
+\r
+# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will\r
+# evaluate all C-preprocessor directives found in the sources and include\r
+# files.\r
+\r
+ENABLE_PREPROCESSING   = YES\r
+\r
+# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro\r
+# names in the source code. If set to NO (the default) only conditional\r
+# compilation will be performed. Macro expansion can be done in a controlled\r
+# way by setting EXPAND_ONLY_PREDEF to YES.\r
+\r
+MACRO_EXPANSION        = YES\r
+\r
+# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES\r
+# then the macro expansion is limited to the macros specified with the\r
+# PREDEFINED and EXPAND_AS_DEFINED tags.\r
+\r
+EXPAND_ONLY_PREDEF     = YES\r
+\r
+# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files\r
+# pointed to by INCLUDE_PATH will be searched when a #include is found.\r
+\r
+SEARCH_INCLUDES        = YES\r
+\r
+# The INCLUDE_PATH tag can be used to specify one or more directories that\r
+# contain include files that are not input files but should be processed by\r
+# the preprocessor.\r
+\r
+INCLUDE_PATH           =\r
+\r
+# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard\r
+# patterns (like *.h and *.hpp) to filter out the header-files in the\r
+# directories. If left blank, the patterns specified with FILE_PATTERNS will\r
+# be used.\r
+\r
+INCLUDE_FILE_PATTERNS  =\r
+\r
+# The PREDEFINED tag can be used to specify one or more macro names that\r
+# are defined before the preprocessor is started (similar to the -D option of\r
+# gcc). The argument of the tag is a list of macros of the form: name\r
+# or name=definition (no spaces). If the definition and the = are\r
+# omitted =1 is assumed. To prevent a macro definition from being\r
+# undefined via #undef or recursively expanded use the := operator\r
+# instead of the = operator.\r
+\r
+PREDEFINED             = __DOXYGEN__ \\r
+                         PROGMEM\r
+\r
+# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then\r
+# this tag can be used to specify a list of macro names that should be expanded.\r
+# The macro definition that is found in the sources will be used.\r
+# Use the PREDEFINED tag if you want to use a different macro definition that\r
+# overrules the definition found in the source code.\r
+\r
+EXPAND_AS_DEFINED      =\r
+\r
+# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then\r
+# doxygen's preprocessor will remove all references to function-like macros\r
+# that are alone on a line, have an all uppercase name, and do not end with a\r
+# semicolon, because these will confuse the parser if not removed.\r
+\r
+SKIP_FUNCTION_MACROS   = YES\r
+\r
+#---------------------------------------------------------------------------\r
+# Configuration::additions related to external references\r
+#---------------------------------------------------------------------------\r
+\r
+# The TAGFILES option can be used to specify one or more tagfiles. For each\r
+# tag file the location of the external documentation should be added. The\r
+# format of a tag file without this location is as follows:\r
+#\r
+# TAGFILES = file1 file2 ...\r
+# Adding location for the tag files is done as follows:\r
+#\r
+# TAGFILES = file1=loc1 "file2 = loc2" ...\r
+# where "loc1" and "loc2" can be relative or absolute paths\r
+# or URLs. Note that each tag file must have a unique name (where the name does\r
+# NOT include the path). If a tag file is not located in the directory in which\r
+# doxygen is run, you must also specify the path to the tagfile here.\r
+\r
+TAGFILES               =\r
+\r
+# When a file name is specified after GENERATE_TAGFILE, doxygen will create\r
+# a tag file that is based on the input files it reads.\r
+\r
+GENERATE_TAGFILE       =\r
+\r
+# If the ALLEXTERNALS tag is set to YES all external classes will be listed\r
+# in the class index. If set to NO only the inherited external classes\r
+# will be listed.\r
+\r
+ALLEXTERNALS           = NO\r
+\r
+# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed\r
+# in the modules index. If set to NO, only the current project's groups will\r
+# be listed.\r
+\r
+EXTERNAL_GROUPS        = YES\r
+\r
+# The PERL_PATH should be the absolute path and name of the perl script\r
+# interpreter (i.e. the result of `which perl').\r
+\r
+PERL_PATH              = /usr/bin/perl\r
+\r
+#---------------------------------------------------------------------------\r
+# Configuration options related to the dot tool\r
+#---------------------------------------------------------------------------\r
+\r
+# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will\r
+# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base\r
+# or super classes. Setting the tag to NO turns the diagrams off. Note that\r
+# this option also works with HAVE_DOT disabled, but it is recommended to\r
+# install and use dot, since it yields more powerful graphs.\r
+\r
+CLASS_DIAGRAMS         = NO\r
+\r
+# You can define message sequence charts within doxygen comments using the \msc\r
+# command. Doxygen will then run the mscgen tool (see\r
+# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the\r
+# documentation. The MSCGEN_PATH tag allows you to specify the directory where\r
+# the mscgen tool resides. If left empty the tool is assumed to be found in the\r
+# default search path.\r
+\r
+MSCGEN_PATH            =\r
+\r
+# If set to YES, the inheritance and collaboration graphs will hide\r
+# inheritance and usage relations if the target is undocumented\r
+# or is not a class.\r
+\r
+HIDE_UNDOC_RELATIONS   = YES\r
+\r
+# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is\r
+# available from the path. This tool is part of Graphviz, a graph visualization\r
+# toolkit from AT&T and Lucent Bell Labs. The other options in this section\r
+# have no effect if this option is set to NO (the default)\r
+\r
+HAVE_DOT               = NO\r
+\r
+# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is\r
+# allowed to run in parallel. When set to 0 (the default) doxygen will\r
+# base this on the number of processors available in the system. You can set it\r
+# explicitly to a value larger than 0 to get control over the balance\r
+# between CPU load and processing speed.\r
+\r
+DOT_NUM_THREADS        = 0\r
+\r
+# By default doxygen will use the Helvetica font for all dot files that\r
+# doxygen generates. When you want a differently looking font you can specify\r
+# the font name using DOT_FONTNAME. You need to make sure dot is able to find\r
+# the font, which can be done by putting it in a standard location or by setting\r
+# the DOTFONTPATH environment variable or by setting DOT_FONTPATH to the\r
+# directory containing the font.\r
+\r
+DOT_FONTNAME           = FreeSans\r
+\r
+# The DOT_FONTSIZE tag can be used to set the size of the font of dot graphs.\r
+# The default size is 10pt.\r
+\r
+DOT_FONTSIZE           = 10\r
+\r
+# By default doxygen will tell dot to use the Helvetica font.\r
+# If you specify a different font using DOT_FONTNAME you can use DOT_FONTPATH to\r
+# set the path where dot can find it.\r
+\r
+DOT_FONTPATH           =\r
+\r
+# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen\r
+# will generate a graph for each documented class showing the direct and\r
+# indirect inheritance relations. Setting this tag to YES will force the\r
+# CLASS_DIAGRAMS tag to NO.\r
+\r
+CLASS_GRAPH            = NO\r
+\r
+# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen\r
+# will generate a graph for each documented class showing the direct and\r
+# indirect implementation dependencies (inheritance, containment, and\r
+# class references variables) of the class with other documented classes.\r
+\r
+COLLABORATION_GRAPH    = NO\r
+\r
+# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen\r
+# will generate a graph for groups, showing the direct groups dependencies\r
+\r
+GROUP_GRAPHS           = NO\r
+\r
+# If the UML_LOOK tag is set to YES doxygen will generate inheritance and\r
+# collaboration diagrams in a style similar to the OMG's Unified Modeling\r
+# Language.\r
+\r
+UML_LOOK               = NO\r
+\r
+# If the UML_LOOK tag is enabled, the fields and methods are shown inside\r
+# the class node. If there are many fields or methods and many nodes the\r
+# graph may become too big to be useful. The UML_LIMIT_NUM_FIELDS\r
+# threshold limits the number of items for each type to make the size more\r
+# managable. Set this to 0 for no limit. Note that the threshold may be\r
+# exceeded by 50% before the limit is enforced.\r
+\r
+UML_LIMIT_NUM_FIELDS   = 10\r
+\r
+# If set to YES, the inheritance and collaboration graphs will show the\r
+# relations between templates and their instances.\r
+\r
+TEMPLATE_RELATIONS     = NO\r
+\r
+# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT\r
+# tags are set to YES then doxygen will generate a graph for each documented\r
+# file showing the direct and indirect include dependencies of the file with\r
+# other documented files.\r
+\r
+INCLUDE_GRAPH          = NO\r
+\r
+# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and\r
+# HAVE_DOT tags are set to YES then doxygen will generate a graph for each\r
+# documented header file showing the documented files that directly or\r
+# indirectly include this file.\r
+\r
+INCLUDED_BY_GRAPH      = NO\r
+\r
+# If the CALL_GRAPH and HAVE_DOT options are set to YES then\r
+# doxygen will generate a call dependency graph for every global function\r
+# or class method. Note that enabling this option will significantly increase\r
+# the time of a run. So in most cases it will be better to enable call graphs\r
+# for selected functions only using the \callgraph command.\r
+\r
+CALL_GRAPH             = NO\r
+\r
+# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then\r
+# doxygen will generate a caller dependency graph for every global function\r
+# or class method. Note that enabling this option will significantly increase\r
+# the time of a run. So in most cases it will be better to enable caller\r
+# graphs for selected functions only using the \callergraph command.\r
+\r
+CALLER_GRAPH           = NO\r
+\r
+# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen\r
+# will generate a graphical hierarchy of all classes instead of a textual one.\r
+\r
+GRAPHICAL_HIERARCHY    = NO\r
+\r
+# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES\r
+# then doxygen will show the dependencies a directory has on other directories\r
+# in a graphical way. The dependency relations are determined by the #include\r
+# relations between the files in the directories.\r
+\r
+DIRECTORY_GRAPH        = NO\r
+\r
+# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images\r
+# generated by dot. Possible values are svg, png, jpg, or gif.\r
+# If left blank png will be used. If you choose svg you need to set\r
+# HTML_FILE_EXTENSION to xhtml in order to make the SVG files\r
+# visible in IE 9+ (other browsers do not have this requirement).\r
+\r
+DOT_IMAGE_FORMAT       = png\r
+\r
+# If DOT_IMAGE_FORMAT is set to svg, then this option can be set to YES to\r
+# enable generation of interactive SVG images that allow zooming and panning.\r
+# Note that this requires a modern browser other than Internet Explorer.\r
+# Tested and working are Firefox, Chrome, Safari, and Opera. For IE 9+ you\r
+# need to set HTML_FILE_EXTENSION to xhtml in order to make the SVG files\r
+# visible. Older versions of IE do not have SVG support.\r
+\r
+INTERACTIVE_SVG        = NO\r
+\r
+# The tag DOT_PATH can be used to specify the path where the dot tool can be\r
+# found. If left blank, it is assumed the dot tool can be found in the path.\r
+\r
+DOT_PATH               =\r
+\r
+# The DOTFILE_DIRS tag can be used to specify one or more directories that\r
+# contain dot files that are included in the documentation (see the\r
+# \dotfile command).\r
+\r
+DOTFILE_DIRS           =\r
+\r
+# The MSCFILE_DIRS tag can be used to specify one or more directories that\r
+# contain msc files that are included in the documentation (see the\r
+# \mscfile command).\r
+\r
+MSCFILE_DIRS           =\r
+\r
+# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of\r
+# nodes that will be shown in the graph. If the number of nodes in a graph\r
+# becomes larger than this value, doxygen will truncate the graph, which is\r
+# visualized by representing a node as a red box. Note that doxygen if the\r
+# number of direct children of the root node in a graph is already larger than\r
+# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note\r
+# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH.\r
+\r
+DOT_GRAPH_MAX_NODES    = 15\r
+\r
+# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the\r
+# graphs generated by dot. A depth value of 3 means that only nodes reachable\r
+# from the root by following a path via at most 3 edges will be shown. Nodes\r
+# that lay further from the root node will be omitted. Note that setting this\r
+# option to 1 or 2 may greatly reduce the computation time needed for large\r
+# code bases. Also note that the size of a graph can be further restricted by\r
+# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction.\r
+\r
+MAX_DOT_GRAPH_DEPTH    = 2\r
+\r
+# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent\r
+# background. This is disabled by default, because dot on Windows does not\r
+# seem to support this out of the box. Warning: Depending on the platform used,\r
+# enabling this option may lead to badly anti-aliased labels on the edges of\r
+# a graph (i.e. they become hard to read).\r
+\r
+DOT_TRANSPARENT        = YES\r
+\r
+# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output\r
+# files in one run (i.e. multiple -o and -T options on the command line). This\r
+# makes dot run faster, but since only newer versions of dot (>1.8.10)\r
+# support this, this feature is disabled by default.\r
+\r
+DOT_MULTI_TARGETS      = NO\r
+\r
+# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will\r
+# generate a legend page explaining the meaning of the various boxes and\r
+# arrows in the dot generated graphs.\r
+\r
+GENERATE_LEGEND        = YES\r
+\r
+# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will\r
+# remove the intermediate dot files that are used to generate\r
+# the various graphs.\r
+\r
+DOT_CLEANUP            = YES\r
diff --git a/Projects/SerialToLCD/Lib/HD44780.c b/Projects/SerialToLCD/Lib/HD44780.c
new file mode 100644 (file)
index 0000000..7bf989d
--- /dev/null
@@ -0,0 +1,127 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+#include "HD44780.h"
+
+static void HD44780_WriteNibble(const uint8_t nib)
+{
+       /* Read PORTD and clear the ENABLE and PD0..3 bits 
+          then OR in the data */
+       
+       PORTD = (PORTD & ~(ENABLE | LO4_MASK)) | (nib & LO4_MASK);
+       
+       /* Enforce address setup time (tAS) 60ns 
+          60 @ 16MHz = <1  
+          Let's us a few NOPs for good measure */
+       asm volatile("nop\n\t"
+                    "nop\n\t"
+                    :: );
+       
+       /* Take enable high and enforce Enable High time (tEH=450ns)
+          450ns @ 16MHz = 7.2 => 7 NOPs */
+          
+       PORTD |= ENABLE;
+
+       asm volatile("nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    :: );
+
+       /* Take enable low and enforce Enable Low time (tEL=500ns)
+          500ns @ 16MHz = 8.0 => 7 NOPs */
+       PORTD &= ~ENABLE;
+       
+       asm volatile("nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    "nop\n\t"
+                    :: );
+}
+
+static void HD44780_WriteByte(const uint8_t c)
+{
+       HD44780_WriteNibble(HI4(c));
+       HD44780_WriteNibble(LO4(c));
+}
+
+static void HD44780_PowerUp4Bit(void)
+{
+       /* Wait for more than 40 ms after VCC rises to 2.7 V */
+       _delay_ms(40);
+       HD44780_WriteNibble(0x03);        // FN_SET 8-bit
+
+       /* Wait for more than 4.1 ms */
+       _delay_ms(5);
+       HD44780_WriteNibble(0x03);        // FN_SET 8-bit
+       
+       /* Wait for more than 100 Âµs */
+       _delay_us(100);
+       HD44780_WriteNibble(0x03);        // FN_SET 8-bit
+       
+       /* From now on we must allow 40us for each command */
+       _delay_us(50);
+       HD44780_WriteNibble(0x02);        // FN_SET 4-bit
+
+       /* The LCD is now in 4-bit mode so we can continue
+          using the 4-bit API */
+       _delay_us(50);
+}
+
+void HD44780_Initialise(void)
+{
+       PORTD &= ~ALL_BITS;
+       DDRD  |=  ALL_BITS;
+       HD44780_PowerUp4Bit();
+}
+
+void HD44780_WriteCommand(const uint8_t c)
+{
+       PORTD &= ~RS;
+       HD44780_WriteByte(c);
+       _delay_us(50);
+}
+
+void HD44780_WriteData(const uint8_t c)
+{
+       PORTD |=  RS;
+       HD44780_WriteByte(c);
+       PORTD &= ~RS;
+       _delay_us(50);
+}
diff --git a/Projects/SerialToLCD/Lib/HD44780.h b/Projects/SerialToLCD/Lib/HD44780.h
new file mode 100644 (file)
index 0000000..680e69b
--- /dev/null
@@ -0,0 +1,64 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *
+ *  Header file for HD44780.c.
+ */
+
+#ifndef _HD44780_H_
+#define _HD44780_H_
+       
+       /* Includes: */
+               #include <avr/io.h>
+               #include <util/delay.h>
+               #include <avr/power.h>
+
+       /* Macros: */
+               #define RS                  (1 << 4)    /* PD4 */
+               #define ENABLE              (1 << 7)    /* PD7 */
+
+               #define HI4_MASK            0xF0
+               #define LO4_MASK            0x0F        /* PD0-PD3 */
+
+               #define ALL_BITS            (RS | ENABLE | LO4_MASK)
+
+               #define HI4(c)              ((c & HI4_MASK) >> 4)
+               #define LO4(c)              ((c & LO4_MASK) >> 0)
+
+               #define CMD_DISPLAY_ON      0x0C
+
+       /* Function Prototypes: */
+               void HD44780_Initialise(void);
+               void HD44780_WriteData(const uint8_t c);
+               void HD44780_WriteCommand(const uint8_t c);
+
+#endif
diff --git a/Projects/SerialToLCD/SerialToLCD.c b/Projects/SerialToLCD/SerialToLCD.c
new file mode 100644 (file)
index 0000000..952e2d4
--- /dev/null
@@ -0,0 +1,168 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file 
+ *
+ *  Main source file for the SerialToLCD program. This file contains the main tasks of
+ *  the project and is responsible for the initial application hardware configuration.
+ */
+
+#include "SerialToLCD.h"
+
+/** Circular buffer to hold data from the host before it is sent to the LCD */
+static RingBuffer_t FromHost_Buffer;
+
+/** Underlying data buffer for \ref FromHost_Buffer, where the stored bytes are located. */
+static uint8_t      FromHost_Buffer_Data[128];
+
+/** LUFA CDC Class driver interface configuration and state information. This structure is
+ *  passed to all CDC Class driver functions, so that multiple instances of the same class
+ *  within a device can be differentiated from one another.
+ */
+USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
+       {
+               .Config =
+                       {
+                               .ControlInterfaceNumber   = 0,
+                               .DataINEndpoint           =
+                                       {
+                                               .Address          = CDC_TX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .DataOUTEndpoint =
+                                       {
+                                               .Address          = CDC_RX_EPADDR,
+                                               .Size             = CDC_TXRX_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                               .NotificationEndpoint =
+                                       {
+                                               .Address          = CDC_NOTIFICATION_EPADDR,
+                                               .Size             = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks            = 1,
+                                       },
+                       },
+       };
+
+
+/** Main program entry point. This routine contains the overall program flow, including initial
+ *  setup of all components and the main program loop.
+ */
+int main(void)
+{
+       SetupHardware();
+
+       RingBuffer_InitBuffer(&FromHost_Buffer, FromHost_Buffer_Data, sizeof(FromHost_Buffer_Data));
+
+       sei();
+
+       for (;;)
+       {
+               /* Only try to read in bytes from the CDC interface if the transmit buffer is not full */
+               if (!(RingBuffer_IsFull(&FromHost_Buffer)))
+               {
+                       int16_t ReceivedByte = CDC_Device_ReceiveByte(&VirtualSerial_CDC_Interface);
+
+                       /* Read bytes from the USB OUT endpoint into the USART transmit buffer */
+                       if (!(ReceivedByte < 0))
+                         RingBuffer_Insert(&FromHost_Buffer, ReceivedByte);
+               }
+
+               while (RingBuffer_GetCount(&FromHost_Buffer) > 0)
+               {
+                       static uint8_t EscapePending = 0;
+                       int16_t HD44780Byte = RingBuffer_Remove(&FromHost_Buffer);
+                       
+                       if (HD44780Byte == COMMAND_ESCAPE)
+                       {
+                               if (EscapePending)
+                               {
+                                       HD44780_WriteData(HD44780Byte);
+                                       EscapePending = 0;
+                               }
+                               else
+                               {
+                                       /* Next received character is the command byte */
+                                       EscapePending = 1;
+                               }
+                       }
+                       else
+                       {
+                               if (EscapePending)
+                               {
+                                       HD44780_WriteCommand(HD44780Byte);
+                                       EscapePending = 0;
+                               }
+                               else
+                               {
+                                       HD44780_WriteData(HD44780Byte);
+                               }
+                       }
+               }
+
+               CDC_Device_USBTask(&VirtualSerial_CDC_Interface);
+               USB_USBTask();
+       }
+}
+
+/** Configures the board hardware and chip peripherals for the application's functionality. */
+void SetupHardware(void)
+{
+       /* Disable watchdog if enabled by bootloader/fuses */
+       MCUSR &= ~(1 << WDRF);
+       wdt_disable();
+
+       /* Disable clock division */
+       clock_prescale_set(clock_div_1);
+
+       /* Hardware Initialization */
+       USB_Init();
+
+       /* Power up the HD44780 Interface */
+       HD44780_Initialise();
+       HD44780_WriteCommand(CMD_DISPLAY_ON);
+       
+       /* Start the flush timer so that overflows occur rapidly to push received bytes to the USB interface */
+       TCCR0B = (1 << CS02);
+}
+
+/** Event handler for the library USB Configuration Changed event. */
+void EVENT_USB_Device_ConfigurationChanged(void)
+{
+       CDC_Device_ConfigureEndpoints(&VirtualSerial_CDC_Interface);
+}
+
+/** Event handler for the library USB Control Request reception event. */
+void EVENT_USB_Device_ControlRequest(void)
+{
+       CDC_Device_ProcessControlRequest(&VirtualSerial_CDC_Interface);
+}
diff --git a/Projects/SerialToLCD/SerialToLCD.h b/Projects/SerialToLCD/SerialToLCD.h
new file mode 100644 (file)
index 0000000..52efe44
--- /dev/null
@@ -0,0 +1,63 @@
+/*
+             LUFA Library
+     Copyright (C) Dean Camera, 2012.
+
+  dean [at] fourwalledcubicle [dot] com
+           www.lufa-lib.org
+*/
+
+/*
+  Copyright 2012  Dean Camera (dean [at] fourwalledcubicle [dot] com)
+  Copyright 2012  Simon Foster (simon.foster [at] inbox [dot] com)
+
+  Permission to use, copy, modify, distribute, and sell this
+  software and its documentation for any purpose is hereby granted
+  without fee, provided that the above copyright notice appear in
+  all copies and that both that the copyright notice and this
+  permission notice and warranty disclaimer appear in supporting
+  documentation, and that the name of the author not be used in
+  advertising or publicity pertaining to distribution of the
+  software without specific, written prior permission.
+
+  The author disclaim all warranties with regard to this
+  software, including all implied warranties of merchantability
+  and fitness.  In no event shall the author be liable for any
+  special, indirect or consequential damages or any damages
+  whatsoever resulting from loss of use, data or profits, whether
+  in an action of contract, negligence or other tortious action,
+  arising out of or in connection with the use or performance of
+  this software.
+*/
+
+/** \file
+ *
+ *  Header file for SerialToLCD.c.
+ */
+
+#ifndef _SERIALTOLCD_H_
+#define _SERIALTOLCD_H_
+
+    /* Includes: */
+        #include <avr/io.h>
+        #include <avr/wdt.h>
+        #include <avr/interrupt.h>
+        #include <avr/power.h>
+
+        #include "Descriptors.h"
+               #include "Lib/HD44780.h"
+
+        #include <LUFA/Version.h>
+        #include <LUFA/Drivers/Misc/RingBuffer.h>
+        #include <LUFA/Drivers/USB/USB.h>
+               
+       /* Macros: */
+               #define COMMAND_ESCAPE     0x1B
+
+    /* Function Prototypes: */
+        void SetupHardware(void);
+
+        void EVENT_USB_Device_ConfigurationChanged(void);
+        void EVENT_USB_Device_ControlRequest(void);
+
+#endif
+
diff --git a/Projects/SerialToLCD/SerialToLCD.txt b/Projects/SerialToLCD/SerialToLCD.txt
new file mode 100644 (file)
index 0000000..84237b4
--- /dev/null
@@ -0,0 +1,97 @@
+/** \file\r
+ *\r
+ *  This file contains special DoxyGen information for the generation of the main page and other special\r
+ *  documentation pages. It is not a project source file.\r
+ */\r
+\r
+/** \mainpage Simon Foster's USB Serial to HD44780 LCD Project\r
+ *\r
+ *  \section Sec_Compat Project Compatibility:\r
+ *\r
+ *  The following list indicates what microcontrollers are compatible with this project.\r
+ *\r
+ *  - AT90USB162\r
+ *\r
+ *  \section Sec_Info USB Information:\r
+ *\r
+ *  The following table gives a rundown of the USB utilization of this project.\r
+ *\r
+ *  <table>\r
+ *   <tr>\r
+ *    <td><b>USB Mode:</b></td>\r
+ *    <td>Device</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td><b>USB Class:</b></td>\r
+ *    <td>Communications Device Class (CDC)</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td><b>USB Subclass:</b></td>\r
+ *    <td>Abstract Control Model (ACM)</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td><b>Relevant Standards:</b></td>\r
+ *    <td>USBIF CDC Class Standard</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td><b>Usable Speeds:</b></td>\r
+ *    <td>Full Speed Mode</td>\r
+ *   </tr>\r
+ *  </table>\r
+ *\r
+ *  \section Sec_Description Project Description:\r
+ *\r
+ *  Firmware for a USB Virtual Serial to HD44780 LCD controller project, by Simon Foster. This\r
+ *  project connects a standard HD7780 compatible LCD controller to a PC via a virtual serial\r
+ *  link, so that data supplied by the host can be written to the display. This project is\r
+ *  designed to use the Minimum USB AVR board, however it can be modified to suit other hardware\r
+ *  if desired.\r
+ *\r
+ *  LCD Datasheet:    http://www.sparkfun.com/datasheets/LCD/HD44780.pdf \n\r
+ *  More Information: http://en.wikipedia.org/wiki/HD44780_Character_LCD \n\r
+ *\r
+ *  Below are the connections between the AVR Minimus board and LCD.\r
+ *\r
+ *  <table>\r
+ *   <tr>\r
+ *    <td><b>AVR Pin:</b></td>\r
+ *    <td><b>HD44780 LCD Pin:</b></td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>VCC</td>\r
+ *    <td>VCC</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>GND</td>\r
+ *    <td>GND</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD0</td>\r
+ *    <td>DB4</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD1</td>\r
+ *    <td>DB5</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD2</td>\r
+ *    <td>DB6</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD3</td>\r
+ *    <td>DB7</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD4</td>\r
+ *    <td>/RS</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>GND</td>\r
+ *    <td>/RW</td>\r
+ *   </tr>\r
+ *   <tr>\r
+ *    <td>PD7</td>\r
+ *    <td>/E</td>\r
+ *   </tr>\r
+ *  </table>\r
+ */\r
diff --git a/Projects/SerialToLCD/makefile b/Projects/SerialToLCD/makefile
new file mode 100644 (file)
index 0000000..ad66578
--- /dev/null
@@ -0,0 +1,731 @@
+# Hey Emacs, this is a -*- makefile -*-\r
+#----------------------------------------------------------------------------\r
+# WinAVR Makefile Template written by Eric B. Weddington, Jörg Wunsch, et al.\r
+#  >> Modified for use with the LUFA project. <<\r
+#\r
+# Released to the Public Domain\r
+#\r
+# Additional material for this makefile was written by:\r
+# Peter Fleury\r
+# Tim Henigan\r
+# Colin O'Flynn\r
+# Reiner Patommel\r
+# Markus Pfaff\r
+# Sander Pool\r
+# Frederik Rouleau\r
+# Carlos Lamas\r
+# Dean Camera\r
+# Opendous Inc.\r
+# Denver Gingerich\r
+#\r
+#----------------------------------------------------------------------------\r
+# On command line:\r
+#\r
+# make all = Make software.\r
+#\r
+# make clean = Clean out built project files.\r
+#\r
+# make coff = Convert ELF to AVR COFF.\r
+#\r
+# make extcoff = Convert ELF to AVR Extended COFF.\r
+#\r
+# make program = Download the hex file to the device, using avrdude.\r
+#                Please customize the avrdude settings below first!\r
+#\r
+# make dfu = Download the hex file to the device, using dfu-programmer (must\r
+#            have dfu-programmer installed).\r
+#\r
+# make flip = Download the hex file to the device, using Atmel FLIP (must\r
+#             have Atmel FLIP installed).\r
+#\r
+# make dfu-ee = Download the eeprom file to the device, using dfu-programmer\r
+#               (must have dfu-programmer installed).\r
+#\r
+# make flip-ee = Download the eeprom file to the device, using Atmel FLIP\r
+#                (must have Atmel FLIP installed).\r
+#\r
+# make doxygen = Generate DoxyGen documentation for the project (must have\r
+#                DoxyGen installed)\r
+#\r
+# make debug = Start either simulavr or avarice as specified for debugging,\r
+#              with avr-gdb or avr-insight as the front end for debugging.\r
+#\r
+# make filename.s = Just compile filename.c into the assembler code only.\r
+#\r
+# make filename.i = Create a preprocessed source file for use in submitting\r
+#                   bug reports to the GCC project.\r
+#\r
+# To rebuild project do "make clean" then "make all".\r
+#----------------------------------------------------------------------------\r
+\r
+\r
+# MCU name\r
+MCU = at90usb162\r
+\r
+\r
+# Target architecture (see library "Board Types" documentation).\r
+ARCH = AVR8\r
+\r
+\r
+# Target board (see library "Board Types" documentation, NONE for projects not requiring\r
+# LUFA board drivers). If USER is selected, put custom board drivers in a directory called\r
+# "Board" inside the application directory.\r
+BOARD = MINIMUS\r
+\r
+\r
+# Processor frequency.\r
+#     This will define a symbol, F_CPU, in all source code files equal to the\r
+#     processor frequency in Hz. You can then use this symbol in your source code to\r
+#     calculate timings. Do NOT tack on a 'UL' at the end, this will be done\r
+#     automatically to create a 32-bit value in your source code.\r
+#\r
+#     This will be an integer division of F_USB below, as it is sourced by\r
+#     F_USB after it has run through any CPU prescalers. Note that this value\r
+#     does not *change* the processor frequency - it should merely be updated to\r
+#     reflect the processor speed set externally so that the code can use accurate\r
+#     software delays.\r
+F_CPU = 16000000\r
+\r
+\r
+# Input clock frequency.\r
+#     This will define a symbol, F_USB, in all source code files equal to the\r
+#     input clock frequency (before any prescaling is performed) in Hz. This value may\r
+#     differ from F_CPU if prescaling is used on the latter, and is required as the\r
+#     raw input clock is fed directly to the PLL sections of the AVR for high speed\r
+#     clock generation for the USB and other AVR subsections. Do NOT tack on a 'UL'\r
+#     at the end, this will be done automatically to create a 32-bit value in your\r
+#     source code.\r
+#\r
+#     If no clock division is performed on the input clock inside the AVR (via the\r
+#     CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU.\r
+F_USB = $(F_CPU)\r
+\r
+\r
+# Output format. (can be srec, ihex, binary)\r
+FORMAT = ihex\r
+\r
+\r
+# Target file name (without extension).\r
+TARGET = SerialToLCD\r
+\r
+\r
+# Object files directory\r
+#     To put object files in current directory, use a dot (.), do NOT make\r
+#     this an empty or blank macro!\r
+OBJDIR = .\r
+\r
+\r
+# Path to the LUFA library\r
+LUFA_PATH = ../..\r
+\r
+\r
+# LUFA library compile-time options and predefined tokens\r
+LUFA_OPTS  = -D USB_DEVICE_ONLY\r
+LUFA_OPTS += -D DEVICE_STATE_AS_GPIOR=0\r
+LUFA_OPTS += -D ORDERED_EP_CONFIG\r
+LUFA_OPTS += -D FIXED_CONTROL_ENDPOINT_SIZE=8\r
+LUFA_OPTS += -D FIXED_NUM_CONFIGURATIONS=1\r
+LUFA_OPTS += -D USE_FLASH_DESCRIPTORS\r
+LUFA_OPTS += -D USE_STATIC_OPTIONS="(USB_DEVICE_OPT_FULLSPEED | USB_OPT_REG_ENABLED | USB_OPT_AUTO_PLL)"\r
+LUFA_OPTS += -D INTERRUPT_CONTROL_ENDPOINT\r
+\r
+\r
+# Create the LUFA source path variables by including the LUFA root makefile\r
+include $(LUFA_PATH)/LUFA/makefile\r
+\r
+\r
+# List C source files here. (C dependencies are automatically generated.)\r
+SRC = $(TARGET).c                                               \\r
+         Lib/HD44780.c                                             \\r
+         Descriptors.c                                             \\r
+         $(LUFA_SRC_USB)                                           \\r
+         $(LUFA_SRC_USBCLASS)\r
+\r
+\r
+# List C++ source files here. (C dependencies are automatically generated.)\r
+CPPSRC =\r
+\r
+\r
+# List Assembler source files here.\r
+#     Make them always end in a capital .S.  Files ending in a lowercase .s\r
+#     will not be considered source files but generated files (assembler\r
+#     output from the compiler), and will be deleted upon "make clean"!\r
+#     Even though the DOS/Win* filesystem matches both .s and .S the same,\r
+#     it will preserve the spelling of the filenames, and gcc itself does\r
+#     care about how the name is spelled on its command-line.\r
+ASRC =\r
+\r
+\r
+# Optimization level, can be [0, 1, 2, 3, s].\r
+#     0 = turn off optimization. s = optimize for size.\r
+#     (Note: 3 is not always the best optimization level. See avr-libc FAQ.)\r
+OPT = s\r
+\r
+\r
+# Debugging format.\r
+#     Native formats for AVR-GCC's -g are dwarf-2 [default] or stabs.\r
+#     AVR Studio 4.10 requires dwarf-2.\r
+#     AVR [Extended] COFF format requires stabs, plus an avr-objcopy run.\r
+DEBUG = dwarf-2\r
+\r
+\r
+# List any extra directories to look for include files here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRAINCDIRS = $(LUFA_PATH)/\r
+\r
+\r
+# Compiler flag to set the C Standard level.\r
+#     c89   = "ANSI" C\r
+#     gnu89 = c89 plus GCC extensions\r
+#     c99   = ISO C99 standard (not yet fully implemented)\r
+#     gnu99 = c99 plus GCC extensions\r
+CSTANDARD = -std=gnu99\r
+\r
+\r
+# Place -D or -U options here for C sources\r
+CDEFS  = -DF_CPU=$(F_CPU)UL\r
+CDEFS += -DF_USB=$(F_USB)UL\r
+CDEFS += -DBOARD=BOARD_$(BOARD) -DARCH=ARCH_$(ARCH)\r
+CDEFS += $(LUFA_OPTS)\r
+\r
+\r
+# Place -D or -U options here for ASM sources\r
+ADEFS  = -DF_CPU=$(F_CPU)\r
+ADEFS += -DF_USB=$(F_USB)UL\r
+ADEFS += -DBOARD=BOARD_$(BOARD)\r
+ADEFS += $(LUFA_OPTS)\r
+\r
+# Place -D or -U options here for C++ sources\r
+CPPDEFS  = -DF_CPU=$(F_CPU)UL\r
+CPPDEFS += -DF_USB=$(F_USB)UL\r
+CPPDEFS += -DBOARD=BOARD_$(BOARD)\r
+CPPDEFS += $(LUFA_OPTS)\r
+#CPPDEFS += -D__STDC_LIMIT_MACROS\r
+#CPPDEFS += -D__STDC_CONSTANT_MACROS\r
+\r
+\r
+\r
+#---------------- Compiler Options C ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CFLAGS = -g$(DEBUG)\r
+CFLAGS += $(CDEFS)\r
+CFLAGS += -O$(OPT)\r
+CFLAGS += -funsigned-char\r
+CFLAGS += -funsigned-bitfields\r
+CFLAGS += -ffunction-sections\r
+CFLAGS += -fno-inline-small-functions\r
+CFLAGS += -fpack-struct\r
+CFLAGS += -fshort-enums\r
+CFLAGS += -fno-strict-aliasing\r
+CFLAGS += -Wall\r
+CFLAGS += -Wstrict-prototypes\r
+#CFLAGS += -mshort-calls\r
+#CFLAGS += -fno-unit-at-a-time\r
+#CFLAGS += -Wundef\r
+#CFLAGS += -Wunreachable-code\r
+#CFLAGS += -Wsign-compare\r
+CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)\r
+CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+CFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Compiler Options C++ ----------------\r
+#  -g*:          generate debugging information\r
+#  -O*:          optimization level\r
+#  -f...:        tuning, see GCC manual and avr-libc documentation\r
+#  -Wall...:     warning level\r
+#  -Wa,...:      tell GCC to pass this to the assembler.\r
+#    -adhlns...: create assembler listing\r
+CPPFLAGS = -g$(DEBUG)\r
+CPPFLAGS += $(CPPDEFS)\r
+CPPFLAGS += -O$(OPT)\r
+CPPFLAGS += -funsigned-char\r
+CPPFLAGS += -funsigned-bitfields\r
+CPPFLAGS += -fpack-struct\r
+CPPFLAGS += -fshort-enums\r
+CPPFLAGS += -fno-exceptions\r
+CPPFLAGS += -Wall\r
+CPPFLAGS += -Wundef\r
+#CPPFLAGS += -mshort-calls\r
+#CPPFLAGS += -fno-unit-at-a-time\r
+#CPPFLAGS += -Wstrict-prototypes\r
+#CPPFLAGS += -Wunreachable-code\r
+#CPPFLAGS += -Wsign-compare\r
+CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)\r
+CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))\r
+#CPPFLAGS += $(CSTANDARD)\r
+\r
+\r
+#---------------- Assembler Options ----------------\r
+#  -Wa,...:   tell GCC to pass this to the assembler.\r
+#  -adhlns:   create listing\r
+#  -gstabs:   have the assembler create line number information; note that\r
+#             for use in COFF files, additional information about filenames\r
+#             and function names needs to be present in the assembler source\r
+#             files -- see avr-libc docs [FIXME: not yet described there]\r
+#  -listing-cont-lines: Sets the maximum number of continuation lines of hex\r
+#       dump that will be displayed for a given single line of source input.\r
+ASFLAGS = $(ADEFS) -Wa,-adhlns=$(<:%.S=$(OBJDIR)/%.lst),-gstabs,--listing-cont-lines=100\r
+\r
+\r
+#---------------- Library Options ----------------\r
+# Minimalistic printf version\r
+PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min\r
+\r
+# Floating point printf version (requires MATH_LIB = -lm below)\r
+PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt\r
+\r
+# If this is left blank, then it will use the Standard printf version.\r
+PRINTF_LIB =\r
+#PRINTF_LIB = $(PRINTF_LIB_MIN)\r
+#PRINTF_LIB = $(PRINTF_LIB_FLOAT)\r
+\r
+\r
+# Minimalistic scanf version\r
+SCANF_LIB_MIN = -Wl,-u,vfscanf -lscanf_min\r
+\r
+# Floating point + %[ scanf version (requires MATH_LIB = -lm below)\r
+SCANF_LIB_FLOAT = -Wl,-u,vfscanf -lscanf_flt\r
+\r
+# If this is left blank, then it will use the Standard scanf version.\r
+SCANF_LIB =\r
+#SCANF_LIB = $(SCANF_LIB_MIN)\r
+#SCANF_LIB = $(SCANF_LIB_FLOAT)\r
+\r
+\r
+MATH_LIB = -lm\r
+\r
+\r
+# List any extra directories to look for libraries here.\r
+#     Each directory must be seperated by a space.\r
+#     Use forward slashes for directory separators.\r
+#     For a directory that has spaces, enclose it in quotes.\r
+EXTRALIBDIRS =\r
+\r
+\r
+\r
+#---------------- External Memory Options ----------------\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# used for variables (.data/.bss) and heap (malloc()).\r
+#EXTMEMOPTS = -Wl,-Tdata=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+# 64 KB of external RAM, starting after internal RAM (ATmega128!),\r
+# only used for heap (malloc()).\r
+#EXTMEMOPTS = -Wl,--section-start,.data=0x801100,--defsym=__heap_end=0x80ffff\r
+\r
+EXTMEMOPTS =\r
+\r
+\r
+\r
+#---------------- Linker Options ----------------\r
+#  -Wl,...:     tell GCC to pass this to linker.\r
+#    -Map:      create map file\r
+#    --cref:    add cross reference to  map file\r
+LDFLAGS  = -Wl,-Map=$(TARGET).map,--cref\r
+LDFLAGS += -Wl,--relax\r
+LDFLAGS += -Wl,--gc-sections\r
+LDFLAGS += $(EXTMEMOPTS)\r
+LDFLAGS += $(patsubst %,-L%,$(EXTRALIBDIRS))\r
+LDFLAGS += $(PRINTF_LIB) $(SCANF_LIB) $(MATH_LIB)\r
+#LDFLAGS += -T linker_script.x\r
+\r
+\r
+\r
+#---------------- Programming Options (avrdude) ----------------\r
+\r
+# Programming hardware\r
+# Type: avrdude -c ?\r
+# to get a full listing.\r
+#\r
+AVRDUDE_PROGRAMMER = jtagmkII\r
+\r
+# com1 = serial port. Use lpt1 to connect to parallel port.\r
+AVRDUDE_PORT = usb\r
+\r
+AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex\r
+#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep\r
+\r
+\r
+# Uncomment the following if you want avrdude's erase cycle counter.\r
+# Note that this counter needs to be initialized first using -Yn,\r
+# see avrdude manual.\r
+#AVRDUDE_ERASE_COUNTER = -y\r
+\r
+# Uncomment the following if you do /not/ wish a verification to be\r
+# performed after programming the device.\r
+#AVRDUDE_NO_VERIFY = -V\r
+\r
+# Increase verbosity level.  Please use this when submitting bug\r
+# reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude>\r
+# to submit bug reports.\r
+#AVRDUDE_VERBOSE = -v -v\r
+\r
+AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER)\r
+AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)\r
+AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)\r
+AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)\r
+\r
+\r
+\r
+#---------------- Debugging Options ----------------\r
+\r
+# For simulavr only - target MCU frequency.\r
+DEBUG_MFREQ = $(F_CPU)\r
+\r
+# Set the DEBUG_UI to either gdb or insight.\r
+# DEBUG_UI = gdb\r
+DEBUG_UI = insight\r
+\r
+# Set the debugging back-end to either avarice, simulavr.\r
+DEBUG_BACKEND = avarice\r
+#DEBUG_BACKEND = simulavr\r
+\r
+# GDB Init Filename.\r
+GDBINIT_FILE = __avr_gdbinit\r
+\r
+# When using avarice settings for the JTAG\r
+JTAG_DEV = /dev/com1\r
+\r
+# Debugging port used to communicate between GDB / avarice / simulavr.\r
+DEBUG_PORT = 4242\r
+\r
+# Debugging host used to communicate between GDB / avarice / simulavr, normally\r
+#     just set to localhost unless doing some sort of crazy debugging when\r
+#     avarice is running on a different computer.\r
+DEBUG_HOST = localhost\r
+\r
+\r
+\r
+#============================================================================\r
+\r
+\r
+# Define programs and commands.\r
+SHELL = sh\r
+CC = avr-gcc\r
+OBJCOPY = avr-objcopy\r
+OBJDUMP = avr-objdump\r
+SIZE = avr-size\r
+AR = avr-ar rcs\r
+NM = avr-nm\r
+AVRDUDE = avrdude\r
+REMOVE = rm -f\r
+REMOVEDIR = rm -rf\r
+COPY = cp\r
+WINSHELL = cmd\r
+\r
+\r
+# Define Messages\r
+# English\r
+MSG_ERRORS_NONE = Errors: none\r
+MSG_BEGIN = -------- begin --------\r
+MSG_END = --------  end  --------\r
+MSG_SIZE_BEFORE = Size before:\r
+MSG_SIZE_AFTER = Size after:\r
+MSG_COFF = Converting to AVR COFF:\r
+MSG_EXTENDED_COFF = Converting to AVR Extended COFF:\r
+MSG_FLASH = Creating load file for Flash:\r
+MSG_EEPROM = Creating load file for EEPROM:\r
+MSG_EXTENDED_LISTING = Creating Extended Listing:\r
+MSG_SYMBOL_TABLE = Creating Symbol Table:\r
+MSG_LINKING = Linking:\r
+MSG_COMPILING = Compiling C:\r
+MSG_COMPILING_CPP = Compiling C++:\r
+MSG_ASSEMBLING = Assembling:\r
+MSG_CLEANING = Cleaning project:\r
+MSG_CREATING_LIBRARY = Creating library:\r
+\r
+\r
+\r
+\r
+# Define all object files.\r
+OBJ = $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+\r
+# Define all listing files.\r
+LST = $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+\r
+\r
+# Compiler flags to generate dependency files.\r
+GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d\r
+\r
+\r
+# Combine all necessary flags and optional flags.\r
+# Add target processor to flags.\r
+ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS)\r
+ALL_CPPFLAGS = -mmcu=$(MCU) -I. -x c++ $(CPPFLAGS) $(GENDEPFLAGS)\r
+ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS)\r
+\r
+\r
+\r
+\r
+\r
+# Default target.\r
+all: begin gccversion sizebefore build sizeafter end\r
+\r
+# Change the build target to build a HEX file or a library.\r
+build: elf hex eep lss sym\r
+#build: lib\r
+\r
+\r
+elf: $(TARGET).elf\r
+hex: $(TARGET).hex\r
+eep: $(TARGET).eep\r
+lss: $(TARGET).lss\r
+sym: $(TARGET).sym\r
+LIBNAME=lib$(TARGET).a\r
+lib: $(LIBNAME)\r
+\r
+\r
+\r
+# Eye candy.\r
+# AVR Studio 3.x does not check make's exit code but relies on\r
+# the following magic strings to be generated by the compile job.\r
+begin:\r
+       @echo\r
+       @echo $(MSG_BEGIN)\r
+\r
+end:\r
+       @echo $(MSG_END)\r
+       @echo\r
+\r
+\r
+# Display size of file.\r
+HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex\r
+ELFSIZE = $(SIZE) $(MCU_FLAG) $(FORMAT_FLAG) $(TARGET).elf\r
+MCU_FLAG = $(shell $(SIZE) --help | grep -- --mcu > /dev/null && echo --mcu=$(MCU) )\r
+FORMAT_FLAG = $(shell $(SIZE) --help | grep -- --format=.*avr > /dev/null && echo --format=avr )\r
+\r
+\r
+sizebefore:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+sizeafter:\r
+       @if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); \\r
+       2>/dev/null; echo; fi\r
+\r
+\r
+\r
+# Display compiler version information.\r
+gccversion :\r
+       @$(CC) --version\r
+\r
+\r
+# Program the device.\r
+program: $(TARGET).hex $(TARGET).eep\r
+       $(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM)\r
+\r
+flip: $(TARGET).hex\r
+       batchisp -hardware usb -device $(MCU) -operation erase f\r
+       batchisp -hardware usb -device $(MCU) -operation loadbuffer $(TARGET).hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+\r
+dfu: $(TARGET).hex\r
+       dfu-programmer $(MCU) erase\r
+       dfu-programmer $(MCU) flash $(TARGET).hex\r
+       dfu-programmer $(MCU) reset\r
+\r
+flip-ee: $(TARGET).hex $(TARGET).eep\r
+       $(COPY) $(TARGET).eep $(TARGET)eep.hex\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM erase\r
+       batchisp -hardware usb -device $(MCU) -operation memory EEPROM loadbuffer $(TARGET)eep.hex program\r
+       batchisp -hardware usb -device $(MCU) -operation start reset 0\r
+       $(REMOVE) $(TARGET)eep.hex\r
+\r
+dfu-ee: $(TARGET).hex $(TARGET).eep\r
+       dfu-programmer $(MCU) eeprom-flash $(TARGET).eep\r
+       dfu-programmer $(MCU) reset\r
+\r
+\r
+# Generate avr-gdb config/init file which does the following:\r
+#     define the reset signal, load the target file, connect to target, and set\r
+#     a breakpoint at main().\r
+gdb-config:\r
+       @$(REMOVE) $(GDBINIT_FILE)\r
+       @echo define reset >> $(GDBINIT_FILE)\r
+       @echo SIGNAL SIGHUP >> $(GDBINIT_FILE)\r
+       @echo end >> $(GDBINIT_FILE)\r
+       @echo file $(TARGET).elf >> $(GDBINIT_FILE)\r
+       @echo target remote $(DEBUG_HOST):$(DEBUG_PORT)  >> $(GDBINIT_FILE)\r
+ifeq ($(DEBUG_BACKEND),simulavr)\r
+       @echo load  >> $(GDBINIT_FILE)\r
+endif\r
+       @echo break main >> $(GDBINIT_FILE)\r
+\r
+debug: gdb-config $(TARGET).elf\r
+ifeq ($(DEBUG_BACKEND), avarice)\r
+       @echo Starting AVaRICE - Press enter when "waiting to connect" message displays.\r
+       @$(WINSHELL) /c start avarice --jtag $(JTAG_DEV) --erase --program --file \\r
+       $(TARGET).elf $(DEBUG_HOST):$(DEBUG_PORT)\r
+       @$(WINSHELL) /c pause\r
+\r
+else\r
+       @$(WINSHELL) /c start simulavr --gdbserver --device $(MCU) --clock-freq \\r
+       $(DEBUG_MFREQ) --port $(DEBUG_PORT)\r
+endif\r
+       @$(WINSHELL) /c start avr-$(DEBUG_UI) --command=$(GDBINIT_FILE)\r
+\r
+\r
+\r
+\r
+# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB.\r
+COFFCONVERT = $(OBJCOPY) --debugging\r
+COFFCONVERT += --change-section-address .data-0x800000\r
+COFFCONVERT += --change-section-address .bss-0x800000\r
+COFFCONVERT += --change-section-address .noinit-0x800000\r
+COFFCONVERT += --change-section-address .eeprom-0x810000\r
+\r
+\r
+\r
+coff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-avr $< $(TARGET).cof\r
+\r
+\r
+extcoff: $(TARGET).elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_COFF) $(TARGET).cof\r
+       $(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof\r
+\r
+\r
+\r
+# Create final output files (.hex, .eep) from ELF output file.\r
+%.hex: %.elf\r
+       @echo\r
+       @echo $(MSG_FLASH) $@\r
+       $(OBJCOPY) -O $(FORMAT) -R .eeprom -R .fuse -R .lock $< $@\r
+\r
+%.eep: %.elf\r
+       @echo\r
+       @echo $(MSG_EEPROM) $@\r
+       -$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \\r
+       --change-section-lma .eeprom=0 --no-change-warnings -O $(FORMAT) $< $@ || exit 0\r
+\r
+# Create extended listing file from ELF output file.\r
+%.lss: %.elf\r
+       @echo\r
+       @echo $(MSG_EXTENDED_LISTING) $@\r
+       $(OBJDUMP) -h -S -z $< > $@\r
+\r
+# Create a symbol table from ELF output file.\r
+%.sym: %.elf\r
+       @echo\r
+       @echo $(MSG_SYMBOL_TABLE) $@\r
+       $(NM) -n $< > $@\r
+\r
+\r
+\r
+# Create library from object files.\r
+.SECONDARY : $(TARGET).a\r
+.PRECIOUS : $(OBJ)\r
+%.a: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_CREATING_LIBRARY) $@\r
+       $(AR) $@ $(OBJ)\r
+\r
+\r
+# Link: create ELF output file from object files.\r
+.SECONDARY : $(TARGET).elf\r
+.PRECIOUS : $(OBJ)\r
+%.elf: $(OBJ)\r
+       @echo\r
+       @echo $(MSG_LINKING) $@\r
+       $(CC) $(ALL_CFLAGS) $^ --output $@ $(LDFLAGS)\r
+\r
+\r
+# Compile: create object files from C source files.\r
+$(OBJDIR)/%.o : %.c\r
+       @echo\r
+       @echo $(MSG_COMPILING) $<\r
+       $(CC) -c $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create object files from C++ source files.\r
+$(OBJDIR)/%.o : %.cpp\r
+       @echo\r
+       @echo $(MSG_COMPILING_CPP) $<\r
+       $(CC) -c $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C source files.\r
+%.s : %.c\r
+       $(CC) -S $(ALL_CFLAGS) $< -o $@\r
+\r
+\r
+# Compile: create assembler files from C++ source files.\r
+%.s : %.cpp\r
+       $(CC) -S $(ALL_CPPFLAGS) $< -o $@\r
+\r
+\r
+# Assemble: create object files from assembler source files.\r
+$(OBJDIR)/%.o : %.S\r
+       @echo\r
+       @echo $(MSG_ASSEMBLING) $<\r
+       $(CC) -c $(ALL_ASFLAGS) $< -o $@\r
+\r
+\r
+# Create preprocessed source for use in sending a bug report.\r
+%.i : %.c\r
+       $(CC) -E -mmcu=$(MCU) -I. $(CFLAGS) $< -o $@\r
+\r
+\r
+# Target: clean project.\r
+clean: begin clean_list end\r
+\r
+clean_list :\r
+       @echo\r
+       @echo $(MSG_CLEANING)\r
+       $(REMOVE) $(TARGET).hex\r
+       $(REMOVE) $(TARGET).eep\r
+       $(REMOVE) $(TARGET).cof\r
+       $(REMOVE) $(TARGET).elf\r
+       $(REMOVE) $(TARGET).map\r
+       $(REMOVE) $(TARGET).sym\r
+       $(REMOVE) $(TARGET).lss\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)\r
+       $(REMOVE) $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)\r
+       $(REMOVE) $(SRC:.c=.s)\r
+       $(REMOVE) $(SRC:.c=.d)\r
+       $(REMOVE) $(SRC:.c=.i)\r
+       $(REMOVEDIR) .dep\r
+\r
+doxygen:\r
+       @echo Generating Project Documentation \($(TARGET)\)...\r
+       @if ( doxygen Doxygen.conf 2>&1 | grep -v "warning: ignoring unsupported tag" ;); then \\r
+         exit 1; \\r
+       fi;\r
+       @echo Documentation Generation Complete.\r
+\r
+clean_doxygen:\r
+       rm -rf Documentation\r
+\r
+checksource:\r
+       @for f in $(SRC) $(CPPSRC) $(ASRC); do \\r
+               if [ -f $$f ]; then \\r
+                       echo "Found Source File: $$f" ; \\r
+               else \\r
+                       echo "Source File Not Found: $$f" ; \\r
+               fi; done \r
+\r
+\r
+# Create object files directory\r
+$(shell mkdir $(OBJDIR) 2>/dev/null)\r
+\r
+\r
+# Include the dependency files.\r
+-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*)\r
+\r
+\r
+# Listing of phony targets.\r
+.PHONY : all begin finish end sizebefore sizeafter gccversion \\r
+build elf hex eep lss sym coff extcoff doxygen clean          \\r
+clean_list clean_doxygen program dfu flip flip-ee dfu-ee      \\r
+debug gdb-config checksource\r
index d930137..ffd312d 100644 (file)
@@ -136,20 +136,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .HID_Interface =
@@ -183,10 +183,10 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | GENERIC_IN_EPNUM),
+                       .EndpointAddress        = GENERIC_IN_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = GENERIC_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 };
 
index 87ed01e..5f98143 100644 (file)
                #include "TempDataLogger.h"
 
        /* Macros: */
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
 
-               /** Endpoint number of the Generic HID reporting IN endpoint. */
-               #define GENERIC_IN_EPNUM               1
+               /** Endpoint address of the Generic HID reporting IN endpoint. */
+               #define GENERIC_IN_EPADDR              (ENDPOINT_DIR_IN  | 1)
 
                /** Size in bytes of the Generic HID reporting endpoint. */
                #define GENERIC_EPSIZE                 16
index 83590b3..9ead42e 100644 (file)
@@ -45,15 +45,18 @@ USB_ClassInfo_MS_Device_t Disk_MS_Interface =
                .Config =
                        {
                                .InterfaceNumber           = 0,
-
-                               .DataINEndpointNumber      = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize        = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
-
+                               .DataINEndpoint            =
+                                       {
+                                               .Address           = MASS_STORAGE_IN_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
+                               .DataOUTEndpoint           =
+                                       {
+                                               .Address           = MASS_STORAGE_OUT_EPADDR,
+                                               .Size              = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks             = 1,
+                                       },
                                .TotalLUNs                 = 1,
                        },
        };
@@ -70,11 +73,12 @@ USB_ClassInfo_HID_Device_t Generic_HID_Interface =
                .Config =
                        {
                                .InterfaceNumber              = 1,
-
-                               .ReportINEndpointNumber       = GENERIC_IN_EPNUM,
-                               .ReportINEndpointSize         = GENERIC_EPSIZE,
-                               .ReportINEndpointDoubleBank   = false,
-
+                               .ReportINEndpoint             =
+                                       {
+                                               .Address              = GENERIC_IN_EPADDR,
+                                               .Size                 = GENERIC_EPSIZE,
+                                               .Banks                = 1,
+                                       },
                                .PrevReportINBuffer           = PrevHIDReportBuffer,
                                .PrevReportINBufferSize       = sizeof(PrevHIDReportBuffer),
                        },
index e623a54..b7aa48c 100644 (file)
@@ -143,7 +143,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -169,20 +169,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 03f4e5e..e481793 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 194f6b0..7fe67da 100644 (file)
@@ -57,18 +57,24 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = false,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = false,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                        },
        };
 
index 54cec1c..57519c8 100644 (file)
@@ -157,7 +157,7 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -183,20 +183,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .RNDIS_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_Interface =
@@ -219,20 +219,20 @@ const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | MASS_STORAGE_IN_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .MS_DataOutEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | MASS_STORAGE_OUT_EPNUM),
+                       .EndpointAddress        = MASS_STORAGE_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = MASS_STORAGE_IO_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index b0e0c11..591947c 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the Mass Storage device-to-host data IN endpoint. */
-               #define MASS_STORAGE_IN_EPNUM          3
+               /** Endpoint address of the Mass Storage device-to-host data IN endpoint. */
+               #define MASS_STORAGE_IN_EPADDR         (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the Mass Storage host-to-device data OUT endpoint. */
-               #define MASS_STORAGE_OUT_EPNUM         4
+               /** Endpoint address of the Mass Storage host-to-device data OUT endpoint. */
+               #define MASS_STORAGE_OUT_EPADDR        (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the Mass Storage data endpoints. */
                #define MASS_STORAGE_IO_EPSIZE         64
 
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         5
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 5)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   1
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 1)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   2
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 2)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index 591ee92..158e759 100644 (file)
@@ -45,19 +45,24 @@ USB_ClassInfo_RNDIS_Device_t Ethernet_RNDIS_Interface_Device =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = true,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = true,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = true,
-
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                                .AdapterVendorDescription       = "LUFA RNDIS Adapter",
                                .AdapterMACAddress              = {{0x02, 0x00, 0x02, 0x00, 0x02, 0x00}},
                        },
@@ -71,16 +76,19 @@ USB_ClassInfo_MS_Device_t Disk_MS_Interface =
        {
                .Config =
                        {
-                               .InterfaceNumber           = 2,
-
-                               .DataINEndpointNumber      = MASS_STORAGE_IN_EPNUM,
-                               .DataINEndpointSize        = MASS_STORAGE_IO_EPSIZE,
-                               .DataINEndpointDoubleBank  = false,
-
-                               .DataOUTEndpointNumber     = MASS_STORAGE_OUT_EPNUM,
-                               .DataOUTEndpointSize       = MASS_STORAGE_IO_EPSIZE,
-                               .DataOUTEndpointDoubleBank = false,
-
+                               .InterfaceNumber                = 2,
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = MASS_STORAGE_IN_EPADDR,
+                                               .Size                   = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = MASS_STORAGE_OUT_EPADDR,
+                                               .Size                   = MASS_STORAGE_IO_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                                .TotalLUNs                 = 1,
                        },
        };
index e7091fc..601ebda 100644 (file)
@@ -44,16 +44,22 @@ USB_ClassInfo_RNDIS_Host_t Ethernet_RNDIS_Interface_Host =
        {
                .Config =
                        {
-                               .DataINPipeNumber           = 1,
-                               .DataINPipeDoubleBank       = false,
-
-                               .DataOUTPipeNumber          = 2,
-                               .DataOUTPipeDoubleBank      = false,
-
-                               .NotificationPipeNumber     = 3,
-                               .NotificationPipeDoubleBank = false,
-
-                               .HostMaxPacketSize          = UIP_CONF_BUFFER_SIZE,
+                               .DataINPipe             =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 1),
+                                               .Banks          = 1,
+                                       },
+                               .DataOUTPipe            =
+                                       {
+                                               .Address        = (PIPE_DIR_OUT | 2),
+                                               .Banks          = 1,
+                                       },
+                               .NotificationPipe       =
+                                       {
+                                               .Address        = (PIPE_DIR_IN  | 3),
+                                               .Banks          = 1,
+                                       },
+                               .HostMaxPacketSize      = UIP_CONF_BUFFER_SIZE,
                        },
        };
 
index 5f2071e..a901e09 100644 (file)
@@ -106,7 +106,7 @@ const AVRISP_USB_Descriptor_Configuration_t PROGMEM AVRISP_ConfigurationDescript
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | AVRISP_DATA_IN_EPNUM),
+                       .EndpointAddress        = AVRISP_DATA_IN_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = AVRISP_DATA_EPSIZE,
                        .PollingIntervalMS      = 0x0A
@@ -116,7 +116,7 @@ const AVRISP_USB_Descriptor_Configuration_t PROGMEM AVRISP_ConfigurationDescript
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | AVRISP_DATA_OUT_EPNUM),
+                       .EndpointAddress        = AVRISP_DATA_OUT_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = AVRISP_DATA_EPSIZE,
                        .PollingIntervalMS      = 0x0A
index 9487f68..c0eeedf 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               #if !defined(LIBUSB_DRIVER_COMPAT)
-                       /** Endpoint number of the AVRISP data OUT endpoint. */
-                       #define AVRISP_DATA_OUT_EPNUM      2
+               #if !defined(LIBUSB_DRIVER_COMPAT) || defined(__DOXYGEN__)
+                       /** Endpoint address of the AVRISP data OUT endpoint. */
+                       #define AVRISP_DATA_OUT_EPADDR     (ENDPOINT_DIR_OUT | 2)
 
-                       /** Endpoint number of the AVRISP data IN endpoint. */
-                       #define AVRISP_DATA_IN_EPNUM       2
+                       /** Endpoint address of the AVRISP data IN endpoint. */
+                       #define AVRISP_DATA_IN_EPADDR      (ENDPOINT_DIR_IN  | 2)
                #else
-                       /** Endpoint number of the AVRISP data OUT endpoint. */
-                       #define AVRISP_DATA_OUT_EPNUM      2
-
-                       /** Endpoint number of the AVRISP data IN endpoint. */
-                       #define AVRISP_DATA_IN_EPNUM       3
+                       #define AVRISP_DATA_OUT_EPADDR     (ENDPOINT_DIR_OUT | 2)
+                       #define AVRISP_DATA_IN_EPADDR      (ENDPOINT_DIR_IN  | 3)
                #endif
 
                /** Size in bytes of the AVRISP data endpoint. */
index 6b9c96d..5628d23 100644 (file)
@@ -26,7 +26,7 @@ DOXYFILE_ENCODING      = UTF-8
 # identify the project. Note that if you do not use Doxywizard you need
 # to put quotes around the project name if it contains spaces.
 
-PROJECT_NAME           = "LUFA Library - XPLAIN Serial Bridge/PDI Programmer Device Demo"
+PROJECT_NAME           = "LUFA Library - XPLAIN Serial Bridge/PDI Programmer Project"
 
 # The PROJECT_NUMBER tag can be used to enter a project or revision number.
 # This could be handy for archiving the generated documentation or
index 30039aa..6c131af 100644 (file)
@@ -143,7 +143,7 @@ const USART_USB_Descriptor_Configuration_t PROGMEM USART_ConfigurationDescriptor
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_NOTIFICATION_EPNUM),
+                       .EndpointAddress        = CDC_NOTIFICATION_EPADDR,
                        .Attributes             = (EP_TYPE_INTERRUPT | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_NOTIFICATION_EPSIZE,
                        .PollingIntervalMS      = 0xFF
@@ -169,20 +169,20 @@ const USART_USB_Descriptor_Configuration_t PROGMEM USART_ConfigurationDescriptor
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_OUT | CDC_RX_EPNUM),
+                       .EndpointAddress        = CDC_RX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                },
 
        .CDC_DataInEndpoint =
                {
                        .Header                 = {.Size = sizeof(USB_Descriptor_Endpoint_t), .Type = DTYPE_Endpoint},
 
-                       .EndpointAddress        = (ENDPOINT_DIR_IN | CDC_TX_EPNUM),
+                       .EndpointAddress        = CDC_TX_EPADDR,
                        .Attributes             = (EP_TYPE_BULK | ENDPOINT_ATTR_NO_SYNC | ENDPOINT_USAGE_DATA),
                        .EndpointSize           = CDC_TXRX_EPSIZE,
-                       .PollingIntervalMS      = 0x01
+                       .PollingIntervalMS      = 0x05
                }
 };
 
index 2569a72..4bb771b 100644 (file)
                #include <LUFA/Drivers/USB/USB.h>
 
        /* Macros: */
-               /** Endpoint number of the CDC device-to-host notification IN endpoint. */
-               #define CDC_NOTIFICATION_EPNUM         2
+               /** Endpoint address of the CDC device-to-host notification IN endpoint. */
+               #define CDC_NOTIFICATION_EPADDR        (ENDPOINT_DIR_IN  | 2)
 
-               /** Endpoint number of the CDC device-to-host data IN endpoint. */
-               #define CDC_TX_EPNUM                   3
+               /** Endpoint address of the CDC device-to-host data IN endpoint. */
+               #define CDC_TX_EPADDR                  (ENDPOINT_DIR_IN  | 3)
 
-               /** Endpoint number of the CDC host-to-device data OUT endpoint. */
-               #define CDC_RX_EPNUM                   4
+               /** Endpoint address of the CDC host-to-device data OUT endpoint. */
+               #define CDC_RX_EPADDR                  (ENDPOINT_DIR_OUT | 4)
 
                /** Size in bytes of the CDC device-to-host notification IN endpoint. */
                #define CDC_NOTIFICATION_EPSIZE        8
index bee770a..071c13e 100644 (file)
@@ -48,18 +48,24 @@ USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
                .Config =
                        {
                                .ControlInterfaceNumber         = 0,
-
-                               .DataINEndpointNumber           = CDC_TX_EPNUM,
-                               .DataINEndpointSize             = CDC_TXRX_EPSIZE,
-                               .DataINEndpointDoubleBank       = true,
-
-                               .DataOUTEndpointNumber          = CDC_RX_EPNUM,
-                               .DataOUTEndpointSize            = CDC_TXRX_EPSIZE,
-                               .DataOUTEndpointDoubleBank      = true,
-
-                               .NotificationEndpointNumber     = CDC_NOTIFICATION_EPNUM,
-                               .NotificationEndpointSize       = CDC_NOTIFICATION_EPSIZE,
-                               .NotificationEndpointDoubleBank = false,
+                               .DataINEndpoint                 =
+                                       {
+                                               .Address                = CDC_TX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .DataOUTEndpoint                =
+                                       {
+                                               .Address                = CDC_RX_EPADDR,
+                                               .Size                   = CDC_TXRX_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
+                               .NotificationEndpoint           =
+                                       {
+                                               .Address                = CDC_NOTIFICATION_EPADDR,
+                                               .Size                   = CDC_NOTIFICATION_EPSIZE,
+                                               .Banks                  = 1,
+                                       },
                        },
        };
 
@@ -105,7 +111,7 @@ void AVRISP_Task(void)
 
        V2Params_UpdateParamValues();
 
-       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPNUM);
+       Endpoint_SelectEndpoint(AVRISP_DATA_OUT_EPADDR);
 
        /* Check to see if a V2 Protocol command has been received */
        if (Endpoint_IsOUTReceived())
@@ -213,12 +219,10 @@ void EVENT_USB_Device_ConfigurationChanged(void)
        }
        else
        {
-               ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_OUT_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_OUT,
-                                                           AVRISP_DATA_EPSIZE, ENDPOINT_BANK_SINGLE);
+               ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_OUT_EPADDR, EP_TYPE_BULK, AVRISP_DATA_EPSIZE, 1);
 
                #if defined(LIBUSB_DRIVER_COMPAT)
-               ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_IN_EPNUM, EP_TYPE_BULK, ENDPOINT_DIR_IN,
-                                                           AVRISP_DATA_EPSIZE, ENDPOINT_BANK_SINGLE);
+               ConfigSuccess &= Endpoint_ConfigureEndpoint(AVRISP_DATA_IN_EPADDR, EP_TYPE_BULK, AVRISP_DATA_EPSIZE, 1);
                #endif
 
                /* Configure the V2 protocol packet handler */
index 5570a1a..33c66bf 100644 (file)
@@ -46,9 +46,7 @@
                #include "AVRISPDescriptors.h"
                #include "USARTDescriptors.h"
                
-               // cppcheck-suppress missingInclude
                #include "Lib/V2Protocol.h"
-               // cppcheck-suppress missingInclude
                #include "Lib/SoftUART.h"
 
                #include <LUFA/Version.h>
index 9dead42..e71d06a 100644 (file)
  *    <td><b>Description:</b></td>
  *   </tr>
  *   <tr>
- *    <td>BUFFER_SIZE</td>
- *    <td>LightweightRingBuff.h</td>
- *    <td>Defines the maximum number of bytes which can be buffered in each Ring Buffer when in serial bridge mode.</td>
- *   </tr>
- *   <tr>
  *    <td>LIBUSB_DRIVER_COMPAT</td>
  *    <td>Makefile LUFA_OPTS</td>
  *    <td>Define to switch to a non-standard endpoint scheme, breaking compatibility with AVRStudio under Windows but making
index 707188c..d8fe77a 100644 (file)
@@ -41,6 +41,9 @@ all:
        $(MAKE) -C RelayBoard clean
        $(MAKE) -C RelayBoard all
 
+       $(MAKE) -C SerialToLCD clean
+       $(MAKE) -C SerialToLCD all
+
        $(MAKE) -C TempDataLogger clean
        $(MAKE) -C TempDataLogger all
 
@@ -63,6 +66,7 @@ all:
        $(MAKE) -C MIDIToneGenerator $@ 
        $(MAKE) -C MissileLauncher $@
        $(MAKE) -C RelayBoard $@
+       $(MAKE) -C SerialToLCD $@
        $(MAKE) -C TempDataLogger $@
        $(MAKE) -C USBtoSerial $@
        $(MAKE) -C Webserver $@