Simulink C2000 I2C exception handling in case of no answer, total DSP hang-up, no recover (R2019b)

3 visualizzazioni (ultimi 30 giorni)
Hello,
I am developing a PCB with a TI C2000 DSP (F28379D) as the central controller and several IC's for measuring and controlling tasks. Some of them are connected by I2C. All software is programmed with MATLAB/Simulink and the "Embedded Coder Support Package for Texas Instruments C2000 Processors" in version R2019b. Except for my problem everything works well.
In case the DSP is communicating over I2C and receives no answer (wrong I2C address, IC disabled, EMC problems ...) from the slave, the complete application immediately stops and only a power cycle can recover the DSP from hang-up! My communication is built up like this example code:
C:\ProgramData\MATLAB\SupportPackages\R2019b\toolbox\target\supportpackages\tic2000\tic2000examples\c28x_i2c_eeprom.slx
Only "exception handling" (from software perspective) is to use the hardware watchdog, but in this case the application starts in its initialization and current operation is interrupted. This is not a suitable solution in my mind.
Is anyone knowing a way of handling this exception?
I already tried to use the status out port of the I2C Transmit block for switch casing the "No-acknowledgment interrupt flag bit" for example (documentation: TMS320F2837xD Dual-Core Real-Time Microcontrollers Technical Reference Manual SPRUHM8J, page 2382), but I am not able to use this information.
I assume an error in the hardware support package so that you can not reach this lower layer and implement a proper handling with Simulink only ...
Any help would be great! Thanks

Risposte (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by