I have a project that is using (among other things) a Teensy 3.2, OctoWS2811 adapter and FastLED, with 8 channels of WS2812B strips. Each strip is between 72 and 86 LEDs long, 630 LEDs in total. All this is working fine.
I want to swap out the Teensy 3.2 for a Teensy 4.0, keeping the rest of the hardware the same. When I do this however, three of the LED channels (2, 5 and 6) no longer get updated, and they change to random colours or bright white when the Teensy is rebooted or power cycled. The other five channels work as expected. Interestingly, if I swap the two RJ45 connectors around, it is STILL channels 2, 5 and 6 that don't work correctly. If I swap the Teensy 3.2 back in (painful, since soldering/desoldering is required on some of the bottom pads!), everything works fine again.
I've seen the recent FastLED fixes for OctoWS2811 and WS2812B LEDs, but they don't seem to make any difference. Regardless of whether I use FastLED 3.4.0, FastLED 3.5.0 or the latest from https://github.com/PaulStoffregen/FastLED, the behaviour is the same. Additionally, I am using the latest code from https://github.com/PaulStoffregen/OctoWS2811, and Teensyduino 1.56. For what it's worth I use PlatformIO for this project, with the following in platformio.ini:
On a hunch, I tried removing some audio/FFT code from my codebase (which sadly doesn't work well for me on the Teensy 4.0 anyway - see my question at https://forum.pjrc.com/threads/60618-FFT-on-Teesy-4?p=297070&viewfull=1#post297070). Once I removed this line:
all 8 LED channels started working again... for the most part at least. I did still have a different channel combination (4 and 6) fail in one instance even with my simplified code.
I don't really know where to go from here. My guess is that there's some sort of timing or interrupt problem with the OctoWS2811/FastLED (and possibly audio) combination. Do you have any suggestions for what I can try?
I want to swap out the Teensy 3.2 for a Teensy 4.0, keeping the rest of the hardware the same. When I do this however, three of the LED channels (2, 5 and 6) no longer get updated, and they change to random colours or bright white when the Teensy is rebooted or power cycled. The other five channels work as expected. Interestingly, if I swap the two RJ45 connectors around, it is STILL channels 2, 5 and 6 that don't work correctly. If I swap the Teensy 3.2 back in (painful, since soldering/desoldering is required on some of the bottom pads!), everything works fine again.
I've seen the recent FastLED fixes for OctoWS2811 and WS2812B LEDs, but they don't seem to make any difference. Regardless of whether I use FastLED 3.4.0, FastLED 3.5.0 or the latest from https://github.com/PaulStoffregen/FastLED, the behaviour is the same. Additionally, I am using the latest code from https://github.com/PaulStoffregen/OctoWS2811, and Teensyduino 1.56. For what it's worth I use PlatformIO for this project, with the following in platformio.ini:
Code:
[env:myproject]
platform = https://github.com/platformio/platform-teensy.git
board = teensy40
framework = arduino
lib_deps =
;fastled/FastLED @ ^3.5.0
https://github.com/PaulStoffregen/FastLED
https://github.com/PaulStoffregen/OctoWS2811
On a hunch, I tried removing some audio/FFT code from my codebase (which sadly doesn't work well for me on the Teensy 4.0 anyway - see my question at https://forum.pjrc.com/threads/60618-FFT-on-Teesy-4?p=297070&viewfull=1#post297070). Once I removed this line:
Code:
AudioOutputI2S i2s1;
I don't really know where to go from here. My guess is that there's some sort of timing or interrupt problem with the OctoWS2811/FastLED (and possibly audio) combination. Do you have any suggestions for what I can try?