Search found 4 matches

by johntramp
Thu May 23, 2013 1:30 am
Forum: STM32 Support
Topic: Only one I2C bus responding
Replies: 19
Views: 12476

Re: Only one I2C bus responding

Ah, reading into the data sheet:
The master sends a NACK for the last byte received from the slave. After receiving this
NACK, the slave releases the control of the SCL and SDA lines. Then the master can send
a Stop/Restart condition.

So it is working as it should. Sorry for the noise.

John
by johntramp
Thu May 23, 2013 12:47 am
Forum: STM32 Support
Topic: Only one I2C bus responding
Replies: 19
Views: 12476

I2C woes

Hi again,

Carrying on from this, I now have the I2C bus mostly working except for some reason the final received packet will always NAK. Here is what I am doing https://gist.github.com/johnhowe/05839338f1e20ba747a5 , which in short is just:


i2cAcquireBus(cfg->driver ...
by johntramp
Fri May 17, 2013 1:59 am
Forum: STM32 Support
Topic: Only one I2C bus responding
Replies: 19
Views: 12476

Re: Only one I2C bus responding

Thanks Giovanni, I hadn't set the alternate pad modes. I was following the code example in /testhal/STM32F4xx/I2C/ which doesn't include that step.

John
by johntramp
Thu May 16, 2013 1:53 am
Forum: STM32 Support
Topic: Only one I2C bus responding
Replies: 19
Views: 12476

Only one I2C bus responding

Hi,

I am only able to get one of the I2C bus interfaces working on an STM32F4 discovery board. The I2CD1 driver works fine, but I2CD2 and I2CD3 show no activity on the I/O pins. Has anyone else come across this? Or able to see what I am doing wrong?
Here is the code I am using https://gist.github.com/johnhowe/5588359

Cheers,
John