To catch undefined program counter jumps to the SRAM I want to fill my hole SRAM with 0xFFFFFFFF(undefined instruction) before my C-program is entered. This way the unused (large) area of SRAM will not generate undefined behaviour when the corrupted PC jumps to it. I think that the only way to do this is to clear SRAM in the init.s. But in the init.s I can only write assembly code. Because I am not able to write this I have the following question: Does someone have an example, tips or a ready to use piece of assembly code that clears the hole SRAM with 0xFFFFFF that I can put in the init.s? Thanks, Jimmey
But is this code for the STR710 MCU? My compiler doesn't think so! I checked the assembly code and I can not find it in the instruction set for my MCU. (ARM7TDMI downloaded from www.ARM.com) To clear my question: I like to fill the hole SRAM starting at 0x20000000 with 0xFFFFFFF in my startup.s/init.s file. Regards, Jimmey