IF this AND this THEN thet

I make smart watering system and it work great. Universal PCB board with ESP8266
Now I’d like to make it also better. Let say if it is not enough water in system don’t watering, if soil is enough wet, don’t watering, etc…
How to do this?
I have now
IF on time 5:00AM THEN open valve 1
IF tank level is lower then 20% THEN close valve 1
IF soli is more then 60% THEN close valve 1

this works. But If I open manual watering it must ignore this two conditions and keep open valve.
So it will be very good option to user have choice for AND and OR. Let’s say like this
IF on time 5:00AN AND tank level is higher then 20% THEN open valve 1

best regards

you can do this in the code itself with use of some variable.

if ((5:00AM) && (20%)) { turn ON motor)

Thanks for fast replay.
I’m new here and not exact understand where to add this? on ESP program?
This is accapible, but if I need to change this I need to take my computer on garden and reprogram it. Much better will be, if I can do this on Cayenne site

sorry, cayenne does not offer this kind of trigger.

Can you add this possibility? I think it is very useful gadget.

no, this wont be added to cayenne. But we have a commercial platform with all this features https://mydevices.com/work-with-us/