Cypress Perform

Home > Design Support > Cypress Developer CommunityTM > Cypress Forums > USB Controllers > Adding serial number descriptor to FX3 firmware

Bookmark and Share
Cypress Developer CommunityTM
Forums | Videos | Blogs | Training | Rewards Program | Community Components



Adding serial number descriptor to FX3 firmware
Moderator:
RSKV

Post Reply
Follow this topic



Adding serial number descriptor to FX3 firmware

aulucan posted on 24 Jul 2012 12:01 AM PST
Senior Member
19 Forum Posts

Hello,


How can we add serial number descriptor to FX3 firmware design? "boot_fw" example firmware has serial number descriptor.
I looked at the example and I added following serial number definition and I called following function in the code but Control Center did not show the serial number. By the way, we can see the bootloader's serial number in Control Center.


Regards,
Ali


const uint8_t CyFxUSBSerialNumDesc [] =
{
    0x1A,                           /* Descriptor size */
    CY_U3P_USB_STRING_DESCR,        /* Device descriptor type */
    '0',0,'0',0,'0',0,'0',0,'0',0,'0',0,
    '0',0,'0',0,'0',0,'A',0,'A',0,'A',0,
    0,0,                            /* long word align */
};


apiRetStatus = CyU3PUsbSetDesc(CY_U3P_USB_SET_STRING_DESCR, 3, (uint8_t *)CyFxUSBSerialNumDesc);




Re: Adding serial number descriptor to FX3 firmware

RSKV posted on 24 Jul 2012 03:54 AM PST
Cypress Employee
655 Forum Posts

Please check whether you are doing the following change:

/* Standard device descriptor for USB 3.0 */

const uint8_t CyFxUSB30DeviceDscr[] __attribute__ ((aligned (32))) =

{

    0x12,                           /* Descriptor size */

    CY_U3P_USB_DEVICE_DESCR,        /* Device descriptor type */

    0x00,0x03,                      /* USB 3.0 */

    0x00,                           /* Device class */

    0x00,                           /* Device sub-class */

    0x00,                           /* Device protocol */

    0x09,                           /* Maxpacket size for EP0 : 2^9 */

    0xB4,0x04,                      /* Vendor ID */

    0xF0,0x00,                      /* Product ID */

    0x00,0x00,                      /* Device release number */

    0x01,                           /* Manufacture string index */

    0x02,                           /* Product string index */

    0x03,                           /* Serial number string index */

    0x01                            /* Number of configurations */

};

 

/* Standard device descriptor for USB 2.0 */

const uint8_t CyFxUSB20DeviceDscr[] __attribute__ ((aligned (32))) =

{

    0x12,                           /* Descriptor size */

    CY_U3P_USB_DEVICE_DESCR,        /* Device descriptor type */

    0x10,0x02,                      /* USB 2.10 */

    0x00,                           /* Device class */

    0x00,                           /* Device sub-class */

    0x00,                           /* Device protocol */

    0x40,                           /* Maxpacket size for EP0 : 64 bytes */

    0xB4,0x04,                      /* Vendor ID */

    0xF0,0x00,                      /* Product ID */

    0x00,0x00,                      /* Device release number */

    0x01,                           /* Manufacture string index */

    0x02,                           /* Product string index */

    0x03,                           /* Serial number string index */

    0x01                            /* Number of configurations */

};

 Regards,

sai krishna.

 



Re: Adding serial number descriptor to FX3 firmware

aulucan posted on 24 Jul 2012 04:05 AM PST
Senior Member
19 Forum Posts

Sai,


These fields were 0x00. I changed fields with 0x03 as you said. Now, I can see the serial number in Control Center.


Thank you for your help.
Ali






ALL CONTENT AND MATERIALS ON THIS SITE ARE PROVIDED "AS IS". CYPRESS SEMICONDUCTOR AND ITS RESPECTIVE SUPPLIERS MAKE NO REPRESENTATIONS ABOUT THE SUITABILITY OF THESE MATERIALS FOR ANY PURPOSE AND DISCLAIM ALL WARRANTIES AND CONDITIONS WITH REGARD TO THESE MATERIALS, INCLUDING BUT NOT LIMITED TO, ALL IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT OF ANY THIRD PARTY INTELLECTUAL PROPERTY RIGHT. NO LICENSE, EITHER EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, IS GRANTED BY CYPRESS SEMICONDUCTOR. USE OF THE INFORMATION ON THIS SITE MAY REQUIRE A LICENSE FROM A THIRD PARTY, OR A LICENSE FROM CYPRESS SEMICONDUCTOR.

Content on this site may contain or be subject to specific guidelines or limitations on use. All postings and use of the content on this site are subject to the Terms and Conditions of the site; third parties using this content agree to abide by any limitations or guidelines and to comply with the Terms and Conditions of this site. Cypress Semiconductor and its suppliers reserve the right to make corrections, deletions, modifications, enhancements, improvements and other changes to the content and materials, its products, programs and services at any time or to move or discontinue any content, products, programs, or services without notice.