Cp2112 Dll

0 views
Skip to first unread message

Gordon Neal

unread,
Aug 3, 2024, 5:23:41 PM8/3/24
to relapdevi

I am trying to get a SiLabs CP2112 USB to I2C bridge working with my Pi. At some point in recent history I had it working just fine. I could plug in a CP2112 evaluation board and a new entry /dev/i2c-2 was created for a new I2C bus. For some reason this doesn't seem to work anymore. I've gone back to a stock Raspbian image and still can't get the device to appear as an I2C bus.

The Kernel for the Pi is not compiled with the driver for the CP2112 selected as either a builtin or a loadable module. For the CP2112 to operate correctly as a USB->I2C bridge follow the guide here to rebuild the kernel, with the exception that before compiling/building you should modify the .config to allow the hid-cp2112 driver to be included as a builtin driver.

I just watched this video about how to revive and/or review status of DJI batteries. I'd like to get that functionality, and it seems like it ought to be simple enough to just use the SDA/SCL pins on an arduino or similar microcontroller. Is there something special about CP2112 that you have to use that particular module here?
I also have a Silicom Labs JTAG/C2 debug adapter that I bought for a client project but never wound up using (or learning to use). I wonder if that's an option?

The Datasheet for the CP2112 specifically states I2C, so I would think it should work. However, the CP2112 seems to be 3.3V whereas the Arduino you are using may be 5V. See page 17 of the CP2112 datasheet for their suggested connections.

I correct myself. The datasheet says voltages between 3 and 5 are acceptable. I just did a quick review and didn't immediately find the specific I2C address to use. If you can't find it in the datasheet either, you could use an I2C scanner to automatically detect it for you.

It looks like the author of the video provides an executable Windows application. That obviously interacts with the CP2112 board in some way. A quick look at what the CP2112 is on the Silicon Labs website says that it is a USB to SMBus/I2C bridge.

You would need to know what the Windows application is sending and receiving over the I2C bus in order to replicate the functionality on an Arduino board. The author doesn't seem to supply any source code.

After seeing someone having trouble with their battery, thought I'd share some of what I've learned about the Intelligent Battery. =viewthread&tid=195480The Motion Controller board communicates with the battery...

DJI's "intellegent" batteries use I2C to communicate all sorts of battery data. If anything unusual happens to the battery it will flag it and software prevents it from running again. CP2112 module along with a program is used to access that battery info and reset it if desired.
I was wondering if there is an alternative module to cp2112.

c80f0f1006
Reply all
Reply to author
Forward
0 new messages