If all works fine – I mean I2C-Sensor is working properly on Bus – (imho) no one spend thoughts what happens if:
-a bit is missing/modified by EMI,
-the device is suddenly down maybe due brownout,
– other nice pain.

To utilize I2C-Bus in a secure manner (I mean preventing program from stuck endless in a while Loop) all rescue and error handler should  be utilized not only why they are dedicated and available.

To do that, I have build up a working example, which could be implemented in the I2C-Communication Code to prevent from above mentioned  pain.

Download Project for XMC1300 BootKit (or merge structure and Code to other Targets):

https://fhkarnten-my.sharepoint.com/:u:/g/personal/haselb_fh-kaernten_at/EdRIkMu-FmxGp6-GwW4Lq0kB4h9rl-KFH2A_5tc8CZzMFg?e=ANpUYY

 

I2C_BusScanner for Infineon XMC

Schreibe einen Kommentar

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert

Diese Website verwendet Akismet, um Spam zu reduzieren. Erfahre mehr darüber, wie deine Kommentardaten verarbeitet werden.