adafruit / Adafruit_CircuitPython_Display_Text

Library to display text using displayio
MIT License
59 stars 38 forks source link

Program stops without any error when importing the library #200

Closed mirkokral closed 7 months ago

mirkokral commented 1 year ago

Hello, my program stops without any output while importing the library, and i can't get it to work. maybe helpful info: the program is ran using exec() Board: SeeedStudio WIO terminal Code:

print(1)
import board, digitalio
print(2)
from adafruit_display_text import bitmap_label as label
print(3)
from adafruit_bitmap_font import bitmap_font

(print statements only for debugging) Serial output:

1
2

And no three. Can somebody help? (this happens in both bitmap label and normal label.

FoamyGuy commented 1 year ago

@mirkokral What device are you running this code on? A circuitpython microcontroller? Or on a PC or raspberry pi in "normal" python?

I'm not sure what you mean when you said "the program is ran using exec()" either can you elaborate any further about how you are executing this code? On a microcontroller it should just be saved as code.py in order to be run automatically by the device. On a PC or Raspberry pi under CPython I think it should be run with a command like python my_script.py and the code would be contained inside of that file that you specify.

mirkokral commented 1 year ago

@mirkokral What device are you running this code on? A circuitpython microcontroller? Or on a PC or raspberry pi in "normal" python?

I'm not sure what you mean when you said "the program is ran using exec()" either can you elaborate any further about how you are executing this code? On a microcontroller it should just be saved as code.py in order to be run automatically by the device. On a PC or Raspberry pi under CPython I think it should be run with a command like python my_script.py and the code would be contained inside of that file that you specify.

The board is a wio terminal, i updated the post.

FoamyGuy commented 12 months ago

@mirkokral are you saving your file as code.py on the CIRCUITPY drive? or doing something different?

mirkokral commented 7 months ago

Old issue and also it was something with my sd card (because i use an sd card to run my code)