Electronics notes/Changing voltage

From Helpful
(Redirected from Level shifting)
Jump to: navigation, search
This is for beginners and very much by a beginner.

It's intended to get an intuitive overview for hobbyist needs. It may get you started, but to be able to do anything remotely clever, follow a proper course or read a good book.


Some basics and reference: Volts, amps, energy, power · Ground · batteries · resistors · changing voltage · transistors · fuses · diodes · varistors · capacitors · inductors · transformers · baluns · amplifier notes · frequency generation · skin effect


And some more applied stuff:

IO: Input and output pins · wired local IO · wired local-ish IO · · · · Shorter-range wireless (IR, ISM RF) · RFID and NFC · bluetooth · 802.15 (including zigbee) · 802.11 (WiFi) · cell phone

Sensors: General sensor notes, voltage and current sensing · Knobs and dials · Pressure sensing · Temperature sensing · humidity sensing · Light sensing · Movement sensing · Capacitive sensing · Touch screen notes

Actuators: General actuator notes, circuit protection · Motors and servos · Solenoids

Some stuff I've messed with: Avrusb500v2 · GPS · Hilo GPRS · JY-MCU · DMX · Thermal printer ·


Noise stuff: Stray signals and noise · sound-related noise names · electronic non-coupled noise names · electronic coupled noise · ground loop · strategies to avoid coupled noise · Sampling, reproduction, and transmission distortions


Audio notes: See avnotes

Microcontroller and computer platforms Arduino and AVR notes · ESP series notes · STM32 series notes · · · ·


Less sorted: device voltage and impedance, audio and otherwise · electricity and humans · power supply considerations · Common terms, useful basics, soldering · PLL · pulse modulation · signal reflection · resource metering · SDR · Project boxes · Unsorted stuff

See also Category:Electronics.


When you talk about trying to get an particular voltage level, 'voltage regulator' and 'voltage converter' are near-synonymous terms, and 'voltage stabilizer' is also related.


Some terms and properties

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)
  • Step-down: output voltage is lower than the input voltage
  • Step-up: output voltage is higher than the input voltage
  • Inverting - Creates a voltage of opposite polarity
(Not to be confused with 'inverter' , which refers to DC-to-AC conversion, such as those use in cars, and solar panels that provide AC power)


  • Charge pumps - designs that use capacitors for temporary storage, switching it one of a few ways to exchange voltage for current (fractionally divide/multiply one for the other)
Charge pumps are somewhat cheaper and simpler than inductor-based circuits.
Depending on design and use, they can be ~80-95% efficient, usually a bit less.


  • low-dropout, often referring to voltage regulation step of something larger:
A low-dropout variant requires less input-output voltage difference than is typical.
e.g. where linear regulators often need 2 to 2.5V higher input, LDO regulators may need only 1.5V.
note that they are often also pickier about what range they comfortably accept
Can matter for small drops, for efficiency, for battery-powered situations


Continuous/Discontinuous mode:

  • Discontinuous designs either simply discharge to zero, or rely on a short-term buffer to sustain current (e.g. capacitors)
Discontinuous designs are often simpler and smaller.
  • Continuous mode never discharge too significantly during operation (which particularly for DC-DC converters depends on load), meaning you'll always get current.
Performance is usually better in continuous mode.



Further notes:

  • In any designs that are based on feedback, stability and adaptation speed are conflicting interests.
  • One distinction is whether you use a switching design (stepdown can e.g. be primarily resistive instead)

LED drivers

LED drivers are often CC (Constant Current) or CV (Constant Voltage) - see also Electronics_notes/Diodes#LED_drivers

DC level shifting

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)

Level shifting usually refers not to power conversion, but to making voltage signals like logic and communication work between devices that naturally run at different voltages.


The thing that makes this simpler than much of the DC-to-DC section below is that you are dealing with negligible current - just enough to move the level (with the capacitance involved, which is typically tiny).


DIYers will regularly run into

  • 3.3V output to 5V input
3.3V logic to 5V TTL: high starts above 2V so a 3.3V high is high enough and will work as-is.
3.3V logic to 5V CMOS, is high above ~3.5V (70% * 5V) so 3.3V won't work.
The recommended approach is probably a diode logic level step-up (see below). There are others.
  • 5V output to 3.3V input
If the 3.3V device, or some pins on it, are 5V tolerant, that roughly means its pins have protection diodes that can sink the difference without shortening lifespan(verify)
This varies between devices, so unless the datasheet says it's okay, don't do a direct connection.
The recommended approach is probably a voltage divider. There are others.


More generally:

optocouple

components: optocouple and (current limiting) resistor
should work fine below <1MHz (order of magnitude, check datasheet)
not the smallest, or least components, but easy
can give isolation to boot (e.g. isolating ground between devices, which is one reason it was a nice choice in serial MIDI).

Note that most optocouples can't sink much on the output - usually a few dozen mA for most (check datasheet). For IO that's plenty, for anything else you may want to add a transistor.

voltage divider (lower voltage only)

components: 2 resistors
simple for a singe line, sort of annoying for more than a few


diode logic level step-up (higher voltage)

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)
components; 2 diodes, 1 resistor
upsides:
simple and cheap
downsides
additional footnotes about the two rails communicating
resistor choice is a careful balance between four different things
wastes a little power, so not ideal for battery


some footnotes about impedance (and note the low level is raised)
e.g.
see e.g. its mention in 3V tips 'n tricks

IO controlling a BJT/FET

components: transistor + resistor
inverts the logic. If you can tweak the code, this saves a component over the diode solution (but for hardware protocols this may be impossible)
in general you should tweak the resistor values to lower current use
for faster cases, FETs aren't always easier. that is, specific FETs may have distinct parasitic properties to mitigate

Bidirectinal FET level shifter

  • components:
see e.g. [1] [2]

IC level shifters

  • IC solutions can be nice when you have a handful or more lines
e.g. the (74hc)4050 is six non-inverting high-to-low shifters
will output what it gets on its Vcc
has over-voltage tolerant inputs (up to ~15V)
or TTL logic gates (e.g. 74HCT) in general


Other level shifting notes

See also:

DC-to-DC

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)

Shunt regulator

A shunt regulator is based on a (zener) diode used as a shunt. [3]. Upside: very simple Downside: low current capacity, and requires a fixed design, zener burning out puts full voltage on output


Transistor series regulator

A transistor series regulator is basically a shunt regulator fed into a transistor as a voltage follower[4].

Upside:

  • Better regulation than shunt (transistor's base is a light load)
  • handles more current

Downsides:

  • still sensitive to load variation, sensitive to supply variation.
  • Linear regulator is often better for similar price.

Linear regulator

So the more typical resistive design is the linear regulator,

  • basically operates as a variable resistor, intentionally wastes the voltage difference (times the current actually drawn) as heat
  • named for being a device (BJT, FET, tube) operating in its linear region - or passive device like a zener diode operating in its breakdown region.
...and contrasted to e.g. switching regulators
  • Simple, cheap
  • lower noise than switching (still has thermal noise) particularly for lower frequencies


Fixed versus variable linear regulators:

  • you can change a fixed, but variable ones are more precise (and efficient) to tweak


Low-dropout regulator (LDO)

  • a (typically linear) regulator which can work with a lower-than-typical voltage difference
  • More power-efficient (than basic linear) for larger currents
  • sometimes a practical necessity (over linear) when supply voltage is not far away (consider e.g. batteries)



Around the regulator:

  • you'll want a capacitor on the input side, particularly if it's a bit away from the power supply
bypassing moderate current draws, so order of ≥0.1 μF or more on the input side (verify)
but too large will make it less stable (verify)
on all regulators, really (but it's not known as a rule, in part because the once-uniquitous 78xx series was more stable than most)
  • a capacitor on the output side can help stability and transient response
could be on the order of ≥1 μF (verify)


See also:

Capacitors around regulators

See also:

Switching designs

Switching designs refer broadly to any design that uses fast switching to change how storage elements (inductors and/or capacitors) are connected, and can be step-up, step-down, and inverting constructions..

Since they work with a charge-discharge cycle they will have voltage ripple in their output.

Efficiency (often something between 70% and 90%) varies with current drawn, so are typically more efficient than linear regulators (except in some low-difference situations, where LDOs may actually be more efficient).

See also:


Designs of switch-mode regulators include:

Step-down

Buck converter

a switch-mode step-down design, based on a single inductor



http://en.wikipedia.org/wiki/Buck_converter

Step-up

Boost converter

a switch-mode, step-up design, based on a single inductor

Basically charges a capacitor, and connects it so that it regularly doubles the input voltage

http://en.wikipedia.org/wiki/Boost_converter

Step-up or step-down

Buck-boost converter

(Note: distinct from the buck / boost transformer)


based on a single inductor

(inverting)

mostly used for stabilisation

http://en.wikipedia.org/wiki/Buck-Boost

flyback converter

basically buck-boost, but with the inductor split into a transformer

giving isolation, and allowing voltage multiplication via the transformer

can also do AC-to-DC

Push-Pull converter

(similar to the flyback converter)

http://en.wikipedia.org/wiki/Push–pull_converter

Forward converter

http://en.wikipedia.org/wiki/Forward_converter

Split-Pi

topology of inductors and capacitors

similar to buck-boost

http://en.wikipedia.org/wiki/Split-pi

Ćuk

inductors and capacitors(verify)

http://en.wikipedia.org/wiki/%C4%86uk_converter

SEPIC

Single-ended primary-inductor converter

inductors and capacitors(verify)

https://en.wikipedia.org/wiki/Single-ended_primary-inductor_converter

AC-to-DC

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)


Half-Bridge rectifier

https://en.wikipedia.org/wiki/Rectifier#Half-wave_rectification

Full-Bridge rectifier

https://en.wikipedia.org/wiki/Rectifier#Full-wave_rectification



AC-to-AC

transformer

The basic transformer can be seen as a specific exchange between voltage and current.

Flyback transformer

Zeta converter

buck / boost transformer

(note: distinct from the Buck-boost converter)


capacitive dropper

DC-to-AC

Inverter

Basically anything that generates a simple waveform, and allows load worth mentioning to be drawn from it.

http://en.wikipedia.org/wiki/Inverter_%28electrical%29

Other

See also

Comparison notes

Transformer notes

Named purposes / designs

This article/section is a stub — probably a pile of half-sorted notes, is not well-checked so may have incorrect bits. (Feel free to ignore, fix, or tell me)

Audio transformers

On cores, on windings, on taps

Going from transformer to DC, design considerations

Rectifying AC

Could I reverse primary and secondary?

Can I series-connect for higher voltages?

Can I add more transformers in parallel later for more current?

Unsorted