I want to divide internal ROM of STM32f030 using scatter file for custom boot loader. When the size of ROM for main application is less then 0x1000 its work properly but when i increase the size from 0x1000 the keil MDK v5 debugger generate hard fault error. Please also tell we should I also need the RAM for custom bootloader.
Below link might be helpful: http://www.keil.com/forum/60446/stm32-sdram-scatter-file/
In one of the comment users have suggested that: "The memory needs to get configured prior to use by the C compiler's run time code, as if you describe the available memory in the scatter file and put statics there, they will need to be initialized or zeroed. If the FMC hasn't been configured the system will Hard Fault."
Other than that, you can analyze the hard fault as mentioned: community.arm.com/.../5414