So many many many thanks, after hours of searching for the solution, you pointed with the answer: root access..
On Thursday, March 6, 2014 3:38:43 PM UTC-6, [email protected] wrote: > > Robert Nelson <[email protected] <javascript:>> wrote: > > On Thu, Mar 6, 2014 at 1:11 PM, <[email protected] <javascript:>> wrote: > > > I am trying to use the Adafruit BBIO library on a BBB with Ubuntu > > > 13.10 installed. It's for reading ADC values and sending some digital > > > data. > > > > > > A trivial program as follows shows the error:- > > > > > > #!/usr/bin/python > > > import os > > > import sys > > > import Adafruit_BBIO.ADC as ADC > > > # > > > # > > > # Read A2D using Adafruit libraries > > > # > > > ADC.setup() > > > > > > > > > As soon as it executes the ADC.setup() call I get the following > error:- > > > > > > chris@beaglebone$ bt.py > > > Traceback (most recent call last): > > > File "/home/chris/bin/bt.py", line 9, in <module> > > > ADC.setup() > > > RuntimeError: Unable to setup ADC system. Possible causes are: > > > - A cape with a conflicting pin mapping is loaded > > > - A device tree object is loaded that uses the same name for a > fragment: helper > > > > > > > > > > > > This worked OK on the Angstrom distribution but for lots of reasons I > > > want to use Ubuntu. > > > > > > So, what's wrong, I'm not running anything at all before running the > > > above. There are no capes installed. I get the above error if I > > > simply power up the system and run the above code. Is it just some > sort of > > > name conflict with more than one thing called 'helper' or am I > > > misunderstanding what it's telling me? > > > > According to dmesg, did it actually load anything? > > > > Probally also need the patch "dtc" .. > > > > wget -c https://raw.github.com/RobertCNelson/tools/master/pkgs/dtc.sh > > chmod +x dtc.sh > > ./dtc.sh > > > No, after a little while I twigged what the problem was, it needs root > access to work. > > It's not a big issue for me at the moment but it does seem a bit wrong > to need root access to be able to get at the GPIO and ADC data. Is > there some sort of group membership I can add to my user to make it > work or maybe some library needs to be SETUID? > > On the Angstrom distribution of course everything is done as root, > that's why it worked there. > > That dtc patch is only needed for SPI and UART use I think, I don't > need those. > > -- > Chris Green > > -- 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]. For more options, visit https://groups.google.com/d/optout.
