Can someone help me understand the possible reasons for the output below?
I’m currently working with ESP8266 and Blynk. Template ID, name, and authentication token were provided in the actual code. Based on my research, I’ve noticed there might be an issue with the input in blynk.begin(). So, I attempted to change blynk.begin(auth) to blynk.begin(BLYN_AUTH_TOKEN), but the output remains unchanged.
1st Code:
#define BLYNK_PRINT Serial
#include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
#define BLYNK_TEMPLATE_ID "********"
#define BLYNK_TEMPLATE_NAME "LED Blink"
#define BLYNK_AUTH_TOKEN "**************"
char auth[] = BLYNK_AUTH_TOKEN;
char ssid[] = "try";
char pass[] = "try";
BLYNK_WRITE(V0) {
digitalWrite(D0, param.asInt());
}
void setup() {
pinMode(D0, OUTPUT);
Blynk.begin(BLYNK_AUTH_TOKEN, ssid, pass, "blynk.cloud", 80);
}
void loop() {
Blynk.run();
}``
1st Output:
error: #error “Please specify your BLYNK_TEMPLATE_ID and BLYNK_TEMPLATE_NAME”
39 | #error “Please specify your BLYNK_TEMPLATE_ID and BLYNK_TEMPLATE_NAME”
| ^~~~~
exit status 1
Compilation error: exit status 1
2nd code:
#define BLYNK_PRINT Serial
#include <ESP8266WiFi.h>
#include <BlynkSimpleEsp8266.h>
#define BLYNK_TEMPLATE_ID "********"
#define BLYNK_TEMPLATE_NAME "LED Blink"
#define BLYNK_AUTH_TOKEN "**************"
char auth[] = BLYNK_AUTH_TOKEN;
char ssid[] = "try";
char pass[] = "try";
BLYNK_WRITE(V0) {
digitalWrite(D0, param.asInt());
}
void setup() {
pinMode(D0, OUTPUT);
Blynk.begin(BLYNK_AUTH_TOKEN, ssid, pass, "blynk.cloud", 80);
}
void loop() {
Blynk.run();
}``
2nd output:
error: #error “Please specify your BLYNK_TEMPLATE_ID and BLYNK_TEMPLATE_NAME”
39 | #error “Please specify your BLYNK_TEMPLATE_ID and BLYNK_TEMPLATE_NAME”
| ^~~~~
exit status 1
Compilation error: exit status 1
Eve is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.