projects
/
pub
/
USBasp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b9dd51c
)
State information for class drivers is now zeroed out during enumeration (both in...
author
Dean Camera
<dean@fourwalledcubicle.com>
Mon, 27 Jul 2009 23:19:17 +0000
(23:19 +0000)
committer
Dean Camera
<dean@fourwalledcubicle.com>
Mon, 27 Jul 2009 23:19:17 +0000
(23:19 +0000)
34 files changed:
Demos/Device/ClassDriver/AudioInput/AudioInput.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/CDC/CDC.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/DualCDC/DualCDC.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/GenericHID/GenericHID.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/Joystick/Joystick.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/Keyboard/Keyboard.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/MIDI/MIDI.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/MassStorage/MassStorage.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/Mouse/Mouse.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
patch
|
blob
|
blame
|
history
Demos/Device/ClassDriver/USBtoSerial/USBtoSerial.c
patch
|
blob
|
blame
|
history
Demos/Host/ClassDriver/CDCHost/CDCHost.c
patch
|
blob
|
blame
|
history
Demos/Host/ClassDriver/MouseHost/MouseHost.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/Audio.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/Audio.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/CDC.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/CDC.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/HID.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/HID.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/MIDI.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/MIDI.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/MassStorage.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/MassStorage.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/RNDIS.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Device/RNDIS.h
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Host/CDC.c
patch
|
blob
|
blame
|
history
LUFA/Drivers/USB/Class/Host/HID.c
patch
|
blob
|
blame
|
history
LUFA/ManPages/ChangeLog.txt
patch
|
blob
|
blame
|
history
LUFA/ManPages/DirectorySummaries.txt
patch
|
blob
|
blame
|
history
LUFA/ManPages/MigrationInformation.txt
patch
|
blob
|
blame
|
history
Projects/Benito/Benito.c
patch
|
blob
|
blame
|
history
Projects/Magstripe/Magstripe.c
patch
|
blob
|
blame
|
history
diff --git
a/Demos/Device/ClassDriver/AudioInput/AudioInput.c
b/Demos/Device/ClassDriver/AudioInput/AudioInput.c
index
af0f6d2
..
7b7ca2c
100644
(file)
--- a/
Demos/Device/ClassDriver/AudioInput/AudioInput.c
+++ b/
Demos/Device/ClassDriver/AudioInput/AudioInput.c
@@
-49,11
+49,6
@@
USB_ClassInfo_Audio_Device_t Microphone_Audio_Interface =
.DataINEndpointNumber = AUDIO_STREAM_EPNUM,
\r
.DataINEndpointSize = AUDIO_STREAM_EPSIZE,
\r
},
\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
};
\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
b/Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
index
f859c7c
..
129fca5
100644
(file)
--- a/
Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
+++ b/
Demos/Device/ClassDriver/AudioOutput/AudioOutput.c
@@
-49,11
+49,6
@@
USB_ClassInfo_Audio_Device_t Speaker_Audio_Interface =
.DataINEndpointNumber = AUDIO_STREAM_EPNUM,
\r
.DataINEndpointSize = AUDIO_STREAM_EPSIZE,
\r
},
\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
};
\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/CDC/CDC.c
b/Demos/Device/ClassDriver/CDC/CDC.c
index
95e1a69
..
3e83ec2
100644
(file)
--- a/
Demos/Device/ClassDriver/CDC/CDC.c
+++ b/
Demos/Device/ClassDriver/CDC/CDC.c
@@
-55,11
+55,6
@@
USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,
\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/DualCDC/DualCDC.c
b/Demos/Device/ClassDriver/DualCDC/DualCDC.c
index
adc17ae
..
0de83e1
100644
(file)
--- a/
Demos/Device/ClassDriver/DualCDC/DualCDC.c
+++ b/
Demos/Device/ClassDriver/DualCDC/DualCDC.c
@@
-56,11
+56,6
@@
USB_ClassInfo_CDC_Device_t VirtualSerial1_CDC_Interface =
.NotificationEndpointNumber = CDC1_NOTIFICATION_EPNUM,
\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,
\r
},
\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
\r
/** LUFA CDC Class driver interface configuration and state information. This structure is
\r
diff --git
a/Demos/Device/ClassDriver/GenericHID/GenericHID.c
b/Demos/Device/ClassDriver/GenericHID/GenericHID.c
index
3f9c402
..
72063b6
100644
(file)
--- a/
Demos/Device/ClassDriver/GenericHID/GenericHID.c
+++ b/
Demos/Device/ClassDriver/GenericHID/GenericHID.c
@@
-51,11
+51,6
@@
USB_ClassInfo_HID_Device_t Generic_HID_Interface =
\r
.ReportINBufferSize = GENERIC_REPORT_SIZE,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/Joystick/Joystick.c
b/Demos/Device/ClassDriver/Joystick/Joystick.c
index
1e13e99
..
9a1080c
100644
(file)
--- a/
Demos/Device/ClassDriver/Joystick/Joystick.c
+++ b/
Demos/Device/ClassDriver/Joystick/Joystick.c
@@
-51,11
+51,6
@@
USB_ClassInfo_HID_Device_t Joystick_HID_Interface =
\r
.ReportINBufferSize = sizeof(USB_JoystickReport_Data_t),
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/Keyboard/Keyboard.c
b/Demos/Device/ClassDriver/Keyboard/Keyboard.c
index
af56a22
..
ba0d239
100644
(file)
--- a/
Demos/Device/ClassDriver/Keyboard/Keyboard.c
+++ b/
Demos/Device/ClassDriver/Keyboard/Keyboard.c
@@
-52,11
+52,6
@@
USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
b/Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
index
5c33eeb
..
241553c
100644
(file)
--- a/
Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
+++ b/
Demos/Device/ClassDriver/KeyboardMouse/KeyboardMouse.c
@@
-53,11
+53,6
@@
USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),
\r
},
\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
};
\r
\r
/** LUFA HID Class driver interface configuration and state information. This structure is
\r
diff --git
a/Demos/Device/ClassDriver/MIDI/MIDI.c
b/Demos/Device/ClassDriver/MIDI/MIDI.c
index
a6c31ee
..
243ae9e
100644
(file)
--- a/
Demos/Device/ClassDriver/MIDI/MIDI.c
+++ b/
Demos/Device/ClassDriver/MIDI/MIDI.c
@@
-52,11
+52,6
@@
USB_ClassInfo_MIDI_Device_t Keyboard_MIDI_Interface =
.DataOUTEndpointNumber = MIDI_STREAM_OUT_EPNUM,
\r
.DataOUTEndpointSize = MIDI_STREAM_EPSIZE,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/MassStorage/MassStorage.c
b/Demos/Device/ClassDriver/MassStorage/MassStorage.c
index
0a6604c
..
6a4612e
100644
(file)
--- a/
Demos/Device/ClassDriver/MassStorage/MassStorage.c
+++ b/
Demos/Device/ClassDriver/MassStorage/MassStorage.c
@@
-54,11
+54,6
@@
USB_ClassInfo_MS_Device_t Disk_MS_Interface =
\r
.TotalLUNs = TOTAL_LUNS,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/Mouse/Mouse.c
b/Demos/Device/ClassDriver/Mouse/Mouse.c
index
45d14a3
..
4bb1fa1
100644
(file)
--- a/
Demos/Device/ClassDriver/Mouse/Mouse.c
+++ b/
Demos/Device/ClassDriver/Mouse/Mouse.c
@@
-51,11
+51,6
@@
USB_ClassInfo_HID_Device_t Mouse_HID_Interface =
\r
.ReportINBufferSize = sizeof(USB_MouseReport_Data_t),
\r
},
\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
};
\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
b/Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
index
ed07184
..
81d31c9
100644
(file)
--- a/
Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
+++ b/
Demos/Device/ClassDriver/RNDISEthernet/RNDISEthernet.c
@@
-58,11
+58,6
@@
USB_ClassInfo_RNDIS_Device_t Ethernet_RNDIS_Interface =
.AdapterVendorDescription = "LUFA RNDIS Demo Adapter",
\r
.AdapterMACAddress = {ADAPTER_MAC_ADDRESS},
\r
},
\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
};
\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Device/ClassDriver/USBtoSerial/USBtoSerial.c
b/Demos/Device/ClassDriver/USBtoSerial/USBtoSerial.c
index
637071a
..
e51963c
100644
(file)
--- a/
Demos/Device/ClassDriver/USBtoSerial/USBtoSerial.c
+++ b/
Demos/Device/ClassDriver/USBtoSerial/USBtoSerial.c
@@
-61,11
+61,6
@@
USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,
\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Demos/Host/ClassDriver/CDCHost/CDCHost.c
b/Demos/Host/ClassDriver/CDCHost/CDCHost.c
index
291e835
..
0cbb771
100644
(file)
--- a/
Demos/Host/ClassDriver/CDCHost/CDCHost.c
+++ b/
Demos/Host/ClassDriver/CDCHost/CDCHost.c
@@
-48,11
+48,6
@@
USB_ClassInfo_CDC_Host_t VirtualSerial_CDC_Interface =
.DataOUTPipeNumber = 2,
\r
.NotificationPipeNumber = 3,
\r
},
\r
.DataOUTPipeNumber = 2,
\r
.NotificationPipeNumber = 3,
\r
},
\r
-
\r
- .State =
\r
- {
\r
- // Leave all state values to their defaults
\r
- }
\r
};
\r
\r
\r
};
\r
\r
\r
diff --git
a/Demos/Host/ClassDriver/MouseHost/MouseHost.c
b/Demos/Host/ClassDriver/MouseHost/MouseHost.c
index
6913ec3
..
61d7d7b
100644
(file)
--- a/
Demos/Host/ClassDriver/MouseHost/MouseHost.c
+++ b/
Demos/Host/ClassDriver/MouseHost/MouseHost.c
@@
-50,11
+50,6
@@
USB_ClassInfo_HID_Host_t Mouse_HID_Interface =
.MatchInterfaceProtocol = true,
\r
.HIDInterfaceProtocol = 0x02,
\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
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/Audio.c
b/LUFA/Drivers/USB/Class/Device/Audio.c
index
116921e
..
b018d66
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/Audio.c
+++ b/
LUFA/Drivers/USB/Class/Device/Audio.c
@@
-59,6
+59,8
@@
void Audio_Device_ProcessControlPacket(USB_ClassInfo_Audio_Device_t* const Audio
\r
bool Audio_Device_ConfigureEndpoints(USB_ClassInfo_Audio_Device_t* AudioInterfaceInfo)
\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
if (AudioInterfaceInfo->Config.DataINEndpointNumber)
\r
{
\r
if (!(Endpoint_ConfigureEndpoint(AudioInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_ISOCHRONOUS,
\r
@@
-78,7
+80,7
@@
bool Audio_Device_ConfigureEndpoints(USB_ClassInfo_Audio_Device_t* AudioInterfac
return false;
\r
}
\r
}
\r
return false;
\r
}
\r
}
\r
-
\r
+
\r
return true;
\r
}
\r
\r
return true;
\r
}
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/Audio.h
b/LUFA/Drivers/USB/Class/Device/Audio.h
index
767f754
..
eef7f90
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/Audio.h
+++ b/
LUFA/Drivers/USB/Class/Device/Audio.h
@@
-91,8
+91,7
@@
* of the Audio Streaming interface.
\r
*/
\r
} State; /**< State data for the USB class interface within the device. All elements in this section
\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
} USB_ClassInfo_Audio_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/CDC.c
b/LUFA/Drivers/USB/Class/Device/CDC.c
index
237e1dd
..
0359afe
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/CDC.c
+++ b/
LUFA/Drivers/USB/Class/Device/CDC.c
@@
-87,6
+87,8
@@
void CDC_Device_ProcessControlPacket(USB_ClassInfo_CDC_Device_t* CDCInterfaceInf
\r
bool CDC_Device_ConfigureEndpoints(USB_ClassInfo_CDC_Device_t* CDCInterfaceInfo)
\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
if (!(Endpoint_ConfigureEndpoint(CDCInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,
\r
ENDPOINT_DIR_IN, CDCInterfaceInfo->Config.DataINEndpointSize,
\r
ENDPOINT_BANK_SINGLE)))
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/CDC.h
b/LUFA/Drivers/USB/Class/Device/CDC.h
index
17e9b35
..
2a8f1ec
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/CDC.h
+++ b/
LUFA/Drivers/USB/Class/Device/CDC.h
@@
-102,8
+102,7
@@
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
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
} USB_ClassInfo_CDC_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/HID.c
b/LUFA/Drivers/USB/Class/Device/HID.c
index
f292c63
..
43f11ee
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/HID.c
+++ b/
LUFA/Drivers/USB/Class/Device/HID.c
@@
-135,6
+135,8
@@
void HID_Device_ProcessControlPacket(USB_ClassInfo_HID_Device_t* const HIDInterf
\r
bool HID_Device_ConfigureEndpoints(USB_ClassInfo_HID_Device_t* const HIDInterfaceInfo)
\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
HIDInterfaceInfo->State.UsingReportProtocol = true;
\r
\r
if (!(Endpoint_ConfigureEndpoint(HIDInterfaceInfo->Config.ReportINEndpointNumber, EP_TYPE_INTERRUPT,
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/HID.h
b/LUFA/Drivers/USB/Class/Device/HID.h
index
e4a919d
..
87f96c6
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/HID.h
+++ b/
LUFA/Drivers/USB/Class/Device/HID.h
@@
-83,8
+83,7
@@
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
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
} USB_ClassInfo_HID_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/MIDI.c
b/LUFA/Drivers/USB/Class/Device/MIDI.c
index
3643275
..
ed3aaa7
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/MIDI.c
+++ b/
LUFA/Drivers/USB/Class/Device/MIDI.c
@@
-40,6
+40,8
@@
void MIDI_Device_ProcessControlPacket(USB_ClassInfo_MIDI_Device_t* const MIDIInt
\r
bool MIDI_Device_ConfigureEndpoints(USB_ClassInfo_MIDI_Device_t* const MIDIInterfaceInfo)
\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
if (MIDIInterfaceInfo->Config.DataINEndpointNumber)
\r
{
\r
if (!(Endpoint_ConfigureEndpoint(MIDIInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/MIDI.h
b/LUFA/Drivers/USB/Class/Device/MIDI.h
index
66330a1
..
980ddc5
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/MIDI.h
+++ b/
LUFA/Drivers/USB/Class/Device/MIDI.h
@@
-80,8
+80,7
@@
{
\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
{
\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
} USB_ClassInfo_MIDI_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/MassStorage.c
b/LUFA/Drivers/USB/Class/Device/MassStorage.c
index
9f8688c
..
6160641
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/MassStorage.c
+++ b/
LUFA/Drivers/USB/Class/Device/MassStorage.c
@@
-74,6
+74,8
@@
void MS_Device_ProcessControlPacket(USB_ClassInfo_MS_Device_t* const MSInterface
\r
bool MS_Device_ConfigureEndpoints(USB_ClassInfo_MS_Device_t* const MSInterfaceInfo)
\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
if (!(Endpoint_ConfigureEndpoint(MSInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,
\r
ENDPOINT_DIR_IN, MSInterfaceInfo->Config.DataINEndpointSize,
\r
ENDPOINT_BANK_SINGLE)))
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/MassStorage.h
b/LUFA/Drivers/USB/Class/Device/MassStorage.h
index
22f7160
..
cd7a8ef
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/MassStorage.h
+++ b/
LUFA/Drivers/USB/Class/Device/MassStorage.h
@@
-89,8
+89,7
@@
* 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
* 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
} USB_ClassInfo_MS_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/RNDIS.c
b/LUFA/Drivers/USB/Class/Device/RNDIS.c
index
37771c6
..
8131d87
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/RNDIS.c
+++ b/
LUFA/Drivers/USB/Class/Device/RNDIS.c
@@
-112,6
+112,8
@@
void RNDIS_Device_ProcessControlPacket(USB_ClassInfo_RNDIS_Device_t* const RNDIS
\r
bool RNDIS_Device_ConfigureEndpoints(USB_ClassInfo_RNDIS_Device_t* const RNDISInterfaceInfo)
\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
if (!(Endpoint_ConfigureEndpoint(RNDISInterfaceInfo->Config.DataINEndpointNumber, EP_TYPE_BULK,
\r
ENDPOINT_DIR_IN, RNDISInterfaceInfo->Config.DataINEndpointSize,
\r
ENDPOINT_BANK_SINGLE)))
\r
diff --git
a/LUFA/Drivers/USB/Class/Device/RNDIS.h
b/LUFA/Drivers/USB/Class/Device/RNDIS.h
index
2aaf261
..
8855aac
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Device/RNDIS.h
+++ b/
LUFA/Drivers/USB/Class/Device/RNDIS.h
@@
-97,8
+97,7
@@
* user application
\r
*/
\r
} State; /**< State data for the USB class interface within the device. All elements in this section
\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
} USB_ClassInfo_RNDIS_Device_t;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Host/CDC.c
b/LUFA/Drivers/USB/Class/Host/CDC.c
index
4402f33
..
9c59b5c
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Host/CDC.c
+++ b/
LUFA/Drivers/USB/Class/Host/CDC.c
@@
-39,6
+39,8
@@
uint8_t CDC_Host_ConfigurePipes(USB_ClassInfo_CDC_Host_t* CDCInterfaceInfo, uint
{
\r
uint8_t FoundEndpoints = 0;
\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
if (DESCRIPTOR_TYPE(ConfigDescriptorData) != DTYPE_Configuration)
\r
return CDC_ENUMERROR_InvalidConfigDescriptor;
\r
\r
diff --git
a/LUFA/Drivers/USB/Class/Host/HID.c
b/LUFA/Drivers/USB/Class/Host/HID.c
index
8639b48
..
6652cdc
100644
(file)
--- a/
LUFA/Drivers/USB/Class/Host/HID.c
+++ b/
LUFA/Drivers/USB/Class/Host/HID.c
@@
-39,6
+39,8
@@
uint8_t HID_Host_ConfigurePipes(USB_ClassInfo_HID_Host_t* HIDInterfaceInfo, uint
{
\r
uint8_t FoundEndpoints = 0;
\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
if (DESCRIPTOR_TYPE(ConfigDescriptorData) != DTYPE_Configuration)
\r
return HID_ENUMERROR_InvalidConfigDescriptor;
\r
\r
diff --git
a/LUFA/ManPages/ChangeLog.txt
b/LUFA/ManPages/ChangeLog.txt
index
f96168f
..
ff34ff2
100644
(file)
--- a/
LUFA/ManPages/ChangeLog.txt
+++ b/
LUFA/ManPages/ChangeLog.txt
@@
-62,7
+62,7
@@
* 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
* 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
+ * - Fix
ed 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
* - 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
diff --git
a/LUFA/ManPages/DirectorySummaries.txt
b/LUFA/ManPages/DirectorySummaries.txt
index
3b2c15f
..
c6691d7
100644
(file)
--- a/
LUFA/ManPages/DirectorySummaries.txt
+++ b/
LUFA/ManPages/DirectorySummaries.txt
@@
-33,7
+33,7
@@
*
\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
*
\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
* instead.
\r
*
\r
* \dir LUFA/Drivers/USB
\r
diff --git
a/LUFA/ManPages/MigrationInformation.txt
b/LUFA/ManPages/MigrationInformation.txt
index
5ea8d9c
..
be84c36
100644
(file)
--- a/
LUFA/ManPages/MigrationInformation.txt
+++ b/
LUFA/ManPages/MigrationInformation.txt
@@
-35,7
+35,7
@@
* - 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
* - 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_IsSuspend
ed - test \ref USB_DeviceState against \ref DEVICE_STATE_Suspended instead.
\r
+ * -
The USB_IsSuspended global has been remov
ed - test \ref USB_DeviceState against \ref DEVICE_STATE_Suspended instead.
\r
*
\r
*
\r
* \section Sec_Migration090605 Migrating from 090510 to 090605
\r
*
\r
*
\r
* \section Sec_Migration090605 Migrating from 090510 to 090605
\r
diff --git
a/Projects/Benito/Benito.c
b/Projects/Benito/Benito.c
index
2f0317d
..
9e85fbd
100644
(file)
--- a/
Projects/Benito/Benito.c
+++ b/
Projects/Benito/Benito.c
@@
-67,11
+67,6
@@
USB_ClassInfo_CDC_Device_t VirtualSerial_CDC_Interface =
.NotificationEndpointNumber = CDC_NOTIFICATION_EPNUM,
\r
.NotificationEndpointSize = CDC_NOTIFICATION_EPSIZE,
\r
},
\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
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r
diff --git
a/Projects/Magstripe/Magstripe.c
b/Projects/Magstripe/Magstripe.c
index
087e510
..
aaa432d
100644
(file)
--- a/
Projects/Magstripe/Magstripe.c
+++ b/
Projects/Magstripe/Magstripe.c
@@
-60,11
+60,6
@@
USB_ClassInfo_HID_Device_t Keyboard_HID_Interface =
\r
.ReportINBufferSize = sizeof(USB_KeyboardReport_Data_t),
\r
},
\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
};
\r
\r
/** Main program entry point. This routine contains the overall program flow, including initial
\r