Mr.Dee67
Published © MIT

1-Dollar Opto-Coupled Logic Level-Shifter

A 1-Dollar Non-Inverting Logic-Level-Shifting Heavy Load Control Unit. 3.3V Signal to 12V Load, using 2 LEDs for Opto-coupling.

BeginnerFull instructions provided1 hour63
1-Dollar Opto-Coupled Logic Level-Shifter

Things used in this project

Hardware components

MCU with 3.3V GPIO
×1
BUZ 71A N-Channel MOSFET
×1
Resistor 100 ohm
Resistor 100 ohm
×1
Resistor 10M
×1
LED red, clear dome (30deg spotlight), superbright, s 20mA
Clear Dome lens type that causes narrow spotlight, super-bright, 20 mA. Must be red light, other colors work less reliably, or not at all.
×2
Power supply 12 v and 3.3 V
×1
12 Volt test load like a 12 V DC Motor
×1
Wires, Tin and Soldering Iron
×1

Software apps and online services

Arduino IDE
Arduino IDE

Hand tools and fabrication machines

Soldering iron (generic)
Soldering iron (generic)
Multimeter any

Story

Read more

Schematics

Non-inverting opto-coupled Level-Shifter and Load Driver

3.3V Signal to 12V Load. Using 2 LEDs for opto-coupling.

Code

Some external LED Blink Code

C/C++
(In Arduino IDE)
// I am hesitating to provide code here, as it is essentially just an external
// LED blinking.
// However, as a general rule you may follow this procedure:

// To set the pin high, the emitter LED off and the motor on, do this:
  pinMode(myGPIO, OUTPUT);
  digitalWrite(myGPIO,1);

// to turn it off, do this
  pinMode(myGPIO, INPUT_PULLDOWN);

Credits

Mr.Dee67
2 projects • 1 follower

Comments