cancel
Showing results for 
Search instead for 
Did you mean: 

I am looking for an undefined instruction

pchignon
Associate II
Posted on March 13, 2006 at 10:22

I am looking for an undefined instruction

4 REPLIES 4
pchignon
Associate II
Posted on August 09, 2005 at 08:44

Hi,

I want to test my undefine instruction handler, but I don't know how?

Is anybody known a undefine instruction ? I want to put this in my code :

UNDEFINED_CODE:

DCD 0X2C2C000A

Thanks,

Ludo

pchignon
Associate II
Posted on August 09, 2005 at 10:06

I have not found the undefined instruction. It seems to me that the code jump to 0x4000FFFC and call the undefined instruction because something was there, but It is not my case.

Isn't it.

pchignon
Associate II
Posted on August 09, 2005 at 10:11

Ok,

I found one ;

DCD 0x776D2D75

Thanks,

Ludo

ezanen9
Associate II
Posted on March 13, 2006 at 06:34

Hi Ludo,

I have created the undefine handler that should reset the system when the program counter jumps to unused(filled with 0xFFFFFF) memory.

Now I what to test this. How can I trigger an undefined exception from my C program?

Here is what I want to do to trigger an undefined exception. I am running from SRAM(evaluation board) and I want the program counter to jump to a memory location in the flash. The flash contains only FFFFFF's, this way the undef exception will be triggert.

But How do I make a jump with the PC?

I tried with inline assembly in my main() function:

__asm

{

B 0x40010000 //location in the flash

}

To jump to the flash memory. But this does not work.

Does someone know how to jump to a specific memory location in a C program. I am not known with assembly instructions.

Regards,

Jimmey