jklondon
Posts: 23
Joined: Thu Dec 31, 2015 1:58 pm

Static Display on Sensehat

Thu Mar 24, 2016 9:01 am

Looking to generate a countdown on the sensehat (e.g. 10...9...8..) based on a certain triggers. How can I display a static character on the sensehat, when I try its always scrolling)? Thanks Rav

DirkS
Posts: 10347
Joined: Tue Jun 19, 2012 9:46 pm
Location: Essex, UK

Re: Static Display on Sensehat

Thu Mar 24, 2016 10:41 am

Try using show_letter instead of show_message.
See https://pythonhosted.org/sense-hat/api/#led-matrix

sergeyglazyrin
Posts: 4
Joined: Sun Feb 28, 2016 7:02 pm

Re: Static Display on Sensehat

Thu Mar 24, 2016 11:00 am

Yes, but that's only for one letter, right ?
What if number has two letters ?
I thought about generating image and using method: display_image or something, don't remember exact method

DirkS
Posts: 10347
Joined: Tue Jun 19, 2012 9:46 pm
Location: Essex, UK

Re: Static Display on Sensehat

Thu Mar 24, 2016 11:29 am

sergeyglazyrin wrote:Yes, but that's only for one letter, right ?
Well, you did ask about 'a static character'...
I thought about generating image and using method: display_image or something, don't remember exact method
it's set_pixels, see link above for syntax and an example

sergeyglazyrin
Posts: 4
Joined: Sun Feb 28, 2016 7:02 pm

Re: Static Display on Sensehat

Thu Mar 24, 2016 12:42 pm

No it's load_image method
Loads an image file, converts it to RGB format and displays it on the LED matrix. The image must be 8 x 8 pixels in size.

Return to “Astro Pi”