David,
Good for you. I don't understand that connection. If I get the driver and a 
DTB loaded, where will it show up? Possible answers are under bone_capmgr, 
under /sys/...i2c-1, and under /dev/i2c. And do you have any reason to 
believe this will be faster than simply file i/o-ing thru /dev/i2c? --Clark
On Wednesday, October 16, 2013 1:58:26 AM UTC-7, David Goodenough wrote:

> On Wednesday 16 Oct 2013, Jacek Radzikowski wrote: 
> > You're barking at a wrong tree. /sys/devices/bone_capmgr.9/slots is used 
> to 
> > load device tree overlays and has nothing to do with devices on I2C bus. 
> This is not quite true.  While you can access the I2C bus directly without 
> a device tree entry, if there is an overlay you can tell the kernel that 
> this 
> device is expected to be there, and if the driver is DTB enabled you can 
> get it loaded and configured for you. 
>
> David 
> > The correct place to write to instantiate a new i2c device is 
> > /sys/bus/i2c/devices/i2c-X/new_device (substitute X with bus number to 
> > which the chip is connected). The echo command in your case would look 
> like 
> > something like this: 
> > 
> > echo inv-mpu6050 0x68 > /sys/bus/i2c/devices/i2c-X/new_device 
> > 
> > j. 
> > 
> > On Tue, Oct 15, 2013 at 6:02 PM, <[email protected] <javascript:>> 
> wrote: 
> > > We are using the Invensense MPU6050 IMU on I2C with Beaglebone Black 
> > > (Angstrom 3.8.13). We can use I2C-tools and file I/O thru /dev/i2c but 
> > > the read speed is disappointingly slow.  We only read the 3x gyros and 
> > > 3x accels (each one byte at a time plus the 2 byte temperature 
> reading) 
> > > and it takes ~2msecs.  My estimate of the I2C bus cycles for a block 
> > > read suggests this should take ~160 bus cycles or .38msec on a 400MHz 
> > > I2C bus. ****** 
> > > 
> > > The distribution includes the Invensense driver inv-mpu6050.ko but 
> there 
> > > is no indication that reading through /dev/i2c invokes it.  This is a 
> > > very popular IMU and Invensense widely distributes the driver over 
> many 
> > > Linux platforms.  The driver source includes “successful installation 
> > > will create two directories under /sys/bus/iio/devices” and lists the 
> > > files there (aka functions). I can never get these to show up.**** 
> > > 
> > > I can “insmod 
> > > /lib/modules/3.8.13/kernel/drivers/iio/imu/inv_mpu6050/inv-mpu6050.ko” 
> > > and “echo inv-mpu6050 0x68 > /sys/class/i2c-adapter/i2c-1/new_device”. 
> > > This causes a new directory named 1-0068 to show in 
> > > /sys/class/i2c-adapter/i2c-1with entries like name and modalias but no 
> > > functions.  It never shows in /sys/bus/iio/devices.**** 
> > > 
> > > What constitutes “successful installation”?  **** 
> > > 
> > > What else is needed to get the inv-mpu6050 to expose functions in 
> > > /sys/bus/iio/devices like the driver sources says?**** 
> > > 
> > > Beaglebone Black uses bone_capemgr for exposing driver functions for 
> many 
> > > devices.  “echo inv-mpu6050 0x68 > /sys/devices/bone_capmgr.9/slots” 
> > > raises the gripe “write error: no such file or directory”.  (I can 
> > > successfully load the am33xx_pwm driver this way.) Is this because 
> there 
> > > is no matching DT fragment in /lib/firmware? Is the inv-mpu6050 driver 
> > > supposed to be invoked thru cape manager?**** 
> > > Then, most importantly, if I did read and write through the /sys tree 
> > > using the Invensense driver would it be faster than /dev/i2c? 
> > > Help on sorting this out would be much appreciated. 
> > > 
> > > -- 
> > > 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] <javascript:>. 
> > > For more options, visit https://groups.google.com/groups/opt_out. 
>
>

-- 
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/groups/opt_out.

Reply via email to