I'm working on an embedded processor and having trouble getting interrupts to work in real life. They work fine in simulation but that's another story.
Anyway on this ARC processor you set the interrupt handler with this function _setvect1 that looks like this
extern void _setvect1(int vector, _Interrupt1 void (*target)());
I don't understand what the second part means and what it's looking for. Is that a pointer to a function, I'm not used to seeing something like (*target) I vaguely remember that () is a function?
This is my isr
int volatile flag_sp3 = 0;
_Interrupt1 _Save_all_regs void sp3_isr(void)
{
unsigned volatile long result;
result = _lr(0x0A);//status maybe
display_value(result);
flag_sp3++;
}
They call Interrupt1 and _Save_all_regs calling conventions, another thing I've not really run into before. I am talking to their support but still trying to understand and work it out for myself.