forked from micropython/micropython
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Milestone
Description
This is very odd:
- Get the .py version of the CPX library: https://github.com/adafruit/Adafruit_CircuitPython_CircuitPlayground/releases/download/1.2.0/adafruit-circuitpython-circuitplayground-py-1.2.0.zip
- Unzip it and put the
adafruit_circuitplayground
directory at the top level ofCIRCUITPY
- In the repl, try to import it. It's too big to compile, as expected. But note that the
Memory Error:
is incomplete.
Adafruit CircuitPython 2.2.1 on 2018-01-23; Adafruit CircuitPlayground Express with samd21g18
>>> from adafruit_circuitplayground.express import cpx
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
MemoryError:
>>>
- Now move the
adafruit_circuitplayground
directory into thelib
directory, and restart the board. - Import it again in the REPL:
Adafruit CircuitPython 2.2.1 on 2018-01-23; Adafruit CircuitPlayground Express with samd21g18
>>> from adafruit_circuitplayground.express import cpx
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
MemoryError: memory allocation failed, allocating 338 bytes
Note the differences in the exception message.
I've tried to make a simpler test case and haven't succeeded yet. T module's position on sys.path
makes a difference. But it should not.
Metadata
Metadata
Assignees
Labels
No labels