]> Repositories - Adafruit_Blinka-hackapet.git/commit
Add PWMOut for PocketBeagle #159
authorDrew Fustini <drew@pdp7.com>
Sat, 26 Oct 2019 19:03:09 +0000 (21:03 +0200)
committerDrew Fustini <drew@pdp7.com>
Sat, 26 Oct 2019 20:08:26 +0000 (22:08 +0200)
commit824d525493acfb26728ca74e183417e4a58aaa23
tree9656a0533224aba020c6ddbcd37c9284b32ba1bf
parentcc3f8eccf2dda19777ed270a956d5fc8f201628d
Add PWMOut for PocketBeagle #159

Add PWMOut for PocketBeagle which has the AM3358 SoC.

Note that the generic linux PWMOut implementation will
not work as BeagleBoard.org kernel has a patch to allow
udev to be able to set the ownership and permissions
in /sys/class/pwm when channels are exported.  However,
this naming scheme is different than what is used in the
mainline kernel.

The PocketBeagle has these PWM outputs:

/sys/class/pwm/pwmchip0/pwm-0:0/period
/sys/class/pwm/pwmchip0/pwm-0:1/period
/sys/class/pwm/pwmchip2/pwm-2:0/period
/sys/class/pwm/pwmchip2/pwm-2:1/period
/sys/class/pwm/pwmchip4/pwm-4:0/period
/sys/class/pwm/pwmchip4/pwm-4:1/period

Here is the kernel patch that is being used:
https://github.com/RobertCNelson/bb-kernel/blob/am33x-v4.11/patches/drivers/pwm/0001-pwm-Create-device-class-for-pwm-channels.p$
src/adafruit_blinka/board/beaglebone_pocketbeagle.py
src/adafruit_blinka/microcontroller/am335x/pin.py
src/adafruit_blinka/microcontroller/am335x/sysfs_pwmout.py [new file with mode: 0644]
src/pulseio.py