Hello,
I am using Stellaris Launchpad with LM4F and I wanted to use the I2C0 as a Master. I used the API for configuring:
GPIOPinConfigure(GPIO_PB2_I2C0SCL);// 0x00010803
GPIOPinConfigure(GPIO_PB3_I2C0SDA);// 0x00010C03
GPIOPinTypeI2C(GPIO_PORTB_BASE, GPIO_PIN_3);
GPIOPinTypeI2CSCL(GPIO_PORTB_BASE, GPIO_PIN_2);
Uart_Send(UART0_BASE,"I2C GPIO DONE\n\r\0",0);
I2CMasterInitExpClk(I2C0_MASTER_BASE,SysCtlClockGet(),false);
SDA is as expected high (3,3V) because of the weak pull up. The SCL-line is always around 0,6V. I dont check it...
In the data sheet (page 949) there is mentioned that the clock pin has an active pull up and should not be configured as open drain. In the API I saw that the pin is configured as push/pull. I wanted to use the internal pullups but I can't configure the SCL-Pin: it is never high (except when I conigure it as output and write '1'). Should I use external pull ups? It is stupid when I am not allowed to configure the SCL as open drain. 2 parallel pull ups (internal + external)? What can I do to fix this problem?
Greets, Matthias