1 Reply Latest reply on Mar 13, 2018 8:07 AM by e.pratt_1639216

    TCPWM QuadDec counter reset after DeepSleep

    sungjune_2519341

      Hi,

       

      I'm having an issue with TCPWM QuadDec. To my knowledge the counter value should be retained during DeepSleep. However, it does not survive DeepSleep. The settings of the QuadDec was saved and restored. But the counter value (qdec_count below) resets, i.e. returns to the initial value 0x8000 after the DeepSleep.

       

      QuadDec_WriteCounter(12345)

       

      QuadDec.Sleep()

      CySysPmDeepSleep();

      QuadDec.Wakeup()

       

      qdec_count = QuadDec_ReadCounter() // always 32768

      You can reproduce it with the project included.

       

      Thanks,