Dear All Have a nice day
I have two hardware ( two NODE MCU’s)
I used same pins of both Node MCU to turn on and off LED’s (Ex. D1, D2,D3)
But One Node MCU is controlling by switch module in Blynk APP
and other node MCU is controlling by Segment switch in Blynk App
Segment switch assign with virtual pins ( V1)
Program is working but both hardware is working simultaneously even I pressed any switch
Please advice
BLYNK_WRITE(V1) { // Widget for interval timing
switch (param.asInt())
{
case 1: { // Item 1
digitalWrite(D1, HIGH);
digitalWrite(D2, LOW);
digitalWrite(D3, LOW);
break;
}
case 2: { // Item 2
digitalWrite(D1, LOW);
digitalWrite(D2, HIGH);
digitalWrite(D3, LOW);
break;
}
}
}
void loop() {
Blynk.run();
BLYNK_WRITE();
}