4 Replies Latest reply on Jan 10, 2013 7:49 AM by kasi_283151

    GPIF Pull-ups/Pull-downs

      Is it possible to use a pull-up or pull-down on a GPIO that is used by the GPIF?  If so, how do I go about implementing this?

        • 1. Re: GPIF Pull-ups/Pull-downs

          I am getting a configuration error from CyU3PDeviceConfigureIOMatrix() when any of the pins that are part of the GPIF are enabled for GPIO. In the Programmer's Manual it states that when a block of pins are allocated into a group (GPIF, UART, etc) then "unused pins may be overridden as GPIO" - the implication being that a pin can't be both.

          • 2. Re: GPIF Pull-ups/Pull-downs

            If you wanted to use GPIF pins as GPIO you would need to call CyU3PDeviceGpioOverride() for each pin before calling CyU3PPibInit() - and not include any of those pins in the call to CyU3PDeviceConfigureIOMatrix().

            But it sounds like what you want is to keep the pins as part of GPIF and merely change how they are driven. Correct?



            • 3. Re: GPIF Pull-ups/Pull-downs

              Correct, I would like to keep the pins as part of the GPIF and still take advantage of the internal pull-up/pull-down capabilities.


              Here is the answer I got from Cypress technical support:

              The CyU3PDeviceGpioOverride() API should be used followed by the CyU3PGpioSetSimpleConfig() API to configure an I/O pin used by the GPIF.

              The CyU3PDeviceConfigureIOMatrix() API cannot access the pins which are allocated into a group.
              • 4. Re: GPIF Pull-ups/Pull-downs

                You can use CyU3PGpioSetIoMode for GPIF controlled pins as well.