28
\$\begingroup\$

I am interfacing to an EEPROM that works via SPI at 1.8V; unfortunately I do not have a 1.8V power source around and being this a weekend project, I wanted to complete it without going to the shop.

I asked a skilled friend an advice and he suggested I could put a 1.5V AA battery in the circuit to get 1.8V.

Is this a sound configuration? I am a newbie but by gut feelings I feel there is something wrong, in particular regarding current intensity.

suggested example

Edit 1: I know this is a bad idea, but I am asking here to know why. I could not find a similar question so I believe it will be useful to have here as a reminder of why not to pursue bad ideas like these. I will accept the answer with the explanation of why not to do this. I know it should be done with a voltage regulator, I am asking if it is possible without it, so answer can be yes/no with an explanation. I am also curious to read about anybody that thinks it is possible.

Edit 2: for those interested in the power draw, the EEPROM is a Winbond W25Q64FW and I will use it through a TXB0108 level shifter (side B). For the records, I did not ever try this circuit (in particular after the answers/comments I received) but I am nonetheless very interested in reading what is possible or not.

\$\endgroup\$
  • 11
    \$\begingroup\$ You could, but the battery is liable to explode as you'd be driving a charging current into it. \$\endgroup\$ – Tom Carpenter Apr 8 '18 at 10:13
  • 15
    \$\begingroup\$ @Bimpelrekkie if you read carefully, you will notice that I am asking to validate somebody else's idea, that I have concerns about. This is not even my own solution...I am asking here if this solution is valid, please let's stay on topic. \$\endgroup\$ – gdm85 Apr 8 '18 at 10:21
  • 23
    \$\begingroup\$ @Bimpelrekkie why are you attacking him? He asked a skilled friend, he asks here - that is exactly learning from others not coming up with own solutions. After all, this solution is not even his own. \$\endgroup\$ – Džuris Apr 8 '18 at 13:25
  • 15
    \$\begingroup\$ @JamieHanrahan according to description he appeared to be more experienced and more skilled than OP. As the offered solution seemed dubious, he re-asked here. OP has behaved exactly like one should do, I don't think he deserved that scolding for "not learning from others" and coming up with "own solutions" as that is the opposite of what the OP does. \$\endgroup\$ – Džuris Apr 8 '18 at 19:07
  • 7
    \$\begingroup\$ I offer a bounty of EUR10 for the first person that can get a consumer AA alkaline cell to explode inside of a month when loaded as first described with the estimated static current draw of the two mentioned ICs. \$\endgroup\$ – KalleMP Apr 9 '18 at 14:41
49
\$\begingroup\$

TL;DR; Your friend is telling you how to destroy a battery, potentially violently. Use a proper voltage regulator circuit instead.


Batteries are not designed to be used a voltage regulators. While it is true that in an ideal world your proposed circuit would work (after all, an ideal battery drops its rated voltage at any current), in practice things are a little different.

All the current drawn from the 1.8V supply will have to flow from the 3.3V supply, into the battery + terminal, then out of the battery - terminal. This is in effect driving a charging current into the battery. The battery is acting as a load.

There is a reason that the batteries have a warning "Do No Recharge" printed on them, charging them can cause venting, in a potentially violent manner. Certainly a messy one.


Now you will be wondering, but what if I were to use a rechargeable battery. Initially, it would probably work ok. However the output voltage will drop as the battery charges up.

The voltage across the battery will keep increasing until either the full 3.3V is dropped across it, or the battery is damaged by over-voltage charging.

In any case this will not give you a stable output voltage, as the cell voltage will vary with the current drawn by the load. It is really little different to using a resistor as a regulator, which doesn't work well.


The proper solution is to use a voltage regulator circuit. There are many designs. Shunt regulators using Zener diodes, Linear Regulator ICs (e.g. LM317), Transistor series voltage regulators.

\$\endgroup\$
  • 1
    \$\begingroup\$ I have to write to this EEPROM a few times, so total active time would be minutes when I am finished with this circuit. But regardless, I understand your explanation applies as well. I am going to pick this answer if nothing better is posted. Thanks for the detailed explanation. \$\endgroup\$ – gdm85 Apr 8 '18 at 10:53
  • 3
    \$\begingroup\$ Many varieties of rechargable batteries will also fail violently and messily when overcharged. \$\endgroup\$ – zwol Apr 8 '18 at 16:57
  • 4
    \$\begingroup\$ @zwol Some (NiMH) batteries may be charged indefinitely(TM) at 1/10C or less (trickle charge). \$\endgroup\$ – JimmyB Apr 9 '18 at 14:34
  • 3
    \$\begingroup\$ The AA cell would likely last a week of driving a small circuit in forward of reverse mode (see fix in other answer) and consumer alkaline batteries are also rechargeable "within limits" and this would likely be no more than a trickle charge in any event that would keep the battery full until no longer needed in this project. Do not leave connected unattended and you will be fine. \$\endgroup\$ – KalleMP Apr 9 '18 at 14:36
  • 1
    \$\begingroup\$ @Molot - or $0.02 - the cost of a pair of 1N4001s (assuming 2.1v is within the max voltage range for the EEPROM). \$\endgroup\$ – Jules Apr 9 '18 at 18:30
34
\$\begingroup\$

Let me show you exactly why this is a bad idea to use a battery in this manner. The following simulation shows an example with a 100mA load. As you can see this forces 100mA of current to flow in the battery as well.

enter image description here

If you use an alkaline battery this will be causing a charging action which cause an eventual heating of the battery and it may explode or at a minimum burst a seal and leak.

If you tried a rechargeable battery technology such as a lithium type it will soon become over charged and these are likely to even catch fire when over charged too much.

There is a safe way to use a battery to regulate the output voltage in a circuit like this. If you can evaluate your load current requirements carefully then you can place a ballast resistor across the battery as shown below. You must size the ballast resistor so that the battery current is always discharging the battery when the load current goes from zero to whatever maximum current that your load requires. I have shown values suitable for loads up to 50mA.

enter image description here

In this way the battery operates as a shunt regulator. The ballast resistor is wasteful of the battery energy but it does achieve the OP's goal of how to get 1.8V for a quick one time application.

\$\endgroup\$
  • 3
    \$\begingroup\$ Use of a rechargeable battery, and including some series diodes in the shunt path, will make the shunt responsive to the state-of-charge of the battery, avoiding overdischarge by letting it charge when low, and avoiding overcharge by shunting more when full. The voltage will still vary somewhat, but less. \$\endgroup\$ – Ben Voigt Apr 8 '18 at 20:15
  • \$\begingroup\$ thanks for your detailed answer, and the effort you put into visualizations. I can only pick one answer unfortunately..but I think this is equally good and completes the one I chose \$\endgroup\$ – gdm85 Apr 9 '18 at 7:23
  • \$\begingroup\$ +1 for the shunt resistor that makes it perfectly useable. Problem still remains when 3V3 supply is at 0V and the rail goes negative if not disconnected with a real switch. \$\endgroup\$ – KalleMP Apr 9 '18 at 14:32
  • \$\begingroup\$ If you're going to add the shunt resistor, you might as well go the next step and remove the battery to leave a voltage divider... \$\endgroup\$ – TripeHound Apr 9 '18 at 15:36
  • 4
    \$\begingroup\$ @TripeHound: A battery serves to stabilize the voltage in the divider. It won't be perfectly constant, but it will be much more consistent. \$\endgroup\$ – Ben Voigt Apr 9 '18 at 16:36
4
\$\begingroup\$

It looks, on paper, like it would would, but...

The output voltage of this arrangement may be a bit less than you might expect. The battery may output 1.5V under a nominal load, but to drive a current back into it may require a small additional potential, which in your circuit, would come at the expense of output voltage.

Regardless, what makes this a bad (potentially dangerous) idea is that when you run a charging current into a single use battery, you force chemical reactions to occur inside the battery for which it was never designed. A likely reaction will be the formation of heat and explosive gases which the cell cannot dispose of. This can lead to a build-up of pressure until the cell ruptures (explodes), releasing potentially harmful, corrosive, and/or flammable chemicals.

Even using a rechargeable battery in this way is a bad idea, because the voltage across its terminals will vary according to its charge state, giving you a not-very-predictable output voltage, and again, you risk overcharging it with the potential of similar consequences; overcharging typically causes (again) chemical reactions to occur for which the battery was not designed. Rechargeables only charge safely in a circuit designed with that purpose in mind.

\$\endgroup\$
3
\$\begingroup\$

Are you sure your friend was not suggesting this?

schematic

simulate this circuit – Schematic created using CircuitLab

A 1.5V alkaline battery is closer to 1.65 when fully charged and not under a high load. And that may be close enough to 1.8V to work for your needs. Consult the spec sheet. Or if this is an inconsequential hobby project, maybe you just build it and see if it works.

Or perhaps the suggestion was:

schematic

simulate this circuit

Either of these approaches will work. Unlike the arrangement you have drawn, they do not rely on running the battery "backwards" to charge it.

\$\endgroup\$
  • \$\begingroup\$ I'm a total electronics noob so I'm probably missing the point but... You seem to be saying that (under certain circumstances) a 1.5V battery is really 1.65V, which is close enough to 1.8V that it'll probably work. Given that the goal is to jury-rig a 1.8V supply, what are the 3.3V sections of your circuits for? Why not just use the battery on its own? \$\endgroup\$ – David Richerby Apr 9 '18 at 21:43
  • \$\begingroup\$ @DavidRicherby I'm assuming whatever is interfacing to this EEPROM, whatever has been built so far, still needs a 3.3V supply. \$\endgroup\$ – Phil Frost Apr 9 '18 at 23:05
  • \$\begingroup\$ I reported his drawing 1:1; but thanks for these circuits, I find them interesting. The EEPROM is a Winbond W25Q64FW on a TXB0108 shifter side B, so yeah, really low power draw. \$\endgroup\$ – gdm85 Apr 10 '18 at 8:53
2
\$\begingroup\$

if it's low current, and your 3v3 has sufficient drive, just use a resistive divider- let's say 83r to + and 100r to gnd. The center point will give you 1v8. Yes, that will droop as you draw current and long term it's nasty. But it'll work for the few cycles you need. The reisitor values could be scaled to match what you have hanging around.

\$\endgroup\$
0
\$\begingroup\$

As described by other answers, the most important thing you have to understand is that you are unintentionally charging this battery. Assuming the battery is not designed to be charged, you are expecting some flames upon prolong usage.

Instead of this method, there are many methods that utilise "Voltage Regulators". Take a look at LM334 instead. With proper resistor biasing, you can get perfect 1.8V output.

Remember, EEPROMs might misbehave if the power source is not stable. You might be wreaking your head on things for your simple mistake of not choosing a proper power source.

\$\endgroup\$
0
\$\begingroup\$

Independent of the battery problem:

If you have a selection of silicon diodes and/or LEDs, these can be used to achieve the kind of voltage drop you need. You might want some resistor parallel to the IC to get the diode forward voltage into a stable section of the curve.

Mind that most ICs absolutely cannot stand being driven with input voltages that exceed their supply voltage.

\$\endgroup\$
0
\$\begingroup\$

If it's a weekend hacking project, I'd say the answer is a resounding YES YOU CAN, until you can get to the shops on Monday.

Although you'd be charging the battery at the same time, EEPROMS don't draw all that much current, so you'd be charging the battery at a low current. I've done it myself although not for EEPROMS. Otherwise, do you have a 1.5V zener diode lying around?

NB: Also, be sure to disconnect the 3.3V supply before switching it off, otherwise you may be supplying -1.5V to the EEPROM :)

\$\endgroup\$

protected by Community Apr 8 '18 at 17:39

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

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