I'm using the I2C driver in a project generated using the project generation tool. If I have the optimisation level set to anything other than -O0, the project locks up in the driver / function I'm calling. I2C_MasterTransferBlocking() for instance.
Any advice other than don't use optimisation?
I can attach files fine in the "advanced editor" view, when the attach option is there. However, if I look at posts and replies in my inbox, then there isn't an attach option.
But, I did find that if I click on the original post title, then it will go to the view where "use advanced editor" is a small link in the top right hand corner, then I can click on that, and then the "attach" option appears in the bottom left. Once you're in the advanced view, then you can do as your screenshots point out, it's getting there that was awkward.
Anyway, I've now attached the project, thanks.
I just tested your project on my TWR-KV58F220M demo board. test the project with -O0 and -O2, -O3 separately, but the appearance is the same in debugger run.
see attached video for -O3 for instance. with -O0 and -O2, everything is same in debugger run.
Have a great day,
Jennie Zhang
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
P.S. It will lock up waiting for an interrupt, as I'm using a blocking function call. However, I can see the TCF (transfer complete) flag in the I2C reg, but not any interrupt flag, and it doesn't look like interrupts are enabled either. I didn't dig too deeply here.
Hello
which controller you are using?
can you please share code??
Regards,
Harsh
Hello Harsh, here are some more details:
KDS 3.2.0
SDK_2.0_TWR-KV58F220M
KV58F220M tower board, using I2C driver to read the who_am_i register from the FXOS8700CQ. Using PKV58F1M0VLQ22, so pre-prod part on an early version tower board. Project generated by kinetis project generator using the 2.0 SDK generated for the KV58F using the SDK builder app.
There is no button to attach a zip file on this reply frame. There is also no option to "go advanced" and see more controls.