cancel
Showing results for 
Search instead for 
Did you mean: 

SW Interrupt on Iar (Vectors)

jorge2399
Associate II
Posted on September 30, 2006 at 13:06

SW Interrupt on Iar (Vectors)

4 REPLIES 4
jorge2399
Associate II
Posted on September 08, 2006 at 07:39

Hi all,

I'm implementing a software interrupt on STR71x.

I use Iar tools, and would like to know how to add the interrupt

in vector function.

An example of vector table could be nice !

Thanks,

Regards,

jorge2399
Associate II
Posted on September 08, 2006 at 08:12

Thanks Zouh,

But i already found this post;

That's not dealing with Iar environment.

So, It differ . and it doesn't reply to my interrogation

around vector table and its configuratin for SWI

Rgds,

[ This message was edited by: jorge50 on 08-09-2006 11:43 ]

jorge2399
Associate II
Posted on September 11, 2006 at 06:16

> 3. in 71x_it.c in the void SWInterrupt (void)

> write the routine you want to execute.

Oh ok that's what missed me. (to declare in the SWIt).

Thanks Zouh.

Rgds,

wolf2
Associate II
Posted on September 30, 2006 at 13:06

Dear Zouhair:

Could you explain more ?

I try C/C++ Guide P.19

#pragma swi_number=0x23

__swi __arm int swi_function(int a, int b);

and I declare

int swi_function(int a, int b)

{

return (a+b);

}

3rd step at P.20 of Guide

I add swi_handler.s79 to my project

At SWI_Handler routine, I add __iar_swi_handler()

But I find the assemble code is BL swi_function not asm 23

So never trigger SWI_Handler function.

What is wrong with me ?

Or I misunderstand the Guide.

Thank you.

Wolf