I'm stuck with a problem and I can not figure out why it can not work.
I setup a interrupt that will start with a Timer1 Compare A Handler.
Every time the interrupt is started it is the meaning that it reads the value on 1 of the ADC pins. But noting is happening.
What should happen is the next:
I tied a 10K potentiometer to ADC0 and a LED to PD6 and PD7. When the Voltage on ADC0 is under 2V5 or above 1 of the LEDs is turned on.
But this is not working.
I tied AVcc to Vcc and put Aref with 100nF to GND.
I included the Main file PT544.asm and the interrupt.
By the way I set the prescaler to 128 because in the futher I want to use a 16Mhz crystal.
Maybe one of you can help me to find out what I'm doing wrong.