Important: 7-Bit I2C Addresses are Now Working! (01/24/2014)

Since release, the Spark Core has had a major I2C bug wherein entering a standard 7-Bit I2C address didn’t work. The problem turned out to be in the low level STM32 I2C code; it wasn’t shifting the address one bit to the left before adding the read (1) or write (0) bit to the end.

About two weeks ago I fixed the bug and submitted it to the Spark Team. It went live on the Spark Build IDE (Sparkulator) this morning around Midnight Pacific.

  • What does this mean to you?

  • If you have any sketches that are currently using an I2C address you’ve manually bit shifted, they’ll stop working the next time you flash from the IDE unless you change them back to the standard 7-Bit address.

No other changes have been made to the I2C system other than this fix. I am currently working on overhauling the I2C system to be completely more reliable by using DMA for transfers, making it non-blocking and starting the transfer immediately instead of waiting for Wire.endTransmission(). I expect these changes to be available for beta testing by the community towards the end of the week.

7 Likes

Thanks @timb, I have updated my Weather Station for 7-bit addresses and retested - all good.

timb, as of 10am EST, I have not seen any changes to the core firmware on github! Hopefully, they will be published soon.

@peekay123 It’s in core-common. :smile:

It’s been live in the master branch for a week or so. It went live on compile-server2 yesterday.

1 Like

Hey man, this will be excellent! I have had to go back to developing one project on my Uno's and the Yun test unit I have in house - without reliable access to I2C the Core was slowing me down too much. Once this has been addressed it will be great to get back onto my preferred platform!

Ken

Oops, missed the git pull on that branch. Thanks timb!

:sunny:

1 Like

This topic is now pinned. It will appear at the top of its category until it is either unpinned by a moderator, or the Clear Pin button is pressed.

Thank you for the suggestion. I would now observe the changes.