X-Git-Url: http://git.linex4red.de/pub/USBasp.git/blobdiff_plain/c5038f1bf44aea75f1ae1ed035cb7d523ccfdacb..03ee87b35abdb8b92e8b55ec040fa943f9a6786c:/LUFA/Drivers/USB/LowLevel/LowLevel.h?ds=inline diff --git a/LUFA/Drivers/USB/LowLevel/LowLevel.h b/LUFA/Drivers/USB/LowLevel/LowLevel.h index b8f7b9de1..dc01d24e5 100644 --- a/LUFA/Drivers/USB/LowLevel/LowLevel.h +++ b/LUFA/Drivers/USB/LowLevel/LowLevel.h @@ -1,21 +1,21 @@ /* LUFA Library - Copyright (C) Dean Camera, 2009. + Copyright (C) Dean Camera, 2010. dean [at] fourwalledcubicle [dot] com www.fourwalledcubicle.com */ /* - Copyright 2009 Dean Camera (dean [at] fourwalledcubicle [dot] com) + Copyright 2010 Dean Camera (dean [at] fourwalledcubicle [dot] com) - Permission to use, copy, modify, and distribute this software - and its documentation for any purpose and without fee is hereby - granted, 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 + 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 @@ -71,11 +71,13 @@ /* Preprocessor Checks and Defines: */ #if !defined(F_CLOCK) - #error F_CLOCK is not defined. You must device F_CLOCK to the frequency of the unprescaled input clock in your project makefile. + #error F_CLOCK is not defined. You must define F_CLOCK to the frequency of the unprescaled input clock in your project makefile. #endif #if (F_CLOCK == 8000000) - #if (defined(__AVR_AT90USB82__) || defined(__AVR_AT90USB162__)) + #if (defined(__AVR_AT90USB82__) || defined(__AVR_AT90USB162__) || \ + defined(__AVR_ATmega8U2__) || defined(__AVR_ATmega16U2__) || \ + defined(__AVR_ATmega32U2__)) #define USB_PLL_PSC 0 #elif (defined(__AVR_ATmega16U4__) || defined(__AVR_ATmega32U4__)) #define USB_PLL_PSC 0 @@ -85,7 +87,9 @@ #define USB_PLL_PSC ((1 << PLLP1) | (1 << PLLP0)) #endif #elif (F_CLOCK == 16000000) - #if (defined(__AVR_AT90USB82__) || defined(__AVR_AT90USB162__)) + #if (defined(__AVR_AT90USB82__) || defined(__AVR_AT90USB162__) || \ + defined(__AVR_ATmega8U2__) || defined(__AVR_ATmega16U2__) || \ + defined(__AVR_ATmega32U2__)) #define USB_PLL_PSC (1 << PLLP0) #elif (defined(__AVR_ATmega16U4__) || defined(__AVR_ATmega32U4__)) #define USB_PLL_PSC (1 << PINDIV) @@ -112,14 +116,10 @@ */ #define USB_MODE_DEVICE 1 - #if defined(USB_CAN_BE_HOST) || defined(__DOXYGEN__) - /** Mode mask for the \ref USB_CurrentMode global and the \ref USB_Init() function. This indicates that the - * USB interface is or should be initialized in the USB host mode. - * - * \note This token is not available on AVR models which do not support host mode. - */ - #define USB_MODE_HOST 2 - #endif + /** Mode mask for the \ref USB_CurrentMode global and the \ref USB_Init() function. This indicates that the + * USB interface is or should be initialized in the USB host mode. + */ + #define USB_MODE_HOST 2 #if defined(USB_CAN_BE_BOTH) || defined(__DOXYGEN__) /** Mode mask for the the \ref USB_Init() function. This indicates that the USB interface should be