Re: [libgpiod] How can I use PWM

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Aug 6, 2022 at 3:40 PM Kent Gibson <warthog618@xxxxxxxxx> wrote:
> On Sat, Aug 06, 2022 at 12:12:31PM +0200, Andy Shevchenko wrote:
> > On Fri, Aug 5, 2022 at 1:17 PM Robert Baumgartner <rbaumgar@xxxxxxxxxx> wrote:

...

> > No, you haven't missed anything except Unix ideology. That ideology is
> > telling us that one tool for one thing, and in very featurable mode.
> > That said, lingpiod is exclusively for GPIO ABI between kernel and
> > user space. For PWM you need to access the PWM ABI in a way how it's
> > represented by the Linux kernel. I believe there are plenty of
> > libraries more or less okayish for that purpose, but I never heard
> > about any official library and/or Python bindings for it.
>
> I'm assuming Robert is refering to software PWM.

I don't think so. The article he referenced clearly tells about two
(hardware!) PWMs.

> AFAIAA Rpi.GPIO doesn't
> support hardware PWM, and the referenced article also refers to software
> PWM for the Python case.
>
> libgpiod doesn't directly support software PWM, but it is fairly
> straight forward to implement yourself using libgpiod.

Hmm... I was under the impression that we have pwm-gpio in the
kernel... Can't find quickly if there is one.

-- 
With Best Regards,
Andy Shevchenko



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux