How to Use Potentiometer Properly?

Hello.

I want to create a voltage divider using Arduino. Now, I am using a 30 volts DC power source, and 26 kilo-ohms resistor as a load (ideal would be 25 kilo-ohms, but didn’t get one at lab). As the second resistor, I want 5 kilo-ohms. So, I want to use a potentiometer.

Now I am really confused about the potentiometer wiring.

I want to use the output voltage of the wiper to analog port A2 (as shown in the attached photo).

I know that to set 5 kilo-ohms, I need to connect the wiper to the red plug of the multimeter.

My question is, which pin (left or right of wiper) of the potentiometer should be to the multimeter? Also, which pin should be connected to the ground, and which should be connected to the load?

Thanks in advance.

My question is, which pin (left or right of wiper) of the potentiometer should be to the multimeter? Also, which pin should be connected to the ground, and which should be connected to the load?

It doesn't matter as long as one of connections is to the wiper. (Resistors don't have polarity.) If you use the opposite "end" of the pot, the effect of the rotation will be reversed. i.e. If clockwise is more resistance and you switch terminals, clockwise will be less resistance. Or in the case of an audio taper pot, where half-resistance is not in the middle, switching terminals will affect the way it operates (but audio volume controls normally use all 3 terminals).

Check the resistance with your multimeter.... and play around to get a feel for how it works... Assuming it's a 10K pot, the mid point should be 5K in between the wiper and either terminal (within tolerances).

If you're only using 2-terminals (using it as a variable resistor instead of as a pot) it's fairly common to connect the unused terminal to the wiper, but as long as everything is working normally that won't make any difference. The idea is, that if the wiper makes poor contact at a certain position you'll get the full resistance of the pot instead of infinity...

I want to create a voltage divider using Arduino. Now, I am using a 30 volts DC power source, and 26 kilo-ohms resistor as a load (ideal would be 25 kilo-ohms, but didn't get one at lab). As the second resistor, I want 5 kilo-ohms. So, I want to use a potentiometer.

Depending on your application/requirements, there's probably a way to compensate for the "wrong resistance" in software. ;)

And/or, it's common to put two resistors in series to get the right value, or a "small" pot in series with the resistor for finer/more precise adjustment. i.e. It can be tricky to adjust a 10K pot to 5K within 1%.

So, you're constructing a voltage divider to divide 30 V down to 5 V, correct? And you're using a 10 kΩ variable for the "lower" resistor in the divider, right? That means that, when the variable is away from the center position, you'll either get less than 5 V in one direction, or more than 5 V in the other direction. You could get up to 8.33 V with the pot turned all the way to one side. So you're risking blowing out A2 if not worse. With 26 kΩ in series with the 30 V source the risk is probably not great, since you'll see no more than 1.15 mA, But still one is not supposed to exceed 5 V on an input pin.

What is is it you're trying to accomplish? Perhaps there is a better way.