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

Add pins rep cap #1122

Merged
merged 3 commits into from
Nov 15, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ All notable changes to this project will be documented in this file.
* #### Removed
* ### NI-Digital Pattern Driver
* #### Added
* `pins` is now a valid repeated capability
* #### Changed
* Fix get/set properties - [#1062](https://github.com/ni/nimi-python/issues/1062)
* Removed array-size parameter from apply_tdr_offsets() and write_source_waveform_broadcast_u32() methods - [#1070](https://github.com/ni/nimi-python/issues/1070)
Expand Down
12 changes: 12 additions & 0 deletions docs/nidigital/class.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3384,6 +3384,18 @@ channels
passes a string of :python:`'0, 1, 2'` to the set attribute function.


pins
----

.. py:attribute:: nidigital.Session.pins[]

.. code:: python

session.pins['0-2'].channel_enabled = True
Copy link
Member

Choose a reason for hiding this comment

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

This is not a good example. How difficult is it to do something nidigital specific?
#1125 created


passes a string of :python:`'0, 1, 2'` to the set attribute function.
Copy link
Member

Choose a reason for hiding this comment

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

We need to stop documenting implementation details. The customer doesn't have to know or care how this ends up calling into the C API.

#1126 created




Properties
==========
Expand Down
1 change: 1 addition & 0 deletions generated/nidigital/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -1833,6 +1833,7 @@ def __init__(self, resource_name, id_query=False, reset_device=False, options={}

# Instantiate any repeated capability objects
self.channels = _RepeatedCapabilities(self, '')
self.pins = _RepeatedCapabilities(self, '')

self.tclk = nitclk.SessionReference(self._vi)

Expand Down
6 changes: 5 additions & 1 deletion src/nidigital/metadata/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@
{
'prefix': '',
'python_name': 'channels'
}
},
{
'prefix': '',
'python_name': 'pins',
},
],
'session_class_description': 'An NI-Digital session',
'session_handle_parameter_name': 'vi',
Expand Down