A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: Function create_function() is deprecated

Filename: geshi/geshi.php

Line Number: 4751

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876

A PHP Error was encountered

Severity: Warning

Message: Cannot modify header information - headers already sent by (output started at /home/Jenja/www/mcpaste.de/www/system/core/Exceptions.php:272)

Filename: view/raw.php

Line Number: 2

// Lösung zu Termin3 // Aufgabe 1 // von: // vom: // #include "../h/pmc.h" #include "../h/tc.h" #include "../h/pio.h" #include "../h/aic.h" void taste_irq_handler (void) __attribute__ ((interrupt)); // Interruptserviceroutine für die Tasten SW1 und SW2 void taste_irq_handler (void) { StructPIO* piobaseA = PIOA_BASE; StructPIO* piobaseB = PIOB_BASE; // Basisadresse PIO B StructAIC* aicbase = AIC_BASE; // Basisadresse des Advanced interrupt controllers // ab hier entsprechend der Aufgabestellung ergänzen // ************************************************* if(!(piobaseB->PIO_PDSR & KEY1)) { piobaseA->PIO_PER = (1<PIO_PDSR & KEY2)) { piobaseA->PIO_PDR = (1<AIC_EOICR = piobaseB->PIO_ISR; //Ende der Interruptserviceroutine } // Timer3 initialisieren void Timer3_init( void ) { StructTC* timerbase3 = TCB3_BASE; // Basisadressse TC Block 1 StructPIO* piobaseA = PIOA_BASE; // Basisadresse PIO B timerbase3->TC_CCR = TC_CLKDIS; // Disable Clock // Initialize the mode of the timer 3 timerbase3->TC_CMR = TC_ACPC_CLEAR_OUTPUT | //ACPC : Register C clear TIOA TC_ACPA_SET_OUTPUT | //ACPA : Register A set TIOA TC_WAVE | //WAVE : Waveform mode TC_CPCTRG | //CPCTRG : Register C compare trigger enable TC_CLKS_MCK8; //TCCLKS : MCKI / 8 // Initialize the counter: timerbase3->TC_RA = 31250; //50% High timerbase3->TC_RC = 62500; // // Start the timer : timerbase3->TC_CCR = TC_CLKEN ; // Timer Enable timerbase3->TC_CCR = TC_SWTRG ; // Softwaretrigger piobaseA->PIO_PER = (1<PIO_OER = (1<PIO_CODR = (1< kein anderes signal liegt an } int main(void) { StructPMC* pmcbase = PMC_BASE; // Basisadresse des PMC StructPIO* piobaseA = PIOA_BASE; // Basisadresse PIO A StructPIO* piobaseB = PIOB_BASE; // Basisadresse PIO B StructAIC* aicbase = AIC_BASE; pmcbase->PMC_PCER = 0x6200; // Peripheral Clocks einschalten für PIOB, Timer3 // ab hier entsprechend der Aufgabestellung ergänzen //************************************************** Timer3_init(); piobaseA->PIO_PDR = (1<PIO_PER = KEY1 | KEY2; /*########### Interrupt Service Routine ausführbar machen ################*/ aicbase->AIC_IDCR = 1 << 14; aicbase->AIC_ICCR = 1 << 14; aicbase->AIC_SVR[PIOB_ID] = (unsigned int)taste_irq_handler; aicbase->AIC_SMR[PIOB_ID] = 0x7; aicbase->AIC_IECR = 1 << 14; piobaseB->PIO_IER = KEY1 | KEY2; while(1) { } aicbase->AIC_IDCR = 1 << 14; // Interrupt PIOB ausschalten aicbase->AIC_ICCR = 1 << 14; // Interrupt PIOB löschen return 0; }

A PHP Error was encountered

Severity: 8192

Message: strpos(): Non-string needles will be interpreted as strings in the future. Use an explicit chr() call to preserve the current behavior

Filename: database/DB_driver.php

Line Number: 1876