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_AT90USB1287_EXTERNAL_INTERRUPT_H__
00029 #define __AVR_CPP_AT90USB1287_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/at90usb1287/ExternalInterrupt.h>."
00038 #endif
00039 #endif
00040
00041 #ifndef __AVR_CPP_XXX_EXTERNAL_INTERRUPT_H__
00042 #define __AVR_CPP_XXX_EXTERNAL_INTERRUPT_H__ "at90usb1287/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 #define PCINT0_ns ExternalInterrupt
00056
00057 #define INT0_struct ExternalInterrupt::Interrupt0
00058 #define INT1_struct ExternalInterrupt::Interrupt1
00059 #define INT2_struct ExternalInterrupt::Interrupt2
00060 #define INT3_struct ExternalInterrupt::Interrupt3
00061 #define INT4_struct ExternalInterrupt::Interrupt4
00062 #define INT5_struct ExternalInterrupt::Interrupt5
00063 #define INT6_struct ExternalInterrupt::Interrupt6
00064 #define INT7_struct ExternalInterrupt::Interrupt7
00065 #define PCINT0_struct ExternalInterrupt::PinChangeInterrupt0
00066
00067
00068 namespace AVRCpp
00069 {
00070 namespace ExternalInterrupt
00071 {
00072 struct Interrupt0 : Internal::InterruptBase <
00073 InputPin0<PortD>,
00074 AsyncEvent,
00075 Bits<_EICRA, _ISC00 | _ISC01>,
00076 Bits<_EIMSK, _INT0>,
00077 Bits<_EIFR, _INTF0>,
00078 0 >
00079
00080 { __INTERRUPT_HANDLER_SUPPORT__ };
00081
00082 struct Interrupt1 : Internal::InterruptBase <
00083 InputPin1<PortD>,
00084 AsyncEvent,
00085 Bits<_EICRA, _ISC10 | _ISC11>,
00086 Bits<_EIMSK, _INT1>,
00087 Bits<_EIFR, _INTF1>,
00088 2 >
00089
00090 { __INTERRUPT_HANDLER_SUPPORT__ };
00091
00092 struct Interrupt2 : Internal::InterruptBase <
00093 InputPin2<PortD>,
00094 AsyncEvent,
00095 Bits<_EICRA, _ISC20 | _ISC21>,
00096 Bits<_EIMSK, _INT2>,
00097 Bits<_EIFR, _INTF2>,
00098 4 >
00099
00100 { __INTERRUPT_HANDLER_SUPPORT__ };
00101
00102 struct Interrupt3 : Internal::InterruptBase <
00103 InputPin3<PortD>,
00104 AsyncEvent,
00105 Bits<_EICRA, _ISC30 | _ISC31>,
00106 Bits<_EIMSK, _INT3>,
00107 Bits<_EIFR, _INTF3>,
00108 6 >
00109
00110 { __INTERRUPT_HANDLER_SUPPORT__ };
00111
00112 struct Interrupt4 : Internal::InterruptBase <
00113 InputPin4<PortE>,
00114 Event,
00115 Bits<_EICRB, _ISC40 | _ISC41>,
00116 Bits<_EIMSK, _INT4>,
00117 Bits<_EIFR, _INTF4>,
00118 0 >
00119
00120 { __INTERRUPT_HANDLER_SUPPORT__ };
00121
00122 struct Interrupt5 : Internal::InterruptBase <
00123 InputPin5<PortE>,
00124 Event,
00125 Bits<_EICRB, _ISC50 | _ISC51>,
00126 Bits<_EIMSK, _INT5>,
00127 Bits<_EIFR, _INTF5>,
00128 2 >
00129
00130 { __INTERRUPT_HANDLER_SUPPORT__ };
00131
00132 struct Interrupt6 : Internal::InterruptBase <
00133 InputPin6<PortE>,
00134 Event,
00135 Bits<_EICRB, _ISC60 | _ISC61>,
00136 Bits<_EIMSK, _INT6>,
00137 Bits<_EIFR, _INTF6>,
00138 4 >
00139
00140 { __INTERRUPT_HANDLER_SUPPORT__ };
00141
00142 struct Interrupt7 : Internal::InterruptBase <
00143 InputPin7<PortE>,
00144 Event,
00145 Bits<_EICRB, _ISC70 | _ISC71>,
00146 Bits<_EIMSK, _INT7>,
00147 Bits<_EIFR, _INTF7>,
00148 6 >
00149
00150 { __INTERRUPT_HANDLER_SUPPORT__ };
00151
00152 struct PinChangeInterrupt0 : Internal::PinChangeInterruptBase <
00153 _PCMSK0,
00154 Bits<_PCICR, _PCIE0>,
00155 Bits<_PCIFR, _PCIF0> >
00156
00157 { __INTERRUPT_HANDLER_SUPPORT__ };
00158
00159 }
00160
00161 }
00162
00163 #endif // ifndef __AVR_CPP_AT90USB1287_EXTERNAL_INTERRUPT_H__