EdgePi-Cloud / edgepi-python-sdk

Python SDK to control EdgePi, an industrial PC/PLC/IoT device powered by Raspberry Pi CM4
MIT License
5 stars 3 forks source link

Type discrepancy for duty_cycle in pwm module #404

Open josiah-tesfu opened 10 months ago

josiah-tesfu commented 10 months ago

In edgepi_pwm.py, In set_config, duty_cycle and frequency should both be float. This should be reflected in both the type hints and the docstring. Currently, the type hints have duty_cycle as an int and frequency as a float, while the docstring has both as an int. The docstring should also change the parameter bounds from 0-100 to 0-1 to be consistent with _set_duty_cycle.