.DataINEndpointNumber = AUDIO_STREAM_EPNUM,\r
.DataINEndpointSize = AUDIO_STREAM_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.DataINEndpointNumber = AUDIO_STREAM_EPNUM,\r
.DataINEndpointSize = AUDIO_STREAM_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.NotificationEndpointNumber = CDC1_NOTIFICATION_EPNUM,\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** LUFA CDC Class driver interface configuration and state information. This structure is\r
\r
.ReportINBufferSize = GENERIC_REPORT_SIZE,\r
},\r
-\r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.ReportINBufferSize = sizeof(USB_JoystickReport_Data_t),\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),\r
},\r
- \r
- .State =\r
- {\r
- .IdleCount = 500,\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),\r
},\r
-\r
- .State =\r
- {\r
- .IdleCount = 500,\r
- }\r
};\r
\r
/** LUFA HID Class driver interface configuration and state information. This structure is\r
.DataOUTEndpointNumber = MIDI_STREAM_OUT_EPNUM,\r
.DataOUTEndpointSize = MIDI_STREAM_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults \r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.TotalLUNs = TOTAL_LUNS,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.ReportINBufferSize = sizeof(USB_MouseReport_Data_t),\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- } \r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.AdapterVendorDescription = "LUFA RNDIS Demo Adapter",\r
.AdapterMACAddress = {ADAPTER_MAC_ADDRESS},\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults \r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
.DataOUTPipeNumber = 2,\r
.NotificationPipeNumber = 3,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults \r
- }\r
};\r
\r
\r
.MatchInterfaceProtocol = true,\r
.HIDInterfaceProtocol = 0x02,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults \r
- }\r
};\r
\r
\r
\r
bool Audio_Device_ConfigureEndpoints(USB_ClassInfo_Audio_Device_t* AudioInterfaceInfo)\r
{\r
+ memset(&AudioInterfaceInfo->State, 0x00, sizeof(AudioInterfaceInfo->State));\r
+\r
if (AudioInterfaceInfo->Config.DataINEndpointNumber)\r
{\r
if (!(Endpoint_ConfigureEndpoint(AudioInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_ISOCHRONOUS,\r
return false;\r
}\r
}\r
-\r
+ \r
return true;\r
}\r
\r
* of the Audio Streaming interface.\r
*/\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
+ * are reset to their defaults when the interface is enumerated.\r
*/ \r
} USB_ClassInfo_Audio_Device_t;\r
\r
\r
bool CDC_Device_ConfigureEndpoints(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo)\r
{\r
+ memset(&CDCInterfaceInfo->State, 0x00, sizeof(CDCInterfaceInfo->State));\r
+\r
if (!(Endpoint_ConfigureEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,\r
ENDPOINT_DIR_IN, CDCInterfaceInfo->Config.DataINEndpointSize,\r
ENDPOINT_BANK_SINGLE)))\r
uint8_t DataBits; /**< Bits of data per character of the virtual serial port */\r
} LineEncoding; \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
+ * are reset to their defaults when the interface is enumerated.\r
*/\r
} USB_ClassInfo_CDC_Device_t;\r
\r
\r
bool HID_Device_ConfigureEndpoints(USB_ClassInfo_HID_Device_t* const HIDInterfaceInfo)\r
{\r
+ memset(&HIDInterfaceInfo->State, 0x00, sizeof(HIDInterfaceInfo->State));\r
+ HIDInterfaceInfo->State.IdleCount = 500;\r
HIDInterfaceInfo->State.UsingReportProtocol = true;\r
\r
if (!(Endpoint_ConfigureEndpoint(HIDInterfaceInfo->Config.ReportINEndpointNumber, EP_TYPE_INTERRUPT,\r
uint16_t IdleMSRemaining; /**< Total number of ms remaining before the idle period elapsed - this should be\r
* decremented by the user application if non-zero each millisecond */ \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
+ * are reset to their defaults when the interface is enumerated.\r
*/\r
} USB_ClassInfo_HID_Device_t;\r
\r
\r
bool MIDI_Device_ConfigureEndpoints(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo)\r
{\r
+ memset(&MIDIInterfaceInfo->State, 0x00, sizeof(MIDIInterfaceInfo->State));\r
+\r
if (MIDIInterfaceInfo->Config.DataINEndpointNumber)\r
{\r
if (!(Endpoint_ConfigureEndpoint(MIDIInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,\r
{\r
// No state information for this class yet\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
+ * are reset to their defaults when the interface is enumerated.\r
*/\r
} USB_ClassInfo_MIDI_Device_t; \r
\r
\r
bool MS_Device_ConfigureEndpoints(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo)\r
{\r
+ memset(&MSInterfaceInfo->State, 0x00, sizeof(MSInterfaceInfo->State));\r
+\r
if (!(Endpoint_ConfigureEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,\r
ENDPOINT_DIR_IN, MSInterfaceInfo->Config.DataINEndpointSize,\r
ENDPOINT_BANK_SINGLE)))\r
* and that all current Mass Storage operations should immediately abort\r
*/\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
+ * are reset to their defaults when the interface is enumerated.\r
*/\r
} USB_ClassInfo_MS_Device_t;\r
\r
\r
bool RNDIS_Device_ConfigureEndpoints(USB_ClassInfo_RNDIS_Device_t* const RNDISInterfaceInfo)\r
{\r
+ memset(&RNDISInterfaceInfo->State, 0x00, sizeof(RNDISInterfaceInfo->State));\r
+\r
if (!(Endpoint_ConfigureEndpoint(RNDISInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,\r
ENDPOINT_DIR_IN, RNDISInterfaceInfo->Config.DataINEndpointSize,\r
ENDPOINT_BANK_SINGLE)))\r
* user application\r
*/\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
+ * are reset to their defaults when the interface is enumerated.\r
*/\r
} USB_ClassInfo_RNDIS_Device_t;\r
\r
{\r
uint8_t FoundEndpoints = 0;\r
\r
+ memset(&CDCInterfaceInfo->State, 0x00, sizeof(CDCInterfaceInfo->State));\r
+\r
if (DESCRIPTOR_TYPE(ConfigDescriptorData) != DTYPE_Configuration)\r
return CDC_ENUMERROR_InvalidConfigDescriptor;\r
\r
{\r
uint8_t FoundEndpoints = 0;\r
\r
+ memset(&HIDInterfaceInfo->State, 0x00, sizeof(HIDInterfaceInfo->State));\r
+\r
if (DESCRIPTOR_TYPE(ConfigDescriptorData) != DTYPE_Configuration)\r
return HID_ENUMERROR_InvalidConfigDescriptor;\r
\r
* to only unfreeze and check one data pipe at a time) to prevent incorrect device enumerations and freezes while trasferring data\r
* - Make Pipe_ConfigurePipe() mask the given endpoint number against PIPE_EPNUM_MASK to ensure the endpoint IN direction bit is\r
* cleared to prevent endpoint type corruption\r
- * - Fix documentation mentioning Pipe_GetCurrentToken() function when real name is Pipe_GetPipeToken()\r
+ * - Fixed documentation mentioning Pipe_GetCurrentToken() function when correct function name is Pipe_GetPipeToken()\r
* - Fixed ADC driver for the ATMEGA32U4 and ATMEGA16U4 (thanks to Opendous Inc.)\r
* - Fixed CDCHost demo unfreezing the pipes at the point of configuration, rather than use\r
* - Fixed MassStorage demo not clearing the reset flag when a Mass Storage Reset is issued while not processing a command\r
* \r
* This folder contains drivers for several of the AVR internal peripherals such as the USART, compatible only with\r
* the AT90USBXXX6, AT90USBXXX7 and ATMEGAXXU4 USB AVR models, such as the AT90USB1287. Its contents should <b>not</b> be\r
- * included by the user application - the dispatch header file located in the parent AT90USBXXX directory should be used\r
+ * included by the user application - the dispatch header file located in the parent directory should be used\r
* instead.\r
*\r
* \dir LUFA/Drivers/USB\r
* - The \ref CALLBACK_USB_GetDescriptor() function now takes an extra parameter to specify the descriptor's memory space so that\r
* descriptors in mixed memory spaces can be used. The previous functionality can be returned by defining the USE_FLASH_DESCRIPTORS\r
* token in the project makefile to fix all descriptors into FLASH space and remove the extra function parameter.\r
- * - Removed USB_IsSuspended - test \ref USB_DeviceState against \ref DEVICE_STATE_Suspended instead.\r
+ * - The USB_IsSuspended global has been removed - test \ref USB_DeviceState against \ref DEVICE_STATE_Suspended instead.\r
*\r
*\r
* \section Sec_Migration090605 Migrating from 090510 to 090605\r
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults\r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),\r
},\r
- \r
- .State =\r
- {\r
- // Leave all state values to their defaults \r
- }\r
};\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial\r