cancel
Showing results for 
Search instead for 
Did you mean: 

FSMC clobbers I2C1

brianforde9
Associate II
Posted on February 16, 2009 at 08:09

FSMC clobbers I2C1

10 REPLIES 10
ccowdery9
Associate III
Posted on May 17, 2011 at 12:43

Right, my code is fixed.

Every routine that does an IIC transaction is enclosed with this wrapper:

Code:

RCC_AHBPeriphClockCmd(RCC_AHBPeriph_FSMC, DISABLE);

I2C_LM75_Init(); // taken from tsensor.c in it's entirety

// IIC stuff here

RCC_AHBPeriphClockCmd(RCC_AHBPeriph_FSMC, ENABLE);

Bit of a rigmarole, but it seems to work OK........

Chris.