Close

slow libraries everywhere

A project log for LEDodecahedron

We're going for it now, 612 LEDs, 51 of them controlled by a single IS31FL3733 chip

davedarkodavedarko 11/15/2022 at 12:141 Comment

I've spent 3 hours hunting down the speed settings for I2C on the Seeed XIAO NRF sense board in Arduino, but couldn't find it. My goal was to have a frequency of 1MHz for I2C instead of 100kHz, but so far there was no chance.

it's quite frustrating that I still have no idea where the seeed library based on mbed for the XIAO NRF sense defines how the I2C works with the wire library in Arduino. I found so many registers and values where I was "aha! That's the two wire interface speed value that I was looking for!" but then nothing changed when I edited the sdk_config.h file.

The other thing that slows down the animations is the code for writing to the LEDs. Looks like the code first writes a select page and then writes a single byte for the LED pwm value. There's definitely optimisation possible in streaming plenty bytes after selecting a page, instead of ping pong-ing that often to effectively set one byte.

[UPDATE] 10 frames per seconds reached

managed to send complete frames to the I2C controllers and now reach 10 frames per second on the NRF52840 board. After some datasheet reading I'm not so sure I can easily reconfigure the I2C to go 1MHz on the NRF52 and ordered an ESP32-S2 QT PY board to play around with. Last hope for the NRF52 is using the adafruit board libraries instead of the XIAO mbed library as I am fairly certain I saw code there that makes more sense. Would be nice to be able to use the NRF board with all its sensors (mic+accelerometer) on board.


FLASHING LIGHTS WARNING 

Discussions

Noblauch wrote 01/26/2023 at 23:47 point

Heyo, I'm stuck with the same problem. Can't get an OLED display to update I2C faster than 400 kbit/s :/
Did you ever manage to speed up your project to 800 or 1000? 😋

Greetings from Germany,
Noblauch

  Are you sure? yes | no