Ejemplo n.º 1
0
 def setResolution(self, resolution):
     self.resolution = resolution.upper()
     _resolution = ps.PS5000A_DEVICE_RESOLUTION['PS5000A_DR_' +
                                                self.resolution.upper()]
     self.status['setRes'] = ps.ps5000aSetDeviceResolution(
         self.chandle, _resolution)
     assert_pico_ok(self.status['setRes'])
 def resolution(self,value,at_startup=False):
     value = value.upper()
     possible_values = [str(r)+'BIT' for r in [8,12,14,15,16]]
     assert value in possible_values, 'resolution can be 8,12,14, 15 or 16BIT'
     res = ps.PS5000A_DEVICE_RESOLUTION["PS5000A_DR_"+value.upper()]
     status = ps.ps5000aSetDeviceResolution(self.chandle,res)
     assert_pico_ok(status)
     self.settings['resolution'] = value
Ejemplo n.º 3
0
 def setResolution(self, reso):
     if (reso >= 8 and reso <= 16):
         command = "PS5000A_DR_{0}BIT".format(reso)
     self.resolution = ps.PS5000A_DEVICE_RESOLUTION[command]
     self.status["resolution"] = ps.ps5000aSetDeviceResolution(
         self.chandle, self.resolution)
Ejemplo n.º 4
0
 def set_resolution(self, resolution): # Change resolution
     device_resolution = ps.PS5000A_DEVICE_RESOLUTION[resolution]
     self.status["setResolution"] = ps.ps5000aSetDeviceResolution(self.chandle, device_resolution)
     self.status["maximumValue"] = ps.ps5000aMaximumValue(self.chandle, ctypes.byref(self.maxADC))