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.

AWR1642: How to disable watchdog driver

Part Number: AWR1642

Hello team,

Customer is now enable the watchdog driver in both SBL and APP. And he has one question is that we de-init all the other driver at the end of the SBL and then jump to APP. But in the watchdog driver, the close function is empty. So they can not close the watchdog driver.

So, customer's question is, how to close the watchdog? If the watchdog cannot be close, how to due with the watchdog during the SBL jumping to APP?

And, is the watchdog driver can be re-config in app or not? Will it cause halt similiar to CAN driver?

Thanks.

Wesley

  • Hi Wesley,

    Customer needs to modify same SOC driver API a bit to disable the Watchdog (held in reset). Here is the code snippet for reference.

    int32_t SOC_disableWatchdog(SOC_Handle handle, int32_t* errCode)
    {
        SOC_DriverMCB*      ptrSOCDriverMCB;
        int32_t             retVal = 0;
    
        /* Get the pointer to the SOC Driver Block: */
        ptrSOCDriverMCB = (SOC_DriverMCB*)handle;
        if (ptrSOCDriverMCB == NULL)
        {
            *errCode = SOC_EINVAL;
            retVal   = MINUS_ONE;
        }
        else
        {
            /* Put Watchdog into Reset */
    		ptrSOCDriverMCB->ptrRCMRegs->SOFTRST3 = CSL_FINSR (ptrSOCDriverMCB->ptrRCMRegs->SOFTRST3,
    															SOFTRST3_WDTRST_BIT_END,
    															SOFTRST3_WDTRST_BIT_START,
    															0xADU);
        }
        return retVal;
    }

    After this application can reconfigure the watchdog if required.

    Regards,

    Jitendra