// Timer/Counter 0 initialization // Clock source: System Clock // Clock value: 2000,000 kHz // Mode: Normal top=0xFF // OC0 output: Disconnected // Timer Period: 0,06 ms ASSR=0<>8; TCNT1L=T1_INIT&0xFF; /* enable Timer1 overflow interrupt */ TIMSK=1<>8; UBRR0L=BAUD_INIT&0xFF; } /* mount logical drive 0: */ { if ((res=f_mount(0,&drive))==FR_OK) { lcd_clear(); lcd_puts("Logical drive 0:\n mounted OK\r\n"); delay_ms(500); } else //if an error occured, display it and stop error(res); } //Hauptprogramm //Referenzpunkte anfahren FN_Referenz(); while (1) { //Automatikbetrieb if (Schalter_Auto == EIN) { FN_Automatikbetrieb(); } //Handbetrieb if (Schalter_Auto == AUS) { FN_Handbetrieb(); } } }