Skip to content

Commit

Permalink
Merge pull request #171 from bmoneke/ps4824-setChannel
Browse files Browse the repository at this point in the history
Ps4824 set channel fixed
  • Loading branch information
hmaarrfk authored Aug 10, 2021
2 parents 3b79245 + ee03abb commit 62cb0bd
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions picoscope/ps4000a.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,11 +228,13 @@ def _lowLevelSetChannel(self, chNum, enabled, coupling, VRange, VOffset,
c_int16(enabled), c_enum(coupling),
c_enum(VRange), c_float(VOffset))
self.checkResult(m)

m = self.lib.ps4000aSetBandwidthFilter(c_int16(self.handle),
c_enum(chNum),
c_enum(BWLimited))
self.checkResult(m)
# Only for model PS4444
# See discussion: https://github.com/colinoflynn/pico-python/pull/171
if self.model.startswith('4444'): # Only for model 4444
m = self.lib.ps4000aSetBandwidthFilter(c_int16(self.handle),
c_enum(chNum),
c_enum(BWLimited))
self.checkResult(m)

def _lowLevelStop(self):
m = self.lib.ps4000aStop(c_int16(self.handle))
Expand Down Expand Up @@ -454,6 +456,10 @@ def _lowLevelSetDataBufferBulk(self, channel, data, segmentIndex,
self._lowLevelSetDataBuffer(channel, data, downSampleMode,
segmentIndex)

def _lowLevelPingUnit(self):
"""Check connection to picoscope and return the error."""
return self.lib.ps4000aPingUnit(c_int16(self.handle))

####################################################################
# Untested functions below #
# #
Expand Down

0 comments on commit 62cb0bd

Please sign in to comment.