Sorry for my poor English.
I am a noob in Arduino. Recently I am doing my school project. I am creating one device with both physical and digital switches. I want to make it be able to be remote controlled by mobile phone.
So I choose to use Blynk cloud service and NodeMCU. The program is not difficult. I wrote for physical push button and it function well. I use the standard example of Blynk code. It also works well. But when I tried to combine these two, I am facing this problem.
Example:
void loop()
{
digitalWrite(4, HIGH);
Blynk.run();
delay (1000);
digitalWrite(4, LOW);
}
When the program go to Blynk.run(), it will stuck in the function and cannot continue to next row.
Actually I want to make them parallel. If I control a LED, I want the physical push button and Blynk digital push button both can turn on the LED.
How can I write the program?
Thanks for your help.