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

Update measurement link examples to match dcpower example changes. #284

Merged
merged 23 commits into from
Jun 14, 2023

Conversation

subash-suresh
Copy link
Contributor

TODO: Check the above box with an 'x' indicating you've read and followed CONTRIBUTING.md.

What does this Pull Request accomplish?

This Pull request updates the measurement link examples to match the changes recently done in the NI DC power examples.
The updates are as follows,

  1. Created new driver specific helper files which contains the session creation logic.
  2. Update the general helper files to match the updates done in ni dcpower example.
  3. Update the reservation and session creation logic to match the updates done in ni dcpower example.

Why should this Pull Request be merged?

Updates the measurement link example files to match the latest changes done to measurement service and the helpers.

What testing has been done?

Manually ran all the tests and verified the functionality of them.

@subash-suresh
Copy link
Contributor Author

I would like to get some thoughts on moving the helpers.py into the measurement service module, so that it could be accessible by all the examples and measurements using them.

@dixonjoel
Copy link
Collaborator

I would like to get some thoughts on moving the helpers.py into the measurement service module, so that it could be accessible by all the examples and measurements using them.

The argument that I've heard against doing that is we would have to maintain that code with backwards compatibility going forward and that we didn't want to take that responsibility on for example code.
@bkeryan may have some other thoughts.

@bkeryan
Copy link
Collaborator

bkeryan commented Jun 8, 2023

The argument that I've heard against doing that is we would have to maintain that code with backwards compatibility going forward and that we didn't want to take that responsibility on for example code. @bkeryan may have some other thoughts.

That's exactly right.

Copy link
Collaborator

@bkeryan bkeryan left a comment

Choose a reason for hiding this comment

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

Many of these issues apply to multiple examples.

examples/nidaqmx_analog_input/_nidaqmx_helpers.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/_nidaqmx_helpers.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/measurement.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/measurement.py Outdated Show resolved Hide resolved
examples/nidigital_spi/_nidigital_helpers.py Outdated Show resolved Hide resolved
examples/nidigital_spi/measurement.py Show resolved Hide resolved
examples/nidmm_measurement/_nidmm_helpers.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/measurement.py Show resolved Hide resolved
@subash-suresh subash-suresh requested a review from bkeryan June 12, 2023 12:25
Copy link
Collaborator

@bkeryan bkeryan left a comment

Choose a reason for hiding this comment

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

Oops, we overlooked the TestStand fixtures, which are the reason we're adding the create_session helpers in the first place.

examples/nidaqmx_analog_input/_helpers.py Outdated Show resolved Hide resolved
examples/nidigital_spi/_nidigital_helpers.py Outdated Show resolved Hide resolved
examples/nivisa_dmm_measurement/measurement.py Outdated Show resolved Hide resolved
@subash-suresh subash-suresh requested a review from bkeryan June 13, 2023 07:15
examples/nidaqmx_analog_input/_helpers.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/_helpers.py Outdated Show resolved Hide resolved
examples/nivisa_dmm_measurement/measurement.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/teststand_fixture.py Outdated Show resolved Hide resolved
examples/nidmm_measurement/teststand_fixture.py Outdated Show resolved Hide resolved
@subash-suresh subash-suresh requested a review from bkeryan June 13, 2023 15:33
Copy link
Collaborator

@bkeryan bkeryan left a comment

Choose a reason for hiding this comment

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

Approved with suggestions

examples/nidaqmx_analog_input/teststand_fixture.py Outdated Show resolved Hide resolved
examples/nidaqmx_analog_input/teststand_fixture.py Outdated Show resolved Hide resolved
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.

3 participants