Skip to content

OS Error: 2 while opening a file #1745

Answered by dlech
Redstonetill asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, there is a gc module.

import gc

...

gc.collect()

There is also a gc.threshold(() function that can be useful instead of manually calling gc.collect().

https://docs.micropython.org/en/latest/library/gc.html

Replies: 1 comment 10 replies

Comment options

You must be logged in to vote
10 replies
@dlech
Comment options

@Redstonetill
Comment options

@Redstonetill
Comment options

@dlech
Comment options

Answer selected by Redstonetill
@Redstonetill
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants