aboutsummaryrefslogtreecommitdiffstats
path: root/LUFA/Drivers
diff options
context:
space:
mode:
Diffstat (limited to 'LUFA/Drivers')
-rw-r--r--LUFA/Drivers/Board/Dataflash.h2
-rw-r--r--LUFA/Drivers/Board/EVK527/Dataflash.h2
-rw-r--r--LUFA/Drivers/Board/STK525/Dataflash.h2
-rw-r--r--LUFA/Drivers/Board/STK526/Dataflash.h2
-rw-r--r--LUFA/Drivers/Board/USBKEY/Dataflash.h2
-rw-r--r--LUFA/Drivers/Board/XPLAIN/Dataflash.h2
-rw-r--r--LUFA/Drivers/USB/Class/Device/CDC.h2
-rw-r--r--LUFA/Drivers/USB/Class/Host/CDC.h2
-rw-r--r--LUFA/Drivers/USB/Core/Events.h2
-rw-r--r--LUFA/Drivers/USB/Core/StdDescriptors.h4
-rw-r--r--LUFA/Drivers/USB/Core/USBMode.h49
-rw-r--r--LUFA/Drivers/USB/Core/USBTask.h8
-rw-r--r--LUFA/Drivers/USB/USB.h5
13 files changed, 45 insertions, 39 deletions
diff --git a/LUFA/Drivers/Board/Dataflash.h b/LUFA/Drivers/Board/Dataflash.h
index 0158e0200..4ed77a374 100644
--- a/LUFA/Drivers/Board/Dataflash.h
+++ b/LUFA/Drivers/Board/Dataflash.h
@@ -151,7 +151,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
*
- * \note The AVR's SPI driver must be initialized before any of the dataflash commands are used.
+ * \note The microcontroller's SPI driver must be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void);
diff --git a/LUFA/Drivers/Board/EVK527/Dataflash.h b/LUFA/Drivers/Board/EVK527/Dataflash.h
index d9f20d52d..2f0ad5724 100644
--- a/LUFA/Drivers/Board/EVK527/Dataflash.h
+++ b/LUFA/Drivers/Board/EVK527/Dataflash.h
@@ -83,7 +83,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
- * The AVR's SPI driver MUST be initialized before any of the dataflash commands are used.
+ * The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void)
{
diff --git a/LUFA/Drivers/Board/STK525/Dataflash.h b/LUFA/Drivers/Board/STK525/Dataflash.h
index 687b194bd..3d1cffaa5 100644
--- a/LUFA/Drivers/Board/STK525/Dataflash.h
+++ b/LUFA/Drivers/Board/STK525/Dataflash.h
@@ -83,7 +83,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
- * The AVR's SPI driver MUST be initialized before any of the dataflash commands are used.
+ * The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void)
{
diff --git a/LUFA/Drivers/Board/STK526/Dataflash.h b/LUFA/Drivers/Board/STK526/Dataflash.h
index 626946a0e..6688358be 100644
--- a/LUFA/Drivers/Board/STK526/Dataflash.h
+++ b/LUFA/Drivers/Board/STK526/Dataflash.h
@@ -83,7 +83,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
- * The AVR's SPI driver MUST be initialized before any of the dataflash commands are used.
+ * The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void)
{
diff --git a/LUFA/Drivers/Board/USBKEY/Dataflash.h b/LUFA/Drivers/Board/USBKEY/Dataflash.h
index 19040cf5c..e54f0d838 100644
--- a/LUFA/Drivers/Board/USBKEY/Dataflash.h
+++ b/LUFA/Drivers/Board/USBKEY/Dataflash.h
@@ -86,7 +86,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
- * The AVR's SPI driver MUST be initialized before any of the dataflash commands are used.
+ * The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void)
{
diff --git a/LUFA/Drivers/Board/XPLAIN/Dataflash.h b/LUFA/Drivers/Board/XPLAIN/Dataflash.h
index 069512aec..ed4ab6a18 100644
--- a/LUFA/Drivers/Board/XPLAIN/Dataflash.h
+++ b/LUFA/Drivers/Board/XPLAIN/Dataflash.h
@@ -89,7 +89,7 @@
/* Inline Functions: */
/** Initialises the dataflash driver so that commands and data may be sent to an attached dataflash IC.
- * The AVR's SPI driver MUST be initialized before any of the dataflash commands are used.
+ * The microcontroller's SPI driver MUST be initialized before any of the dataflash commands are used.
*/
static inline void Dataflash_Init(void)
{
diff --git a/LUFA/Drivers/USB/Class/Device/CDC.h b/LUFA/Drivers/USB/Class/Device/CDC.h
index 9eb7b48fc..8b4e2da8e 100644
--- a/LUFA/Drivers/USB/Class/Device/CDC.h
+++ b/LUFA/Drivers/USB/Class/Device/CDC.h
@@ -295,7 +295,7 @@
void CDC_Device_SendControlLineStateChange(USB_ClassInfo_CDC_Device_t* const CDCInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1);
/** Creates a standard character stream for the given CDC Device instance so that it can be used with all the regular
- * functions in the avr-libc <stdio.h> library that accept a \c FILE stream as a destination (e.g. \c fprintf). The created
+ * functions in the standard <stdio.h> library that accept a \c FILE stream as a destination (e.g. \c fprintf). The created
* stream is bidirectional and can be used for both input and output functions.
*
* Reading data from this stream is non-blocking, i.e. in most instances, complete strings cannot be read in by a single
diff --git a/LUFA/Drivers/USB/Class/Host/CDC.h b/LUFA/Drivers/USB/Class/Host/CDC.h
index 8e799709e..b679d1023 100644
--- a/LUFA/Drivers/USB/Class/Host/CDC.h
+++ b/LUFA/Drivers/USB/Class/Host/CDC.h
@@ -285,7 +285,7 @@
uint8_t CDC_Host_Flush(USB_ClassInfo_CDC_Host_t* const CDCInterfaceInfo) ATTR_NON_NULL_PTR_ARG(1);
/** Creates a standard character stream for the given CDC Device instance so that it can be used with all the regular
- * functions in the avr-libc \c <stdio.h> library that accept a \c FILE stream as a destination (e.g. \c fprintf). The created
+ * functions in the standard \c <stdio.h> library that accept a \c FILE stream as a destination (e.g. \c fprintf). The created
* stream is bidirectional and can be used for both input and output functions.
*
* Reading data from this stream is non-blocking, i.e. in most instances, complete strings cannot be read in by a single
diff --git a/LUFA/Drivers/USB/Core/Events.h b/LUFA/Drivers/USB/Core/Events.h
index c0a322b26..18814715e 100644
--- a/LUFA/Drivers/USB/Core/Events.h
+++ b/LUFA/Drivers/USB/Core/Events.h
@@ -183,7 +183,7 @@
* This event is time-critical; exceeding OS-specific delays within this event handler (typically of around
* two seconds) will prevent the device from enumerating correctly.
*
- * \note For the smaller series 2 USB AVRs with limited USB controllers, VBUS is not available to the USB controller.
+ * \note For the microcontrollers with limited USB controller functionality, VBUS sensing is not available.
* this means that the current connection state is derived from the bus suspension and wake up events by default,
* which is not always accurate (host may suspend the bus while still connected). If the actual connection state
* needs to be determined, VBUS should be routed to an external pin, and the auto-detect behaviour turned off by
diff --git a/LUFA/Drivers/USB/Core/StdDescriptors.h b/LUFA/Drivers/USB/Core/StdDescriptors.h
index d2a9bee0e..8599f47aa 100644
--- a/LUFA/Drivers/USB/Core/StdDescriptors.h
+++ b/LUFA/Drivers/USB/Core/StdDescriptors.h
@@ -303,7 +303,7 @@
uint8_t SerialNumStrIndex; /**< String index for the product's globally unique hexadecimal
* serial number, in uppercase Unicode ASCII.
*
- * \note On some AVR models, there is an embedded serial number
+ * \note On some microcontroller models, there is an embedded serial number
* in the chip which can be used for the device serial number.
* To use this serial number, set this to USE_INTERNAL_SERIAL.
* On unsupported devices, this will evaluate to 0 and will cause
@@ -351,7 +351,7 @@
uint8_t iSerialNumber; /**< String index for the product's globally unique hexadecimal
* serial number, in uppercase Unicode ASCII.
*
- * \note On some AVR models, there is an embedded serial number
+ * \note On some microcontroller models, there is an embedded serial number
* in the chip which can be used for the device serial number.
* To use this serial number, set this to USE_INTERNAL_SERIAL.
* On unsupported devices, this will evaluate to 0 and will cause
diff --git a/LUFA/Drivers/USB/Core/USBMode.h b/LUFA/Drivers/USB/Core/USBMode.h
index ff95ce3d5..1cb132812 100644
--- a/LUFA/Drivers/USB/Core/USBMode.h
+++ b/LUFA/Drivers/USB/Core/USBMode.h
@@ -82,17 +82,17 @@
*/
#define USB_SERIES_7_AVR
- /** Indicates that the target AVR microcontroller and compilation settings allow for the
+ /** Indicates that the target microcontroller and compilation settings allow for the
* target to be configured in USB Device mode when defined.
*/
#define USB_CAN_BE_DEVICE
- /** Indicates that the target AVR microcontroller and compilation settings allow for the
+ /** Indicates that the target microcontroller and compilation settings allow for the
* target to be configured in USB Host mode when defined.
*/
#define USB_CAN_BE_HOST
- /** Indicates that the target AVR microcontroller and compilation settings allow for the
+ /** Indicates that the target microcontroller and compilation settings allow for the
* target to be configured in either USB Device or Host mode when defined.
*/
#define USB_CAN_BE_BOTH
@@ -101,37 +101,48 @@
#if (defined(__AVR_AT90USB162__) || defined(__AVR_AT90USB82__) || \
defined(__AVR_ATmega32U2__) || defined(__AVR_ATmega16U2__) || defined(__AVR_ATmega8U2__))
#define USB_SERIES_2_AVR
+ #define USB_CAN_BE_DEVICE
#elif (defined(__AVR_ATmega32U4__) || defined(__AVR_ATmega16U4__))
#define USB_SERIES_4_AVR
+ #define USB_CAN_BE_DEVICE
#elif (defined(__AVR_ATmega32U6__) || defined(__AVR_AT90USB646__) || defined(__AVR_AT90USB1286__))
#define USB_SERIES_6_AVR
+ #define USB_CAN_BE_DEVICE
#elif (defined(__AVR_AT90USB647__) || defined(__AVR_AT90USB1287__))
#define USB_SERIES_7_AVR
+ #define USB_CAN_BE_DEVICE
+ #define USB_CAN_BE_HOST
+ #endif
+
+ #if (defined(USB_CAN_BE_DEVICE) && defined(USB_CAN_BE_HOST))
+ #define USB_CAN_BE_BOTH
#endif
- #if !defined(USB_SERIES_7_AVR)
- #if defined(USB_HOST_ONLY)
- #error USB_HOST_ONLY is not available for the currently selected USB AVR model.
- #endif
-
- #if !defined(USB_DEVICE_ONLY)
- #define USB_DEVICE_ONLY
+ #if defined(USB_HOST_ONLY)
+ #if !defined(USB_CAN_BE_HOST)
+ #error USB_HOST_ONLY is not available for the currently selected microcontroller model.
+ #else
+ #undef USB_CAN_BE_DEVICE
+ #undef USB_CAN_BE_BOTH
#endif
#endif
- #if (!defined(USB_DEVICE_ONLY) && !defined(USB_HOST_ONLY))
- #define USB_CAN_BE_BOTH
- #define USB_CAN_BE_HOST
- #define USB_CAN_BE_DEVICE
- #elif defined(USB_HOST_ONLY)
- #define USB_CAN_BE_HOST
- #elif defined(USB_DEVICE_ONLY)
- #define USB_CAN_BE_DEVICE
+ #if defined(USB_DEVICE_ONLY)
+ #if !defined(USB_CAN_BE_DEVICE)
+ #error USB_DEVICE_ONLY is not available for the currently selected microcontroller model.
+ #else
+ #undef USB_CAN_BE_HOST
+ #undef USB_CAN_BE_BOTH
+ #endif
#endif
-
+
#if (defined(USB_HOST_ONLY) && defined(USB_DEVICE_ONLY))
#error USB_HOST_ONLY and USB_DEVICE_ONLY are mutually exclusive.
#endif
+
+ #if (!defined(USB_CAN_BE_DEVICE) && !defined(USB_CAN_BE_HOST))
+ #error The currently selected architecture is not supported under the USB component of the library.
+ #endif
#endif
#endif
diff --git a/LUFA/Drivers/USB/Core/USBTask.h b/LUFA/Drivers/USB/Core/USBTask.h
index b5cf381aa..f2ed7b7ba 100644
--- a/LUFA/Drivers/USB/Core/USBTask.h
+++ b/LUFA/Drivers/USB/Core/USBTask.h
@@ -98,8 +98,8 @@
* the library internally.
*
* To reduce program size and speed up checks of this global on the AVR8 architecture, it can be
- * placed into one of the AVR's GPIOR hardware registers instead of RAM by defining the
- * HOST_STATE_AS_GPIOR token to a value between 0 and 2 in the project makefile and passing it to
+ * placed into one of the AVR's \c GPIOR hardware registers instead of RAM by defining the
+ * \c HOST_STATE_AS_GPIOR token to a value between 0 and 2 in the project makefile and passing it to
* the compiler via the -D switch. When defined, the corresponding GPIOR register should not be used
* in the user application except implicitly via the library APIs.
*
@@ -127,8 +127,8 @@
* (see \ref EVENT_USB_Device_Connect() and \ref EVENT_USB_Device_Disconnect() events).
*
* To reduce program size and speed up checks of this global on the AVR8 architecture, it can be
- * placed into one of the AVR's GPIOR hardware registers instead of RAM by defining the
- * DEVICE_STATE_AS_GPIOR token to a value between 0 and 2 in the project makefile and passing it to
+ * placed into one of the AVR's \c GPIOR hardware registers instead of RAM by defining the
+ * \c DEVICE_STATE_AS_GPIOR token to a value between 0 and 2 in the project makefile and passing it to
* the compiler via the -D switch. When defined, the corresponding GPIOR register should not be used
* in the user application except implicitly via the library APIs.
*
diff --git a/LUFA/Drivers/USB/USB.h b/LUFA/Drivers/USB/USB.h
index 6dba17f64..2c590968a 100644
--- a/LUFA/Drivers/USB/USB.h
+++ b/LUFA/Drivers/USB/USB.h
@@ -364,11 +364,6 @@
#include "../../Common/Common.h"
#include "Core/USBMode.h"
- /* Preprocessor Checks: */
- #if (!defined(USB_CAN_BE_DEVICE) && !defined(USB_CAN_BE_HOST))
- #error The currently selected architecture is not supported under the USB component of the library.
- #endif
-
/* Includes: */
#include "Core/USBTask.h"
#include "Core/Events.h"