vitormhenrique / OctoPrint-Enclosure

OctoPrint Enclosure Plugin
GNU General Public License v3.0
399 stars 203 forks source link

Hardware PWM using lightweight rpi_hardware_pwm library #474

Open shortbloke opened 2 years ago

shortbloke commented 2 years ago

Lightweight hardware PWM implementation with GUI configuration, allowing 25000 Hz PWM signal suitable for controlling Noctua PWM fans.

Another PR #442 but was criticised for needing pigpio and lacking UI configuration. This PR attempts so address the requirement whilst:

Fixes: #349

GerhardMassenbichler commented 2 years ago

Great Work. I like the small and lightweight rpi_hardware_pwm library instead of pigpio.

pipersw commented 1 year ago

Could you provide a binary for Raspbian ?

joh commented 1 year ago

Hi, what remains for this PR to be merged? :)

joh commented 1 year ago

Just tested this and it works great, thank you! Only snag was that installing rpi-hardware-pwm system-wide (as per instructions) didn't work on OctoPi, since OctoPrint runs in a virtual environment and won't see system-wide packages. Instead I had to install it in the virtual environment, like so:

source ~/oprint/bin/activate
pip install rpi-hardware-pwm

Perhaps the docs can be updated, or even better, that the package can be installed on demand by the plugin?