Quantcast
Channel: Support - Pimoroni Buccaneers
Viewing all articles
Browse latest Browse all 6853

Set_all() is missing from the UnicornHAT

$
0
0

@LimeBlast wrote:

I'm playing with the UnicornHAT on a Pi 2, after having installed the software via the full install command, and I've found the set_all() method doesn't exist.

I checked the source on GitHub, and it's there, but checking the same file on my Pi, and it's missing.

Most of the other functions work, and I'm able to get the same effect using the following code, but I doubt this is very efficient:

width, height = unicorn.get_shape()
for y in range(height):
    for x in range(width):
        unicorn.set_pixel(x, y, rgb['red'], rgb['green'], rgb['blue'])
unicorn.show()

This leads me to think I've maybe done something wrong, or the version installed via pip is old. I tried updating the package manually, but that didn't work either.

I'm pretty new to python, so it's totally possible that I'm doing something wrong, but I don't know what.

Posts: 7

Participants: 4

Read full topic


Viewing all articles
Browse latest Browse all 6853

Trending Articles