diff --git a/src/tekhsi/tek_hsi_connect.py b/src/tekhsi/tek_hsi_connect.py index d391935..8702f9e 100644 --- a/src/tekhsi/tek_hsi_connect.py +++ b/src/tekhsi/tek_hsi_connect.py @@ -7,7 +7,6 @@ from atexit import register from enum import Enum -from contextlib import contextmanager from typing import List, Optional, Dict @@ -214,7 +213,7 @@ def verbose(self, value: bool): ################################################################################################ # Context Manager Methods ################################################################################################ - @contextmanager + @contextlib.contextmanager def access_data(self, on: AcqWaitOn = AcqWaitOn.NewData, after: float = -1): """Grants access to data. @@ -650,7 +649,7 @@ def _read_waveform(self, header: WaveformHeader): ) sample_index = 0 - data_size = header.sourcewidth + unused_data_size = header.sourcewidth request = WaveformRequest(sourcename=header.sourcename, chunksize=self.chunksize) response_iterator = self.native.GetWaveform(request) dt = None