Jorge,
Ok to explain the problem..
To configure a I2C based port expander we are writing to the different registers multiple time using the below source code
reg_buff[0]= 0x40;
data_Buff[0]= 0x10;
I2C_DRV_MasterSendDataBlocking(I2C_FOOTSWITCH_INSTANCE, &footSwitch, reg_buff, 1, data_Buff, 1, 1000);
xTaskDelay(40);
reg_buff[0]= 0x43;
data_Buff[0]= 0x10;
I2C_DRV_MasterSendDataBlocking(I2C_FOOTSWITCH_INSTANCE, &footSwitch, reg_buff, 1, data_Buff, 1, 1000);
xTaskDelay(40);
so our board is clocked at 120MHz (K64 processor board). When we put breakpoint before every I2C_HAL_WRITE we are able successfully write to the register and everything works properly.
When we do not put breakpoint but just run the application. As we are running safeRTOS which is nothing but freeRTOS it gets to an errorhook.
So we need to understand how the timeout of I2C_DRV_Mastersendblockingdata works and also the xTaskDelay which is used in I2C example code provided.
hope it helps.
Thanks,
Kewal