Help with twitter widget

Hello,
I am newbe in twitter widget. I don’t understand how to use it.
I use the program in https://github.com/blynkkk/blynk-library/blob/master/examples/Widgets/Twitter/Twitter.ino and I changed the include to use with esp8266-01 ( ESP8266WiFi.h and BlynkSimpleEsp8266.h), but in line 48 what must I change?
Thank you.

Please add category to your topic

  1. Use ESP example sketch as a start. Make sure it works
  2. Add twitter widget in the Blynk app and connect it with your Twitter Account
  3. Read http://docs.blynk.cc/#widgets-notifications-twitter to learn how to send tweets from the hardware

This is one of the simplest widgets ever :wink:

Hello,
I have done 1. 2. and 3. (With an ESP8266-01).
The 1st twitt and the twitt sent every 10 minutes are ok, but the twitt doesn’t work when I press the button connected to gpio2. In the serial I have the message : “[19560262] Button is pressed.” and then

wdt reset
load 0x4010f000, len 1264, room 16
tail 0
chksum 0x42
csum 0x42
~ld

I have in the serial the message “Button is pressed.”, so I suppose that “attachInterrupt” is working, but I don’t understand why this crash.
I try the same sketch with an ESP8266-12E with the same result…
What can I do?
Thank you.

First of all, you can’t send the same text over and over, it’s Twitter policy. Each message should be unique

Limitations :
• you cant’ send 2 tweets with same message (it’s Twitter policy)
• only 1 tweet per minute is allowed

@Dmitriy could you please comment on

Thanks

@Pavel you probably mean @vshymanskyy. not me =)

Hello,
I have the same pb with the email widget (sketch changed to use ESP8266-01 or 12E).
The line 49 of the sketch sends email,
but the line 69 activated with the “attachInterrupt” just crashes (wdt reset …).
Where can be my pb?
Thank you.

When using esp8266-01, you should add stability capacitors and resistors to the board, and use a 600mA+ power supply.

Hello,
Thank you for your reply.
I am using an ESP8266-12E
I have a 3.3V 2A power supply
I have a 1500uF capacitor direct on pins GND / VCC of the ESP.
The pb is only when entering into interrupt
Blynk.email("me@abcde.fg", "Starting", "My Blynk project is online."); in void setup is working.
But Blynk.email("me@abcde.fg", "Subject: Button Logger", "You just pushed the button..."); in void emailOnButtonPress() makes the esp crash in watchdog timer.
What can I do please?
Thank you

Please, help me.
Does someone make working blynk, interrupt on ESP8266 to send email?
I changed all the wiring, used a new power supply with regulator 3.3V and new ESP8266 - 07 with no success.
I see no issue…

@whogarden posting your code would be nice.

/ **************************************************************
* Blynk is a platform with iOS and Android apps to control
* Arduino, Raspberry Pi and the likes over the Internet.
* You can easily build graphic interfaces for all your
* projects by simply dragging and dropping widgets.
*
* Downloads, docs, tutorials: http://www.blynk.cc
* Blynk community: http://community.blynk.cc
* Social networks: http://www.fb.com/blynkapp
*
* Blynk library is licensed under MIT license
* This example code is in public domain.
*
**************************************************************
* Simple e-mail example
*
* App dashboard setup:
* E-mail Widget
*
* Connect a button to digital pin 4 and GND
* Connect a led to digital pin 13 with R 1K to 3.3V
* Pressing this button will send the 2nd e-mail and switch off the led
*
* WARNING: You are limited to send ONLY ONE E-MAIL PER MINUTE!
*
**************************************************************/
//#define BLYNK_DEBUG
#define BLYNK_PRINT Serial
#include <ESP8266WiFi.h>
#include <SPI.h>
#include <BlynkSimpleEsp8266.h>

// You should get Auth Token in the Blynk App.
// Go to the Project Settings (nut icon).
char auth[] = "5a5963b8f**********a2cfe974591";

void setup()
{
  Serial.begin(115200);
  pinMode(4, INPUT_PULLUP);
  pinMode(13,OUTPUT);
  digitalWrite(13, LOW); // led on
  Serial.print("\n\n");
  Blynk.begin(auth, "mySSID", "myPassword");

  while (Blynk.connect() == false) {
    // Wait until connected
  }

  // Send e-mail when your hardware gets connected to Blynk Server
  // Just put the recepient's "e-mail address", "Subject" and the "message body"
  Blynk.email("******@******.fr", "Starting", "My Blynk project is online.");
  BLYNK_LOG("1st email is sent."); // This can be seen in the Serial Monitor
    
  // Setting the button
  pinMode(4, INPUT_PULLUP);
  // Attach pin 4 interrupt to our handler
  attachInterrupt(digitalPinToInterrupt(4), emailOnButtonPress, FALLING);
}

void emailOnButtonPress()
{
  // *** WARNING: You are limited to send ONLY ONE E-MAIL PER MINUTE! ***

  // Let's send an e-mail when you press the button
  // connected to digital pin 4 on your Arduino

  int isButtonPressed = !digitalRead(4); // Invert state, since button is "Active LOW"

  if (isButtonPressed) // You can write any condition to trigger e-mail sending
  {
    BLYNK_LOG("Button is pressed."); // This can be seen in the Serial Monitor
    Blynk.email("******@******.fr", "Subject: Button Logger", "You just pushed the button...");
    BLYNK_LOG("2nd email is sent."); // This can be seen in the Serial Monitor
    digitalWrite(13, HIGH); // led off
  }
}

void loop()
{
  Blynk.run();
}

Code seems ok. Does simplest BLYNK_WRITE works for you (on button for instance)? Does your email is correct/exists/not firewalled? Do you have “email” widget in app?
Also have in mind Blynk allows only 1 email per 60 seconds.

The first email is sent and well received in my PC with client mail thunderbird with windows 10.

Before pushing the button, I am waiting more than one minute.
I have the email widget in the android app.
I have a Button (switch) on gp0 in the android app and it’s working.
(GPIO0 is connected to a led (wired to a 1K resistor connected to the 3.3Volts) on the ESP8266 and the led is following the on and off button of the android app).

When I press the button (GPIO4 of the ESP8266) to work with interrupt,
*It’s like this : *
[10002] Connecting to cloud.blynk.cc:8442
[10211] Ready (ping: 0ms).
[10349] 1st email is sent.
[360758] Button is pressed.

  • ets Jan 8 2013,rst cause:4, boot mode:(3,0)*

wdt reset
*load 0x4010f000, len 1264, room 16 *
tail 0
chksum 0x42
csum 0x42

Hello,
I have just spent some time to rebuild the same sketch with an ethernet shield, and it is working perfecly.
What about using interrupts and email widget on ESP8266?
Does someone have already done this?
Thank you.
(I tried twitter widget with ESP8266 and I have the same wdt reset (the fist twitt is ok, the twitt on interrupt crashes in wdt reset).