bbulkow / FastLED-idf

FastLED port to the ESP-IDF 4.0 development environment
https://fastled.io/
MIT License
162 stars 41 forks source link

RMT mode messes up pin 0 #22

Open L0laapk3 opened 3 years ago

L0laapk3 commented 3 years ago

Hi there

I've noticed that, when using GPIO 0, using fastled with RMT mode messes up this pin. After a little digging I've come to the conclusion that the problem is caused by these lines: https://github.com/bbulkow/FastLED-idf/blob/47f83d46898465f3e2298edc50810231166ae504/components/FastLED-idf/platforms/esp/32/clockless_rmt_esp32.cpp#L279-L285

From a quick scan of the original fastled code, it seems like they dont set it to pin zero first (anymore) (https://github.com/FastLED/FastLED/blob/master/src/platforms/esp/32/clockless_rmt_esp32.cpp#L109) so an update would hopefully be all thats needed to resolve this :)

L0laapk3 commented 3 years ago

PS. not entirely related, but also not worth making an entire issue over, but it would be nice to enclose the entire clockless_rmt_esp32.cpp file in #ifndef FASTLED_ESP32_I2S #endif to avoid having to mess around in multiple places to enable RMT mode :)