https://github.com/DFRobot/DFRobot_RaspberryPi_Motor/blob/28c6fb77f35d09a336170e37c26cfadd53edf2f6/python/raspberryPi/DFRobot_RaspberryPi_DC_Motor.py#L162 Why you say that frequency is 1000Hz, if in the library you divide value 1000 by 50? Then value "frequency" becomes 20.