2
\$\begingroup\$

I have an ATTiny85 that switches 4 loads based on data from a (Software) Serial connection. I need to switch a fifth load on when any of the other four loads are switched on. I have no more IO pins available to me and I don't want to change my microcontroller, so ideally I need a way of switching the fifth MOSFET with the other pins.

How can I switch this fifth load?

Schematic (ATTiny omitted and loads replaced with resistors for simplicity): Schematic
Mosfet QC and load RC are my common circuit, and the numbered ones correspond to their individual circuits.

\$\endgroup\$
2
  • \$\begingroup\$ Hmm, perhaps a CD4078B could be used. OR is K output, NOR is J. Note that operation at 3.3V is not defined in the datasheet - if it did work at that voltage, expect it to be significantly slower than 5V operation. \$\endgroup\$
    – rdtsc
    Commented Feb 9, 2022 at 16:20
  • 1
    \$\begingroup\$ Can you potentially use the ~RESET pin? On this chip it can be disabled and then used as IO pin PB5. \$\endgroup\$
    – bigjosh
    Commented Feb 9, 2022 at 21:12

2 Answers 2

2
\$\begingroup\$

Use diodes to form a wired OR circuit for the fifth load. Follow this tutorial for the circuit.

enter image description here

\$\endgroup\$
2
  • 1
    \$\begingroup\$ Will the reduced voltage drive at Vout be sufficient for the MOSFETs being used by the OP? \$\endgroup\$
    – Andy aka
    Commented Feb 9, 2022 at 16:51
  • \$\begingroup\$ @Andyaka, that could be a concern if poorly choosing a MOSFET with low Vgs turn-on threshold. It can be offset some by using Schottky diodes that have low forward voltage. \$\endgroup\$ Commented Feb 23, 2022 at 4:20
0
\$\begingroup\$

How about something like...

enter image description here

...with the new resistor being sized based on voltages and currents involved. (Potentially might also want another resistor at the base of the new BJT again depending on voltages and currents needed).

You could also add an op-amp or comparator or opto-isolator if the voltage/current at the base of the BJT would be too low or you need the common load to be switched with a MOSFET rather than BJT.

\$\endgroup\$
1
  • \$\begingroup\$ You're proposing operating Q1/Q2/Q3/Q4 as common-drain buffers; can you assure that there's sufficient headroom with the necessary Vgs? \$\endgroup\$
    – nanofarad
    Commented Feb 9, 2022 at 22:02

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.