Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

Re: [AVR-Chat] Timer1 Problems

2005-07-07 by James Hatley

> At 09:20 AM 7/7/2005, James Hatley wrote:
> >Good point. And for most processors I assume that the JMP would be more
> >appropriate.
> >
> >However, the little 2313 only has a RJMP. I couldn't find any other
> >instruction that fit for interrupt vectors.
> >
> >I wrote some code and it ran just fine with the RJMP. (on the simulator
> >anyway).
>
> At 07:42 AM 7/7/2005 Dave VanHorn wrote:
> Be sure which is right for your box.
> I made the mistake once, of copying the vector table from a lower AVR
> (with rjmps) into a mega, which uses JMP, and the results were most
> amusing, but depending on how much code there is, and how it's
> structured, it might have worked, which is more scary, to me anyway.
>
Excellent advice for all starting out (or continuing) to write assembler (or
C or whatever for that matter), namely, that it is essential to know the
processor that you are writing code for. The only way to get that is to
study, write code, build something, and get your hands dirty. Atmel, as much
as we complain at times, does write a pretty good manual on their products
but they do take serious study and that takes time and perseverance, for
sure.

Jim

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.