diff options
Diffstat (limited to 'Demos')
87 files changed, 213 insertions, 127 deletions
diff --git a/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.c b/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.c index d103b5d33..a4248e201 100644 --- a/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.c +++ b/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.c @@ -91,12 +91,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.h b/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.h index d0abfeff6..58b18e94c 100644 --- a/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.h +++ b/Demos/Host/ClassDriver/AndroidAccessoryHost/AndroidAccessoryHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/AndroidAccessoryHost/asf.xml b/Demos/Host/ClassDriver/AndroidAccessoryHost/asf.xml index 19c6348c2..c31e66320 100644 --- a/Demos/Host/ClassDriver/AndroidAccessoryHost/asf.xml +++ b/Demos/Host/ClassDriver/AndroidAccessoryHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Android Accessory Host Demo (Class Driver APIs)" id="lufa.demos.host.class.android.example">
+ <project caption="Android Accessory Host Demo (Class Driver APIs)" id="lufa.demos.host.class.android.example.avr8">
<require idref="lufa.demos.host.class.android"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.android" caption="Android Accessory Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.c b/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.c index bc6ade835..fe0235688 100644 --- a/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.c +++ b/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.c @@ -106,12 +106,14 @@ ISR(TIMER0_COMPA_vect, ISR_BLOCK) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.h b/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.h index b802a58ac..3da8d88f4 100644 --- a/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.h +++ b/Demos/Host/ClassDriver/AudioInputHost/AudioInputHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/AudioInputHost/asf.xml b/Demos/Host/ClassDriver/AudioInputHost/asf.xml index 5c28af91c..ac0d067fb 100644 --- a/Demos/Host/ClassDriver/AudioInputHost/asf.xml +++ b/Demos/Host/ClassDriver/AudioInputHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Audio Input Host Demo (Class Driver APIs)" id="lufa.demos.host.class.audio_input.example">
+ <project caption="Audio Input Host Demo (Class Driver APIs)" id="lufa.demos.host.class.audio_input.example.avr8">
<require idref="lufa.demos.host.class.audio_input"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.audio_input" caption="Audio Input Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.c b/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.c index 30e60e5da..6faa8fe30 100644 --- a/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.c +++ b/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.c @@ -111,12 +111,14 @@ ISR(TIMER0_COMPA_vect, ISR_BLOCK) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); @@ -128,9 +130,9 @@ void SetupHardware(void) /* Create a stdio stream for the serial port for stdin and stdout */ Serial_CreateStream(NULL); - + /* Start the ADC conversion in free running mode */ - ADC_StartReading(ADC_REFERENCE_AVCC | ADC_RIGHT_ADJUSTED | ADC_GET_CHANNEL_MASK(MIC_IN_ADC_CHANNEL)); + ADC_StartReading(ADC_REFERENCE_AVCC | ADC_RIGHT_ADJUSTED | ADC_GET_CHANNEL_MASK(MIC_IN_ADC_CHANNEL)); } /** Event handler for the USB_DeviceAttached event. This indicates that a device has been attached to the host, and diff --git a/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.h b/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.h index 35f881cd5..543f88ddc 100644 --- a/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.h +++ b/Demos/Host/ClassDriver/AudioOutputHost/AudioOutputHost.h @@ -50,7 +50,8 @@ #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/Board/Buttons.h> #include <LUFA/Drivers/USB/USB.h> - + #include <LUFA/Platform/Platform.h> + #include "Config/AppConfig.h" /* Macros: */ diff --git a/Demos/Host/ClassDriver/AudioOutputHost/asf.xml b/Demos/Host/ClassDriver/AudioOutputHost/asf.xml index 19f915c01..5b53faffd 100644 --- a/Demos/Host/ClassDriver/AudioOutputHost/asf.xml +++ b/Demos/Host/ClassDriver/AudioOutputHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Audio Output Host Demo (Class Driver APIs)" id="lufa.demos.host.class.audio_output.example">
+ <project caption="Audio Output Host Demo (Class Driver APIs)" id="lufa.demos.host.class.audio_output.example.avr8">
<require idref="lufa.demos.host.class.audio_output"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.audio_output" caption="Audio Output Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c index e2f49bcd6..dc0532e6a 100644 --- a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c +++ b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.c @@ -87,12 +87,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h index e29040790..b66216e1b 100644 --- a/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h +++ b/Demos/Host/ClassDriver/JoystickHostWithParser/JoystickHostWithParser.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/JoystickHostWithParser/asf.xml b/Demos/Host/ClassDriver/JoystickHostWithParser/asf.xml index 29eb91764..54a5a2ce5 100644 --- a/Demos/Host/ClassDriver/JoystickHostWithParser/asf.xml +++ b/Demos/Host/ClassDriver/JoystickHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Joystick HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.joystick_parser.example">
+ <project caption="Joystick HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.joystick_parser.example.avr8">
<require idref="lufa.demos.host.class.joystick_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.joystick_parser" caption="Joystick HID (with parser) Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c index 95b96cd3f..ee86cfcdd 100644 --- a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c +++ b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.c @@ -83,12 +83,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h index e890df455..aaf0477a2 100644 --- a/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h +++ b/Demos/Host/ClassDriver/KeyboardHost/KeyboardHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/KeyboardHost/asf.xml b/Demos/Host/ClassDriver/KeyboardHost/asf.xml index 76762067f..f9d6067e0 100644 --- a/Demos/Host/ClassDriver/KeyboardHost/asf.xml +++ b/Demos/Host/ClassDriver/KeyboardHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Keyboard HID Host Demo (Class Driver APIs)" id="lufa.demos.host.class.keyboard.example">
+ <project caption="Keyboard HID Host Demo (Class Driver APIs)" id="lufa.demos.host.class.keyboard.example.avr8">
<require idref="lufa.demos.host.class.keyboard"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.keyboard" caption="Keyboard HID Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c index 58c5029f6..c47d719ee 100644 --- a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c +++ b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.c @@ -87,12 +87,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h index 63078fb0f..643e2f3af 100644 --- a/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h +++ b/Demos/Host/ClassDriver/KeyboardHostWithParser/KeyboardHostWithParser.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/KeyboardHostWithParser/asf.xml b/Demos/Host/ClassDriver/KeyboardHostWithParser/asf.xml index c7352f641..fdd3e7997 100644 --- a/Demos/Host/ClassDriver/KeyboardHostWithParser/asf.xml +++ b/Demos/Host/ClassDriver/KeyboardHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Keyboard HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.keyboard_parser.example">
+ <project caption="Keyboard HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.keyboard_parser.example.avr8">
<require idref="lufa.demos.host.class.keyboard_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.keyboard_parser" caption="Keyboard HID (with parser) Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c index 6e8c3e244..1160f6319 100644 --- a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c +++ b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.c @@ -82,12 +82,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h index 1b8619d7e..db1aaf612 100644 --- a/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h +++ b/Demos/Host/ClassDriver/MIDIHost/MIDIHost.h @@ -50,6 +50,7 @@ #include <LUFA/Drivers/Board/Buttons.h> #include <LUFA/Drivers/Board/Joystick.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/MIDIHost/asf.xml b/Demos/Host/ClassDriver/MIDIHost/asf.xml index 3ae82cbf8..b52521f47 100644 --- a/Demos/Host/ClassDriver/MIDIHost/asf.xml +++ b/Demos/Host/ClassDriver/MIDIHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="MIDI Host Demo (Class Driver APIs)" id="lufa.demos.host.class.midi.example">
+ <project caption="MIDI Host Demo (Class Driver APIs)" id="lufa.demos.host.class.midi.example.avr8">
<require idref="lufa.demos.host.class.midi"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.midi" caption="MIDI Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c index a09ae54e9..ead53a801 100644 --- a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c +++ b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.c @@ -82,12 +82,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h index d3a906a61..519aad713 100644 --- a/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h +++ b/Demos/Host/ClassDriver/MassStorageHost/MassStorageHost.h @@ -49,6 +49,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/MassStorageHost/asf.xml b/Demos/Host/ClassDriver/MassStorageHost/asf.xml index 7eb2a6b54..dbc871e9d 100644 --- a/Demos/Host/ClassDriver/MassStorageHost/asf.xml +++ b/Demos/Host/ClassDriver/MassStorageHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mass Storage Host Demo (Class Driver APIs)" id="lufa.demos.host.class.ms.example">
+ <project caption="Mass Storage Host Demo (Class Driver APIs)" id="lufa.demos.host.class.ms.example.avr8">
<require idref="lufa.demos.host.class.ms"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.ms" caption="Mass Storage Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/MouseHost/MouseHost.c b/Demos/Host/ClassDriver/MouseHost/MouseHost.c index e56590262..7b3d20b54 100644 --- a/Demos/Host/ClassDriver/MouseHost/MouseHost.c +++ b/Demos/Host/ClassDriver/MouseHost/MouseHost.c @@ -83,12 +83,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/MouseHost/MouseHost.h b/Demos/Host/ClassDriver/MouseHost/MouseHost.h index d6c50f9e5..b25664174 100644 --- a/Demos/Host/ClassDriver/MouseHost/MouseHost.h +++ b/Demos/Host/ClassDriver/MouseHost/MouseHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/MouseHost/asf.xml b/Demos/Host/ClassDriver/MouseHost/asf.xml index 1bc0a3104..ecc621854 100644 --- a/Demos/Host/ClassDriver/MouseHost/asf.xml +++ b/Demos/Host/ClassDriver/MouseHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mouse HID Host Demo (Class Driver APIs)" id="lufa.demos.host.class.mouse.example">
+ <project caption="Mouse HID Host Demo (Class Driver APIs)" id="lufa.demos.host.class.mouse.example.avr8">
<require idref="lufa.demos.host.class.mouse"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.mouse" caption="Mouse HID Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c index 0ecab535f..265a8f66c 100644 --- a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c +++ b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.c @@ -87,12 +87,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h index cb5c3130f..d0dd9a9ff 100644 --- a/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h +++ b/Demos/Host/ClassDriver/MouseHostWithParser/MouseHostWithParser.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/MouseHostWithParser/asf.xml b/Demos/Host/ClassDriver/MouseHostWithParser/asf.xml index c1a475578..a9ca34bff 100644 --- a/Demos/Host/ClassDriver/MouseHostWithParser/asf.xml +++ b/Demos/Host/ClassDriver/MouseHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mouse HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.mouse_parser.example">
+ <project caption="Mouse HID (with parser) Host Demo (Class Driver APIs)" id="lufa.demos.host.class.mouse_parser.example.avr8">
<require idref="lufa.demos.host.class.mouse_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.mouse_parser" caption="Mouse HID (with parser) Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c index 4c8229190..3a19a7efd 100644 --- a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c +++ b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.c @@ -82,12 +82,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h index 0bbec9ff1..6d289d18a 100644 --- a/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h +++ b/Demos/Host/ClassDriver/PrinterHost/PrinterHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/PrinterHost/asf.xml b/Demos/Host/ClassDriver/PrinterHost/asf.xml index 69b4e1314..fa704ff5e 100644 --- a/Demos/Host/ClassDriver/PrinterHost/asf.xml +++ b/Demos/Host/ClassDriver/PrinterHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Printer Host Demo (Class Driver APIs)" id="lufa.demos.host.class.printer.example">
+ <project caption="Printer Host Demo (Class Driver APIs)" id="lufa.demos.host.class.printer.example.avr8">
<require idref="lufa.demos.host.class.printer"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.printer" caption="Printer Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c index b512735d1..50e2e50b3 100644 --- a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c +++ b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.c @@ -117,12 +117,14 @@ void RNDISHost_Task(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h index 602421c80..965ff447a 100644 --- a/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h +++ b/Demos/Host/ClassDriver/RNDISEthernetHost/RNDISEthernetHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/RNDISEthernetHost/asf.xml b/Demos/Host/ClassDriver/RNDISEthernetHost/asf.xml index 5c55c5a70..8199f2d92 100644 --- a/Demos/Host/ClassDriver/RNDISEthernetHost/asf.xml +++ b/Demos/Host/ClassDriver/RNDISEthernetHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="RNDIS Ethernet Host Demo (Class Driver APIs)" id="lufa.demos.host.class.rndis.example">
+ <project caption="RNDIS Ethernet Host Demo (Class Driver APIs)" id="lufa.demos.host.class.rndis.example.avr8">
<require idref="lufa.demos.host.class.rndis"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.rndis" caption="RNDIS Ethernet Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c index 35a98eb23..a08be2115 100644 --- a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c +++ b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.c @@ -87,12 +87,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h index abe0e0581..e8110a6d9 100644 --- a/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h +++ b/Demos/Host/ClassDriver/StillImageHost/StillImageHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/StillImageHost/asf.xml b/Demos/Host/ClassDriver/StillImageHost/asf.xml index 3703164f4..947178288 100644 --- a/Demos/Host/ClassDriver/StillImageHost/asf.xml +++ b/Demos/Host/ClassDriver/StillImageHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Still Image Host Demo (Class Driver APIs)" id="lufa.demos.host.class.si.example">
+ <project caption="Still Image Host Demo (Class Driver APIs)" id="lufa.demos.host.class.si.example.avr8">
<require idref="lufa.demos.host.class.si"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.si" caption="Still Image Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c index 13c8018ed..c20a7dead 100644 --- a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c +++ b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.c @@ -87,12 +87,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); @@ -170,17 +172,17 @@ void EVENT_USB_Host_DeviceEnumerationComplete(void) LEDs_SetAllLEDs(LEDMASK_USB_ERROR); return; } - + VirtualSerial_CDC_Interface.State.LineEncoding.BaudRateBPS = 9600; VirtualSerial_CDC_Interface.State.LineEncoding.CharFormat = CDC_LINEENCODING_OneStopBit; VirtualSerial_CDC_Interface.State.LineEncoding.ParityType = CDC_PARITY_None; VirtualSerial_CDC_Interface.State.LineEncoding.DataBits = 8; - + if (CDC_Host_SetLineEncoding(&VirtualSerial_CDC_Interface)) { puts_P(PSTR("Error Setting Device Line Encoding.\r\n")); LEDs_SetAllLEDs(LEDMASK_USB_ERROR); - return; + return; } puts_P(PSTR("CDC Device Enumerated.\r\n")); diff --git a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h index 4aec83051..1c63166ec 100644 --- a/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h +++ b/Demos/Host/ClassDriver/VirtualSerialHost/VirtualSerialHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/ClassDriver/VirtualSerialHost/asf.xml b/Demos/Host/ClassDriver/VirtualSerialHost/asf.xml index 67eb347cd..4d0ebb0f8 100644 --- a/Demos/Host/ClassDriver/VirtualSerialHost/asf.xml +++ b/Demos/Host/ClassDriver/VirtualSerialHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Virtual Serial CDC Host Demo (Class Driver APIs)" id="lufa.demos.host.class.cdc.example">
+ <project caption="Virtual Serial CDC Host Demo (Class Driver APIs)" id="lufa.demos.host.class.cdc.example.avr8">
<require idref="lufa.demos.host.class.cdc"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.class.cdc" caption="Virtual Serial CDC Host Demo (Class Driver APIs)">
diff --git a/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.c b/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.c index 72190a42b..e84b877b8 100644 --- a/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.c +++ b/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.c @@ -58,12 +58,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.h b/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.h index 5383d86c4..395206d40 100644 --- a/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.h +++ b/Demos/Host/LowLevel/AndroidAccessoryHost/AndroidAccessoryHost.h @@ -52,6 +52,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/LowLevel/AndroidAccessoryHost/asf.xml b/Demos/Host/LowLevel/AndroidAccessoryHost/asf.xml index 0100f60ee..9d95cb5d2 100644 --- a/Demos/Host/LowLevel/AndroidAccessoryHost/asf.xml +++ b/Demos/Host/LowLevel/AndroidAccessoryHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Android Accessory Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.android.example">
+ <project caption="Android Accessory Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.android.example.avr8">
<require idref="lufa.demos.host.lowlevel.android"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.android" caption="Android Accessory Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.c b/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.c index 9e6ddd360..a4d083b9f 100644 --- a/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.c +++ b/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.c @@ -57,12 +57,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.h b/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.h index febd6eae7..abf19732c 100644 --- a/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.h +++ b/Demos/Host/LowLevel/AudioInputHost/AudioInputHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/AudioInputHost/asf.xml b/Demos/Host/LowLevel/AudioInputHost/asf.xml index f043fb9ed..6c565b3bc 100644 --- a/Demos/Host/LowLevel/AudioInputHost/asf.xml +++ b/Demos/Host/LowLevel/AudioInputHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Audio Input Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.audio_input.example">
+ <project caption="Audio Input Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.audio_input.example.avr8">
<require idref="lufa.demos.host.lowlevel.audio_input"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.audio_input" caption="Audio Input Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.c b/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.c index dfe0609a8..5d6250882 100644 --- a/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.c +++ b/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.c @@ -57,12 +57,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); @@ -76,7 +78,7 @@ void SetupHardware(void) Serial_CreateStream(NULL); /* Start the ADC conversion in free running mode */ - ADC_StartReading(ADC_REFERENCE_AVCC | ADC_RIGHT_ADJUSTED | ADC_GET_CHANNEL_MASK(MIC_IN_ADC_CHANNEL)); + ADC_StartReading(ADC_REFERENCE_AVCC | ADC_RIGHT_ADJUSTED | ADC_GET_CHANNEL_MASK(MIC_IN_ADC_CHANNEL)); } /** Event handler for the USB_DeviceAttached event. This indicates that a device has been attached to the host, and diff --git a/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.h b/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.h index 58655ba28..3c4ef5b80 100644 --- a/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.h +++ b/Demos/Host/LowLevel/AudioOutputHost/AudioOutputHost.h @@ -50,6 +50,7 @@ #include <LUFA/Drivers/Peripheral/ADC.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/Board/Buttons.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" #include "Config/AppConfig.h" diff --git a/Demos/Host/LowLevel/AudioOutputHost/asf.xml b/Demos/Host/LowLevel/AudioOutputHost/asf.xml index 200832452..a56c84d09 100644 --- a/Demos/Host/LowLevel/AudioOutputHost/asf.xml +++ b/Demos/Host/LowLevel/AudioOutputHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Audio Output Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.audio_output.example">
+ <project caption="Audio Output Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.audio_output.example.avr8">
<require idref="lufa.demos.host.lowlevel.audio_output"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.audio_output" caption="Audio Output Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c index 392620461..35794df0e 100644 --- a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c +++ b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h index ac9cd24bc..8c05d301e 100644 --- a/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h +++ b/Demos/Host/LowLevel/GenericHIDHost/GenericHIDHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/GenericHIDHost/asf.xml b/Demos/Host/LowLevel/GenericHIDHost/asf.xml index 17cc78aa0..12df51faa 100644 --- a/Demos/Host/LowLevel/GenericHIDHost/asf.xml +++ b/Demos/Host/LowLevel/GenericHIDHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Generic HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.generic_hid.example">
+ <project caption="Generic HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.generic_hid.example.avr8">
<require idref="lufa.demos.host.lowlevel.generic_hid"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.generic_hid" caption="Generic HID Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.c b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.c index bc5a457da..35e34692b 100644 --- a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.c +++ b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h index a6acd1a24..90bc70f41 100644 --- a/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h +++ b/Demos/Host/LowLevel/JoystickHostWithParser/JoystickHostWithParser.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" #include "HIDReport.h" diff --git a/Demos/Host/LowLevel/JoystickHostWithParser/asf.xml b/Demos/Host/LowLevel/JoystickHostWithParser/asf.xml index 245051995..cf877064d 100644 --- a/Demos/Host/LowLevel/JoystickHostWithParser/asf.xml +++ b/Demos/Host/LowLevel/JoystickHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Joystick HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.joystick_parser.example">
+ <project caption="Joystick HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.joystick_parser.example.avr8">
<require idref="lufa.demos.host.lowlevel.joystick_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.joystick_parser" caption="Joystick HID (with parser) Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c index a5a24aba9..f10191a0e 100644 --- a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c +++ b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h index 0f38db74f..e11e63f7f 100644 --- a/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h +++ b/Demos/Host/LowLevel/KeyboardHost/KeyboardHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/KeyboardHost/asf.xml b/Demos/Host/LowLevel/KeyboardHost/asf.xml index db3efd16b..32a88aff8 100644 --- a/Demos/Host/LowLevel/KeyboardHost/asf.xml +++ b/Demos/Host/LowLevel/KeyboardHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Keyboard HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.keyboard.example">
+ <project caption="Keyboard HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.keyboard.example.avr8">
<require idref="lufa.demos.host.lowlevel.keyboard"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.keyboard" caption="Keyboard HID Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c index 9587d7108..e02d583e5 100644 --- a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c +++ b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h index 7d384d6d2..14a56931a 100644 --- a/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h +++ b/Demos/Host/LowLevel/KeyboardHostWithParser/KeyboardHostWithParser.h @@ -43,6 +43,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" #include "HIDReport.h" diff --git a/Demos/Host/LowLevel/KeyboardHostWithParser/asf.xml b/Demos/Host/LowLevel/KeyboardHostWithParser/asf.xml index e6f343deb..1b781972c 100644 --- a/Demos/Host/LowLevel/KeyboardHostWithParser/asf.xml +++ b/Demos/Host/LowLevel/KeyboardHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Keyboard HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.keyboard_parser.example">
+ <project caption="Keyboard HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.keyboard_parser.example.avr8">
<require idref="lufa.demos.host.lowlevel.keyboard_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.keyboard_parser" caption="Keyboard HID (with parser) Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/MIDIHost/MIDIHost.c b/Demos/Host/LowLevel/MIDIHost/MIDIHost.c index 7cef4427d..620cbc988 100644 --- a/Demos/Host/LowLevel/MIDIHost/MIDIHost.c +++ b/Demos/Host/LowLevel/MIDIHost/MIDIHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); @@ -188,7 +190,7 @@ void MIDIHost_Task(void) MIDIEvent.Data2, MIDIEvent.Data3); } } - + Pipe_Freeze(); Pipe_SelectPipe(MIDI_DATA_OUT_PIPE); diff --git a/Demos/Host/LowLevel/MIDIHost/MIDIHost.h b/Demos/Host/LowLevel/MIDIHost/MIDIHost.h index 73933c03a..fd250016c 100644 --- a/Demos/Host/LowLevel/MIDIHost/MIDIHost.h +++ b/Demos/Host/LowLevel/MIDIHost/MIDIHost.h @@ -50,6 +50,7 @@ #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/Board/Buttons.h> #include <LUFA/Drivers/Board/Joystick.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/MIDIHost/asf.xml b/Demos/Host/LowLevel/MIDIHost/asf.xml index 1ecde005a..862f71928 100644 --- a/Demos/Host/LowLevel/MIDIHost/asf.xml +++ b/Demos/Host/LowLevel/MIDIHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="MIDI Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.midi.example">
+ <project caption="MIDI Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.midi.example.avr8">
<require idref="lufa.demos.host.lowlevel.midi"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.midi" caption="MIDI Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c index b3757981c..ff32da5bf 100644 --- a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c +++ b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.c @@ -63,12 +63,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h index 2229ff3b9..429193dd6 100644 --- a/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h +++ b/Demos/Host/LowLevel/MassStorageHost/MassStorageHost.h @@ -55,6 +55,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/Board/Buttons.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/LowLevel/MassStorageHost/asf.xml b/Demos/Host/LowLevel/MassStorageHost/asf.xml index fd93fc644..1ee5870ba 100644 --- a/Demos/Host/LowLevel/MassStorageHost/asf.xml +++ b/Demos/Host/LowLevel/MassStorageHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mass Storage Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.ms.example">
+ <project caption="Mass Storage Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.ms.example.avr8">
<require idref="lufa.demos.host.lowlevel.ms"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.ms" caption="Mass Storage Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/MouseHost/MouseHost.c b/Demos/Host/LowLevel/MouseHost/MouseHost.c index b24d1ae72..a9225a1df 100644 --- a/Demos/Host/LowLevel/MouseHost/MouseHost.c +++ b/Demos/Host/LowLevel/MouseHost/MouseHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/MouseHost/MouseHost.h b/Demos/Host/LowLevel/MouseHost/MouseHost.h index 6bbb71a1e..4dddd2074 100644 --- a/Demos/Host/LowLevel/MouseHost/MouseHost.h +++ b/Demos/Host/LowLevel/MouseHost/MouseHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/MouseHost/asf.xml b/Demos/Host/LowLevel/MouseHost/asf.xml index 8fca686c1..30aa33dbc 100644 --- a/Demos/Host/LowLevel/MouseHost/asf.xml +++ b/Demos/Host/LowLevel/MouseHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mouse HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.mouse.example">
+ <project caption="Mouse HID Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.mouse.example.avr8">
<require idref="lufa.demos.host.lowlevel.mouse"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.mouse" caption="Mouse HID Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c index 81c734395..438c6fee9 100644 --- a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c +++ b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h index 8d907d7df..d0744e522 100644 --- a/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h +++ b/Demos/Host/LowLevel/MouseHostWithParser/MouseHostWithParser.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> #include <LUFA/Drivers/USB/USB.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" #include "HIDReport.h" diff --git a/Demos/Host/LowLevel/MouseHostWithParser/asf.xml b/Demos/Host/LowLevel/MouseHostWithParser/asf.xml index afc321afe..f5a76a365 100644 --- a/Demos/Host/LowLevel/MouseHostWithParser/asf.xml +++ b/Demos/Host/LowLevel/MouseHostWithParser/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Mouse HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.mouse_parser.example">
+ <project caption="Mouse HID (with parser) Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.mouse_parser.example.avr8">
<require idref="lufa.demos.host.lowlevel.mouse_parser"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.mouse_parser" caption="Mouse HID (with parser) Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/PrinterHost/PrinterHost.c b/Demos/Host/LowLevel/PrinterHost/PrinterHost.c index 31b0145b4..c028f2823 100644 --- a/Demos/Host/LowLevel/PrinterHost/PrinterHost.c +++ b/Demos/Host/LowLevel/PrinterHost/PrinterHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/PrinterHost/PrinterHost.h b/Demos/Host/LowLevel/PrinterHost/PrinterHost.h index 7998b98a9..69cfb9129 100644 --- a/Demos/Host/LowLevel/PrinterHost/PrinterHost.h +++ b/Demos/Host/LowLevel/PrinterHost/PrinterHost.h @@ -52,6 +52,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/LowLevel/PrinterHost/asf.xml b/Demos/Host/LowLevel/PrinterHost/asf.xml index abe73c5ae..f24a1e164 100644 --- a/Demos/Host/LowLevel/PrinterHost/asf.xml +++ b/Demos/Host/LowLevel/PrinterHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Printer Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.printer.example">
+ <project caption="Printer Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.printer.example.avr8">
<require idref="lufa.demos.host.lowlevel.printer"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.printer" caption="Printer Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c index e92b3146b..d01bc3a90 100644 --- a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c +++ b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h index cb77075f9..9843b64a2 100644 --- a/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h +++ b/Demos/Host/LowLevel/RNDISEthernetHost/RNDISEthernetHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "Lib/RNDISCommands.h" diff --git a/Demos/Host/LowLevel/RNDISEthernetHost/asf.xml b/Demos/Host/LowLevel/RNDISEthernetHost/asf.xml index fafffbf08..7f64c8415 100644 --- a/Demos/Host/LowLevel/RNDISEthernetHost/asf.xml +++ b/Demos/Host/LowLevel/RNDISEthernetHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="RNDIS Ethernet Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.rndis.example">
+ <project caption="RNDIS Ethernet Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.rndis.example.avr8">
<require idref="lufa.demos.host.lowlevel.rndis"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.rndis" caption="RNDIS Ethernet Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/StillImageHost/StillImageHost.c b/Demos/Host/LowLevel/StillImageHost/StillImageHost.c index 779827a9c..89e7996f7 100644 --- a/Demos/Host/LowLevel/StillImageHost/StillImageHost.c +++ b/Demos/Host/LowLevel/StillImageHost/StillImageHost.c @@ -59,13 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); - /* Disable Clock Division */ - CLKPR = (1 << CLKPCE); - CLKPR = 0; + /* Disable clock division */ + clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/StillImageHost/StillImageHost.h b/Demos/Host/LowLevel/StillImageHost/StillImageHost.h index 8ce267d0e..2d2181c94 100644 --- a/Demos/Host/LowLevel/StillImageHost/StillImageHost.h +++ b/Demos/Host/LowLevel/StillImageHost/StillImageHost.h @@ -51,6 +51,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> /* Macros: */ /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ diff --git a/Demos/Host/LowLevel/StillImageHost/asf.xml b/Demos/Host/LowLevel/StillImageHost/asf.xml index 5645c292a..6592bf3b1 100644 --- a/Demos/Host/LowLevel/StillImageHost/asf.xml +++ b/Demos/Host/LowLevel/StillImageHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Still Image Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.si.example">
+ <project caption="Still Image Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.si.example.avr8">
<require idref="lufa.demos.host.lowlevel.si"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.si" caption="Still Image Host Demo (Low Level APIs)">
diff --git a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c index 73a5b9c74..59bd2b478 100644 --- a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c +++ b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.c @@ -59,12 +59,14 @@ int main(void) /** Configures the board hardware and chip peripherals for the demo's functionality. */ void SetupHardware(void) { +#if (ARCH == ARCH_AVR8) /* Disable watchdog if enabled by bootloader/fuses */ MCUSR &= ~(1 << WDRF); wdt_disable(); /* Disable clock division */ clock_prescale_set(clock_div_1); +#endif /* Hardware Initialization */ Serial_Init(9600, false); diff --git a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h index 05d94a8d8..486aed188 100644 --- a/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h +++ b/Demos/Host/LowLevel/VirtualSerialHost/VirtualSerialHost.h @@ -48,6 +48,7 @@ #include <LUFA/Drivers/USB/USB.h> #include <LUFA/Drivers/Peripheral/Serial.h> #include <LUFA/Drivers/Board/LEDs.h> + #include <LUFA/Platform/Platform.h> #include "ConfigDescriptor.h" diff --git a/Demos/Host/LowLevel/VirtualSerialHost/asf.xml b/Demos/Host/LowLevel/VirtualSerialHost/asf.xml index 783862d7b..cfe4e2f86 100644 --- a/Demos/Host/LowLevel/VirtualSerialHost/asf.xml +++ b/Demos/Host/LowLevel/VirtualSerialHost/asf.xml @@ -1,14 +1,14 @@ <asf xmlversion="1.0">
- <project caption="Virtual Serial CDC Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.cdc.example">
+ <project caption="Virtual Serial CDC Host Demo (Low Level APIs)" id="lufa.demos.host.lowlevel.cdc.example.avr8">
<require idref="lufa.demos.host.lowlevel.cdc"/>
<require idref="lufa.boards.dummy.avr8"/>
<generator value="as5_8"/>
<device-support value="at90usb1287"/>
- <config name="lufa.drivers.board.name" value="usbkey"/>
+ <config name="lufa.drivers.board.name" value="none"/>
- <build type="define" name="F_CPU" value="8000000UL"/>
- <build type="define" name="F_USB" value="8000000UL"/>
+ <build type="define" name="F_CPU" value="16000000UL"/>
+ <build type="define" name="F_USB" value="16000000UL"/>
</project>
<module type="application" id="lufa.demos.host.lowlevel.cdc" caption="Virtual Serial CDC Host Demo (Low Level APIs)">
|