From fd3f66b8325ec7cacf126e91a9e446b183efff4d Mon Sep 17 00:00:00 2001 From: Ben Nuttall Date: Mon, 5 Oct 2015 12:09:35 +0100 Subject: [PATCH] Ensure PWMOutputDevice pin argument not mandatory, close #43 --- gpiozero/output_devices.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gpiozero/output_devices.py b/gpiozero/output_devices.py index 5dc8f28..1a3213c 100644 --- a/gpiozero/output_devices.py +++ b/gpiozero/output_devices.py @@ -156,7 +156,7 @@ class PWMOutputDevice(DigitalOutputDevice): """ Generic Output device configured for PWM (Pulse-Width Modulation). """ - def __init__(self, pin): + def __init__(self, pin=None): super(PWMOutputDevice, self).__init__(pin) self._frequency = 100 self._pwm = GPIO.PWM(self._pin, self._frequency)