The IS31FL3206 is a 12 channel, constant current LED driver with independent PWM control for each channel.
Install this module using mip:
mpremote mip install github:metr-systems/micropython-is31fl3206
To use the driver, simply set up the I2C channel and instantiate a new
IS31FL3206 object:
from is31fl3206 import IS31FL3206
i2c = I2C(sda=Pin(4), scl=Pin(5))
led_driver = IS31FL3206(i2c, en=Pin(6, Pin.OUT))
led_driver.set_channel_pwm(0, 255)This library was tested on the Raspberry Pi RP2350. It should work on other platforms for which micropython supports I2C communication, but this is not yet tested.