4
\$\begingroup\$

Short version:

I am looking for a high side switch (20mA, 400V) circuit for half wave rectified mains, which I would be able to control with 5V GPUO.

Long version:

I am building a Nixie clock with 74141 drivers and a microcontroller. The Nixie tubes are powered from half wave rectified 230V 50Hz mains. I would like to turn off the Nixie tubes completely for 400ms (i. e. blink them.) It seems to me that 74141 drivers don't offer any way to turn off Nixies completely (all digits at once,) so I thought about adding a high side transistor switch, controlled by 5V GPIO.

What's the best switch for this application? PNP or PMOS or maybe something different? Thyristor? (Requirements are: 20mA max, 400V.)

I can think of two solutions. I think with PMOS there is a problem with keeping Vgs within limits all the way through half of sinewave, because of voltage variation.

Application circuit:

PNP:

pnp

PMOS:

pmos

\$\endgroup\$
13
  • 1
    \$\begingroup\$ Precisely what do you mean by PNP seems to accept more variation of base current, staying in saturation? \$\endgroup\$
    – Andy aka
    Aug 30, 2021 at 10:27
  • 1
    \$\begingroup\$ Ok, I've edited question. In general I'm confused, because I can't calculate base current / gate voltage setting resistors, since the supply varies from 0 to 325V peak. I meant pnp has some play in base current since it could be driven to hard saturation, when the voltage peaks. \$\endgroup\$
    – Michal
    Aug 30, 2021 at 10:41
  • 1
    \$\begingroup\$ Why not add a DC hold-up capacitor (aka a smoothing capacitor) on the cathode of D1 to GND? \$\endgroup\$
    – Andy aka
    Aug 30, 2021 at 10:44
  • 2
    \$\begingroup\$ Is it really a good idea to power your circuit off the mains? How can you safely debug it let alone operate it? \$\endgroup\$
    – Kartman
    Aug 30, 2021 at 12:02
  • 1
    \$\begingroup\$ @Michal. As long as you’re aware of the potential dangers. Personally I’d use a little flyback converter. Easy enough to modulate at mains freq or just do it in your multiplexing code. \$\endgroup\$
    – Kartman
    Aug 31, 2021 at 21:56

5 Answers 5

5
\$\begingroup\$

You could increase the wattage on the 47K resistor to 1W and just shunt the tube to ground with an NPN BJT (eg. 500V PMBTA45) or an N-channel MOSFET.

Actual resistor dissipation with the tube shunted would be 0.56W.

1mA of base drive would be plenty.

\$\endgroup\$
2
  • 1
    \$\begingroup\$ Thank You! Simplest solution. I think there is even some room to lower power dissipation. Since nixies turn off at 110V ( youtu.be/ggVu_U-CsAk?t=467 ), I am going to try shunting the tube with 13k and NPN BJT. I am changing 47k anode resistor to 33k, 13k parallel with tube should give <100V. \$\endgroup\$
    – Michal
    Aug 30, 2021 at 20:36
  • \$\begingroup\$ That may work, though it may take until the next blank half-cycle to turn off once it's been ionized. \$\endgroup\$ Aug 30, 2021 at 20:37
4
\$\begingroup\$

This is one of those situations where a current-source driver makes way more sense than a voltage divider. This way, all of the voltage level shifting occurs across the driver transistor, and the second transistor gets consistent drive across a wide range of supply voltages.

schematic

simulate this circuit – Schematic created using CircuitLab

Q1 becomes a switchable current source, where the collector current is determined by the base voltage and R1.

For the BJT case, this becomes the base current of Q2, and R2 serves to reduce the effects of leakage current through Q1, keeping Vbe for Q2 less than 0.65 V.

For the MOSFET case, the switchable current develops a voltage across R3 to drive M1 with either less than 0.1V (which is assumed to be well under its threshold voltage) or 10 V, which should be well above.

In either case, Q2 or M1 get the same amount of "drive" regardless of the value of the rectified AC bus, at least until it drops so low that Q1 saturates. But if it's that low, the Nixie tubes aren't conducting anyway.

Note that on half-wave 400V power, Q1 will dissipating about 400 mW peak and 125 mW average.

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

I think your best and quickest solution is to simulate a solution such as this one: -

enter image description here

I've got source V2 (on node V4) turning on and off a BJT at 40 ms intervals. The input (blue on V1) and output (red on V2) look like this: -

enter image description here

I don't see any issues at all. If you wanted to keep the MOSFET on even when the input supply waveform fell to close to 0 volts you could put a 330 nF capacitor across R1: -

enter image description here

\$\endgroup\$
2
  • \$\begingroup\$ Thank You for your effort @Andyaka! Which simulator are You using? To help me understand better: Is R1 there to charge gate before zener starts conducting? Is ratio R1 and R2 somehow determined? \$\endgroup\$
    – Michal
    Aug 30, 2021 at 19:45
  • 1
    \$\begingroup\$ I’m using micro cap (free). R1 discharges the mosfet gate when the BJT is turned off. R2 limits the current into the zener. The zener protects the mosfet. \$\endgroup\$
    – Andy aka
    Aug 30, 2021 at 19:48
2
\$\begingroup\$

The 74141 datasheets I found state that input values 0xA to 0xF turn off all outputs, which should be sufficient for flashing. If you drive the 74141 from a microcontroller that should be easy to achieve.

I know this isn't an electrical engineering solution, just a small programming task :-)

\$\endgroup\$
2
  • \$\begingroup\$ Actually, I've tried this solution already. I tested it with SN74141 and KD155D1 drivers. When driven to illegal state (0xF), their zener protection kicks in and multiple digits glow at once (even permanently, so ic becomes useless). Tesla MH74141 on the other hand displays "8", when overrange. Check this thread: electronics.stackexchange.com/questions/469483/… I wish it was told clearly in datasheet... Many drivers could be saved. :-) \$\endgroup\$
    – Michal
    Aug 31, 2021 at 18:07
  • \$\begingroup\$ Oh, that teaches me to trust data sheets :-( \$\endgroup\$ Aug 31, 2021 at 18:46
0
\$\begingroup\$

How about using an optocoupler as a high side switch?

50mA sounds reasonable for an opto, and driving it from a 5v GPIO is trivial.

\$\endgroup\$

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.