Skip to content

Conversation

@astroloba
Copy link
Contributor

@astroloba astroloba commented Jun 24, 2025

4 small improvements:

  • Corrected NotImplemented to NotImplementedError for all instances in daq_move and daq_viewer files.
  • Corrected indent of .stop_motion() code in daq_move to set it the same as other methods in the class.
  • Added calls to .axis_unit to explicitly set the DataActuator unit used (for getting current value and for conversion before sending to controller methods) to the one configured in the class parameters.
  • Switched to new implementation of master/slave declaration in .close(), .ini_stage() (daq_move) and .ini_detector() (daq_viewerxD)

@astroloba astroloba force-pushed the features/daqmove_improvements branch from 5439446 to 62cdef5 Compare June 24, 2025 12:16
Copy link
Contributor

@seb5g seb5g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After discussion we should add a self.is_!aster clause in the close methods

"""Terminate the communication protocol"""
## TODO for your custom plugin
raise NotImplemented # when writing your own plugin remove this line
raise NotImplementedError # when writing your own plugin remove this line
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe we should add a self.is_master clause??

def close(self):
"""Terminate the communication protocol"""
## TODO for your custom plugin
raise NotImplemented # when writing your own plugin remove this line
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see my other comment

def close(self):
"""Terminate the communication protocol"""
## TODO for your custom plugin
raise NotImplemented # when writing your own plugin remove this line
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see my other comment

@astroloba
Copy link
Contributor Author

Commit d56df09 proposes a master/slave implementation in .stop(). Note that the ... is required, or else Python will trigger an IndentationError.

@seb5g seb5g merged commit 97907be into PyMoDAQ:5.0.x Jul 1, 2025
0 of 24 checks passed
@seb5g
Copy link
Contributor

seb5g commented Jul 1, 2025

thks for this first PyMoDAQ PR

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