0
\$\begingroup\$

Below image is the input voltage VDD to PIC16F18326. I am turning off (Switching off the mains supply) my circuit at point A (see image). Due to large capacitance at load, which is required in my circuit to reduce large current ripples, the VDD to microcontroller is OFF after 8Sec. But I want to turn off my microcontroller immediately (within 1 sec) after I turn off the mains.

I have tried to change the capacitance placed across the VDD. No big changes in the time taken to turn off.

The VDD is supplied and controlled by a LinkSwitch (LNK304) which is fed from the output. I tried to control the feedback FB of LNK304. But the large capacitors at the output has high influence on this as well.

Any simple idea, how to Pull Down this VDD when my I switch off the mains? (Any suggestion on Addition of a component at VDD? for eg. Logic level MOSFET?)

Thanks in advance.

update: µC schematic (not complete) (VDD is supplied by LNK304)

enter image description here

enter image description here

\$\endgroup\$
  • \$\begingroup\$ Can you monitor the main input, right at the input, with a diode before the capacitors? Then you can use that signal to turn the UC off with a simple FET circuit. Though I would ask, WHY do you need to turn it off quickly? Is it a real requirement? \$\endgroup\$ – Puffafish Mar 7 at 15:49
  • \$\begingroup\$ Yes, it is an indirect requirement to pass a compliance test. Where exactly you meant to place the diode? I just have an update with the simple schematic. \$\endgroup\$ – Vidu Kriss Mar 7 at 15:58
  • \$\begingroup\$ Another option - power the MCU with a secondary regulator that has far less stabilization capacitance connected to it. The secondary regulator will be cheap due to lower current requirements, and depending on the nature of your primary load, the secondary Vcc line may actually have less noise. \$\endgroup\$ – Reinderien Mar 7 at 16:51
2
\$\begingroup\$

You don't need to cut off the power - you can simply hold the reset low. MCU will be turned off then. There are monitoring circuits that will do that for you, like ADM6713 for example. It will disable MCU once voltage will slightly drop.

\$\endgroup\$
  • \$\begingroup\$ The problem is voltage does not drop until 8sec. \$\endgroup\$ – Vidu Kriss Mar 7 at 16:49
0
\$\begingroup\$
  1. Monitor the mains by using high value restive n/w & signal conditioning.
  2. Add Series MOSFET switch to cut down the VDD for uc.
\$\endgroup\$
  • \$\begingroup\$ High value resistors are usually insufficient protection from mains power \$\endgroup\$ – Drewster Mar 7 at 17:45
0
\$\begingroup\$

A simple solution is to just add a resistor in parallel with the capacitors. It will always burn power when the device is on, so it's a no-go for low power applications, but it will discharge the capacitors more quickly. At 1.8 V, a 500 ohm resistor would consume 3.6 mA = 6.5 mW, but it would change the time constant for 20 uF to about 10 ms.

\$\endgroup\$
  • \$\begingroup\$ Tried and failed. But works with a 150 ohm resistor and is not recommended due to power rating. The problems due the capacitance are not due to 20µF at the VDD, but due to the cap at the load (which is not shown in the above ckt) \$\endgroup\$ – Vidu Kriss Mar 7 at 16:51
0
\$\begingroup\$

Depending on the nature of why you're trying to make sure the uC shuts down quickly, I would try one of three things:

1) Use a diode on VDD and have your sense/ reset circuit before the diode - especially if you can compensate for the voltage drop and not impact stability. This should ensure that once the capacitors are the only thing supplying current, you can still watch the regulator's output drop and shut down accordingly.

2) Use a different regulator. A lot of switching regulators have a "PWR_GD" pin, or something to that effect to signal that the regulator is stable and ready. This might also help avoid issues on start-up.

3) Create an isolated feedback circuit on the mains side. If you use an optocoupler/ isolator driven off of the rectifier with some basic capacitance, you should be able to tell when mains power disappears very quickly. This route would probably be the most tedious since you need to protect the optocoupler, and if it ever craps out it'll keep you from operating.

\$\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.