Metro Express and color565

CircuitPython on hardware including Adafruit's boards, and CircuitPython libraries using Blinka on host computers.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
bhclowers
 
Posts: 3
Joined: Thu Oct 05, 2017 1:09 am

Metro Express and color565

Post by bhclowers »

I've been trying to get the 1.27" SSD1351 working with circuitpython and the metro express with little luck. Upon inspection in looks like the color565 import is causing the system to run out of memory. Given that the code below is the only thing I'm trying to run, does this simply mean that circuitpython, metro express, and the display libraries are incompatible? If there is a way to make this happen, can anyone point me in the right direction?

Code: Select all

import busio
import digitalio
import board
from adafruit_rgb_display import color565
import adafruit_rgb_display.ssd1331 as ssd1331
spi = busio.SPI(clock=board.SCK, MOSI=board.MOSI, MISO=board.MISO)
display = ssd1331.SSD1331(spi, cs=digitalio.DigitalInOut(board.GPIO0),
                            dc=digitalio.DigitalInOut(board.GPIO15),
                            rst=digitalio.DigitalInOut(board.GPIO16))

display.fill(0x7521)
display.pixel(32, 32, 0)
Cheers,

Brian

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: Metro Express and color565

Post by adafruit_support_mike »

[moved to the CircuitPython forum]

User avatar
tannewt
 
Posts: 3314
Joined: Thu Oct 06, 2016 8:48 pm

Re: Metro Express and color565

Post by tannewt »

Hi Brian,
Are you importing mpy files? They take less memory than regular py files.

~Scott

Locked
Please be positive and constructive with your questions and comments.

Return to “Adafruit CircuitPython”