mega1280: Made PORTK work
authorMichel Pollet <buserror@gmail.com>
Fri, 6 Apr 2012 17:25:43 +0000 (18:25 +0100)
committerMichel Pollet <buserror@gmail.com>
Fri, 6 Apr 2012 17:25:43 +0000 (18:25 +0100)
This was triggering a limit in the AVR core IO table

Signed-off-by: Michel Pollet <buserror@gmail.com>
examples/board_i2ctest/i2ctest.c
simavr/cores/sim_mega1280.c

index 7d191de..afa5fd7 100644 (file)
@@ -82,9 +82,6 @@ int main(int argc, char *argv[])
        printf( "\nDemo launching:\n");
 
        int state = cpu_Running;
-       while((state!= cpu_Done)&&(state != cpu_Crashed ))
+       while ((state != cpu_Done) && (state != cpu_Crashed))
                state = avr_run(avr);
-
-       printf("\n\nPress enter to terminate the program.");
-       getchar();
 }
index acdecd3..e943cf9 100755 (executable)
@@ -623,7 +623,7 @@ void m1280_init(struct avr_t * avr)
        avr_ioport_init(avr, &mcu->portg);
        avr_ioport_init(avr, &mcu->porth);
        avr_ioport_init(avr, &mcu->portj);
-//     avr_ioport_init(avr, &mcu->portk);
+       avr_ioport_init(avr, &mcu->portk);
        avr_ioport_init(avr, &mcu->portl);
 
        avr_uart_init(avr, &mcu->uart0);