Need help for my project in brazil

Hello everyone,

Since the beginning of the pandemic I stopped using Blynk, now I’m coming back and I find myself with a lot of news.
I uploaded my first project on the Dashboard, something very simple, Turning on and off an LED, and Turning on and off a buzzer, I’m using an ESP32, on pin 23 the LED is on, and on pin 22 the Buzzer, on the Dashboard I put the virtual ones pin V0 for the LED and V1 for the Buzzer, I uploaded the code and everything is apparently ok.
The problem is that the LED lights up normally, but the buzzer doesn’t work, I’ve tested the off-board buzzer it works perfectly, on the smartphone I set the buttons exactly like V0 and V1 as on the Dashboard, the buzzer button works, that is, , it is triggered, but the buzzer does not respond.

I’ll put my schedule here to see if there’s something wrong with it.
I would like to thank everyone who wants to collaborate with me to solve my problem.
Greetings to all Blynkers.

//#define BLYNK_DEVICE_NAME           "Device"

#define BLYNK_FIRMWARE_VERSION        "0.1.0"

#define BLYNK_PRINT Serial
//#define BLYNK_DEBUG

#define APP_DEBUG

// Uncomment your board, or configure a custom board in Settings.h
//#define USE_TTGO_T7
//#define USE_ESP32C3_DEV_MODULE
//#define USE_ESP32S2_DEV_KIT

#include "BlynkEdgent.h"
const byte ledPin = 23;
const byte Buzzer = 22;

void setup()
 pinMode (ledPin, OUTPUT);


void loop() {;

 int state = param.asInt();

 int state = param.asInt();

Hey there,
first please edit your post and add triple backticks ( ``` ) before and after your sketch.

Thanks for answer friend, I do it, hoppe now post is ok.

Well, I think I found the error, I didn’t declare the Buzzer in my code as pinMode, OUTPUT, I’ve fixed it and now both are working, Buzeer and LED.

Thank you all.

Yes, now it’s okay.


#define BLYNK_TEMPLATE_ID            

Must be the first two lines in your sketch.

add pinMode(Buzzer, OUTPUT); to the void setup.

Thank you!

1 Like

Hi friend,
the error of the two lines was only here when I pasted the code, but in the sketch they were ok, it was only the undeclared pinMode, thanks again.

1 Like