From 5995c3f880899b2573f1026ed6dc1c3c3a8e93d2 Mon Sep 17 00:00:00 2001 From: Dean Camera Date: Sun, 6 Feb 2011 18:03:29 +0000 Subject: Oops - fix missing constants in the TempDataLogger FatFS diskio.h header file. Add const to all project descriptor definitions for safety. --- Bootloaders/CDC/Descriptors.c | 8 ++++---- Bootloaders/DFU/Descriptors.c | 8 ++++---- Demos/Device/ClassDriver/AudioInput/Descriptors.c | 10 +++++----- Demos/Device/ClassDriver/AudioOutput/Descriptors.c | 10 +++++----- .../Device/ClassDriver/DualVirtualSerial/Descriptors.c | 10 +++++----- Demos/Device/ClassDriver/GenericHID/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/Joystick/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/Keyboard/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c | 14 +++++++------- .../ClassDriver/KeyboardMouseMultiReport/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/MIDI/Descriptors.c | 10 +++++----- Demos/Device/ClassDriver/MassStorage/Descriptors.c | 10 +++++----- .../ClassDriver/MassStorageKeyboard/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/Mouse/Descriptors.c | 12 ++++++------ Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c | 10 +++++----- Demos/Device/ClassDriver/VirtualSerial/Descriptors.c | 10 +++++----- .../ClassDriver/VirtualSerialMouse/Descriptors.c | 12 ++++++------ Demos/Device/Incomplete/Sideshow/Descriptors.c | 16 ++++++++-------- .../Device/Incomplete/TestAndMeasurement/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/AudioInput/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/AudioOutput/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/GenericHID/Descriptors.c | 12 ++++++------ Demos/Device/LowLevel/Joystick/Descriptors.c | 12 ++++++------ Demos/Device/LowLevel/Keyboard/Descriptors.c | 12 ++++++------ Demos/Device/LowLevel/KeyboardMouse/Descriptors.c | 14 +++++++------- Demos/Device/LowLevel/MIDI/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/MassStorage/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/Mouse/Descriptors.c | 12 ++++++------ Demos/Device/LowLevel/RNDISEthernet/Descriptors.c | 10 +++++----- Demos/Device/LowLevel/VirtualSerial/Descriptors.c | 10 +++++----- .../DualRole/ClassDriver/MouseHostDevice/Descriptors.c | 12 ++++++------ Projects/AVRISP-MKII/Descriptors.c | 12 ++++++------ Projects/Benito/Descriptors.c | 10 +++++----- Projects/Incomplete/StandaloneProgrammer/Descriptors.c | 10 +++++----- Projects/LEDNotifier/Descriptors.c | 10 +++++----- Projects/MIDIToneGenerator/Descriptors.c | 10 +++++----- Projects/Magstripe/Descriptors.c | 12 ++++++------ Projects/RelayBoard/Descriptors.c | 16 ++++++++-------- Projects/RelayBoard/Descriptors.h | 6 +++--- Projects/TempDataLogger/Descriptors.c | 12 ++++++------ Projects/TempDataLogger/Lib/FATFs/diskio.h | 18 ++++++++++++++++++ Projects/USBtoSerial/Descriptors.c | 10 +++++----- Projects/Webserver/Descriptors.c | 10 +++++----- Projects/XPLAINBridge/AVRISPDescriptors.c | 12 ++++++------ Projects/XPLAINBridge/USARTDescriptors.c | 10 +++++----- 46 files changed, 265 insertions(+), 247 deletions(-) diff --git a/Bootloaders/CDC/Descriptors.c b/Bootloaders/CDC/Descriptors.c index 267c5dcae..8973c4e96 100644 --- a/Bootloaders/CDC/Descriptors.c +++ b/Bootloaders/CDC/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t DeviceDescriptor = +const USB_Descriptor_Device_t DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t ConfigurationDescriptor = +const USB_Descriptor_Configuration_t ConfigurationDescriptor = { .Config = { @@ -178,7 +178,7 @@ USB_Descriptor_Configuration_t ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t LanguageString = +const USB_Descriptor_String_t LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -189,7 +189,7 @@ USB_Descriptor_String_t LanguageString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t ProductString = +const USB_Descriptor_String_t ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Bootloaders/DFU/Descriptors.c b/Bootloaders/DFU/Descriptors.c index 9baa8890d..55449c606 100644 --- a/Bootloaders/DFU/Descriptors.c +++ b/Bootloaders/DFU/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t DeviceDescriptor = +const USB_Descriptor_Device_t DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t ConfigurationDescriptor = +const USB_Descriptor_Configuration_t ConfigurationDescriptor = { .Config = { @@ -119,7 +119,7 @@ USB_Descriptor_Configuration_t ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t LanguageString = +const USB_Descriptor_String_t LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -130,7 +130,7 @@ USB_Descriptor_String_t LanguageString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t ProductString = +const USB_Descriptor_String_t ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/AudioInput/Descriptors.c b/Demos/Device/ClassDriver/AudioInput/Descriptors.c index e21785881..9706d5506 100644 --- a/Demos/Device/ClassDriver/AudioInput/Descriptors.c +++ b/Demos/Device/ClassDriver/AudioInput/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -236,7 +236,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -247,7 +247,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -258,7 +258,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/AudioOutput/Descriptors.c b/Demos/Device/ClassDriver/AudioOutput/Descriptors.c index 0dd547728..0b1e8c111 100644 --- a/Demos/Device/ClassDriver/AudioOutput/Descriptors.c +++ b/Demos/Device/ClassDriver/AudioOutput/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -236,7 +236,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -247,7 +247,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -258,7 +258,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(19), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.c b/Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.c index 006d46857..8265a1626 100644 --- a/Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.c +++ b/Demos/Device/ClassDriver/DualVirtualSerial/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -305,7 +305,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -316,7 +316,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -327,7 +327,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/GenericHID/Descriptors.c b/Demos/Device/ClassDriver/GenericHID/Descriptors.c index 761e904ea..d36ee4989 100644 --- a/Demos/Device/ClassDriver/GenericHID/Descriptors.c +++ b/Demos/Device/ClassDriver/GenericHID/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = { /* Use the HID class driver's standard Vendor HID report. * Vendor Usage Page: 1 @@ -60,7 +60,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -87,7 +87,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -146,7 +146,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -157,7 +157,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -168,7 +168,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(21), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/Joystick/Descriptors.c b/Demos/Device/ClassDriver/Joystick/Descriptors.c index 5adac0ff8..fc8d99b47 100644 --- a/Demos/Device/ClassDriver/Joystick/Descriptors.c +++ b/Demos/Device/ClassDriver/Joystick/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = { /* Use the HID class driver's standard Joystick report. * Min X/Y Axis values: -100 @@ -60,7 +60,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -87,7 +87,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -146,7 +146,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -157,7 +157,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -168,7 +168,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/Keyboard/Descriptors.c b/Demos/Device/ClassDriver/Keyboard/Descriptors.c index 5f3f14592..24db9781f 100644 --- a/Demos/Device/ClassDriver/Keyboard/Descriptors.c +++ b/Demos/Device/ClassDriver/Keyboard/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { /* Use the HID class driver's standard Keyboard report. * Max simultaneous keys: 6 @@ -56,7 +56,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -83,7 +83,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -142,7 +142,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -153,7 +153,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -164,7 +164,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c b/Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c index 6c7b06dc0..4b1e802f2 100644 --- a/Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c +++ b/Demos/Device/ClassDriver/KeyboardMouse/Descriptors.c @@ -45,7 +45,7 @@ * * This descriptor describes the mouse HID interface's report structure. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { /* Use the HID class driver's standard Mouse report. * Min X/Y Axis values: -1 @@ -59,7 +59,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = }; /** Same as the MouseReport structure, but defines the keyboard HID interface's report structure. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { /* Use the HID class driver's standard Keyboard report. * Max simultaneous keys: 6 @@ -72,7 +72,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -99,7 +99,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -195,7 +195,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -206,7 +206,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -217,7 +217,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(28), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.c b/Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.c index 19f282f37..03a6618e6 100644 --- a/Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.c +++ b/Demos/Device/ClassDriver/KeyboardMouseMultiReport/Descriptors.c @@ -45,7 +45,7 @@ * * This descriptor describes the multiple possible reports of the HID interface's report structure. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM HIDReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM HIDReport[] = { /* Mouse Report */ HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ @@ -119,7 +119,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM HIDReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -146,7 +146,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -205,7 +205,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -216,7 +216,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -227,7 +227,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(26), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/MIDI/Descriptors.c b/Demos/Device/ClassDriver/MIDI/Descriptors.c index 4b6c7d617..0c7e63446 100644 --- a/Demos/Device/ClassDriver/MIDI/Descriptors.c +++ b/Demos/Device/ClassDriver/MIDI/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -248,7 +248,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -259,7 +259,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -270,7 +270,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(14), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/MassStorage/Descriptors.c b/Demos/Device/ClassDriver/MassStorage/Descriptors.c index 127928b41..fc9c87edf 100644 --- a/Demos/Device/ClassDriver/MassStorage/Descriptors.c +++ b/Demos/Device/ClassDriver/MassStorage/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -139,7 +139,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -150,7 +150,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -161,7 +161,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(22), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.c b/Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.c index 577721e01..62aeef881 100644 --- a/Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.c +++ b/Demos/Device/ClassDriver/MassStorageKeyboard/Descriptors.c @@ -56,7 +56,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { /* Use the HID class driver's standard Keyboard report. * Max simultaneous keys: 6 @@ -69,7 +69,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -96,7 +96,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -191,7 +191,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -202,7 +202,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -213,7 +213,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(35), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/Mouse/Descriptors.c b/Demos/Device/ClassDriver/Mouse/Descriptors.c index 75efb09a6..b3c9e38c4 100644 --- a/Demos/Device/ClassDriver/Mouse/Descriptors.c +++ b/Demos/Device/ClassDriver/Mouse/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { /* Use the HID class driver's standard Mouse report. * Min X/Y Axis values: -1 @@ -61,7 +61,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -88,7 +88,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -147,7 +147,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -158,7 +158,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -169,7 +169,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(15), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c b/Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c index 8822a2079..c6feb866b 100644 --- a/Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c +++ b/Demos/Device/ClassDriver/RNDISEthernet/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -178,7 +178,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -189,7 +189,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -200,7 +200,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(19), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/VirtualSerial/Descriptors.c b/Demos/Device/ClassDriver/VirtualSerial/Descriptors.c index 0f52646e0..f84083e61 100644 --- a/Demos/Device/ClassDriver/VirtualSerial/Descriptors.c +++ b/Demos/Device/ClassDriver/VirtualSerial/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -190,7 +190,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -201,7 +201,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -212,7 +212,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.c b/Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.c index 4e0e2b747..ac53f962f 100644 --- a/Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.c +++ b/Demos/Device/ClassDriver/VirtualSerialMouse/Descriptors.c @@ -55,7 +55,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { /* Use the HID class driver's standard Mouse report. * Min X/Y Axis values: -1 @@ -73,7 +73,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -100,7 +100,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -260,7 +260,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -271,7 +271,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -282,7 +282,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(23), .Type = DTYPE_String}, diff --git a/Demos/Device/Incomplete/Sideshow/Descriptors.c b/Demos/Device/Incomplete/Sideshow/Descriptors.c index ca5697c04..b19888d3c 100644 --- a/Demos/Device/Incomplete/Sideshow/Descriptors.c +++ b/Demos/Device/Incomplete/Sideshow/Descriptors.c @@ -30,7 +30,7 @@ #include "Descriptors.h" -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { Header: {Size: sizeof(USB_Descriptor_Device_t), Type: DTYPE_Device}, @@ -52,7 +52,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = NumberOfConfigurations: 1 }; -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -106,35 +106,35 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = } }; -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { Header: {Size: USB_STRING_LEN(1), Type: DTYPE_String}, UnicodeString: {LANGUAGE_ID_ENG} }; -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { Header: {Size: USB_STRING_LEN(11), Type: DTYPE_String}, UnicodeString: L"Dean Camera" }; -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { Header: {Size: USB_STRING_LEN(22), Type: DTYPE_String}, UnicodeString: L"LUFA Sideshow Demo" }; -USB_Descriptor_String_t PROGMEM SerialNumberString = +const USB_Descriptor_String_t PROGMEM SerialNumberString = { Header: {Size: USB_STRING_LEN(12), Type: DTYPE_String}, UnicodeString: L"000000000000" }; -USB_OSDescriptor_t PROGMEM OSDescriptorString = +const USB_OSDescriptor_t PROGMEM OSDescriptorString = { Header: {Size: sizeof(USB_OSDescriptor_t), Type: DTYPE_String}, @@ -142,7 +142,7 @@ USB_OSDescriptor_t PROGMEM OSDescriptorString = VendorCode: REQ_GetOSFeatureDescriptor }; -USB_OSCompatibleIDDescriptor_t PROGMEM DevCompatIDs = +const USB_OSCompatibleIDDescriptor_t PROGMEM DevCompatIDs = { TotalLength: sizeof(USB_OSCompatibleIDDescriptor_t), Version: 0x0100, diff --git a/Demos/Device/Incomplete/TestAndMeasurement/Descriptors.c b/Demos/Device/Incomplete/TestAndMeasurement/Descriptors.c index 93381b4e4..8cc6138f1 100644 --- a/Demos/Device/Incomplete/TestAndMeasurement/Descriptors.c +++ b/Demos/Device/Incomplete/TestAndMeasurement/Descriptors.c @@ -55,7 +55,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -82,7 +82,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -150,7 +150,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -161,7 +161,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -172,7 +172,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/AudioInput/Descriptors.c b/Demos/Device/LowLevel/AudioInput/Descriptors.c index 087b10126..f645d088e 100644 --- a/Demos/Device/LowLevel/AudioInput/Descriptors.c +++ b/Demos/Device/LowLevel/AudioInput/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -236,7 +236,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -247,7 +247,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -258,7 +258,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/AudioOutput/Descriptors.c b/Demos/Device/LowLevel/AudioOutput/Descriptors.c index 78b93234d..3ac23c944 100644 --- a/Demos/Device/LowLevel/AudioOutput/Descriptors.c +++ b/Demos/Device/LowLevel/AudioOutput/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -236,7 +236,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -247,7 +247,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -258,7 +258,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(19), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c b/Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c index 006d46857..8265a1626 100644 --- a/Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c +++ b/Demos/Device/LowLevel/DualVirtualSerial/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -305,7 +305,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -316,7 +316,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -327,7 +327,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/GenericHID/Descriptors.c b/Demos/Device/LowLevel/GenericHID/Descriptors.c index ed93277a3..abc9e8016 100644 --- a/Demos/Device/LowLevel/GenericHID/Descriptors.c +++ b/Demos/Device/LowLevel/GenericHID/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = { HID_RI_USAGE_PAGE(16, 0xFF00), /* Vendor Page 1 */ HID_RI_USAGE(8, 0x01), /* Vendor Usage 1 */ @@ -68,7 +68,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -95,7 +95,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -164,7 +164,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -175,7 +175,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -186,7 +186,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(21), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/Joystick/Descriptors.c b/Demos/Device/LowLevel/Joystick/Descriptors.c index 5db6b0d28..09e86e71e 100644 --- a/Demos/Device/LowLevel/Joystick/Descriptors.c +++ b/Demos/Device/LowLevel/Joystick/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = { HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ HID_RI_USAGE(8, 0x04), /* Joystick */ @@ -79,7 +79,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM JoystickReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -106,7 +106,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -165,7 +165,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -176,7 +176,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -187,7 +187,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/Keyboard/Descriptors.c b/Demos/Device/LowLevel/Keyboard/Descriptors.c index 50d4fe3bc..9f29da827 100644 --- a/Demos/Device/LowLevel/Keyboard/Descriptors.c +++ b/Demos/Device/LowLevel/Keyboard/Descriptors.c @@ -44,7 +44,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ HID_RI_USAGE(8, 0x06), /* Keyboard */ @@ -85,7 +85,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -112,7 +112,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -181,7 +181,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -192,7 +192,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -203,7 +203,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/KeyboardMouse/Descriptors.c b/Demos/Device/LowLevel/KeyboardMouse/Descriptors.c index 5de7afb33..2abbd406d 100644 --- a/Demos/Device/LowLevel/KeyboardMouse/Descriptors.c +++ b/Demos/Device/LowLevel/KeyboardMouse/Descriptors.c @@ -46,7 +46,7 @@ * * This descriptor describes the mouse HID interface's report structure. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ HID_RI_USAGE(8, 0x02), /* Mouse */ @@ -79,7 +79,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = }; /** Same as the MouseReport structure, but defines the keyboard HID interface's report structure. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ HID_RI_USAGE(8, 0x06), /* Keyboard */ @@ -120,7 +120,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -147,7 +147,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -253,7 +253,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -264,7 +264,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -275,7 +275,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(28), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/MIDI/Descriptors.c b/Demos/Device/LowLevel/MIDI/Descriptors.c index 4b6c7d617..0c7e63446 100644 --- a/Demos/Device/LowLevel/MIDI/Descriptors.c +++ b/Demos/Device/LowLevel/MIDI/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -248,7 +248,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -259,7 +259,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -270,7 +270,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(14), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/MassStorage/Descriptors.c b/Demos/Device/LowLevel/MassStorage/Descriptors.c index 127928b41..fc9c87edf 100644 --- a/Demos/Device/LowLevel/MassStorage/Descriptors.c +++ b/Demos/Device/LowLevel/MassStorage/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -139,7 +139,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -150,7 +150,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -161,7 +161,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(22), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/Mouse/Descriptors.c b/Demos/Device/LowLevel/Mouse/Descriptors.c index c1ade26b7..fb1156a9e 100644 --- a/Demos/Device/LowLevel/Mouse/Descriptors.c +++ b/Demos/Device/LowLevel/Mouse/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { HID_RI_USAGE_PAGE(8, 0x01), /* Generic Desktop */ HID_RI_USAGE(8, 0x02), /* Mouse */ @@ -80,7 +80,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -107,7 +107,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -166,7 +166,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -177,7 +177,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -188,7 +188,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(15), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/RNDISEthernet/Descriptors.c b/Demos/Device/LowLevel/RNDISEthernet/Descriptors.c index 8822a2079..c6feb866b 100644 --- a/Demos/Device/LowLevel/RNDISEthernet/Descriptors.c +++ b/Demos/Device/LowLevel/RNDISEthernet/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -178,7 +178,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -189,7 +189,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -200,7 +200,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(19), .Type = DTYPE_String}, diff --git a/Demos/Device/LowLevel/VirtualSerial/Descriptors.c b/Demos/Device/LowLevel/VirtualSerial/Descriptors.c index 0f52646e0..f84083e61 100644 --- a/Demos/Device/LowLevel/VirtualSerial/Descriptors.c +++ b/Demos/Device/LowLevel/VirtualSerial/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -190,7 +190,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -201,7 +201,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -212,7 +212,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.c b/Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.c index 541626e5a..7e47a3769 100644 --- a/Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.c +++ b/Demos/DualRole/ClassDriver/MouseHostDevice/Descriptors.c @@ -43,7 +43,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = { /* Use the HID class driver's standard Mouse report. * Min X/Y Axis values: -1 @@ -61,7 +61,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM MouseReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -88,7 +88,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -147,7 +147,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -158,7 +158,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -169,7 +169,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(15), .Type = DTYPE_String}, diff --git a/Projects/AVRISP-MKII/Descriptors.c b/Projects/AVRISP-MKII/Descriptors.c index 28db15fc3..a84b75f38 100644 --- a/Projects/AVRISP-MKII/Descriptors.c +++ b/Projects/AVRISP-MKII/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -127,7 +127,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -138,7 +138,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -149,7 +149,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(22), .Type = DTYPE_String}, @@ -159,7 +159,7 @@ USB_Descriptor_String_t PROGMEM ProductString = /** Serial number string. This is a Unicode string containing the device's unique serial number, expressed as a * series of uppercase hexadecimal digits. */ -USB_Descriptor_String_t PROGMEM SerialString = +const USB_Descriptor_String_t PROGMEM SerialString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Projects/Benito/Descriptors.c b/Projects/Benito/Descriptors.c index acb11bf36..18a3043da 100644 --- a/Projects/Benito/Descriptors.c +++ b/Projects/Benito/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -178,7 +178,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -189,7 +189,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -200,7 +200,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(25), .Type = DTYPE_String}, diff --git a/Projects/Incomplete/StandaloneProgrammer/Descriptors.c b/Projects/Incomplete/StandaloneProgrammer/Descriptors.c index bc855181b..5fe4e0cbf 100644 --- a/Projects/Incomplete/StandaloneProgrammer/Descriptors.c +++ b/Projects/Incomplete/StandaloneProgrammer/Descriptors.c @@ -56,7 +56,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -83,7 +83,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -141,7 +141,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -152,7 +152,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -163,7 +163,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(26), .Type = DTYPE_String}, diff --git a/Projects/LEDNotifier/Descriptors.c b/Projects/LEDNotifier/Descriptors.c index bd351d0a7..3160374c9 100644 --- a/Projects/LEDNotifier/Descriptors.c +++ b/Projects/LEDNotifier/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -190,7 +190,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -201,7 +201,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -212,7 +212,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(12), .Type = DTYPE_String}, diff --git a/Projects/MIDIToneGenerator/Descriptors.c b/Projects/MIDIToneGenerator/Descriptors.c index 6e50fc8fa..ba50261bf 100644 --- a/Projects/MIDIToneGenerator/Descriptors.c +++ b/Projects/MIDIToneGenerator/Descriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -248,7 +248,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -259,7 +259,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -270,7 +270,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(14), .Type = DTYPE_String}, diff --git a/Projects/Magstripe/Descriptors.c b/Projects/Magstripe/Descriptors.c index 420fe5e02..10312ab4d 100644 --- a/Projects/Magstripe/Descriptors.c +++ b/Projects/Magstripe/Descriptors.c @@ -44,7 +44,7 @@ * * See the HID class specification for more information on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = { /* Use the HID class driver's standard Keyboard report. * Max simultaneous keys: 6 @@ -57,7 +57,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM KeyboardReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -84,7 +84,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -142,7 +142,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = /** Language descriptor structure. This descriptor, located in FLASH memory, is returned when the host requests * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -153,7 +153,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(32), .Type = DTYPE_String}, @@ -164,7 +164,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(20), .Type = DTYPE_String}, diff --git a/Projects/RelayBoard/Descriptors.c b/Projects/RelayBoard/Descriptors.c index bfd3ea4e7..ef98567ef 100644 --- a/Projects/RelayBoard/Descriptors.c +++ b/Projects/RelayBoard/Descriptors.c @@ -43,7 +43,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM RelayBoard_DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM RelayBoard_DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -70,13 +70,13 @@ USB_Descriptor_Device_t PROGMEM RelayBoard_DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -RelayBoard_USB_Descriptor_Configuration_t PROGMEM RelayBoard_ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM RelayBoard_ConfigurationDescriptor = { .Config = { .Header = {.Size = sizeof(USB_Descriptor_Configuration_Header_t), .Type = DTYPE_Configuration}, - .TotalConfigurationSize = sizeof(RelayBoard_USB_Descriptor_Configuration_t), + .TotalConfigurationSize = sizeof(USB_Descriptor_Configuration_t), .TotalInterfaces = 1, .ConfigurationNumber = 1, @@ -108,7 +108,7 @@ RelayBoard_USB_Descriptor_Configuration_t PROGMEM RelayBoard_ConfigurationDescri * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM RelayBoard_LanguageString = +const USB_Descriptor_String_t PROGMEM RelayBoard_LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -119,7 +119,7 @@ USB_Descriptor_String_t PROGMEM RelayBoard_LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM RelayBoard_ManufacturerString = +const USB_Descriptor_String_t PROGMEM RelayBoard_ManufacturerString = { .Header = {.Size = USB_STRING_LEN(5), .Type = DTYPE_String}, @@ -130,7 +130,7 @@ USB_Descriptor_String_t PROGMEM RelayBoard_ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM RelayBoard_ProductString = +const USB_Descriptor_String_t PROGMEM RelayBoard_ProductString = { .Header = {.Size = USB_STRING_LEN(10), .Type = DTYPE_String}, @@ -140,7 +140,7 @@ USB_Descriptor_String_t PROGMEM RelayBoard_ProductString = /** Serial number string. This is a Unicode string containing the device's unique serial number, expressed as a * series of uppercase hexadecimal digits. */ -USB_Descriptor_String_t PROGMEM RelayBoard_SerialString = +const USB_Descriptor_String_t PROGMEM RelayBoard_SerialString = { .Header = {.Size = USB_STRING_LEN(5), .Type = DTYPE_String}, @@ -171,7 +171,7 @@ uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue, break; case DTYPE_Configuration: Address = &RelayBoard_ConfigurationDescriptor; - Size = sizeof(RelayBoard_USB_Descriptor_Configuration_t); + Size = sizeof(USB_Descriptor_Configuration_t); break; case DTYPE_String: switch (DescriptorNumber) diff --git a/Projects/RelayBoard/Descriptors.h b/Projects/RelayBoard/Descriptors.h index 1a68ae3f7..d913eb722 100644 --- a/Projects/RelayBoard/Descriptors.h +++ b/Projects/RelayBoard/Descriptors.h @@ -48,9 +48,9 @@ */ typedef struct { - USB_Descriptor_Configuration_Header_t Config; - USB_Descriptor_Interface_t RelayBoardInterface; - } RelayBoard_USB_Descriptor_Configuration_t; + USB_Descriptor_Configuration_Header_t Config; + USB_Descriptor_Interface_t RelayBoardInterface; + } USB_Descriptor_Configuration_t; /* Function Prototypes: */ uint16_t CALLBACK_USB_GetDescriptor(const uint16_t wValue, diff --git a/Projects/TempDataLogger/Descriptors.c b/Projects/TempDataLogger/Descriptors.c index 44873f1a5..4aae39283 100644 --- a/Projects/TempDataLogger/Descriptors.c +++ b/Projects/TempDataLogger/Descriptors.c @@ -55,7 +55,7 @@ * the device will send, and what it may be sent back from the host. Refer to the HID specification for * more details on HID report descriptors. */ -USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = +const USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = { /* Use the HID class driver's standard Vendor HID report. * Vendor Usage Page: 1 @@ -72,7 +72,7 @@ USB_Descriptor_HIDReport_Datatype_t PROGMEM GenericReport[] = * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -99,7 +99,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -194,7 +194,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -205,7 +205,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -216,7 +216,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(22), .Type = DTYPE_String}, diff --git a/Projects/TempDataLogger/Lib/FATFs/diskio.h b/Projects/TempDataLogger/Lib/FATFs/diskio.h index 5df77502c..61d6601de 100644 --- a/Projects/TempDataLogger/Lib/FATFs/diskio.h +++ b/Projects/TempDataLogger/Lib/FATFs/diskio.h @@ -43,6 +43,24 @@ DRESULT disk_ioctl (BYTE, BYTE, void*); #define STA_NODISK 0x02 /* No medium in the drive */ #define STA_PROTECT 0x04 /* Write protected */ +/* Generic command */ +#define CTRL_SYNC 0 /* Mandatory for write functions */ +#define GET_SECTOR_COUNT 1 /* Mandatory for only f_mkfs() */ +#define GET_SECTOR_SIZE 2 /* Mandatory for multiple sector size cfg */ +#define GET_BLOCK_SIZE 3 /* Mandatory for only f_mkfs() */ +#define CTRL_POWER 4 +#define CTRL_LOCK 5 +#define CTRL_EJECT 6 +/* MMC/SDC command */ +#define MMC_GET_TYPE 10 +#define MMC_GET_CSD 11 +#define MMC_GET_CID 12 +#define MMC_GET_OCR 13 +#define MMC_GET_SDSTAT 14 +/* ATA/CF command */ +#define ATA_GET_REV 20 +#define ATA_GET_MODEL 21 +#define ATA_GET_SN 22 #define _DISKIO #endif diff --git a/Projects/USBtoSerial/Descriptors.c b/Projects/USBtoSerial/Descriptors.c index b117be767..46e608651 100644 --- a/Projects/USBtoSerial/Descriptors.c +++ b/Projects/USBtoSerial/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -190,7 +190,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -201,7 +201,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -212,7 +212,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(23), .Type = DTYPE_String}, diff --git a/Projects/Webserver/Descriptors.c b/Projects/Webserver/Descriptors.c index a9ba0b8ba..ba20f070a 100644 --- a/Projects/Webserver/Descriptors.c +++ b/Projects/Webserver/Descriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = +const USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = { .Config = { @@ -139,7 +139,7 @@ USB_Descriptor_Configuration_t PROGMEM ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM LanguageString = +const USB_Descriptor_String_t PROGMEM LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -150,7 +150,7 @@ USB_Descriptor_String_t PROGMEM LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ManufacturerString = +const USB_Descriptor_String_t PROGMEM ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -161,7 +161,7 @@ USB_Descriptor_String_t PROGMEM ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM ProductString = +const USB_Descriptor_String_t PROGMEM ProductString = { .Header = {.Size = USB_STRING_LEN(14), .Type = DTYPE_String}, diff --git a/Projects/XPLAINBridge/AVRISPDescriptors.c b/Projects/XPLAINBridge/AVRISPDescriptors.c index e67b56188..0715224e7 100644 --- a/Projects/XPLAINBridge/AVRISPDescriptors.c +++ b/Projects/XPLAINBridge/AVRISPDescriptors.c @@ -42,7 +42,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM AVRISP_DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM AVRISP_DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -69,7 +69,7 @@ USB_Descriptor_Device_t PROGMEM AVRISP_DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -AVRISP_USB_Descriptor_Configuration_t PROGMEM AVRISP_ConfigurationDescriptor = +const AVRISP_USB_Descriptor_Configuration_t PROGMEM AVRISP_ConfigurationDescriptor = { .Config = { @@ -127,7 +127,7 @@ AVRISP_USB_Descriptor_Configuration_t PROGMEM AVRISP_ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM AVRISP_LanguageString = +const USB_Descriptor_String_t PROGMEM AVRISP_LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -138,7 +138,7 @@ USB_Descriptor_String_t PROGMEM AVRISP_LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM AVRISP_ManufacturerString = +const USB_Descriptor_String_t PROGMEM AVRISP_ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -149,7 +149,7 @@ USB_Descriptor_String_t PROGMEM AVRISP_ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM AVRISP_ProductString = +const USB_Descriptor_String_t PROGMEM AVRISP_ProductString = { .Header = {.Size = USB_STRING_LEN(22), .Type = DTYPE_String}, @@ -159,7 +159,7 @@ USB_Descriptor_String_t PROGMEM AVRISP_ProductString = /** Serial number string. This is a Unicode string containing the device's unique serial number, expressed as a * series of uppercase hexadecimal digits. */ -USB_Descriptor_String_t PROGMEM AVRISP_SerialString = +const USB_Descriptor_String_t PROGMEM AVRISP_SerialString = { .Header = {.Size = USB_STRING_LEN(13), .Type = DTYPE_String}, diff --git a/Projects/XPLAINBridge/USARTDescriptors.c b/Projects/XPLAINBridge/USARTDescriptors.c index 7eadd9e7d..4c6a758b5 100644 --- a/Projects/XPLAINBridge/USARTDescriptors.c +++ b/Projects/XPLAINBridge/USARTDescriptors.c @@ -54,7 +54,7 @@ * number of device configurations. The descriptor is read out by the USB host when the enumeration * process begins. */ -USB_Descriptor_Device_t PROGMEM USART_DeviceDescriptor = +const USB_Descriptor_Device_t PROGMEM USART_DeviceDescriptor = { .Header = {.Size = sizeof(USB_Descriptor_Device_t), .Type = DTYPE_Device}, @@ -81,7 +81,7 @@ USB_Descriptor_Device_t PROGMEM USART_DeviceDescriptor = * and endpoints. The descriptor is read out by the USB host during the enumeration process when selecting * a configuration so that the host may correctly communicate with the USB device. */ -USART_USB_Descriptor_Configuration_t PROGMEM USART_ConfigurationDescriptor = +const USART_USB_Descriptor_Configuration_t PROGMEM USART_ConfigurationDescriptor = { .Config = { @@ -190,7 +190,7 @@ USART_USB_Descriptor_Configuration_t PROGMEM USART_ConfigurationDescriptor = * the string descriptor with index 0 (the first index). It is actually an array of 16-bit integers, which indicate * via the language ID table available at USB.org what languages the device supports for its string descriptors. */ -USB_Descriptor_String_t PROGMEM USART_LanguageString = +const USB_Descriptor_String_t PROGMEM USART_LanguageString = { .Header = {.Size = USB_STRING_LEN(1), .Type = DTYPE_String}, @@ -201,7 +201,7 @@ USB_Descriptor_String_t PROGMEM USART_LanguageString = * form, and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM USART_ManufacturerString = +const USB_Descriptor_String_t PROGMEM USART_ManufacturerString = { .Header = {.Size = USB_STRING_LEN(11), .Type = DTYPE_String}, @@ -212,7 +212,7 @@ USB_Descriptor_String_t PROGMEM USART_ManufacturerString = * and is read out upon request by the host when the appropriate string ID is requested, listed in the Device * Descriptor. */ -USB_Descriptor_String_t PROGMEM USART_ProductString = +const USB_Descriptor_String_t PROGMEM USART_ProductString = { .Header = {.Size = USB_STRING_LEN(18), .Type = DTYPE_String}, -- cgit v1.2.3