You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i wanted to see if i can somehow get the framebuffer of the badger's display (mainly to create a function that inverts a small section of the display)
there is a set_framebuffer function that works with a bytearray, e.g.
import badger2040
display = badger2040.Badger2040()
fb = bytearray(4736) # (4736 = number of pixels on badger (296*128 = 37888) divided by 8)
display.set_framebuffer(fb) # fills the screen with black since the bytearray is full of 0x00s
display.update()
and picographics does seem to have a get_framebuffer function that is omitted from from the badger (was this deliberate?)
i feel like reading and modifying the framebuffer directly could have some uses, like creating interesting effects or being able to draw patterns faster (the example above is faster than setting the pen to 0 and clearing the screen, albeit by only 9 milliseconds)
The text was updated successfully, but these errors were encountered:
i wanted to see if i can somehow get the framebuffer of the badger's display (mainly to create a function that inverts a small section of the display)
there is a set_framebuffer function that works with a bytearray, e.g.
and picographics does seem to have a get_framebuffer function that is omitted from from the badger (was this deliberate?)
i feel like reading and modifying the framebuffer directly could have some uses, like creating interesting effects or being able to draw patterns faster (the example above is faster than setting the pen to 0 and clearing the screen, albeit by only 9 milliseconds)
The text was updated successfully, but these errors were encountered: