-
-
Notifications
You must be signed in to change notification settings - Fork 271
Open
Labels
Description
This behaviour is new since commit esp8266/Arduino#2239, which causes wdt reset whenever serial.begin() was called again, however, this has been fixed in esp8266/Arduino#2307. Prior to all these commits NeoEsp8266AsyncUart800KbpsMethod worked fine. Currently DMA and normal UART work fine, but using async and calling serial.begin() again, even with the same serial speed, and making the stip buffer dirty, causes a wdt. @me-no-dev has suggested that the RX buffer interrupt that is now being used is shared between both Serial and Serial1. When serial is changed, something is getting messed up...
sketch below causes it
#include <NeoPixelBus.h>
//NeoPixelBus<NeoGrbFeature, Neo800KbpsMethod> strip(20, 2); // does not wdt
//NeoPixelBus<NeoGrbFeature, NeoEsp8266Uart800KbpsMethod> strip(20, 2); // does not wdt
NeoPixelBus<NeoGrbFeature, NeoEsp8266AsyncUart800KbpsMethod> strip(20, 2); // causes wdt
bool triggered = false;
uint32_t timer = 0;
void setup() {
Serial.begin(115200);
Serial.println("BEGIN 115200");
strip.Begin();
strip.Show();
}
void loop() {
if (millis() - timer > 500) {
Serial.println("working.....");
timer = millis();
}
if (!triggered && millis() > 5000) {
if (Serial) {
Serial.println("Changing Serial\n\n");
Serial.flush();
Serial.begin(115200);
}
strip.Dirty(); // this is important.. otherwise it works. can set a color too...
strip.Show();
triggered = true;
}
}