Bart,
The easiest long term is a 240V Float switch that is suitable for Sumps (rather than tanks) although some can do either (they have 3 wires). THey have in built in Hysterisis, and by playing with lead length and the weight you can set on and off depths. A quick search of eBay or internet will find many like this 10m 10A Liquid Water Level Float Switch Sensor Sump Fluid Tank Pump Controller | eBay.
SHort term, just wire in one of those LV float switches to your relay board (or both ) , it will short cycle
but will keep the water out till you find a float switch. You just need to find a LV power supply (an old USB charger should have enough Amps at 5V)
Should work with any sump pumps of size usually used in home basement but do check rating plate (10A is 2400W at 240V, or 1200W at 120V but you load is indictive motor, halve those (1200W or 600W) to help preserve contacts.
Just noticed that we haven't heard from Bart since he started wiring up the pump.
Did anyone warn him about the dangers of wiring mains circuits whilst standing in water??
I would go for either SSR as already stated or for mosfets to switch the pump.
That can be combined with a SR-flipflop:
one level-switch sets the flipflop,
the other resets the flipflop
the output of the flipflop switches the SSR or mosfet.
The flipflop is a standard 5V TTL IC. Inbetween flipflop and SSR/mosfet you might need a buffer, also standard TTL.
The lower switch is connected to âsetâ via RC so the flipflop gets a âsetâ- pulse but after that the reset input is still usable. I donât know how to describe this better in English
SSR is more safe because the switches are the separated from mains. For mosfets there are small driver-ICâs which decouples the input from the mosfet.
Two mechanical relays parallel doesnât look like a good idea to me
Yes, I noticed that later, and thought of a better solution.
What I would do is reverse the float logic by using a resistor between +5v and the float, so that if the float contacts are open, the resistor ensures that the output is +5v.
However, if the float contacts were closed, it would take the output to 0v.
I would do it that way because, if the circuit was as it was previously, the 2 input relays would be energised all of the time, and only de-energised when the water level is high, which is not good practice (and a waste of energy).
I've not amended the circuit (as I don't know if Bart is interested or not), but well spotted @Trying_to_learn
I can't see what Shelly logic you could use to keep the pump running until the water level dropped below the bottom float?
Remember, the pump is not intended to start until the water level reaches the top float, and does not switch off again until it falls below the level of the bottom float.
Paul you can separate the switch from the relay with shellies, so one can turn on and one turn off, using actions. Also with shelly 2 Gen you can use scripts.
Yes I'm aware of that, but not aware of any action that would fulfill Bart's goal.
It would be good if he could explain what he has in mind
Using MQTT to a pi, to perform the logic?
Haha, don't you have to pay Shelly for the script training course?
I will attempt to make it clearer for you Paul. You can disengage the switches from the relay, at which point you can set button/switch actions to on's and off's. so when top float opens (or opposite), the action can be turn on relay, you do not have to set an off action. You can do the same for lower float switch to turn off relay. Hope that clears any confusion.
No you do not have to pay to use scripts and shelly offer many examples free, You can of course pay any company to learn any programming language, or you can educate yourself as many do. The shelly scripting language is based on Javascript i beleive.
Thanks @E1cid I never thought about it that way, it does seem quite a good solution.
All of my devices are 1st Gen, so haven't looked into scripting in any detail, although I seem to be getting endless shelly emails asking me to sign up for their scripting courses.
Should of checked the no marketing box, I have never received any emails from Shelly. You sure they are from Shelly, whats the url?
All I can find is About us - Shelly Academy , do not look like they are part of Shelly/Allterco