The 'deinit' function is called each time a property value is read and written.
However, the duty cycle continues to reset, so the sysfs PWM does not work properly.
Signed-off-by: Steve Jeong <steve@how2flow.net>
def deinit(self):
"""Deinit the sysfs PWM."""
if self._channel is not None:
def deinit(self):
"""Deinit the sysfs PWM."""
if self._channel is not None:
try:
channel_path = os.path.join(
self._sysfs_path, self._channel_path.format(self._channel)
try:
channel_path = os.path.join(
self._sysfs_path, self._channel_path.format(self._channel)