New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
NeoEsp8266Dma* method is not working (Wemos D1 Mini, and 12e confirmed) #88
Comments
Did you read the Wiki on Esp8266 support? Specifically here. You may also want to review the FAQ Due to hardware limitations, the default method (NeoEsp8266Dma800KbpsMethod) uses hardware that gives the user no choice of pin; but its the best mode for Esp8266. Further, the The Uart method (NeoEsp8266Uart800KbpsMethod) also has a limited pin and is the second best method (ESp01 are stuck with this, and it maybe that the pin restrictions on Wemos D1 is also). The Adafruit library support for esp8266 is based on my work (credited in the code file) for the bitbang method (NeoEsp8266BitBang800KbpsMethod) and they both will have the same issue that if you use WiFi, they won't work reliably. This is due to the WiFi core will interrupt the data stream causing all sorts of glitches when WiFi is active, and you can't block these interrupts as doing so will throw an exception and reset the chip. I keep it around for testing primarily. You may hear LadyAda comment about this issue in some videos, and this is why the Dma and Uart methods are best. |
Something else to try as I have had one report of this issue with DMA and chalk it up to failed hardware (or strange board components that effect the DMA pin), but they found a work around by increasing the number pixels passed to the constructor but still only reference the original ones. |
I have a NodeMCU Amica and have been trying to run the demos and some code of my own and I am also having problems with stability. I have a 74AHCT125 level translator and a 100 ohm resistor between the Amica and the 8x8 Adafruit neopixel panel. The demos start to work and then stall completely; the same is true of the code I have written. |
@craiglindley Could you try the work around of passing a larger number to the constructor than you actually have but only reference the original count? Add 50 to it. |
Adding 50 to the led count actually made the problem worse. On Wed, Mar 30, 2016 at 5:04 PM, Michael Miller notifications@github.com
Craig Lindley / Heather Hubbard New Recordings: craigandheather.net/cnmpage.html Personal Website: craigandheather.net Phone: (719) 495-1873 If you’re one in a million, there are now seven thousand people exactly |
Re the Docs/FAQ - yes I saw that. I think that the problem underlying this is that the ESP8266 platform is now much bigger. The Wemos D1 Mini is based on the ESP12EX model which is far more capable than the original ESP01 and is specifically set up to be very Arduino-like. So perhaps the library should not be making choices itself or at least should allow them to be overwritten. I did try to look through the code to see if I could relax the restrictions but I'm afraid my C is rather limited. I will try the other suggestion too. But if there is a way to not use the ESP code, that would be useful. |
Not sure if this might not shed some light on things: http://tech.scargill.net/esp8266-ws2812b-leds-on-a-plate/ |
@TotallyInformation Some of this is best talked about on gitter as to not add noise to the core issue here. But that link is based on an early SDK, and is basically the same as my BitBang method. BUT, last July SDK release broke this, as the interrupt stop no longer will block one core WiFi interrupt; so you can still get interrupted and it breaks the timing. If you call a lower level interrupt disable WiFi will cause a chip reset. So, BitBang is not a solution if you are going to use WiFi (primary reason to have a Esp8266). What feature exactly do you think the library is making a choice and not exposing a way to override? If you look at Wiki, it explains how to switch between different methods to use Dma, Uart, and even Bitbang. |
Update: I was curious why I wasn't seeing this when others obvious were, but not everyone. So I followed my own often suggestion and used the "nuclear option" to clean Arduino and Esp8266 off my machine and started over with the latest. |
I just put in a redesign of the DMA method, underlying hardware use is similar but due to SDK change something I relied on no longer worked. The new design should be future proof and should work on EX chips also (I don't have one to test with yet). |
Thanks, will try when I get a chance. |
Seems like DMA on the NodeMCU Amica is working perfectly now. Thanks Makuna |
@TotallyInformation and @Makuna And @Makuna, I played with animation class and definition, your piece of code is just amazing, thanks a lot for you great work,... Also for those who want to drive WS2812 ESP8266 3V3 with 5V without level shifter, look at this trick It's not my idea, original post here this is efficient and so simple. Just put a diode on 1st LED VCC (small 1N4148 is far enought) |
BTW, some of the newer chips (4 element RGBW) are far more tolerant of the 3.3v IO and will work without a level shifter. Since you have come back stated it works, I am closing this issue. |
Oh, I received the RGBW today, I will test ;-) |
Not had chance to play yet I'm afraid but I will do. I've no doubt you've fixed it though given the comments. Thanks so much for digging into the issue and solving it for us. Your library is definitely cool & I've had the random fade running on an Arduino Nano on my desk for a few days, very relaxing. :-) @hallard thanks for the testing & the info, very useful. |
Hi, there seems to be one or two issues when running on the D1 Mini.
Firstly, the data pin seems to be fixed on Arduino pin 3 which is the RXD pin on the D1 Mini and causes the whole string to go to max output when restarting.
Secondly most of the examples don't work. The Cylon example completes a single cycle, the others don't do anything though the ones that have serial output clearly show they are cycling.
This is a shame as I like the capabilities of the library.
I'm working with an 8 LED WS2812 5050 based neopixel. It works fine with the Adafruit library.
The text was updated successfully, but these errors were encountered: