ioport: Tweak IRQ names
[simavr] / simavr / cores / sim_megax.c
1 /*
2         sim_megax.c
3
4         Copyright 2008, 2009 Michel Pollet <buserror@gmail.com>
5
6         This file is part of simavr.
7
8         simavr is free software: you can redistribute it and/or modify
9         it under the terms of the GNU General Public License as published by
10         the Free Software Foundation, either version 3 of the License, or
11         (at your option) any later version.
12
13         simavr is distributed in the hope that it will be useful,
14         but WITHOUT ANY WARRANTY; without even the implied warranty of
15         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16         GNU General Public License for more details.
17
18         You should have received a copy of the GNU General Public License
19         along with simavr.  If not, see <http://www.gnu.org/licenses/>.
20  */
21
22 #include "sim_avr.h"
23
24
25 #include "sim_megax.h"
26
27 void mx_init(struct avr_t * avr)
28 {
29         struct mcu_t * mcu = (struct mcu_t*)avr;
30
31         avr_eeprom_init(avr, &mcu->eeprom);
32         avr_flash_init(avr, &mcu->selfprog);
33         avr_watchdog_init(avr, &mcu->watchdog);
34         avr_extint_init(avr, &mcu->extint);
35         avr_ioport_init(avr, &mcu->portb);
36         avr_ioport_init(avr, &mcu->portc);
37         avr_ioport_init(avr, &mcu->portd);
38         avr_uart_init(avr, &mcu->uart);
39         avr_adc_init(avr, &mcu->adc);
40         avr_timer_init(avr, &mcu->timer0);
41         avr_timer_init(avr, &mcu->timer1);
42         avr_timer_init(avr, &mcu->timer2);
43         avr_spi_init(avr, &mcu->spi);
44         avr_twi_init(avr, &mcu->twi);
45 }
46
47 void mx_reset(struct avr_t * avr)
48 {
49 //      struct mcu_t * mcu = (struct mcu_t*)avr;
50 }