Closed Ramblurr closed 7 months ago
This seems like a pretty easy fix, so I took a shot at it. If you can check out the particular PR branch and use that to build locally, I think this fixes your issue.
Thanks @EAGrahamJr ! I can confirm this patch fixes my issue. Now the MFRC522 can be opened/closed multiple times in the same process.
Brilliant, thank you. Hope to incorporate in the latest release once I’ve tested the Pi5 changes.
I'm building a modular application where the modules can be re/deactivated at runtime.
One of the modules wraps a MFRC522 device. Unlike other devices I'm wrapping (tested: Button, Led) when I open a
MFRC522
instance, and properlydevice.close()
it, then try to re-open it again.. I get the following error:(the stacktrace looks a little funny because I am calling diozero from Clojure)