Skip to content

Commit

Permalink
Merge pull request #153 from thennen/master
Browse files Browse the repository at this point in the history
Save the channel attenuation when using setChannel
  • Loading branch information
hmaarrfk authored Oct 22, 2019
2 parents a54cca0 + 4d094ee commit c0ea21c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions picoscope/picobase.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ def __init__(self, serialNumber=None, connect=True):
# the "true" voltage as seen at the oscilloscope probe
self.CHRange = [5.0] * self.NUM_CHANNELS
self.CHOffset = [0.0] * self.NUM_CHANNELS
self.CHCoupling = [1] * self.NUM_CHANNELS
self.ProbeAttenuation = [1.0] * self.NUM_CHANNELS

self.handle = None
Expand Down Expand Up @@ -265,6 +266,7 @@ def setChannel(self, channel='A', coupling="AC", VRange=2.0,
# if all was successful, save the parameters
self.CHRange[chNum] = VRange
self.CHOffset[chNum] = VOffset
self.CHCoupling[chNum] = coupling
self.ProbeAttenuation[chNum] = probeAttenuation

return VRange
Expand Down

0 comments on commit c0ea21c

Please sign in to comment.