[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [avr-libc-dev] Possible Incorrect Interrupt Vector Addresses formega
From: |
Weddington, Eric |
Subject: |
RE: [avr-libc-dev] Possible Incorrect Interrupt Vector Addresses formega168 |
Date: |
Tue, 25 May 2010 21:20:59 -0600 |
Can you fill out a bug report at the avr-libc project on Savannah? That way it
won't be forgotten and we can look into it easier.
Thanks,
Eric
> -----Original Message-----
> From:
> address@hidden
> [mailto:address@hidden
org] On Behalf Of Jose Torres
> Sent: Tuesday, May 25, 2010 7:45 PM
> To: address@hidden
> Subject: [avr-libc-dev] Possible Incorrect Interrupt Vector
> Addresses formega168
>
> Hello,
>
> I have been running into an issue using interrupts with
> avr-libc 1.6.7 and
> an atmega168.
>
> According to the mega168 datasheet the following are a sampling of the
> interrupt vector addresses:
>
> Address Labels Code Comments
> 0x0000 jmp RESET ; Reset Handler
> 0x0002 jmp EXT_INT0 ; IRQ0 Handler
> 0x0004 jmp EXT_INT1 ; IRQ1 Handler
> 0x0006 jmp PCINT0 ; PCINT0 Handler
> 0x0008 jmp PCINT1 ; PCINT1 Handler
> 0x000A jmp PCINT2 ; PCINT2 Handler
> 0x000C jmp WDT ; Watchdog Timer Handler
> 0x000E jmp TIM2_COMPA ; Timer2 Compare A Handler
> 0x0010 jmp TIM2_COMPB ; Timer2 Compare B Handler
> 0x0012 jmp TIM2_OVF ; Timer2 Overflow Handler
> 0x0014 jmp TIM1_CAPT ; Timer1 Capture Handler
> 0x0016 jmp TIM1_COMPA ; Timer1 Compare A Handler
> 0x0018 jmp TIM1_COMPB ; Timer1 Compare B Handler
> 0x001A jmp TIM1_OVF ; Timer1 Overflow Handler
> 0x001C jmp TIM0_COMPA ; Timer0 Compare A Handler
> 0x001E jmp TIM0_COMPB ; Timer0 Compare B Handler
> 0x0020 jmp TIM0_OVF ; Timer0 Overflow Handler
>
> iom168.h includes the vectors from iomx8.h.
>
> Which state the vectors as follows:
>
> /* External Interrupt Request 0 */
> #define INT0_vect _VECTOR(1)
> #define SIG_INTERRUPT0 _VECTOR(1)
>
> /* External Interrupt Request 1 */
> #define INT1_vect _VECTOR(2)
> #define SIG_INTERRUPT1 _VECTOR(2)
>
> /* Pin Change Interrupt Request 0 */
> #define PCINT0_vect _VECTOR(3)
> #define SIG_PIN_CHANGE0 _VECTOR(3)
>
> /* Pin Change Interrupt Request 0 */
> #define PCINT1_vect _VECTOR(4)
> #define SIG_PIN_CHANGE1 _VECTOR(4)
>
> /* Pin Change Interrupt Request 1 */
> #define PCINT2_vect _VECTOR(5)
> #define SIG_PIN_CHANGE2 _VECTOR(5)
>
> /* Watchdog Time-out Interrupt */
> #define WDT_vect _VECTOR(6)
> #define SIG_WATCHDOG_TIMEOUT _VECTOR(6)
>
> /* Timer/Counter2 Compare Match A */
> #define TIMER2_COMPA_vect _VECTOR(7)
> #define SIG_OUTPUT_COMPARE2A _VECTOR(7)
>
> These vectors are correct for the 48 and 88 but different for the 168.
>
> Please forgive me if this has been corrected in version 1.6.8.
>
> I am trying to activate PCINT1_vect.
>
> Regards,
> Jose Torres
> _______________________________________________
> AVR-libc-dev mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/avr-libc-dev
>