2 Replies Latest reply on Aug 13, 2015 1:18 AM by hima

    PSoC 5LP WDT Reset Detection

    user_57926609

      Hi to all!

         

      The PSoC® Creator™ System Reference Guide, Document Number: 001-94480, Rev. ** (page 97) states:
      "The CySysResetReason() function can be used to detect if the watchdog has triggered device reset"

         

      It seems to me that this function does not exist!

         
          
                
         
         
          
                
         
         
          
            Does anyone have the specifications for this function?    
          
            Or this is a documentation error?    
          
                
          
           Thank you to all!    
          
                
          
           Graziano G. Ravizza    
         
         

       

         

       

         

       

         

          

         

               

        • 1. Re: PSoC 5LP WDT Reset Detection
          user_57926609

          Hi,

             

          Since I think CySysResetReason() function does not exist, I'm testing the use of RESET_SR0 register to detect the source of the reset.

             

          At the very beginning of the main code I put the test:

             

          void main()
          {
              uint8 ResetReason;    /* Reason of Reset */

             

              ResetReason = CY_GET_REG8(CYDEV_RESET_SR0);
             
              if ((ResetReason & 0x08) == 0x08)
              {

             

                  // THE RESET source was WATCHDOG!
              }   

             

          ...and so on

             

          BUT seems the code does not recognize that the source of the reset was a WDT (I'M SURE was a WDT!)

             

          What do you think?

             

          Something wrong? Any suggestions?

             

          Thanks to all!

             

          Graziano

          • 2. Re: PSoC 5LP WDT Reset Detection
            hima

            Hey,

               

            Can you please attach the project. We can have a look at the project.

               

             

               

            Thanks,

               

            Hima