Skip to content

super slow update on raspberry pi pico W  #115

Open
@jkozniewski

Description

@jkozniewski

Hello

I've observed very slow display update for 14-segement backpack (https://www.adafruit.com/product/1910) controlled by raspberry pi pico W (using latest circuit python uf2)

According to the test code provided below update of all 4 characters takes about 13-14 ms and scales more or less linearly with each new character added ( the single call of display.set_digit_raw takes about 3-4 ms ) which makes integrating this display pretty hopeless for any code that needs to update something else quickly as the code is blocking, especially if someone want's to chain a few of those...

import board
import busio
from adafruit_ht16k33 import segments
import supervisor

i2c = busio.I2C(board.GP21, board.GP20)
display = segments.Seg14x4(i2c)

start_msecs = supervisor.ticks_ms()
display.print("ABCD")
stop_msecs = supervisor.ticks_ms()

print("elapsed time = ", stop_msecs - start_msecs)

Wondering what might be the reason for such slow I2C implementation - is it pico W related or circuit python in general ?
I have tested the displays with regular Arduino UNO and your library (https://github.com/adafruit/Adafruit_LED_Backpack) and the equivalent update (4 characters via writeDigitRaw()) takes only 1 ms, or 1850 micro seconds, if simple micros() before-after measurement can be trusted.

Any insights and ideas how to overcome this are much appreciated !

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions