Perte d'alimentation ESP8266

Are you using the new blynk ( IOT ) or the old one ( legacy ) ?

En parcourant les informations sur mon téléphone, il est question de la version 2.27.32 (04/09/2021) de BLYNK.

J’ai téléchargé le BLYNK pour Arduino, ESP8266,RPi

You’re using blynk legacy. Now are you using digital pin or virtual pin ?

C’est une broche numérique

I’d suggest that you switch to using virtual pins….

Pete.

1 Like

Un grand merci pour avoir pris de ton temps pour m’aiguiller sur mon problème.
Je vais donc suivre tes conseils, et passer à l’utilisation de broches virtuelles.
Je te ferais un retour dès que possible.

Tu veux dire les Pin D1 et D2 ?
Et n’oublie pas que les relais fonctionnent souvent à l’envers !
C’est à dire 0 = ON et 1=OFF
Tu utilises quels relais ?
Montre nous ton code

Alexis

Not all off relays, only the active low relay.

1 Like

Yes but the most of all on AliExpress or eBay are high level at 0v

Yes and some relays give you the ability to choose between active high or low like this one
s-l400

I know that.
But we don’t know what type of relay he has :joy:

The problem is caused by the Blynk library forcing digital pins HIGH at startup, and the easiest way to get around it is to switch to digital pins.
A pinMode statement and digitalWrite is also needed in void setup.

Pete.

I think he is talking about esp8266 pins , not Blynk digital Pin.
There is a french translation problem :stuck_out_tongue_winking_eye:

The sketch has no BLYNK_WRITE(vPin) callbacks, so the widgets are attached to digital pins.
He needs to switch to using virtual pins.

Pete.

1 Like

Bonjour à tous,
J’ai fais des essais en modifiant dans BLYNK les sorties, En PIN virtuelles (V0, V1, V2, ect.) rien ne se passe, que ce soit côté ESP ou relai.
Seul en mode Digital sur la PIN gp0 (PWM), le relai fonctionne.
C’est un module ESP01S avec un relai SRD acheté sur AliExpress


Avez-vous besoin d’autres informations ?

This module doesn’t have enough pins so I recommend you to use esp32 or nodemcu instead.

Voici le programme complet ESP8266_Standalone que j’ai téléversé.

/* Remplissez votre ID de modèle (uniquement si vous utilisez Blynk.Cloud) */
//#define BLYNK_TEMPLATE_ID   "YourTemplateID"
#include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "zA8XXXXXXXXXXXXEOGQp-";
// Your WiFi credentials.
// Set password to "" for open networks.
char ssid[] = "SFR_D5C0";
char pass[] = "whXXXXXXXgfd8";
void setup()
{
  // Debug console
  Serial.begin(9600);
  Blynk.begin(auth, ssid, pass);
}
void loop()
{
  Blynk.run();```

You’re not using virtual pins in your sketch, check post number 13

Mon problème d’alimentation provient du fait que ce module n’a pas assez de broches ?
Pour mon utilisation (allumer ou éteindre un récepteur), je pensais qu’un ESP-01s avec un relai 2 contacts inverseurs (NO et NC) était suffisant.
Que va me procurer, et comment gérer l’esp32 pour ce problème d’alimentation ?