Automation - provide configurable manual trigger

I have setup an Automation feature which Starts and Stops a pump based on level in a tank. However the Automation Device Icon on the dashboard of the phone allows starting and stopping of the the pump manually overriding the level based settings just by pressing the icon. In a smartphone accidental manual activation of Automation can happen, which is undesirable. Please provide a feature to enable/disable manual operation during setting up of the automation feature and editable only by Admin.

You can do it by using isDisabled property on any widget.

Hi Pavel, Looked in the device settings of Automation on the phone app, couldn’t locate such a property. Do you mean this has to be configured through code on the hardware?

Yes, this is firmware API

Hi Pavel, In my opinion the ability to manually override Automation is an important feature, which needs to be available by default and which is already there. My concern is its inadvertent initiation, as an additional security If you can provide a extract confirmation step for the manual action, it would be perfect. To make changes to the code every time the feature is to be enabled / disabled is beyond most users and impractical.

You can check the documentation for more details.
https://docs.blynk.io/en/

In one post you are saying that manual override is undesirable, in the next one that it’s needed.

Since every Blynk user has their personal needs and vision, API gives you a lot of flexibility to achieve your results.

And it has nothing to do with end-users coding something. You can expose all needed controls to dashboard, pages, or tabs and code a very flexible solution that fits your use-case.

@sri_c could you pleae clarify - you don’t want the automation to be triggered from the mobile application/web interaction with widget?

I have a garage door opener running on Blynk. To avoid inadvertent opening/closing of the door I use two buttons to activate a relay. The first button pressed is on a timer. The second button (that activates a relay) will only work if the first button has been pressed.

And what’s the role of automation here?

1 Like

Hi Dimitriy, Certainly I want Automation to be triggered from Mobile/Web interaction through the widget. No doubt about that.

Hi Pavel, Sorry if I created any confusion. I definitely want manual override, which helps in situations where I need to run my pump manually. Let me clarify once again; The only concern I had was that since manual initiation is just a single tap of the Automation Icon on the Mobile dashboard, an accidental / inadvertent manual initiation could happen. I preferred a two step manual initiation to give a second chance before manual initiation signal is sent out. I agree there are many users with each one having unique need. But my requirement I believe is very basic just to make sure that the initiation of signal is intended and not accidental.

That’s possible if you choose device state as a condition.

Use coding instead of automation.

Hi,
I have secured pump system with coding like below

             if(PumpForHouseAutomationValue==1&&AutoManualPumpForHouseValue==1)
                 {

                    if(TankLevelForHouseLevelState==0) //state from ultrosonic sensor if tank is not full 
                                                     {
                                                      
                                                       digitalWrite(PumpForHouse ,0);
                                                       Blynk.virtualWrite(V1, 1);
                                                
                                                         

                                                     } else if (TankLevelForHouseLevelState==1  ) //state from ultrosonic sensor if tank is  full  {

                                                        digitalWrite(PumpForHouse ,1);
                                                        Blynk.virtualWrite(V1, 0);
       
                                                     }
   
                }else if(PumpForHouseAutomationValue==1&&AutoManualPumpForHouseValue==0  || PumpForHouseAutomationValue==0&&AutoManualPumpForHouseValue==1 )
                      {
 
                          digitalWrite(PumpForHouse ,1);
                          Blynk.virtualWrite(V1, 0);
         
                      }

And photo about that systemImage 2022-10-08 at 22.48.28

Automation going to control PumpForHouseAutomationValue and “Avto” (Auto) button going to control AutoManualPumpForHouseValue

Hi Kamran, Thanks you very much for the sample code to secure Automation. Will definitely try it out.