Charging large capacitor for power loss emergency stop

Hi,

I've been working on a project to automate a bale wrapper. I have it working well and it has already done a few hundred bales, but I am trying to improve things a bit. The wrapper so for is here Arduino controlled bale wrapper - YouTube

So it works with servos moving the levers of the spool valves. I have added an emergency stop button to the main body incase power needs to be cut. It will always be stopped from the remote, but just incase. The problem is I had to remove the springs from two of the spool valves. So when power is cut the spools stay in their last position, which would be bad.

I then found this solution Arduino Power Loss Detection with 2 Components - Saving State to EEPROM - YouTube
I am wondering if I used a large capacitor or super capacitor, would there be enough residual power to center a servo?

I have a few caps on order to experiment, but now to my main question. Is it ok to connect a large capacitor between Vin and GND? I also have a voltage regulator in parallel with Arduino for servos. both are running directly off a 12v battery.

If i put caps in parrellel before the regulator and arduino, will the inrush of the caps charging cause any problems to the regulator, Or Arduino? Or will I ned to add a NTC? and if I do, where? and how do I calculate size?

Thanks.

Damien

If the caps are TRULY ahead of the regulator and the Arduino, then they cannot hurt the regulator and Arduino BUT they could be too much load for your power supply.

vaj4088:
If the caps are TRULY ahead of the regulator and the Arduino, then they cannot hurt the regulator and Arduino BUT they could be too much load for your power supply.

Hi, When you say ahead do you mean between regulator/Arduino and power supply?

The power supply is a 12v leisure battery, so it be ok?

Thanks again

If it’s off a battery , why not stop the system under program control , then switch off the power supply to the micro.

Btw - hope you are complying with machinery safety laws , using appropriate safety controls .... the likes of Arduino cannot be used in any safety interlock system. What stops in advertant operation by the remote control when someone is loading it for example . The manual controls are designed to keep the operator away from it and give him direct control; you maybe making something less safe and could be prosecuted in the event of an accident .

In the UK ...

https://www.hse.gov.uk/work-equipment-machinery/manufacturer.htm

The capacitors would get connected at a point between the power supply and the regulator input, but if you do not decrease the current used by your Arduino, you could need a lot of capacitance.

I do not know what a leisure battery is. I would be guessing voltage, current capacity, etc.

A "12 volt" battery does not necessarily output 12 volts. For example, a 12 volt car battery outputs more than 13 volts when fresh.

I am wondering if I used a large capacitor or super capacitor, would there be enough residual power to center a servo?

Your first mistake was removing the springs. Why do you think you needed to do this? Did you get rid of the servo amplifiers? If so, then you need solenoid operated valves.

It’s a waste of time thinking you can get that kind of energy out of capacitors when you’ve got a battery sitting there. You're probably trying to solve the wrong problem. Given the overall lack of information, this is following the pattern of an x-y problem

hammy:
If it’s off a battery , why not stop the system under program control , then switch off the power supply to the micro.

Btw - hope you are complying with machinery safety laws , using appropriate safety controls .... the likes of Arduino cannot be used in any safety interlock system. What stops in advertant operation by the remote control when someone is loading it for example . The manual controls are designed to keep the operator away from it and give him direct control; you maybe making something less safe and could be prosecuted in the event of an accident .

In the UK ...

Are you a designer or manufacturer of equipment for use at work - Work equipment and machinery

Hi, But I was wonting it to act like an emergency stop button that cuts power. Would a programmed shutdown be classed as an emergency stop?

I know what you mean. I have been trying to program in as many safety features as I can, just incase. I have flashing lights and labels everywhere. During operation no one will be near it. it is loaded from tractor.

Thanks.

WattsThat:
Your first mistake was removing the springs. Why do you think you needed to do this? Did you get rid of the servo amplifiers? If so, then you need solenoid operated valves.

It’s a waste of time thinking you can get that kind of energy out of capacitors when you’ve got a battery sitting there. You’re probably trying to solve the wrong problem. Given the overall lack of information, this is following the pattern of an x-y problem

Agreed, bit I am working with what I have. spool slices are old and needed springs removed so servo could move them. I tested with spring though, and it still wasn’t enough in all circumstances to centre spool. And yes a solenoid spool would be better and far easier to implement, but again, got to work with what I have.

So I have an emergency stop switch that is also the on/off switch for the wrapper. How do I make it power down the Arduino, but also make it switch everything back on?

Thanks.

Hi,

I had a while to think it over and came up with the attached schematic. Would this work ok with code switching off the relay when it detects the toggle switch has been opened?

Thanks.

There are very few relays that may be used directly with an Arduino.
It is unclear to me what the thin red and blue lines connect to at the relay.
A diode across the relay coil is not required for some Arduinos but is good and cheap protection.
It is unclear where power goes in and relay switched power goes out. Perhaps "Perminent 12 V" is NOT really permanent.
It has not been explained why there is a voltage divider and what is intended to be measured.
At the moment, I don't know why there is a diode in the circuit.

It's a fair schematic so I am sorry to be so negative.

How is the Arduino going to get power if the switch and the relay are open ?
Why is an Arduino even necessary ?

vaj4088:
How is the Arduino going to get power if the switch and the relay are open ?
Why is an Arduino even necessary ?

Hi, The relay will be a relay module designed for Arduino. I just simplified the drawing. So when switch is closed 12v travel to VIN of Arduino. The Arduino boots up and immediately closes relay, which also connects 12v to VIN. The voltage divider is reading the voltage before the diode. But if the switch is opened the 12v coming through the relay cannot get past the diode, so the voltage divider will read 0v. If the Arduino detects this it will do something, and then switch off relay. Therefore shutting all power down.

Or at least that how I think it works. Does that sound correct?

The Arduino is needed because if the switch is turned off it needs to set a servo to center before shutting everything down.

Thanks.

"I do not know what a leisure battery is. I would be guessing voltage, current capacity, etc."

A leisure battery is a battery that is designed for slow discharge and recharge, rather than a starter battery that expects very fast, high current discharge. They are typically used to power lighting and other low current circuits in a caravan or motorhome.

Hi,

Just an update. Both solutions worked. I decided to go with the relay option.