I am controlling my led with button widget and assigning digital option and pin D13 and working great i am turning on and off my led.
But i want to control my led with virtual pin how i will assign pin D13 to virtual pin ?
I am controlling my led with button widget and assigning digital option and pin D13 and working great i am turning on and off my led.
But i want to control my led with virtual pin how i will assign pin D13 to virtual pin ?
Hello,
Reading the Documentation, Help Center files and checking the Sketch Builder examples (links at the top of this page) will answer many questions…
For example, this…
http://docs.blynk.cc/#blynk-firmware-virtual-pins-control-blynk_writevpin
…and this…
…shows functions similar to this…
const int ledPin = 13;
// When App button, set to V2, is pushed - switch the state, then translate that to a digitalWrite() command.
BLYNK_WRITE(V2) {
ledState = param.asInt();
digitalWrite(ledPin, ledState);
}