1 Reply Latest reply on Dec 7, 2018 1:12 AM by ShanmathiN_06

    CapSense PWM

    95vinaybharadwaj_3886151

      Greetings!

       

      I'm using PSoC 5LP MCU in my project. I'm interfacing CY8CMBR3116 CapSense controller with PSoC through I2C communication.

       

      My requirement is that the CapSense LEDs should glow at the beginning. When I touch a CapSense, the respective CapSense LED should keep blinking until the CapSense is pressed again.

       

      But I'm unable to blink the CapSense LED. I tried to do it using PWM_DUTYCYCLE_CFG1 [for the CapSense at CS1 pin] register but the LED does not blink.

       

      Any help is welcome. Thanks in advance.

       

      Regards,

      Vinay

        • 1. Re: CapSense PWM
          ShanmathiN_06

          Hello Vinay,

           

          You can enable TOGGLE_EN so that the LED turns ON/OFF on consecutive touches on the sensor.

          As you have mentioned, you can control the active and inactive duty cycles through the PWM_DUTYCYCLE_CFG register. However, since the frequency is high, you could only vary the intensity/ brightness using this register.

           

          In case, you would like to visually view the blinking effect in LEDs, I suggest you to enable host control and control the GPIOs in host firmware, depending on button touches.

          Read the BUTTON_STAT register, when the HI pin goes low to find the detected button touches and control the GPIOs accordingly.

           

          Thanks,
          Shanmathi