STM32f103VET6 I2C -1 Do not work when Flash Address & Vector Address changed to 0x08005000 on IAR Embedded Workbench v 6.40

akshay1989 wrote on Wednesday, July 15, 2015:

Hello,

  I have been using FREERtos demo for STM32F103 on 'IAR embedded Workbench ,version 6.40' on windows XP OS.

I am using the microcontroller STM32F103VET6 in my application. Here I am using I2C-1 in polling mode, my I2c works fine when I set my Flash Address & Vector table address = 0x8000000 , but when I set my Flash Address & Vector table address to 0x08005000 I2c-1 do not respond where as rest of the application and peripherials works properly. Initial part of ROM memory is occupied by Device Firmware Upgradion code.
I have performed all the hardware tests on CRO , I2C-1 is not giving any problems.

Here is my code Snippet:

    prvSetupHardware();

    static_delay_ms(50); // system warmup delay

    NVICConfig();  
    GPIOConfig();

    InitI2C();               

I2C_GenerateSTART(I2C1,ENABLE ); // Here I am generating a dummy start.

while(!I2C_GetFlagStatus(I2C1,I2C_FLAG_SB)); // checking I2c-1 startflag status , here my code
// gets stucked

static_delay(100);

I2C_GenerateSTOP(I2C1, ENABLE);

while(I2C_GetFlagStatus(I2C1, I2C_FLAG_STOPF));

rtel wrote on Wednesday, July 15, 2015:

Is this a FreeRTOS issue? From your code snippet it doesn’t look like you have started the scheduler yet.