From f222b5f449af3db638101420070c8b9d78abe95a Mon Sep 17 00:00:00 2001 From: "Eugeniy E. Mikhailov" Date: Sat, 13 Jul 2024 22:35:45 -0400 Subject: better doc string --- qolab/hardware/scope/__init__.py | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'qolab') diff --git a/qolab/hardware/scope/__init__.py b/qolab/hardware/scope/__init__.py index bf9df60..80e9cb2 100644 --- a/qolab/hardware/scope/__init__.py +++ b/qolab/hardware/scope/__init__.py @@ -1,5 +1,6 @@ """ Provide basic class to operate scope + Created by Eugeniy E. Mikhailov 2021/11/29 """ from qolab.hardware.scpi import SCPIinstr @@ -8,8 +9,12 @@ from qolab.data.trace import TraceSetSameX import yaml class Scope(BasicInstrument): + """Minimal class to implement a scope. + + Intended to be used as a parent for hardware aware scopes. - # Minimal set of methods to be implemented by a scope. + Provide a minimal set of methods to be implemented by a scope. + """ def __init__(self, *args, **kwds): BasicInstrument.__init__(self, *args, **kwds) self.config['Device type']='Scope' @@ -70,10 +75,15 @@ class Scope(BasicInstrument): class ScopeSCPI(SCPIinstr, Scope): - """ - Do not instantiate directly, use - rm = pyvisa.ResourceManager() - ScopeSCPI(rm.open_resource('TCPIP::192.168.0.2::INSTR')) + """SCPI aware scope. + + Use as a parent for a hardware aware scope classes. + + Example + ------- + + >>> rm = pyvisa.ResourceManager() + >>> ScopeSCPI(rm.open_resource('TCPIP::192.168.0.2::INSTR')) """ def __init__(self, resource, *args, **kwds): SCPIinstr.__init__(self, resource) -- cgit v1.2.3