Closed alcalyn closed 3 years ago
+1 to that question! I've been wondering how to use PWM with this library.
This library uses the sysfs
driver for controlling the GPIO pins, and this driver doesn't support PWM.
I'd suggest using a library such as phpi as it uses different kernel interfaces to control the pins and can thus support PWM.
Sorry!
It does seem like there is a possible approach that uses a driver similar to the sysfs driver.
If anyone reading this wants to have a crack at PiPHP/PWM
- I'd be more than happy to support.
I've set up a PiPHP/PWM repo that people can fork from if they want to play around with this as a project.
I've stripped it down to a single pin class, and you can see most of the important changes in this diff.
Seems like this has been resolved via https://github.com/piphp/pwm.
I didn't found any PWM support in this library, how do you achieve this ?