@@ -180,12 +180,12 @@ def readADCSingleEnded(self, channel=0, pga=6144, sps=250):
180
180
config |= self .spsADS1015 .setdefault (sps , self .__ADS1015_REG_CONFIG_DR_1600SPS )
181
181
else :
182
182
if ( (sps not in self .spsADS1115 ) & self .debug ):
183
- print "ADS1x15: Invalid pga specified: %d, using 6144mV " % sps
183
+ print "ADS1x15: Invalid sps specified: %d, using 250SPS " % sps
184
184
config |= self .spsADS1115 .setdefault (sps , self .__ADS1115_REG_CONFIG_DR_250SPS )
185
185
186
186
# Set PGA/voltage range, defaults to +-6.144V
187
187
if ( (pga not in self .pgaADS1x15 ) & self .debug ):
188
- print "ADS1x15: Invalid pga specified: %d, using 6144mV" % sps
188
+ print "ADS1x15: Invalid pga specified: %d, using 6144mV" % pga
189
189
config |= self .pgaADS1x15 .setdefault (pga , self .__ADS1015_REG_CONFIG_PGA_6_144V )
190
190
self .pga = pga
191
191
@@ -211,7 +211,7 @@ def readADCSingleEnded(self, channel=0, pga=6144, sps=250):
211
211
# We add 0.1ms to be sure
212
212
delay = 1.0 / sps + 0.0001
213
213
time .sleep (delay )
214
-
214
+
215
215
# Read the conversion results
216
216
result = self .i2c .readList (self .__ADS1015_REG_POINTER_CONVERT , 2 )
217
217
if (self .ic == self .__IC_ADS1015 ):
@@ -263,7 +263,7 @@ def readADCDifferential(self, chP=0, chN=1, pga=6144, sps=250):
263
263
config |= self .spsADS1015 .setdefault (sps , self .__ADS1015_REG_CONFIG_DR_1600SPS )
264
264
else :
265
265
if ( (sps not in self .spsADS1115 ) & self .debug ):
266
- print "ADS1x15: Invalid pga specified: %d, using 6144mV " % sps
266
+ print "ADS1x15: Invalid sps specified: %d, using 250sps " % sps
267
267
config |= self .spsADS1115 .setdefault (sps , self .__ADS1115_REG_CONFIG_DR_250SPS )
268
268
269
269
# Set PGA/voltage range, defaults to +-6.144V
@@ -366,12 +366,12 @@ def startContinuousConversion(self, channel=0, pga=6144, sps=250):
366
366
config |= self .spsADS1015 .setdefault (sps , self .__ADS1015_REG_CONFIG_DR_1600SPS )
367
367
else :
368
368
if ( (sps not in self .spsADS1115 ) & self .debug ):
369
- print "ADS1x15: Invalid pga specified: %d, using 6144mV " % sps
369
+ print "ADS1x15: Invalid sps specified: %d, using 250SPS " % sps
370
370
config |= self .spsADS1115 .setdefault (sps , self .__ADS1115_REG_CONFIG_DR_250SPS )
371
371
372
372
# Set PGA/voltage range, defaults to +-6.144V
373
373
if ( (pga not in self .pgaADS1x15 ) & self .debug ):
374
- print "ADS1x15: Invalid pga specified: %d, using 6144mV" % sps
374
+ print "ADS1x15: Invalid pga specified: %d, using 6144mV" % pga
375
375
config |= self .pgaADS1x15 .setdefault (pga , self .__ADS1015_REG_CONFIG_PGA_6_144V )
376
376
self .pga = pga
377
377
@@ -439,12 +439,12 @@ def startContinuousDifferentialConversion(self, chP=0, chN=1, pga=6144, sps=250)
439
439
config |= self .spsADS1015 .setdefault (sps , self .__ADS1015_REG_CONFIG_DR_1600SPS )
440
440
else :
441
441
if ( (sps not in self .spsADS1115 ) & self .debug ):
442
- print "ADS1x15: Invalid pga specified: %d, using 6144mV " % sps
442
+ print "ADS1x15: Invalid sps specified: %d, using 250SPS " % sps
443
443
config |= self .spsADS1115 .setdefault (sps , self .__ADS1115_REG_CONFIG_DR_250SPS )
444
444
445
445
# Set PGA/voltage range, defaults to +-6.144V
446
446
if ( (pga not in self .pgaADS1x15 ) & self .debug ):
447
- print "ADS1x15: Invalid pga specified: %d, using 6144mV" % sps
447
+ print "ADS1x15: Invalid pga specified: %d, using 6144mV" % pga
448
448
config |= self .pgaADS1x15 .setdefault (pga , self .__ADS1015_REG_CONFIG_PGA_6_144V )
449
449
self .pga = pga
450
450
0 commit comments