Alberto, Maybe, but at least you come bringing good information. Thanks :)
On Thu, Jul 31, 2014 at 2:18 AM, Alberto Potenza < [email protected]> wrote: > Ok, > > as usual, after one day searching around, I found the solution 2 minutes > later I wrote the post. > > Here the solution: > https://github.com/pehrtree/beaglebone_snippets/tree/master/power > > Alberto > > Il giorno giovedì 31 luglio 2014 11:02:03 UTC+2, Alberto Potenza ha > scritto: > >> Dear all, >> >> I would like to see if my Beaglebone black is powered by USB cable or by >> an external power supply. >> To do that I would like to read the "Status register " of the TPS65217C. >> It should be done by using the I2C0. As far as I have understood, it >> cannot be done by userspace by using <linux/i2c-dev.h> and open it by >> /dev/i2c-0. >> >> I tried both >> i2cget 0 0x24 0x0A >> i2cget -y 0 0x24 0x0A >> >> but I obtain always: "Device or resource busy". >> >> Is there a way to check what is written in the status register? >> Or is there another way to check how the Beaglebone black is powered? >> >> Thanks. >> >> Alberto >> >> FYI: >> >> root@arm:/dev# uname -a >> Linux arm 3.8.13-bone28 #1 SMP Thu Sep 12 23:22:35 UTC 2013 armv7l >> GNU/Linux >> > -- > 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. > -- 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.
