[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [avr-gcc-list] atmega8 interrupt vectors
From: |
Andy Warner |
Subject: |
Re: [avr-gcc-list] atmega8 interrupt vectors |
Date: |
Tue, 17 May 2005 17:32:55 -0500 |
User-agent: |
Mutt/1.2.5i |
Tyson Harding wrote:
> I am trying to use the UART on the mega8, and when I compile my code and
> look at the program listing, the vector table is incomplete. The vector
> table only contains first 13 vectors. The _VECTORS_SIZE is set
> correctly, and if I change it to something either bigger, or smaller,
> nothing happens.
Can you send details of the command line options passed to the
compiler/linker and the source code ?
There are a few things that could be wrong, such as:
1. The wrong CPU type passed to the compiler, it should
be:
-mmcu=atmega8
2. The source code pulling in the wrong header file, it
should just have:
...
#include <avr/io.h>
#include <avr/signal.h>
#include <avr/interrupt.h>
...
and not reference a cpu-specific include file directly. Best to
let the compiler define the right symbols and let the preprocessor
figure it out.
There are bound to be other simple errors that can cause you problem,
but these are the usual culprits in my (limited) experience.
--
address@hidden
Andy Warner Voice: (612) 801-8549 Fax: (208) 575-5634