I am currently working on an RF project and using a high power RF SPDT switch. The control voltages of this switch are between 0V/-40V. If the control voltage is 0V, then the corresponding path is ON and if it's -40V then the path is OFF.

I wish to control this switch using a microcontroller. I know I would need a driver between the microcontroller GPIO pin and the RF SPDT control pin. Assuming I have a -40V rail available in the system, how could one convert the microcontroller GPIO signal (for example, working between 0V to 3.3V) to those required by this switch?

One option that I imagined is to use a level shifter. However, level shifters working in these voltage ranges are not available off the shelf. So I thought of building one using high power MOSFETs. But this solution would need several MOSFETs, thereby costing some PCB area.

Are there any other smart solutions for this problem?


  • \$\begingroup\$ I would think an opto would be your best due to the -40V rail. \$\endgroup\$
    – DKNguyen
    Feb 18, 2019 at 21:22
  • \$\begingroup\$ The answers here could probably be adapted to solve your problem. \$\endgroup\$
    – The Photon
    Feb 18, 2019 at 21:33
  • \$\begingroup\$ For speed use common base PNP \$\endgroup\$ Feb 18, 2019 at 21:42
  • \$\begingroup\$ How much current does the switch need? You shouldn't need high power MOSFETs for a control signal. \$\endgroup\$
    – user253751
    Feb 19, 2019 at 4:32

1 Answer 1


consider this


simulate this circuit – Schematic created using CircuitLab

  • \$\begingroup\$ thanks for the schematic. When the Emitter of Q2 is lets say 1.8V, then we have around 2A of current through the diode path. I understand that you put the diodes to clamp the base to emitter voltage of Q1. But how do we prevent such high currents ? Or did I understand this wrong? \$\endgroup\$
    – Nik
    Feb 19, 2019 at 17:37
  • \$\begingroup\$ When left end of R1 is at 1.7v (maybe 10mA thru Q2), the emitter of Q2 will be about 0.7v and we'll see 1.0 volt across R1, thus the 10mA. That 10mA flows out the collector of Q2 (which needs to rated for 40Volts), and down to the top of R2. About 1.5mA flows thru R2, maybe 1mA thru D2 into the base, and the rest (7.5mA) thru D1 into the collector. The 2 diodes provide a Baker Clamp. Schotty diodes are best here. \$\endgroup\$ Feb 19, 2019 at 18:03
  • \$\begingroup\$ Perfect it works as expected. Thanks for the suggestion \$\endgroup\$
    – Nik
    Feb 21, 2019 at 16:09
  • \$\begingroup\$ Realize the output time constant with 100 pF load, and the 10Kohm pullup, will be 1 microsecond. Does your system tolerate that slow a control signal? \$\endgroup\$ Feb 24, 2019 at 10:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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