Found a solution -- turns out that I already have the dependencies satisfied, so the update to Adafruit_BBIO is relatively painless to install without the internet. Thanks, though!
On Tue, Aug 27, 2019 at 11:29 AM Dennis Lee Bieber <[email protected]> wrote: > On Mon, 26 Aug 2019 10:57:36 -0700 (PDT), Marius Strom > <[email protected]> declaimed the > following: > > > > ># pwm test script > >import Adafruit_BBIO.PWM as PWM > > > >out = "P1_36" > > > >PWM.start(out, 0,frequency=50) > > > >while(1): > > PWM.set_duty_cycle(out, 100) > > > >However, upon running this code, I get the following error message: > > > > NOTE: even ignoring the error problem the above code is rather, > uhm, > futile... > > You start with the PWM set to full OFF, then, in a fast running > loop > you repeatedly set it to full ON. You'd get the same result setting the pin > to GPIO mode: > > GPIO.setup(out, GPIO.OUT) > GPIO.output(out, GPIO.LOW) > while True: > GPIO.output(out, GPIO.HIGH) > > Additionally, > > while(1): > > appears to be a C-ism, the Pythonic/preferred form is > > while True: > > and as you can see, you likely wont notice anything on the output pin -- > the program sets up the pin at 0 and immediately sets it to 1, 1, 1, 1, 1. > > >Traceback (most recent call last): > > File "/var/lib/cloud9/pwm_test.py", line 6, in <module> > > PWM.start(out, 0,frequency=50) > >RuntimeError: Problem with the cape manager > > > > Have you attempted to set the pin from the command line using the > config-pin utility? (See the readme at > https://github.com/adafruit/adafruit-beaglebone-io-python ). If that fails > you may need to update the OS device trees etc. since adafruit internally > uses that to set the pin modes. Otherwise, an update of the adafruit > libraries might be needed (there was a PocketBeagle PWM fix in 1.1.0 "fix > pwm on pocketbeagle and beaglebone blue #286" . OR a bug report filed with > AdaFruit. > > >I already looked at > >https://github.com/adafruit/adafruit-beaglebone-io-python/issues/262, > which > >did not work for me, and > >https://github.com/adafruit/adafruit-beaglebone-io-python/issues/286, > which > >I couldn't implement because I'm having difficulties connecting the > >Pocketbeagle to the internet. > > Okay -- so you have seen the report of the problem, and the > solution... > > Unfortunately -- since all potential solutions tend to require > updates > you'll have to figure out some way to get internet access (I would not > recommend trying to hand install the Adafruit libraries). > > Or /maybe/ download and flash a new SD card with either > > > http://debian.beagleboard.org/images/bone-debian-9.9-iot-armhf-2019-08-03-4gb.img.xz > > or > > > http://debian.beagleboard.org/images/bone-debian-9.9-lxqt-armhf-2019-08-03-4gb.img.xz > > and hope that those images include the Adafruit updates. (I'll admit, I'm > still running the 2018-10-07 images myself, on a BBB, but I have no > problems running apt-get and pip to install patches). > > > > -- > Wulfraed Dennis Lee Bieber AF6VN > [email protected] > http://wlfraed.microdiversity.freeddns.org/ > > -- > For more options, visit http://beagleboard.org/discuss > --- > You received this message because you are subscribed to a topic in the > Google Groups "BeagleBoard" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/beagleboard/C9Jf0YjhdI8/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/beagleboard/0mgame10k08fpkle0kbpl0gs1fqu3c4e8i%404ax.com > . > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/CAHebKV%3DuZz2Co6ZMZfgnjFspBdQKZsQmm0gfsLOHe0-G0bYuuw%40mail.gmail.com.
