Page 1 of 1

Wrong I2C output on UDB4 board

Posted: Thu Feb 09, 2012 5:38 pm
by alpert
I'm trying to use the I2C on UDB4 board with Lubin's Block-set. I've done this on to other boards (with dsPIC30 and dsPIC33) and it had worked perfectly.
Unfortunately, when I'm trying it on UDB4 board (with dsPIC33fj256GP710a) the I2C signal that i get is very strange.
This is how I2C signal should look when everything works fine:
When i look with oscilloscope on the I2C signal of the UDB4, it show non stoping bits in the SDA and SCL without any meaning.

This is the model that I've build:
(37.09 KiB) Downloaded 180 times

Does someone have any idea why it happens?


Re: Wrong I2C output on UDB4 board

Posted: Mon Mar 26, 2012 11:32 am
by LubinKerhuel
Hello Lior,

I just tested and I am getting exactly the same result.

When I2C is beeing used, we should not see so many transition as there is no acknowledge from the other side.
Something's might be wrong with the software.

I did not see errata on this 33Fj256GP710A Chip rgarding I2C.
You might try to check the code generated by the blockset to see if there is anything's wrong.
Testing with I2C 1 (connected to EEPROM) does not change anything. Were you able to find out which EEPROM chip is on the board ? UDB4 Schematic does not provide its reference.

Alternatively, if you are wiling to log data, I tested an interreting solution: openlog which just fit perfectly on the UDB4 board (see pictures).
I was able to set-up long lasting logs (few hours). Only potential problem is the speed of the Flash card (When used with Open Log) which does not allows to log about 2600 bytes/s. Using class 10 flash card does not help. Best result (i.e. log without any data loss) were obtained using an ole transflash 128Mb card (SanDisk). recent Transcend Flash Card Class 10 are just not fast enough.

UDB4 with OpenLog
UDB4 with OpenLog
DSC03660_reduced.jpg (89.8 KiB) Viewed 3170 times
UDB4 with OpenLog & GPS
UDB4 with OpenLog & GPS

Re: Wrong I2C output on UDB4 board

Posted: Tue Mar 27, 2012 7:16 am
by alpert
Hi Lubin,
Thank you for your answer.
It looks like this problem is related to the configuration bits. Mybe, from some resone, your I2C block is not configure the registers properly.
It's very strange that it works fine on dsPIC 33FJ256FC710 (Gluon-Pilot's board) , which is not so different from the 33Fj256GP710A .

I'm using the I2C to control the Brushless motors, not the EEPROM. I'm using MIKRO-KOPTER's BL-Motors, and their drivers works with I2C comunication. I agree the eeprom is not very usfull (only 32 KB).
The model of the eeprom on the board is 24LC256. Here is a link to the datasheet: