Can anyone give me the program for controlling PWM by wiringpi through python programming? I have already searched on the net but could only find program through C programming.

  • This answer might help, but not WiringPi: How can Rpi move a servo motor using a GPIO pin in PWM mode? raspberrypi.stackexchange.com/questions/98467/…. – tlfong01 Feb 1 at 14:59
  • 1
    What do you want to control with PWM? Here is an LED controlled by PWM using gpiozero gpiozero.readthedocs.io/en/stable/… WiringPi is deprecated! – CoderMike Feb 1 at 15:02
  • 1
    Actually I want to control something with 50 KHZ frequency with variable duty cycle. But first I want to get the 50 KHZ frequency PWM with best accuracy. I tried to get this with RPI library but it gives me desired accuracy upto 5 KHZ only. Then I read somewhere that with wiringpi library, we can get PWM frequency upto 19.2 MHZ. But I am yet to find the program through python language. – Abhilash Wakodikar Feb 1 at 15:49
  • 1
    Please edit those additional details into the question and I will re-open it. – goldilocks Feb 1 at 17:00

Browse other questions tagged or ask your own question.