Measuring Resistive Pull-Up in PSoC

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

cross mob
Kurian
Level 1
Level 1
5 questions asked 5 replies posted 10 sign-ins

In my application, I want to measure the resistance value of the internal GPIO resistive pull up. Any suggested methods. ?

 

 

0 Likes
5 Replies
DennisS_46
Employee
Employee
100 sign-ins 50 likes received 50 solutions authored

Configure any GPIO as a resistive pull-up. Write logic 1 to that pin. Measure resistance with multi-meter.
Or, configure GPIO as resistive pull-up. Connect GPIO to external resistor with known value pulled to ground.
Measure voltage, calculate resistance.
---- Dennis Seguine, PSoC Apps Engineer

0 Likes

Let me reframe the question. Is there a method by which I can measure the resistance without the need of any external components ?

I was thinking of connecting an IDAC to the GPIO pin with resistive pull. However, the PSoC does not support connecting IDAC to non-analog pin. 

0 Likes

If you are curious what the resistance value is, its about  4.4-4.7k. If you are thinking to exploit internal resistors for something else, I would recommend to describe the project goal rather than asking specific questions

DennisS_46
Employee
Employee
100 sign-ins 50 likes received 50 solutions authored

Kurian:
Actually, you can connect digital I/O to GPIO and also to an analog pin. If you just look at the GPIO table in the TRM: DennisS_46_0-1679001990105.png
it doesn't look possible. But with a closer look at the GPIO block diagram, also from the TRM:

DennisS_46_1-1679002122714.png

You can see that the analog path (4th line from the bottom), the analog input has nothing to do with the drive mode. So, there should be no reason that you can't drive a resistive pullup output while also connecting to and iDAC   AND   an ADC.  The ADC puts a little bit of a load on the pin, so you would have to give it some time to settle. 

A PSoC schematic with said connection implemented is:

DennisS_46_2-1679002693597.png
It builds nicely, do your own code.
There is one wrinkle however. The GPIO pullup resistor is spec'd at 3.5k to 8.5k per datasheet.  The ADC scale accuracy is better than 1%, but  -- here's the problem -- the iDAC scale is +/- 10%, per iDAC component datasheet. Thus, you won't get a resistance measurement any better than +/- 10%. If that's good enough, cool; if not, measure externally. You will find that the GPIO resistance is quite uniform across the chip; no, I don't have test data to prove it, this has been done by characterization on dozens of chips over >10 years of production.

---- Dennis Seguine, THE senior PSoC apps engineer

 

Great. Thanks for the detailed reply. 

0 Likes