This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSP430F6659: device's usb not enumerated in host

Part Number: MSP430F6659

Hello sir,

i want to use usb module of msp430f6659. i have downloaded MSP430USBDevelopersPackage_5_10_00_17 and installed MSPUSBDescriptorTool-5_00_10_19 as well as HID demo app.

i use H6_SendDataBackground example from above package. Using descriptor tool i generate code as per my setting and overwrite it to files in USB_Config folder.

I have made hardware as per slaa457a datasheet page no 14. In hardware i do not connect any external supply on VUSB  pin as a want to use it from VBUS . I want to use separate power supply for microcontroller(other than USB module) which is external 3.3V supply and it remain on independent of weather usb connected with pc or not.

I want to use VBUS spply only for USB module.

my XT2 crystal is 16.384MHZ.

i have not made any other change in example.I want to use HID interface

when i connect this hardware to pc it shows UNKNOWN DEVICE.

please help me that how can i setup usb so it works properly.

it is required to configure clock and port pin separately or it is included in example ?

please mention the necessary  changes that  i have to do for make it working.

  • It is necessary to configure the clock in the USB_config/descriptors.h file, with the USB_XT_* symbols.

    (There is not USBPLL_SETCLK_ symbol for 16.384 MHz; you have to find the correct UPMB/UPQB values yourself, if that is even possible.)
  • Hello,
    Thanks for your reply,

    please find below code from discriptor.h .

    this code is according to 16Mhz which i have selected discriptor tool software selection.


    // MCLK frequency of MCU, in Hz
    // For running higher frequencies the Vcore voltage adjustment may required.
    // Please refer to Data Sheet of the MSP430 device you use
    #define USB_PLL_XT 2 // Defines which XT is used by the PLL (1=XT1, 2=XT2)
    #define USB_XT_FREQ_VALUE 16.0 // Indicates the freq of the crystal on the oscillator indicated by USB_PLL_XT
    #define USB_XT_FREQ USBPLL_SETCLK_16_0 // Indicates the freq of the crystal on the oscillator indicated by USB_PLL_XT
    #define USB_DISABLE_XT_SUSPEND 1 // If non-zero, then USB_suspend() will disable the oscillator
    // that is designated by USB_PLL_XT; if zero, USB_suspend won't
    // affect the oscillator
    #define USB_DMA_CHAN DMA_CHANNEL_1 // Set to 0xFF if no DMA channel will be used 0..7 for selected DMA channel


    please give me hardware connection diagram so that i can double check it.

    As per my study when usb cable not connected with pc D+ line remain high and D- remain low initialy But in my harware it is not happening. In my case both line remain low. Is there any other changes required to make my device work ?


    i am new in USB development so please explain detail.
  • What is the crystal frequency? 16 Mhz or 16.384 MHz?
  • Hello,

    Thank you very much for your quick reply,

    crystal is 16.384 but i have selected 16 mhz so i am going to replace it with 16 mhz in hardware because there is no selection for 16.384 Mhz in discriptor tool .
  • Unobtainium said:

    crystal is 16.384 but i have selected 16 mhz so i am going to replace it with 16 mhz in hardware because there is no selection for 16.384 Mhz in discriptor tool .

    USB spec defines the tolerance as +/- 0.25% (2500 ppm) for full-speed bus. It should work with your crystal, with manually inserted USBPLLDIV value.

  • Hello,

    Thanks for your reply,

    I can't find that where should i make above change in H0_SimpleSend example.

    please mention file name in which i have to change for above setting.

    one another issue i find is when i connect usb cable to my pc, MCU starts heating .

    I can't getting that why MCU is heating as i verify hardware as per datasheet.

    I have given 3.3V to mcu and use VBUS supply for USB module power. I have not taken any power out from VUSB and left it unconnected by simply placing 220nF capacitor between Vssb and VUSB (same for V18 and VUSB).
  • Unobtainium said:

    I can't find that where should i make above change in H0_SimpleSend example.

    please mention file name in which i have to change for above setting.


    Find it by yourself. Just modify line USBPLLDIVB = something to USBPLLDIVB = 0x0625, or define your own constant and update code where it is needed.

    #define USBPLL_SETCLK_16_384      0x0625  /* USB - PLL Set for 16.384 MHz input clock */

  • Hello
    Thanks for your reply

    i have found above line in discriptors.h and modified as you said above also i have found problem of heating of MCU as it is one of the hardware short . So both problem resolved

    But still my device not enumerated in HOST pc

    Sometimes HOST shows that "  A USB device has exceeded the power limit of its HUB port "  and " Unknown device "

    There is one diode used in VBUS .which diode should i connect there. Is there any specific part number ?

    please help me to troubleshoot the problem...

  • The Schottky diode prevents current from flowing from your device into the bus if the bus is powered off; it's needed only if you have a separate power supply.

    The power limit error message says that your device uses too much current. Thus might be an error in your circuit (a short), or defective hardware.
  • Hello,
    thanks for your reply,

    the problem of power limit error solved and for once my device detected in Host pc and when i open demo app it become unknown device.
    after that same problem of unknown device starts.
  • Hello,
    thanks for your support,

    My device got enumerated on HOST pc and start working.
    But some time when i send data from HID Demo app it shows following error and device get disconnected.


    TX-->11245678!
    RX-->Error receiving buffer from device!
    Disconnected from device


    I have checked by placing break point at UNMI ISR but i think it is not due to any NMI reset interrupt because it will no go in UNMI ISR.

**Attention** This is a public forum