Hi,
Just new to blynk, its awesome. Trying to turn led widget on from NodeMCU (ESP8266). I can control the board from the app, but can’t seem to get the led widget to respond to the board.
I looked at the FAQ’s and one was similar but the link to the code example didn’t work.
I have a led widget set to V2
From the Arduino sketch I am using this simple code
void loop()
{
Blynk.run();
result=digitalRead(switchPin);
if(oldresult!=result)
{
if(result){
Blynk.virtualWrite(V2, LOW);
Serial.println(“Sending low”);
}
else {
Blynk.virtualWrite(V2, HIGH);
Serial.println(“Sending high”);
}
oldresult=result;
}
The led widget on the tablet doesn’t change.
Thanks for your help
Alastair