Unable to make i2c-2 working

Started by fiosca, February 23, 2014, 01:47:05 AM

Previous topic - Next topic

fiosca

I could manage to make SPI communicating correctly, changing the fex file and rebuilding the kernel, but there's no way to have i2c working on UEXT connector (I'm using the A10-OLinuXino-LIME-UEXT board).

I2C-0 and I2C-1 seem to work properly, but the third one, which is available on the UEXT connector, doesn't communicate at all.
Is there any open issue related to i2c-sunxi kernel module?

Could anybody manage to have i2c working properly?

soenke

My i2c-2 is working stable at 1MHz. Kernel default is 400kHz or 100kHz depending on the version you are using.

For 1MHz you have to add additional 1.8kOhm pullup-resistors on SDA and SDL in parallel to the existing 2.2kOhm and you have to change the kernel config so it runs at 1MHz. If anybody is interested i can post where to change it.

Try "i2cdetect 2" on the linux shell to see if the device is detected. Check the spec of your i2c-device if it supports at least 400kHz in case your kernel is running at that speed.

You can check the bus with an Oscilloscope if it is working correctly. If you dont have one use a LED with a 220Ohms (or some value matching your LED) resistor. You should see some very short flicker after starting i2cdetect.

fiosca

Thank you Soenke!

Are you using the   A10-OLinuXino-LIME-UEXT connection board?

I already applied kernel patch to have i2c-1 and i2c-2 at 100 khz.
Tried i2cdetect with 4 different UEXT modules and none is detected.

On channel 0, i2cdetect can see the power management device and on channel 1 the eeprom,
so linux kernel seems to work.

I think I have an hardware problem, but don't have an oscilloscope to check the output signals,
I'll try to patch the uext extension board and drive i2c-1 to the uext connector instead of the i2c-2....

soenke

No, i am not using the UEXT connection board.

If you dont have an oscilloscope, then you may try to just measure the voltage on both channels while doing an i2cdetect 2. Even with the strong filter of your voltmeter you should notice a little change at the mV-scale.

Also you could test the connection at the in and out side of the adapter.