00001 /* 00002 * This program is free software; you can redistribute it and/or modify 00003 * it under the terms of the GNU General Public License as published by 00004 * the Free Software Foundation; either version 2 of the License, or 00005 * (at your option) any later version. 00006 * 00007 * This program is distributed in the hope that it will be useful, 00008 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00009 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00010 * GNU Library General Public License for more details. 00011 * 00012 * You should have received a copy of the GNU General Public License 00013 * along with this program; if not, write to the Free Software 00014 * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301, USA 00015 * 00016 * atmega8.h 00017 * 00018 * Created on: 15.10.2010 00019 * Author: ivica 00020 */ 00021 00022 #ifndef ATMEGA8_H_ 00023 #define ATMEGA8_H_ 00024 00025 #include "avrdevice.h" 00026 #include "hardware.h" 00027 #include "rwmem.h" 00028 #include "hwtimer/timerprescaler.h" 00029 #include "hwtimer/timerirq.h" 00030 #include "hwtimer/hwtimer.h" 00031 #include "externalirq.h" 00032 #include "hwuart.h" 00033 #include "hwspi.h" 00034 #include "hwad.h" 00035 #include "pin.h" 00036 00038 class AvrDevice_atmega8: public AvrDevice { 00039 00040 public: 00041 Pin aref; 00042 HWPort *portb; 00043 HWPort *portc; 00044 HWPort *portd; 00045 ExternalIRQHandler *extirq; 00046 IOSpecialReg *gicr_reg; 00047 IOSpecialReg *gifr_reg; 00048 IOSpecialReg *mcucr_reg; 00049 IOSpecialReg *mcucsr_reg; 00050 00051 HWAdmux *admux; 00052 HWAd *ad; 00053 00054 IOSpecialReg *assr_reg; 00055 IOSpecialReg *sfior_reg; 00056 HWPrescaler *prescaler01; 00057 HWPrescalerAsync *prescaler2; 00058 ICaptureSource *inputCapture1; 00059 HWTimer8_0C* timer0; 00060 HWTimer16_2C2* timer1; 00061 HWTimer8_1C* timer2; 00062 TimerIRQRegister* timer012irq; 00063 HWSpi *spi; 00064 HWUsart *usart; 00065 00066 AvrDevice_atmega8(); 00067 virtual ~AvrDevice_atmega8(); 00068 }; 00069 00070 #endif /* ATMEGA8_H_ */