Way over complicated my systems

Status
Not open for further replies.

toxsick

Member
Hi all.

I used an Arduino to switch 6 relays each with resistors across the terminals to Add or Remove resistance to a DC-DC converter board.
My way of making an Arduino controlled DC power supply. It works for the most part.
It made my programming the Arduino a real pain..

Well I am wanting more accuracy. In fan speed steps.. instead of 6 steps of fan speeds.. I want to know if I can use this digital potentiometer.

Would this digital resistor in any way work as I hope it would?
Or is this a totally different device?

Regards
Shaun.
 

Attachments

  • Screenshot_20200506-191047_AliExpress.jpg
    728.5 KB · Views: 108
A digital potentiometer is basically just a lot of switched resistors, so it should have lots more steps.

The X9C104 has 100 steps. It runs from 5 V and the voltages on the potentiometer terminals must be between -5 V and +5V.

Like most potentiometers, the end-to-end accuracy is poor, at ±20%, so for best accuracy you should use it as a proper potentiometer.
 
Hi.

Thanks for replying.

I know when using or buying potentiometer they have a range.. eg 100Kohm
So that is 100Kohm to infinity resistancr
Or is it 100Kohm to closed circuit 0ohm
?

A DC-DC converter I have spare here uses a 10Kohm multiturn
I basically unsoldered that and put in place a bunch of resistors. I forget the values I in my circuit system as it's all sealed and on a wall!

Anyways. Can this digital resistor circuit give a varied resistance output? Or does it simulate a 5v like you mentioned? I am confused .

I could add a normal resistor to bring this close to the 10k if needed, I don't know much.
I am hoping that it's as simple as connect the resistor points to my power supply and adjust it via arduino
 
A potentiometer including a digital one has two ends and a slider. The resistance between the two ends is fixed and is the potentiometer value.

The resistance to the slider from one end, plus the resistance from the slider to the other end, always adds up to the resistance between the two ends (approximately).

So the resistance from one end to the slider of a 100 kOhm potentiometer will vary between 0 and 100 kOhm

There are two main ways that potentiometers can be used. If it is used as a variable resistance, connection is only made to the slider and one end. If the potentiometer is used as a variable potential divider, then the two ends are connected to known voltages, and the voltage on the slider is the output.

When being used as a variable resistance, the tolerance of the value makes a lot more difference. A 100 kOhm potentiometer can be ±20%, so one might be 0 - 80 kOhm, and another might be 120 kOhm. They might vary with temperature as well. For the X9C104, that is up to 300 ppm/°C

Also, when being used as a variable resistance, the slider resistance has to be considered. It's not a lot for a 100 kOhm, as the X9C104 is 100 kOhm and the slider resistance is typically 40 Ohm, 100 Ohm maximum.

When the potentiometer is being used as a potential divider, then the overall resistance doesn't matter, the slider resistance is usually unimportant and the temperature change of the overall resistance doesn't matter. For the X9C104, the ratio only varies by 20 ppm/°C.

Here is one way that you can use a potentiometer to control a power supply. It needs an adjustable regulators that has a feedback voltage that is a lot less than the reference voltage. A 5 V reference can be used and may regulators have a 1.25 V feedback voltage.

If you have a D2A (digital to analog) converter, that can be used instead of the digital potentiometer.
 
Thankyou for your explaining of pots. And it makes alot of sense ..

I watched a demo of the chip being used and seems to be quite interesting

I was looking at digital to analog boards for Arduino but the voltage output is 0-10v max and not more then 20ma output.. something very small. Certainty wouldn't drive a fan.
 
The 0-10 V signal could be used to control a voltage regulator, using the circuit that I posted, without the potentiometer.
 
If you're using the relays to switch different resistors into the power line to the fan, a digipot is not going to work. As you have seen, they can't supply much current.

The more conventional way of controlling speed of a fan like a computer fan is to use PWM (Pulse Width Modulation) to drive the fan. 4-Wire fans have a control input designed to take a 5 volt, loa-current signal for speed control. If your fan doesn't feature this, then the micro's PWM signal is used to switch a MOSFET to control power to the fan.

Think of PWM as a square wave with different duty cycles. If the duty cycle is 100%, power is on full time and the fan runs at full speed. If the duty cycle is 25%, the power is on 25% of the time and the fan runs at 25% speed. The frequency range of the PWM signal depends on the fan, at least a few hundred Hz.

Hope this helps.
 
Okay interesting.

I can learn more about making the circuit for the regulator power supply you describe.

Can you recommend a typical regulator chip to use here?

I need to run a blower fan at 12V and max amp on sticker is 1.66A

Lowest voltage I wish to run is 3.7v which is an idle slow spin.

Thx
Shaun

Edit: new comment while posting this,
I don't use resistors to slow a fan, I use the resistors on the relays to apply more or less resistance to the DC-DC controller..

So if I can substitute the 6 relays for Arduino controlling the electronic resistor I might get much better results rather then clicking relay noises and stepped fan speeds.
 
What is the DC-DC controller that you are using at the moment? What voltage are you running it from?
 
Hi

The DC converter is one of these
The input is via a computer power supply.

So the DC DC converter powers the 3x 120mm blowers
 

Attachments

  • Screenshot_20200506-231356_eBay.jpg
    585.7 KB · Views: 99
  • ae_1567994482719.jpg
    848.3 KB · Views: 95
  • ae_1567994476628.jpg
    1.1 MB · Views: 94
Do you have the DC-DC converter with you?

The potentiometer on the converter will be just for control. In principle it would be quite easy to replace the potentiometer with a signal from the D2A converter but a lot more would be need to be known about the circuit.

There is probably a control IC in the regulator somewhere. It would be useful to know the part number of that IC.
 
Sure I will take photos and see if I can provide more details on the circuits.
It's late now. Will be tomorrow.

Cheers
 
With PWM all you need a a transistor switch to the Fan. A logic gate N-channel mosfet will work here. You switch the fan to ground.. The other terminal to power to the fan (e.g. +12V) The gate needs a current limiting reisistor in series, 100 ohms or so and a gate resistor to ground 100K or so. The switching frequency needs to out of hearing range, say >20 kHz. The processor changes the ON time from 0 to 100%,

The 100 ohms isolates capacitance and the 100K is a place for the leakage current to go, otherwise it turns on with on open gate.

Because the motor sees full voltage, it's a constant torque application.

You can use a fan with a pulse generator to profide fan speed and/or fan failure information.

A logic level MOSFET has a very low Vgs voltage. You need to look at the graphs of Ids and Vgs to make sure the FET is fully on.
 
Below is the LTspice simulation of a simple way to control the output voltage of a switching regulator by the variable voltage from a DAC (which could be from the Arduino) with no pot needed.
That particular converter has an internal reference voltage of 2.2V (the voltage at the FB pin), and the resistor values are selected for that, with a DAC voltage of 4.4V to 0V giving a 0V to 20V output range.
Note that the output voltage increases as the DAC control voltage decreases.

An interesting feature of this circuit is that it allows adjustment of the output voltage down to 0V.
With a pot, the minimum output voltage is normally limited to the internal reference voltage (in this case 2.2V).

An easy way to calculate the resistor values is to start at the half voltage point, where the DAC voltage equals the FB voltage of 2.2V.
Since, at the point there's no current going through R6, you can remove it from the circuit, and calculate the values of R1 and R5 to give the desired 1/2 full-scale output voltage (in this case 10V).
Then you set the DAC voltage to 0V which effectively puts R6 in parallel with R5, and calculate the value of R6 to give the desired full-scale output voltage (here 20V).

 
Last edited:
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…