Skip to content

BeagleBone Green - "RuntimeError: Unknown error" python PWM.start #342

@deelerke

Description

@deelerke

Hi, I'm trying to get this working on a Beaglebone Green with Debian Buster (Linux beaglebone 5.4.38-ti-r8)

root@beaglebone:~# python pwmtest.py
Traceback (most recent call last):
  File "pwmtest.py", line 2, in <module>
    pwm.start("P9_14",50);
RuntimeError: Unknown error

root@beaglebone:~# cat pwmtest.py
import Adafruit_BBIO.PWM as pwm
pwm.start("P9_14",50);
pwm.stop("P9_14");

root@beaglebone:~# /opt/scripts/tools/version.sh
git:/opt/scripts/:[ef16ffa8c27225005cc2b2c974a83da3dee6c1ef]
eeprom:[A335BNLTBBG1BBG217110074]
model:[TI_AM335x_BeagleBone_Green]
dogtag:[BeagleBoard.org Debian Buster Console Image 2020-05-18]
bootloader:[microSD-(push-button)]:[/dev/mmcblk0]:[U-Boot 2019.04-00002-g31a8ae0206]:[location: dd MBR]
UBOOT: Booted Device-Tree:[am335x-boneblack-uboot-univ.dts]
UBOOT: Loaded Overlay:[AM335X-PRU-RPROC-4-19-TI-00A0]
UBOOT: Loaded Overlay:[BB-ADC-00A0]
UBOOT: Loaded Overlay:[M-BB-BBG-00A0]
kernel:[5.4.38-ti-r8]
/boot/uEnv.txt Settings:
uboot_overlay_options:[enable_uboot_overlays=1]
uboot_overlay_options:[disable_uboot_overlay_emmc=1]
uboot_overlay_options:[disable_uboot_overlay_video=1]
uboot_overlay_options:[disable_uboot_overlay_audio=1]
uboot_overlay_options:[disable_uboot_overlay_wireless=1]
uboot_overlay_options:[uboot_overlay_pru=/lib/firmware/AM335X-PRU-RPROC-4-19-TI-00A0.dtbo]
uboot_overlay_options:[enable_uboot_cape_universal=1]
pkg check: to individually upgrade run: [sudo apt install --only-upgrade <pkg>]
pkg:[bb-cape-overlays]:[4.14.20200814.0-0~buster+20200814]
pkg:[bb-wl18xx-firmware]:[1.20200813.1-0~buster+20200813]
pkg:[kmod]:[26-1]
WARNING:pkg:[librobotcontrol]:[NOT_INSTALLED]
pkg:[firmware-ti-connectivity]:[20190717-2rcnee1~buster+20200305]
groups:[debian : debian adm kmem dialout cdrom floppy audio dip video plugdev users systemd-journal input bluetooth netdev gpio pwm eqep remoteproc admin spi iio i2c docker tisdk weston-launch xenomai cloud9ide]
cmdline:[console=ttyO0,115200n8 bone_capemgr.uboot_capemgr_enabled=1 root=/dev/mmcblk0p1 ro rootfstype=ext4 rootwait coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100 quiet]
dmesg | grep remote
[    2.534070] remoteproc remoteproc0: wkup_m3 is available
[    2.757005] remoteproc remoteproc1: 4a334000.pru is available
[    2.758730] remoteproc remoteproc2: 4a338000.pru is available
[    2.763043] remoteproc remoteproc0: powering up wkup_m3
[    2.763202] remoteproc remoteproc0: Booting fw image am335x-pm-firmware.elf, size 217168
[    2.767376] remoteproc remoteproc0: remote processor wkup_m3 is now up
dmesg | grep pru
[    2.757005] remoteproc remoteproc1: 4a334000.pru is available
[    2.757173] pru-rproc 4a334000.pru: PRU rproc node /ocp/interconnect@4a000000/segment@0/target-module@300000/pruss@0/pru@34000 probed successfully
[    2.758730] remoteproc remoteproc2: 4a338000.pru is available
[    2.758899] pru-rproc 4a338000.pru: PRU rproc node /ocp/interconnect@4a000000/segment@0/target-module@300000/pruss@0/pru@38000 probed successfully
dmesg | grep pinctrl-single
[    1.765188] pinctrl-single 44e10800.pinmux: 142 pins, size 568
dmesg | grep gpio-of-helper
[    1.779887] gpio-of-helper ocp:cape-universal: ready
END

and this is my /boot/uEnv.txt

root@beaglebone:~# cat /boot/uEnv.txt | grep -v '#'

uname_r=5.4.38-ti-r8

enable_uboot_overlays=1
disable_uboot_overlay_emmc=1
disable_uboot_overlay_video=1
disable_uboot_overlay_audio=1
disable_uboot_overlay_wireless=1
uboot_overlay_pru=/lib/firmware/AM335X-PRU-RPROC-4-19-TI-00A0.dtbo
enable_uboot_cape_universal=1

cmdline=coherent_pool=1M net.ifnames=0 lpj=1990656 rng_core.default_quality=100 quiet

thanks in advance for your suggestions

Dieter

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions