i am doing a project on relay control using blynk button. i have connected manual switches as a backup in case of blynk internet failure. i want to detect whether my device is on or off in my blynk app even if i switch it on or off from a manual switch or by a blynk button. in other words i want to turn blynk button on or off in the app when a signal in arduino uno digital pin is high. and off when arduino digital pin is low
Hello and welcome to the Blynk Forum. There are many reference pages that will guide you in learning to use Blynk…
All these links are at the upper right of this page.
Help Center: http://docs.blynk.cc (Read up on virtual pins and usage, as you will need those to do what you are wishing to do)
Sketch Builder: (Synchronizing Widget Button with Physical Button State) https://examples.blynk.cc/?board=Arduino%20Uno&shield=Serial%20or%20USB&example=More%2FSync%2FHardwareSyncStateFromApp
Also, please thoroughly read through the Welcome Topic.
my problem is not solved and please anyone help me in the following scenario.
when digital pin 3 is high due to an external input then the button widget should show “on” and all other times when the input signal to pin 3 is low, it should show “off”
@La_Ga_Ri if you need a fix we need all the relevant info including, but not limited to, a nicely formatted sketch.
i am using arduino uno with wemos di r2 board as wifi module. i am going to light an led using external voltage source say a battery, when the bulb is on, i connected the current going path to the arduino input pins. so whenever the bulb is ‘on’ due to external voltage, a smal amount of current goes to the input pin. and i want to detect that small current(the state of bulb) in blynk app button widget as ‘on’. when the bulb is ‘off’ as there is no input current to the i/o pins, the button widget should show ‘off’
It’s done with Arduino’s digitalRead() and Blynk’s virtualWrite() functions.
Your formatted sketch?
I hope we don’t have to wait another 28 days to determine if your issue is solved, again, then
You need to clarify a few things… a Wemos D1 R2 board IS an Arduino UNO compatible board (at 3.3v)… so is that the only board you are using, or are you also connecting a regular UNO to it??? and if so… how and why?
What hardware sensor are you using to detect this current from the external circuit, and are you also controlling that circuit with a relay or is it totally independent?
Timely details will help this process along. Thank you.