Skip to content

Commit

Permalink
Merge pull request #1065 from BenediktBurger/fix-ibeamsmart
Browse files Browse the repository at this point in the history
Fix toptica ibeamsmart referencing removed adapter function.
  • Loading branch information
BenediktBurger committed May 4, 2024
2 parents 08d4982 + 931cb1b commit 64565ed
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pymeasure/instruments/toptica/ibeamsmart.py
Expand Up @@ -146,7 +146,7 @@ def read(self):
before the '[OK]'
Value extraction: extract <value> from 'name = <value> [unit]'.
If <value> can not be identified the orignal string is returned.
If <value> can not be identified the original string is returned.
:return: string containing the ASCII response of the instrument (without '[OK]').
"""
Expand All @@ -164,7 +164,7 @@ def read(self):
except VisaIOError:
reply = '\n'.join(msg)
try:
self.adapter.connection.flush_read_buffer()
self.adapter.flush_read_buffer()
except AttributeError:
log.warning("Adapter does not have 'flush_read_buffer' method.")
raise ValueError(f"Flush buffer failed after '{reply}'")
Expand All @@ -185,7 +185,7 @@ def check_set_errors(self):
reply = self.read()
if reply:
# anything else than '[OK]'.
self.adapter.connection.flush_read_buffer()
self.adapter.flush_read_buffer()
log.error(f"Setting a property failed with reply '{reply}'.")
raise ValueError(f"Setting a property failed with reply '{reply}'.")
return []
Expand Down

0 comments on commit 64565ed

Please sign in to comment.