Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Access multiple ANC350s simultaneously. #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jacione
Copy link

@jacione jacione commented Aug 17, 2021

I was working with v4 and made some edits to the code so that it can address multiple controllers at the same time. It seems like a useful thing, so I figured I'd share it.

PyANC350v4.py

  • Moved Positioner.discover() outside the Positioner class to be its own function.
  • Added a Positioner.__del__() method for safer garbage collection.
  • Removed unused imports.

ANC350libv4.py

  • Made the DLL import more concise with pathlib instead of os.
  • Removed unused imports.

example-v4.py

  • Refactored to match above changes.

Also, my IDE made a few changes to adhere to current PEP8 convention.

…ly in v4.

PyANC350v4.py
 - Moved Positioner.discover() outside the Positioner class to be its own function.
 - Added a Positioner.__del__() method for safer garbage collection.
 - Removed unused imports.

ANC350libv4.py
 - Made the DLL import more concise with pathlib instead of os.
 - Removed unused imports.

example-v4.py
 - Refactored to match above changes.

Also, my IDE made a few changes to adhere to current PEP8 convention.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant