I've been tasked with designing a single PCB that will (amongst other) provide soft-power off feature to two different products with different hardware architectures.

The notable differences between the two products in this case is that product #1 currently has a 12V PSU that is constantly on, feeds 12V to a relay and a latching 12V push button. The product is currently designed so that the latching push button feeds its output to the control tab of the relay, which then powers the relay and feeds 12V to the entire product when the latching push button is pushed.

Product #2 instead has a 5V & 24V PSU that is not constantly on, but instead has an auxiliary connector on the PSU backside with a global inhibit signal. When the global inhibit signal is shorted to GND in the same auxiliary connector, the 5V & 24V output turns on. The product then simply has a latching push button that is connected straight to the PSU auxiliary connector.

Here's an illustration of the architecture of the two different products. enter image description here

This design change from hard power off to soft-power off also has to be done with minimal changes to the rest of the product architecture of course. The solution I've come up with is to change the switches from latching to momentary switches, and then some minor changes to cabling to connect the switches to a PCB instead of to the relay or PSU. The PCB will then provide the soft-power off feature. The tricky part for me is to design a single PCB that is compatible with both of these products with minimal amount of connectors & circuitry. The circuit I've come up with is included below.

Circuit in product #1

enter image description here

When the push button isn't pressed, nothing happens in the circuit, and there are no voltages present in the circuit. When the push button is pressed, NET1 is powered to 12V, and pulls the gate of the Q2 PNP MOSFET high through the R2 resistor. Both Gate & Source of Q2 has the same potential, so Q2 does not conduct. However, at the same time the Relay is powered through the Relay/PSU connector, which turns on the relay and feeds 12V from the PSU into the entire product. The MCU on the PCBA will then turn on and immediately pull the Gate of Q2 low through the signal MCU_ENABLE2 low, which will turn on the Q2 MOSFET and the 12V rail of the PCB is now connected to NET1. When the push button is released, the Q2 MOSFET will be kept conducting as long as MCU_ENABLE2 is kept low. The Q1 MOSFET does nothing in this case.

Circuit in product #2

enter image description here

When the push button isn't pressed, the circuit does nothing and there are no voltages present in the circuit. The Gate of Q3 is tied to AUX_GND through the 1M ohm R3 resistor. When the push button is pressed, NET1 & AUX_GND are short-circuited, which short-circuits AUX_GND and the INHIBIT signal through the Relay/PSU Connector, which turns the 5V & 24V rails ON on the PSU. The MCU on the PCB then wakes up and immediately pulls the Gate of Q3 high through the MCU_ENABLE1 signal, which short-circuits NET1 to AUX_GND through the Q3 MOSFET. When the push button is released, the short-circuit between the INHIBIT & AUX_GND signals are kept as long as MCU_ENABLE1 is kept high.

Architecture modifications:

enter image description here

So with this PCB design I only need to change the push button from latching to momentary switches (which is a very minor change and can be done without changing push button model), and do some minor changes to the cabling. My questions are:

  1. Would the circuits I've come up with work? Would I need any protection for the GPIO pins on the MCU? Is there anything else I haven't thought of?
  2. Would it be a good idea to add some form of flyback diode to handle when the 12V relay switches off?
  3. Is there an easier way of accomplishing what I'm trying to do?
  • \$\begingroup\$ Is AUX_GND connected to the GND for the rest of the circuit? It's hard to tell if this would work without seeing all the connections, including the rest of the relay connections in #1. \$\endgroup\$
    – Finbarr
    Jan 4 at 15:59
  • \$\begingroup\$ Yes, AUX_GND is connected internally in the PSU to the regular GND net of the PSU. Just namned it like that since it comes off the a small auxiliary connector, thinking that it would make it clearer as to how thing would be connected in the architecture, but maybe it confused more than it clarified. \$\endgroup\$ Jan 4 at 16:08
  • \$\begingroup\$ If it helps to see how it's supposed to work, the PSU with the global inhibit signal is the Meanwell NMP1K2 (datasheet here: meanwell.com/productPdf.aspx?i=840), and the 12V relay used is the PC792A from Picker Components (datasheet here: pickercomponents.com/pdf/Relays/PC792A.pdf) \$\endgroup\$ Jan 4 at 16:16
  • 2
    \$\begingroup\$ You really need to know what voltage is on the RC pin when it's not connected to ground. It will probably have some sort of resistive pullup to a positive level, and that may be enough to turn Q4 on and pull it low enough to turn on the PSU. \$\endgroup\$
    – Finbarr
    Jan 4 at 16:46
  • \$\begingroup\$ That's a really good point, thank you! I thought a bit about that there would quite a few signals left floating in this circuit, and I figured that it would be somewhat "OK" to have it that way, but yeah that one if left floating might cause issues. \$\endgroup\$ Jan 4 at 16:47


Your Answer

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