]> Repositories - Adafruit_Blinka-hackapet.git/commitdiff
Merge pull request #126 from brentru/fix-period-property 2.0.2
authorMelissa LeBlanc-Williams <melissa@makermelissa.com>
Thu, 6 Jun 2019 20:47:40 +0000 (13:47 -0700)
committerGitHub <noreply@github.com>
Thu, 6 Jun 2019 20:47:40 +0000 (13:47 -0700)
Add property to period method

src/adafruit_blinka/microcontroller/generic_linux/sysfs_pwmout.py

index d0686f71cdf3ae4b1646b690940d07ec22732e26..fa7266710cbec98c61b5772757e11a29f0a5437c 100644 (file)
@@ -179,6 +179,8 @@ class PWMOut(object):
         # Update our cached period
         self._period = float(period)
 
+    period = property(_get_period, _set_period)
+
     """Get or set the PWM's output period in seconds.
 
     Raises: