Skip to content
Discussion options

You must be logged in to vote

Answering the question how do other drivers do this: For things like file handles, since the types are implemented in C, they can use a finalizer (assuming the port you are using has GC finalization enabled) to release the resources. There is a special GC function that is called in most ports that ensures that all finalizers are run on soft reset.

But if all of your code is written in Python, I'm not sure what could be done.

Replies: 2 comments 5 replies

Comment options

You must be logged in to vote
4 replies
@moefear85
Comment options

@dlech
Comment options

Answer selected by moefear85
@robert-hh
Comment options

@moefear85
Comment options

Comment options

You must be logged in to vote
1 reply
@moefear85
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
5 participants