GPIF Pull-ups/Pull-downs

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

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?

0 Likes
4 Replies
Anonymous
Not applicable

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.

0 Likes
Anonymous
Not applicable

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?

Steve


 

0 Likes
Anonymous
Not applicable

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.
0 Likes
Anonymous
Not applicable

You can use CyU3PGpioSetIoMode for GPIF controlled pins as well.

   

Kalev

0 Likes