cancel
Showing results for 
Search instead for 
Did you mean: 

PSoC 5, 3 & 1 MCU

Anonymous
Not applicable

I'm running I2C on high speed (1000 kbps) to update a TFT screen. But when I add a component (e.g. I2C LCD display) and start it by I2C_LCD_Start(), the whole thing stops working until I reduced the data rate of the master to 400 kbps.

   

When I remove the I2C_LCD_Start() statement it's again possible to run with a data rate of 1000 kbps.

   

B.t.w. I did not changed anything in the hardware configuration.

   

I don’t understand the reason of it.  Somebody do...?

   

Rob

0 Likes
Reply
8 Replies
ETRO_SSN583
Esteemed Contributor

Have you looked at the buss while running 1000kbps ? What

   

is the C loading of the TFT ?

   

 

   

Phillips buss specs -

   

 

   

    

   

          http://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0CDMQFjAA&url=http%3A%2F%2Fwww.nx...

   

 

   

Regards, Dana.

0 Likes
Reply
JoMe_264151
Expert II

Sounds a bit as if you try running two I2C masters at the same time. There might be conflicts with the interrupt priority.

   

Can't you run both of your slaves on the same I2C-line?

   

 

   

Bob

0 Likes
Reply
Anonymous
Not applicable

Thanks both for replay but I think I'm not clear in my explanation...  Try again:

   

In my test project I send data to my TFT screen via I2C. It is working great running on data rate 1000 kbps.

   

Now I add an other I2C slave (for example the I2C Character LCD) in my project.

   

When I only add the line I2C_LCD_1_Start();  in main.c, compilled and run it, the TFT screen is not updated anymore, until I changed the I2C master speed to 400 kbps and compile and run it again.

   

I also did not use the I2C_LCD in my project, I only start it up.

   

There isn’t any change in hardware, only in software.  Below my project.

   

It seems that adding the software component reduced the data rate….but why?

   

Rob

   

   

 

   

0 Likes
Reply
Anonymous
Not applicable

Some additional info:

   

The TFT data is send by I2C to the TFT with the basis Start, Write and Stop functions.

   

@Dana: The TFT is running perfect on 1000 kbps. The second I2C slave is only attached in software, in hardware nothing changed. So I don’t think it has something to do with bus load.

   

@ Bob: As you can see on the schematic I have one master and two slaves. When I add in software the second slave, which is the I2C LCD, then the data rate should be reduced to 400 kbps. Maybe the I2C slave is configured for not higher than 400 kbps? I can’t find that in the specs.

   

Maybe this addition helps I hope…

   

Rob

0 Likes
Reply
JoMe_264151
Expert II

I can be mistaken, but on your schematic I can see two (2) I2C Masters:

   

I2C and I2C_LCD_1

   

 

   

Bob

0 Likes
Reply
Anonymous
Not applicable

Bob,

   

I don't know if the LCD is reacting as master...  I can't find in the datasheet if it's a slave or master.  I should think that the master controlles the slave which is the LCD.

   

From the I2C definitions:  Slave:  the device addressed by the master.  And that is what I'm doing.

   

Maybe I have to do some more test to see what realy happens.

   

Rob

0 Likes
Reply
ETRO_SSN583
Esteemed Contributor

From the datasheet see 4'th bullet item -

   

 

   

0 Likes
Reply
ETRO_SSN583
Esteemed Contributor

One other thought, multiple masters allowed if on separate physical

   

busses, eg. one Master / buss. Or if multi-master then one common

   

buss.

   

 

   

www.i2c-bus.org/MultiMaster/

   

 

   

Regards, Dana.

0 Likes
Reply