Skip to content

Conversation

@roesel
Copy link
Owner

@roesel roesel commented Jun 16, 2025

This pull request makes modifications to the src/elliptec/controller.py file to improve how the port parameter is handled and simplifies the code by removing unused methods. The most important changes include storing the port parameter as an instance variable, updating the logic in the __search_and_connect method to use the stored port, and removing the __enter__ and __exit__ methods.

Improvements to port handling:

  • src/elliptec/controller.py: The port parameter is now stored as an instance variable in the __init__ method, enabling better access and management of the port throughout the class.
  • src/elliptec/controller.py: Updated the __search_and_connect method to assign the port to the instance variable before passing it to the __connect_to_port method. This ensures consistent handling of the port.

Code simplification:

  • src/elliptec/controller.py: Removed the __enter__ and __exit__ methods, as they were unused and unnecessary for the current functionality of the class.

@roesel roesel mentioned this pull request Jun 16, 2025
@roesel roesel closed this Sep 8, 2025
@roesel roesel deleted the fix/port-setting branch September 8, 2025 21:20
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.

2 participants