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.

AM3352: How to configure to use Internal Clock Source

Part Number: AM3352

I have the problem with the DMTIMER1 (1ms timer)  as follow:

1- The DMTIMER1 after being configured and as part of the configuration for that timer the last step is to send the soft reset command then to monitor the reset done status .  The reset done status never showed done. 

    In this case, the CLOCK source is configured to use external 32KHz.

2- Because #1 was failed, I have tried to use the internal clock source but this also failed plus I am not sure the correct way to onfigured the processor to use the internal clock source.

I need help to be sure the internal clock source is configured properly.

And I also need help to analyze the the processor failed case.

The following the code fragment show the clock selection:

/*! \details select the clock source for the 1ms timer

*/

void BSP_SetupClockSrc(void)

    RTCWriteProtectDisable(SOC_RTC_0_REGS); //Write to Kick0 and Kick 1

    RTC_OSC_RegStruct  tOSC_Reg;

    tOSC_Reg.All = HWREG(SOC_RTC_0_REGS + RTC_OSC);

    tOSC_Reg.Bit.RES_SELECT     = 0u; //select internal resistor

 

    #ifdef INTERNAL_CLKSRC    //Internal clock source

      tOSC_Reg.Bit.SEL_32KCLK_SRC = 0u; //select Internal clock source

      tOSC_Reg.Bit.OSC32K_GZ      = 0u; //select Enable OSC32K Osc

    #else    //External clock source

      tOSC_Reg.Bit.SEL_32KCLK_SRC = 1u; //select External clock source

      tOSC_Reg.Bit.OSC32K_GZ      = 0u; //select Enable OSC32K Osc

    #endif

 

    HWREG(SOC_RTC_0_REGS + RTC_OSC) = tOSC_Reg.All;

 

    if (HWREG(SOC_RTC_0_REGS + RTC_OSC) != tOSC_Reg.All)

    {

      //Sysfail here

    }

    RTCWriteProtectEnable(SOC_RTC_0_REGS);  //enable the RTC write protect

}

 

 

  • Hi ,

    Wondering, if you are using the RTC register or DMTIMER1MS register for your work. 
    Can you please share the address of SOC_RTC_0_REGS and  RTC_OSC macro value?

    It appears to me that you are not using DMTIMER1MS registers instead you are programming the RTC.

    Please find the memory map from AM335x TRM as below: