Skip to content

Commit 1c58246

Browse files
committed
Call PWM functions for PWM devices.
1 parent 2466a90 commit 1c58246

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

myDevices/sensors/sensors.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,14 +253,14 @@ def SensorsInfo(self):
253253
if value['type'] == 'Distance':
254254
value['Centimeter'] = self.CallDeviceFunction(sensor.getCentimeter)
255255
value['Inch'] = self.CallDeviceFunction(sensor.getInch)
256-
if value['type'] in ('ADC', 'DAC', 'PWM'):
256+
if value['type'] in ('ADC', 'DAC'):
257257
value['channelCount'] = self.CallDeviceFunction(sensor.analogCount)
258258
value['maxInteger'] = self.CallDeviceFunction(sensor.analogMaximum)
259259
value['resolution'] = self.CallDeviceFunction(sensor.analogResolution)
260260
value['allInteger'] = self.CallDeviceFunction(sensor.analogReadAll)
261261
value['allVolt'] = self.CallDeviceFunction(sensor.analogReadAllVolt)
262262
value['allFloat'] = self.CallDeviceFunction(sensor.analogReadAllFloat)
263-
if value['type'] in ('DAC'):
263+
if value['type'] == 'DAC':
264264
value['vref'] = self.CallDeviceFunction(sensor.analogReference)
265265
if value['type'] == 'PWM':
266266
value['channelCount'] = self.CallDeviceFunction(sensor.pwmCount)

0 commit comments

Comments
 (0)