00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef __AVR_CPP_ATMEGA64_EXTERNAL_INTERRUPT_H__
00029 #define __AVR_CPP_ATMEGA64_EXTERNAL_INTERRUPT_H__
00030
00031
00032
00033 #ifndef __AVR_CPP_EXTERNAL_INTERRUPT_H__
00034 #ifdef __DOXYGEN__
00035 #include <avr/cpp/ExternalInterrupt.h>
00036 #else
00037 #error "Include <avr/cpp/ExternalInterrupt.h> instead of <avr/cpp/atmega64/ExternalInterrupt.h>."
00038 #endif
00039 #endif
00040
00041 #ifndef __AVR_CPP_XXX_EXTERNAL_INTERRUPT_H__
00042 #define __AVR_CPP_XXX_EXTERNAL_INTERRUPT_H__ "atmega64/ExternalInterrupt.h"
00043 #else
00044 #error "Attempt to include more than one <avr/cpp/XXX/ExternalInterrupt.h> file."
00045 #endif
00046
00047 #define INT0_ns ExternalInterrupt
00048 #define INT1_ns ExternalInterrupt
00049 #define INT2_ns ExternalInterrupt
00050 #define INT3_ns ExternalInterrupt
00051 #define INT4_ns ExternalInterrupt
00052 #define INT5_ns ExternalInterrupt
00053 #define INT6_ns ExternalInterrupt
00054 #define INT7_ns ExternalInterrupt
00055
00056 #define INT0_struct ExternalInterrupt::Interrupt0
00057 #define INT1_struct ExternalInterrupt::Interrupt1
00058 #define INT2_struct ExternalInterrupt::Interrupt2
00059 #define INT3_struct ExternalInterrupt::Interrupt3
00060 #define INT4_struct ExternalInterrupt::Interrupt4
00061 #define INT5_struct ExternalInterrupt::Interrupt5
00062 #define INT6_struct ExternalInterrupt::Interrupt6
00063 #define INT7_struct ExternalInterrupt::Interrupt7
00064
00065
00066 namespace AVRCpp
00067 {
00068 namespace ExternalInterrupt
00069 {
00070 struct Interrupt0 : Internal::InterruptBase <
00071 InputPin0<PortD>,
00072 AsyncEvent,
00073 Bits<_EICRA, _ISC00 | _ISC01>,
00074 Bits<_EIMSK, _INT0>,
00075 Bits<_EIFR, _INTF0>,
00076 0 >
00077
00078 { __INTERRUPT_HANDLER_SUPPORT__ };
00079
00080 struct Interrupt1 : Internal::InterruptBase <
00081 InputPin1<PortD>,
00082 AsyncEvent,
00083 Bits<_EICRA, _ISC10 | _ISC11>,
00084 Bits<_EIMSK, _INT1>,
00085 Bits<_EIFR, _INTF1>,
00086 2 >
00087
00088 { __INTERRUPT_HANDLER_SUPPORT__ };
00089
00090 struct Interrupt2 : Internal::InterruptBase <
00091 InputPin2<PortD>,
00092 AsyncEvent,
00093 Bits<_EICRA, _ISC20 | _ISC21>,
00094 Bits<_EIMSK, _INT2>,
00095 Bits<_EIFR, _INTF2>,
00096 4 >
00097
00098 { __INTERRUPT_HANDLER_SUPPORT__ };
00099
00100 struct Interrupt3 : Internal::InterruptBase <
00101 InputPin3<PortD>,
00102 AsyncEvent,
00103 Bits<_EICRA, _ISC30 | _ISC31>,
00104 Bits<_EIMSK, _INT3>,
00105 Bits<_EIFR, _INTF3>,
00106 6 >
00107
00108 { __INTERRUPT_HANDLER_SUPPORT__ };
00109
00110 struct Interrupt4 : Internal::InterruptBase <
00111 InputPin4<PortE>,
00112 Event,
00113 Bits<_EICRB, _ISC40 | _ISC41>,
00114 Bits<_EIMSK, _INT4>,
00115 Bits<_EIFR, _INTF4>,
00116 0 >
00117
00118 { __INTERRUPT_HANDLER_SUPPORT__ };
00119
00120 struct Interrupt5 : Internal::InterruptBase <
00121 InputPin5<PortE>,
00122 Event,
00123 Bits<_EICRB, _ISC50 | _ISC51>,
00124 Bits<_EIMSK, _INT5>,
00125 Bits<_EIFR, _INTF5>,
00126 2 >
00127
00128 { __INTERRUPT_HANDLER_SUPPORT__ };
00129
00130 struct Interrupt6 : Internal::InterruptBase <
00131 InputPin6<PortE>,
00132 Event,
00133 Bits<_EICRB, _ISC60 | _ISC61>,
00134 Bits<_EIMSK, _INT6>,
00135 Bits<_EIFR, _INTF6>,
00136 4 >
00137
00138 { __INTERRUPT_HANDLER_SUPPORT__ };
00139
00140 struct Interrupt7 : Internal::InterruptBase <
00141 InputPin7<PortE>,
00142 Event,
00143 Bits<_EICRB, _ISC70 | _ISC71>,
00144 Bits<_EIMSK, _INT7>,
00145 Bits<_EIFR, _INTF7>,
00146 6 >
00147
00148 { __INTERRUPT_HANDLER_SUPPORT__ };
00149
00150 }
00151
00152 }
00153
00154 #endif // ifndef __AVR_CPP_ATMEGA64_EXTERNAL_INTERRUPT_H__