Argh, I apologize for the error. I thought it was r89, but I've just finished some other tests and I am using r88. I have identified a bug in r91 that affects me, but is not related to your problem.
What's screwing me up is that the projects I'm importing (like I2CU) seem to be built using a particular revision of the mbed library, but it's not possible (at least not straightforward to those new to DVCS systems) to go to the latest revision. For example, if you click on mbed under I2CU, and then show Revisions, you'll see r89 at the latest... so I had thought when I was working in other apps that they were also using r89, when in reality they were using r91. I need to be more aware of this in the future.
I tried to update mbed in I2CU, but when I click Update, I get an error dialog that just says "[object Object]" and all I can do is close it. Do you have a way to manually update the mbed library in I2CU? I can test it once I know how to do that...
Hi,
got a new board, the K22F, i tried to talk to the onboard FXOS8700CQ mag/accel sensor with no luck. On the K22F the mag i2c addr is 1C, while in K64F it's 1D, the weird thing was the mbed i2c api ret ok for all slave addr except for 1C (!?!?!!?)
The bug is about the hal apis mistaking ack for nack. The K22F and K64F mcu referencce manual tells I2C status reg bit0 "RXAK" is like this:
So it's a nack flag, but i2c_api.c mistakes nack with ack http://developer.mbed.org/users/mbed_official/code/mbed-src/file/d73ca02bc818/targets/hal/TARGET_Freescale/TARGET_KPSDK_MCUS/i2c_api.c
swap the 0:1 to 1:0 and problem solved.
I've not a K64F to try, but code is the same and reference manual tells the same, so i would expect K64F also can't talk to its FXOS with actual mbed-src release.
Hope it helps.