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.

MSP430F479: Watchdog Timer Expiration Issue

Part Number: MSP430F479
Other Parts Discussed in Thread: MSP430WARE

Dear All, 

My Micro controller is getting Rest . And i have troubleshooted the  root cause and that is because of the Watchdog timer expiration .

Kindly help me to solve the issue .

Regards

Sameer Batra 

  • Hi Sameer,

    please note that the watchdog timer is meant to do a controlled system restart after a software problem occurs.

    You can disable the watchdog timer, especially before starting initialization of the different modules which might take time. Most of our code examples do this at the beginning of the program code so just have a look at the different code examples we provide.

    This way your MCU will not be reset after a software hangup though so be careful.

    I'd suggest for you to also read through the device family user's guide (SLAU056) to become familiar with the watchdog timer module.

    Best regards,

    Britta

  • Dear Britta,

    Thanks for your quick response .

    You mean to say i should disable my  watchdog timer, especially before starting initialization of the core ( different modules ) ?

    You have also mentioned about some samples codes , can you please post from where i will get that sample code .

    regards,

    Sameer Batra 

  • Hi Sameer,

    you'll find all of our code examples within the MSP430Ware.

    In Code Composer Studio you can also open the Resource Explorer, then browse to the part your working with, go to MSP430Ware, and select Periphreal Examples -> Register Level.

    Please be aware that, when disabling your watchdog timer, you won't have the automatic reset in case your application hangs. You might want to think of re-enabling the whatchdog timer at a later point in time. Please also review the according chapter in the User's Guide as it gives some indications on how to use the watchdog timer.

    Best regards,

    Britta

  • Dear Britta, 

    I will surely go through the guide and the reference code and try to find out the below problem :

    Problem : The Watchdog timer timeout i have set in my code is 2 secs &  module (LCD Controller) takes 20 Msec to get initialized . Then also my watchdog timer is getting expired .

    Thanks .

    Regards

    Sameer Batra 

  • Hi Sameer,

    did you look at the documentation and example code which I indicated. Did it help?
    If not, could you share more details on how you configure the LCD Controller and Watchdog timer?

    Thanks and best regards,
    Britta
  • Hi Britta , 

    I gone through the documentation and the code example . It helps me to find out the root cause of my Problem statement .

    Problem Statement : My Micro-controller  was getting reset because of the Watchdog timer Expiration issue .

    I would Like to share the details on the how i solve the problem .

    Solution : 

    A POR is a device reset. A POR is only generated by the following three
    events:

    • A low signal on the RST/NMI pin when configured in the reset mode
    • An SVS low condition when PORON = 1.
    • A PUC is always generated when a POR is generated, but a POR is not generated by a PUC.
    • The following events trigger a PUC:
    • A POR signal
    • Watchdog timer expiration when in watchdog mode only
    • Watchdog timer security key violation
    • A Flash memory security key violation


    I Checked all the Above condition and found out that my watchdog timer expiration was the reason of my Micro-controller reset .

    For the I2C Initialization i gone through the 21st chapter of the User guide (slau0561) all the relevant information about I2C Mode .

    In the initialization of I2C negative acknowledgement Flag is enabled (UCNACKIFG)  .  So when the Negative acknowledgement bit is set In the service routine of the interrupt  feeding of the watch dog is must ( which i forget to write in my code )  . 

    Hope i am clear , 

    Thanks &  Regards ,

    Sameer Batra 

     

  • Hi Sameer,

    I'm glad that the documentation helped you to understand what was the cause of your issue.
    Please let me know in case I can close this thread now.

    Thanks and best regards,
    Britta
  • Hi Britta ,

    Kindly closed the thread .

    Thanks for the guidance .

    Regards,

    Sameer Batra 

**Attention** This is a public forum