[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] inline assembler, ijmp, X-Register

From: Torsten Mohr
Subject: Re: [avr-gcc-list] inline assembler, ijmp, X-Register
Date: Fri, 1 Jul 2005 18:08:36 +0200
User-agent: KMail/1.8


> > Have you tried it just using a 'vanilla' C function pointer? Although I
> > don't use the 128 I had the impression that avrlib did this for you.
> But he wants to jump, not call...

thanks for the hint with the function pointer, but i already thought of that

- I'm interested what went wrong with the assembler, i'd like to understand
  that part
- I only need a jump

Indeed, your suggestion would work, when i do in high memory at 0x1e000:

typedef void (*fptr)(void);

void a_function(void);

const fptr a_fptr PROGMEM = a_function;

void a_function(void) {

Then i see in the listing that a_fptr contains 0xfa99 and a_function is at
0x1f532, which divided by two is 0xfa99.

But still, i'd like to know what's wrong with my assembler, according to the
documentation i think it should work.

Best regards,

reply via email to

[Prev in Thread] Current Thread [Next in Thread]