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.

TI's Hercules RM48L952ZWT board Red Error LED Light Turns on after board initialization.

Other Parts Discussed in Thread: HALCOGEN, RM48L952, RM46L852

Hi. We are using TI's Hercules RM48L952ZWT board.  After USB Host drivers are initialized a red light, next to nhet1(27) white led, on the Hercules board turns on.  What type of error does this red light indicate?  It happens when we try to enable  the clock for the USB Host controller

i.e,

/* ------------- USB CLOCK INITIALIZATION ------------- */

BSP_SYS_REG_PLLCTL3 (systemREG2 address 0xFFFFE100)  = 0x200; /* En the clock for the Host controller */

....

 Should we have enabled something morein HalCoGen for this to work for USB Host? We have the box checked in PINMUX USBHost0. Thank you.

  • Hi Tammy,

    You have to look at the ESM registers to figure out which error this is due to.
    There's a table in the datasheet that lists the error sources.

    I think this is the same error that I ran into. Have you used HalCoGen startup code?
    If so you want to correctly set the PLL for USB using HalCoGen, and comment out the PLL initialization in the Micrium BSP.

    The way it was being done in the BSP was not really comprehending HalCoGen startup code, and if you already have the PLL enabled and locked and then go make a dramatic change to the PLL setting while running - you'll trip the PLL slip detection. There is a way to turn the PLL off, make a big change to the setting, and then turn it back on, but it's quite involved and easier to configure it only once in the startup code generated by HalCoGen.
  • Hi. Thank you. Yes you are correct. It is the PLL2 Slip that is enabled in ESM that is triggering this and we do go from running the autogenerated HalCoGen to using the Micrium initialization code (and where you saw there is a write into PLL). You wrote"you want to correctly set the PLL for USB using HalCoGen, and comment out the PLL initialization in the Micrium BSP." Is there a wiki or document on how to set up HalCoGen PLL for USB?
  • Tammy,

    It's pretty easy, you need 48MHz and 12MHz for the USB modules.

    The part # in the question was RM48852ZWT and I'm not sure if this means the RM48L952 or the RM46L852.
    There is a slight difference in the clock tree between the two. The RM46L852 is simplified from the 48L952 w.r.t. USB.
    Sunil wrote up a description of the differences e2e.ti.com/.../369302
  • Hi Thank you. Yes you are right, I did a typo which I have fixed now. It is the RM48L952ZWT. In Halcogen on the 48MHz and 12MHz for the USB that you posted, you mean the GCM tab i.e., under clk Domains or the PLL (PLL2 Configuration Osc Freq.?) ? The USB has no field for setting PLL for USB modules. Thank you again.
  • Hi Tammy,

    The GCM tab should be most critical, but if you can't find a divider that works to generate 48MHz then you may need to make adjustments to the PLL output frequency. Having a 2nd PLL makes this easy since you can set it independently of the CPU operating frequency.
  • Hi Thank you. It works now (no more esm trigger) after removing Micrium hardcoded driver code as you guided. Changed HalCoGen:

    1. PLL Tab. PLL 2 Configuration: Clk Div = 1, Multiplier = 3, PLL 2 Div = 1 (OSC Freq = 16), then PLL2 = 48
    2. GCM Tab. VCLKA3 Src = PLL2 and VCLKA3 Divider = 4 (so VCLK DIVR = 12)

    Thank you again.