Skip to content

Commit

Permalink
Adapt to zhinst-toolkit 0.5.2
Browse files Browse the repository at this point in the history
  • Loading branch information
tobiasah committed Feb 28, 2023
1 parent 2ee2496 commit e40b8fd
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 2 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# zhinst-qcodes Changelog

## Version 0.5.2
* Updated to zhinst-toolkit 0.5.2
* Added `find_zsync_worker_port` function to the PQSC

## Version 0.5.0
* Updated to zhinst-toolkit 0.5.0
* Added support for LabOne DAQ module
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ python_requires = >=3.7
use_scm_version = True
install_requires =
numpy>=1.13
zhinst-toolkit>=0.5.0
zhinst-toolkit>=0.5.2
qcodes>=0.30.0
typing_extensions>=4.1.1

Expand Down
20 changes: 19 additions & 1 deletion src/zhinst/qcodes/driver/devices/pqsc.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def check_ref_clock(self, *, timeout: int = 30, sleep_time: int = 1) -> bool:
requesting the reference clock status (default: 1)
Raises:
ToolkitError: If the process of locking to the reference clock
TimeoutError: If the process of locking to the reference clock
exceeds the specified timeout.
"""
return self._tk_object.check_ref_clock(timeout=timeout, sleep_time=sleep_time)
Expand Down Expand Up @@ -137,3 +137,21 @@ def check_zsync_connection(
return self._tk_object.check_zsync_connection(
ports=ports, timeout=timeout, sleep_time=sleep_time
)

def find_zsync_worker_port(self, device: ZIBaseInstrument) -> int:
"""Find the ID of the PQSC ZSync port connected to a given device.
Args:
pqsc: PQSC device over whose ports the research shall be done.
device: device for which the connected ZSync port shall be found.
Returns:
Integer value represent the ID of the searched PQSC Zsync port.
Raises:
ToolkitError: If the given device doesn't appear to be connected
to the PQSC via ZSync.
.. versionadded:: 0.5.1
"""
return self._tk_object.find_zsync_worker_port(device=device._tk_object)

0 comments on commit e40b8fd

Please sign in to comment.