#define R1 13
#define R2 12
#define R3 14
#define R4 27
void setup() {
pinMode(R1, OUTPUT);
pinMode(R2, OUTPUT);
pinMode(R3, OUTPUT);
pinMode(R4, OUTPUT);
digitalWrite(R1, HIGH);
digitalWrite(R2, HIGH);
digitalWrite(R3, HIGH);
digitalWrite(R4, HIGH);
}
void loop() {
digitalWrite(R1, LOW);
delay(500);
digitalWrite(R1, HIGH);
delay(3000);
digitalWrite(R2, LOW);
delay(500);
digitalWrite(R2, HIGH);
delay(3000);
digitalWrite(R3, LOW);
delay(500);
digitalWrite(R3, HIGH);
delay(3000);
digitalWrite(R4, LOW);
delay(500);
digitalWrite(R4, HIGH);
delay(3000);
}
HI! iâm such a beginner, im not have an idea yet about how can i program a ESP32 through bluetooth in blynk, soon start some tutorials about arduino and how can i program by myself but in this moment iâm stuck in a personal project.
The idea is simple (i think), is like a secuentiator, have a 4 module relay and is connected with a ESP32 devkit; so i made rudimentary program, i want to control how much time is âONâ each relay and how much time is âOFFâ each relay, in my rudimentary program iâm control that with a âdelayâ function, is possible link all âdelayâ ON and with blynk app just modify all the delay âONâ (the same case in OFF delays)
for example, i want turn on 1, 2, 3 and 4 just 500ms in each, with a 180000ms turn off in each secuence:
Turn On 1 (500ms) (then off 180000), Turn on 2 (500ms) (then turn off 180000) etcâŚ
Then just change the time while is on and the time while is off trough blynk app, The time of intervals always be the same so i just need modify 2 values. is possible?
iâm such a noob in all this, sorry for my bad english, im learning too. Thanks in advance!