Hey all,
Is there example code anywhere for just having a still image printed out to the LED matrix? The scrolling is nice but I currently just want the image to stay still. Any help would be great.
Thanks!
Still image on 16x32 LED matrix for RPi
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- thaweatherman
- Posts: 39
- Joined: Mon Feb 09, 2015 11:24 pm
- ethur
- Posts: 17
- Joined: Sat Jan 10, 2015 8:51 pm
Re: Still image on 16x32 LED matrix for RPi
I'd recommend starting with Step 6 in the Adafruit RGB HAT tutorial to install the Python Imaging Library. Once that is done, displaying a static image is as easy as:
import Image
import ImageDraw
import time
from rgbmatrix import Adafruit_RGBmatrix
# Rows and chain length are both required parameters:
matrix = Adafruit_RGBmatrix(16, 1)
# yourimage.png could be any PIL supported format with 16x32 pixel dimensions
image = Image.open("yourimage.png")
image.load()
matrix.SetImage(image.im.id, 0, 0)
time.sleep(10)
matrix.Clear()
import Image
import ImageDraw
import time
from rgbmatrix import Adafruit_RGBmatrix
# Rows and chain length are both required parameters:
matrix = Adafruit_RGBmatrix(16, 1)
# yourimage.png could be any PIL supported format with 16x32 pixel dimensions
image = Image.open("yourimage.png")
image.load()
matrix.SetImage(image.im.id, 0, 0)
time.sleep(10)
matrix.Clear()
- thaweatherman
- Posts: 39
- Joined: Mon Feb 09, 2015 11:24 pm
Re: Still image on 16x32 LED matrix for RPi
Hey thanks for the reply.
It seems whenever I get to creating the matrix in your code the Pi disconnects itself and the matrix displays random pixels. Do you know why that would be?
Thanks
Edit: scratch that it doesnt work at all even with the provided examples. However the one from here: https://learn.adafruit.com/connecting-a ... pi/testing works with the demos.
Every time it craps out with the new adafruit library it says this: Result: 0xCF33070 v 0xCF33070
I am using the RPi B
It seems whenever I get to creating the matrix in your code the Pi disconnects itself and the matrix displays random pixels. Do you know why that would be?
Thanks
Edit: scratch that it doesnt work at all even with the provided examples. However the one from here: https://learn.adafruit.com/connecting-a ... pi/testing works with the demos.
Every time it craps out with the new adafruit library it says this: Result: 0xCF33070 v 0xCF33070
I am using the RPi B
- JonTorbitt
- Posts: 1
- Joined: Thu Sep 08, 2016 4:48 pm
Re: Still image on 16x32 LED matrix for RPi
I'm getting this exact same error message - any ideas? AM running up to date everything and standard clock speeds as far as I know - have not changed anything
- satre
- Posts: 8
- Joined: Tue Jul 11, 2017 9:18 pm
Re: Still image on 16x32 LED matrix for RPi
The code above works perfectly for me, but I'm wondering, is there a way to make the image fade in over a second or so, stay for a bit, and then fade out?
Thanks!
Satre
Thanks!
Satre
Please be positive and constructive with your questions and comments.