2
\$\begingroup\$

I've done quite a bit of searching online and can't find a solution to this (probably trivial!) problem:

I am looking to replace a resistive fuel level sensor in a car, with a solution which can be controlled digitally. A digital potentiometer is the obvious solution for this, however it doesn't appear that any exist which match the specifications:

Resistance range is 6-120 ohms. Current through the resistor during operation is up to 80mA.

The wiper resistance of most digital potentiometers is much higher than the 6 ohm minimum requirement. It seems that 80mA is also too much for most options. I have considered linking 4 or more digital potentiometers in parallel, but I'm sure there is a more elegant solution. I don't want to go down the "stepper motor and potentiometer" route unless I have to.

One thing I considered would be a resistor array, switched using transistors. These could be driven from a shift register, allowing suitable resolution without using too much IO on a microcontroller. After all, this is a fuel gauge, it only really needs 16 levels to be functional.

I imagine that having 7 transistors, each switching a resistor, with values of 1,2,4,8,16,32,64 ohms (or similar), it would be possible to create such a circuit. The issue is how these transistors will react when combinations of them are switched. I can't quite get my head around how to design such a circuit.

Does anyone here have experience with such a circuit? Is there a "cleaner" alternative?

Thanks for your time!

In the image below, L1 and L2 are the motor windings, R5 and R6 are fixed resistors, L7 is the potentiometer to replace.

Gauge schematic. R7 to reproduce

I guess I should add that this "digital resistor" is driving a fuel gauge directly. The gauge is a pair of motor windings, it appears that one receives a constant voltage, and the other is varied using the potentiometer as one side of a potential divider. These two coils each want to move the fuel needle in opposite directions, they seem to "fight" each other, and the whole affair ends up rotating to a position determined by the strength of the adjustable winding.

\$\endgroup\$
9
  • 3
    \$\begingroup\$ If you know whether the existing circuit that reads the resistive sensor is a constant voltage or constant current type, you could just make a current or voltage source. \$\endgroup\$
    – The Photon
    Sep 2 '19 at 16:00
  • \$\begingroup\$ 16 levels can be achieved with 4 transistors and scaled resistors. \$\endgroup\$ Sep 2 '19 at 16:04
  • \$\begingroup\$ Would a circuit such as this be functional? i.imgur.com/Ux0D9Zg.png \$\endgroup\$
    – xp677
    Sep 2 '19 at 16:15
  • \$\begingroup\$ How is the potentiometer (sensor) wired? Do you know what properties of the resulting signal the gauge is using? Is it for example voltage-based with the sensor working as a voltage divider? Or is it maybe current-based? I ask because it might be simpler to replicated the desired signal directly instead of trying to mimic one part of a voltage divider. I ask partly because of your numbers; 80mA at up to 120Ω is potentially up to 10W; I find it unlikely that much power is dissipated in your current fuel level sensor. \$\endgroup\$
    – marcelm
    Sep 2 '19 at 16:16
  • 1
    \$\begingroup\$ That should be explained in the question then. \$\endgroup\$
    – Transistor
    Sep 3 '19 at 6:20
1
\$\begingroup\$

It took a while to get over the confusion you caused calling a meter a motor.
With the type of meter you have (it's a differential current meter), the two coils are used to maintain accuracy when the supply voltage varies. In your vehicle the voltage may vary from 10V or less cranking through to above 14V when charging.

Note that your particular type of meter is NOT driven by a constant current, so any answer that pushed toward that as a solution is wrong. The current through your meter varies both with supply voltage AND the 'sender' resistance value.

Your idea of using multiple resistors to create a replacement for the 'sender' is not a bad one. However you will need more bits than you imagine.

I assume that instead of a resistive sender you are going to use an MCU with some appropriate sensor to measure the fuel level ….you just want to use this conventional style meter to display the results from your MCU.

You should use FETs to turn on the individual resistor values to get the appropriate resistance value you need.

A circuit such as this may suit your application:

schematic

simulate this circuit – Schematic created using CircuitLab

Note here that I show AO3400 FETs with very small RDS(on) even when driven by a 3.3V MCU.

Even with 8 bits from the MCU or S/R the resolution around 120 Ohms is only 3 bits, but it's very easy to implement.

\$\endgroup\$
5
  • \$\begingroup\$ The OP added information about the fuel gauge mechanism after I had written my first answer, but I have updated my answer to suggest how a constant resistance could be achieved rather than a constant current. \$\endgroup\$ Sep 3 '19 at 12:09
  • \$\begingroup\$ @ElliotAlderson Your suggested circuit is not going to provide a constant resistance, and even though the current ranges in the meter are going to be linear, it will be difficult to calibrate. \$\endgroup\$ Sep 3 '19 at 15:12
  • \$\begingroup\$ Fair enough. For the kind of meter the OP has you really need an adjustable resistance. \$\endgroup\$ Sep 3 '19 at 15:20
  • \$\begingroup\$ This is great, many thanks. Is it possible to turn on multiple FETs at once to create combinations of resistors, or would I require one FET for each desired gauge position? \$\endgroup\$
    – xp677
    Sep 6 '19 at 23:26
  • \$\begingroup\$ @xp677 Yes that's exactly how you'd operate it, turn on a combination of FETs to get the gauge reading your desire. \$\endgroup\$ Sep 7 '19 at 3:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.