Skip to content

Commit

Permalink
Cleaned up documentation for labjack support.
Browse files Browse the repository at this point in the history
  • Loading branch information
canismarko committed Nov 21, 2023
1 parent fe3d0ed commit f756fd6
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 22 deletions.
47 changes: 25 additions & 22 deletions apstools/devices/labjack.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
"""Ophyd definitions for Labjack T-series data acquisition devices.
"""
LabJack Data Acquisition (DAQ)
+++++++++++++++++++++++++++++++++++++++
.. autosummary::
~LabJackBase
Supported devices:
Ophyd definitions for Labjack T-series data acquisition devices.
Supported devices, all inherit from ``LabJackBase``:
- T4
- T7
Expand Down Expand Up @@ -40,8 +49,8 @@ class MyBeamline(Device):
from apstools.synApps import EpicsRecordOutputFields


__all__ = ["AnalogOutput", "AnalogInput", "DigitalIO", "WaveformDigitizer",
"WaveformGenerator", "LabJackT4", "LabJackT7", "LabJackT7Pro", "LabJackT8"]
__all__ = ["AnalogOutput", "AnalogInput", "DigitalIO", "WaveformDigitizer", "make_digitizer_waveforms",
"WaveformGenerator", "LabJackBase", "LabJackT4", "LabJackT7", "LabJackT7Pro", "LabJackT8"]


class Input(EpicsRecordInputFields, EpicsRecordDeviceCommonAll):
Expand Down Expand Up @@ -132,7 +141,7 @@ class DigitalIO(Device):
dio3 = DigitalIO("LabJackT7_1:", name="dio3", ch_num=3)
This will create signals for the input (``Bi3``), output
(``Bo3``), direction (``Bd3``) records.
(``Bo3``), and direction (``Bd3``) records.
"""
ch_num: int
Expand All @@ -151,8 +160,9 @@ class WaveformDigitizer(Device):
By itself, this device does not include any actual data. It should
be sub-classed for the individual T-series devices to use
``make_digitizer_waveforms`` to produce waveform signals based on
the number of inputs, using the ophyd DynamicDeviceComponent.
:py:func:`~apstools.devices.labjack.make_digitizer_waveforms` to
produce waveform signals based on the number of inputs, using the
ophyd DynamicDeviceComponent.
.. code:: python
Expand Down Expand Up @@ -201,16 +211,6 @@ def make_digitizer_waveforms(num_ais: int):
class WaveformGenerator(Device):
"""A feature of the Labjack devices that generates output waveforms.
By itself, this device does not include any actual data. It should
be sub-classed for the individual T-series devices to use
``make_digitizer_waveforms`` to produce waveform signals based on
the number of inputs, using the ophyd DynamicDeviceComponent.
.. code:: python
class T7Digitizer(WaveformDigitizer):
waveforms = DCpt(make_digitizer_waveforms(14), kind="normal")
"""
external_trigger = Cpt(EpicsSignal, "WaveGenExtTrigger", kind=Kind.config) # config
external_clock = Cpt(EpicsSignal, "WaveGenExtClock", kind=Kind.config) # config
Expand Down Expand Up @@ -316,14 +316,17 @@ def make_digital_ios(num_dios: int):
class LabJackBase(Device):
"""A labjack T-series data acquisition unit (DAQ).
To use the individual components separately, consider using the
corresponding devices in the list below.
This device contains signals for the following:
- device information (e.g. firmware version ,etc)
- analog outputs
- analog inputs*
- digital input/output*
- waveform digitizer*
- waveform generator
- analog outputs (:py:class:`~apstools.devices.labjack.AnalogInput`)
- analog inputs* (:py:class:`~apstools.devices.labjack.AnalogOutput`)
- digital input/output* (:py:class:`~apstools.devices.labjack.DigitalIO`)
- waveform digitizer* (:py:class:`~apstools.devices.labjack.WaveformDigitizer`)
- waveform generator (:py:class:`~apstools.devices.labjack.WaveformGenerator`)
* The number of inputs and digital outputs depends on the specific
LabJack T-series device being used. Therefore, the base device
Expand Down
5 changes: 5 additions & 0 deletions docs/source/api/_devices.rst
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,11 @@ Other Support
~apstools.devices.struck3820.Struck3820
~apstools.devices.delay.DG645Delay
~apstools.devices.labjack.LabJackBase
~apstools.devices.labjack.LabJackT4
~apstools.devices.labjack.LabJackT7
~apstools.devices.labjack.LabJackT7Pro
~apstools.devices.labjack.LabJackT8


Internal Routines
+++++++++++++++++
Expand Down

0 comments on commit f756fd6

Please sign in to comment.