Hello Pratheesh,
I had a look over the CMSIS files included in your project.
The following is a list of things that will most likely not work in this setup:
- You are using a minimal CMSIS SystemInit():
The one in use resets registers for CPU clock configuration regardless of their previous state. You could try to use the CMSIS files shipped with emLoad/embOS as running on a reset setup with the minimum base clock is most likely not what you want anyhow.
As I have already written in my last mail, switching away a CPU clock that is currently in use might result in unpredictable behavior.
- Reconfiguration of VTOR:
Your minimal SystemInit() sets the vector table offset register to FLASH_BASE. I am unable to find the define in the files you uploaded. If this points to the original base address at 0x08000000, this will overwrite the already correctly set VTOR register set by emLoad. embOS makes sure to set the VTOR register to the correct state during init, based on the address of its own (firmware) vector table.
If you have just used the RTX project as it is, the define FLASH_BASE might point to the wrong vector table.
We try to use the CMSIS files as they come form the CPU vendor but these are not always using optimal settings. It might happen that they do not initialize anything at all or initialize clocks to a value that is not compatible for using USB (requires a clock that is a multiple of 48MHz) or other peripherals.
As you have already checked for yourself, embOS (for sure) and FreeRTOS seem to use a different low level setup.
Can you try to use either the complete CMSIS files from one of these packages (embOS/emLoad preferred) or
the SystemInit() content and try if it allows you to successfully run your application ?
Best regards,
Oliver