Re: [AVR-Chat] Jumptable
2005-05-18 by Reza
Hi; this code may help: in r24,port_address andi r24,3 ldi ZH,hi8(jmp_table) ldi ZL,lo8(jmp_table) or ZL,r24 ijmp NOTE: the jmp_table must aligned on 8 words bounry (three lower address bits must be zero) and contains only rjmp instructions. if the value does not lies in 0..7, use a 256 entry table which aligned on 256 words boundry. jmp_table: .dw entry_0,entry_1,... good luck; __________________________________ Yahoo! Mail Mobile Take Yahoo! Mail with you! Check email on your mobile phone. http://mobile.yahoo.com/learn/mail