Hello ,
The project is:
Control an Esp32 via a smartphone …
The idea is to light independent LEDs with an effect selectable by the menu widget
I have already written the skeleton of the project…
There are several effects and a single on / off button and it is he who must activate the programmed effect …
My problem is that I can’t figure out where to start to continue the project
#include <WiFi.h> //Bibliothèque Wifi
#include <WiFiClient.h>
#include <BlynkSimpleEsp32.h>
#include <ezOutput.h> // ezOutput library
char auth[] = ""; //Réseaux
char ssid[] = "Claudine";
char pass[] = "cake2303";
WidgetTerminal terminal(V4);
ezOutput led(13); // create ezOutput object that attach to pin 9;
void Flash(){
}
void Fixe(){
}
void SOS(){
}
void Beacon(){
}
void setup()
{
// Debug console
Serial.begin(9600);
Blynk.begin(auth, ssid, pass);
}
void loop()
{
Blynk.run();
}
BLYNK_WRITE(V0){
int pinValue = param.asInt(); // assigning incoming value from pin V0 to a variable
Serial.print("BUTTON : ");
Serial.println(pinValue);
}
BLYNK_WRITE(V1){
int frequence = param.asInt(); // assigning incoming value from pin V1 to a variable
Serial.print("Frequence : ");
Serial.println(frequence);
}
BLYNK_WRITE(V2){
switch (param.asInt())
{
case 1: Serial.println("Flash"); Flash(); break;
case 2: Serial.println("Fixe"); Fixe(); break;
case 3: Serial.println("SOS"); SOS(); break;
case 4: Serial.println("Beacon"); Beacon(); break;
case 5: Serial.println("Matrice"); Matrice(); break;
default: Serial.println("Mode inconnu");
}
}
BLYNK_WRITE(V3){
int intensite = param.asInt(); // assigning incoming value from pin V3 to a variable
Serial.print("Intensite : ");
Serial.println(intensite);
} ```
Hoping not to have duplicated a topic