2021-06-26 17:15:17 +00:00
|
|
|
#include <avr/io.h>
|
|
|
|
#include <avr/interrupt.h>
|
2021-07-03 13:02:01 +00:00
|
|
|
#include "const.h"
|
|
|
|
|
|
|
|
char line_buffer[LINE_BUFFER_SIZE];
|
2021-06-26 17:15:17 +00:00
|
|
|
|
2021-06-26 20:34:22 +00:00
|
|
|
ISR(INT0_vect, ISR_NAKED) {
|
2021-06-26 21:42:23 +00:00
|
|
|
asm("jmp int_vertical_sync");
|
|
|
|
}
|
|
|
|
ISR(INT1_vect, ISR_NAKED) {
|
|
|
|
asm("jmp int_horizontal_sync");
|
2021-06-26 17:15:17 +00:00
|
|
|
}
|
2021-07-03 09:54:31 +00:00
|
|
|
ISR(TIMER0_COMPA_vect, ISR_NAKED) {
|
|
|
|
asm("jmp int_timer_0");
|
|
|
|
}
|
2021-07-03 13:02:01 +00:00
|
|
|
|
|
|
|
void main_c() {
|
|
|
|
for (int i = 0; i < LINE_BUFFER_SIZE; ++i) {
|
|
|
|
line_buffer[i] = (i % 2) ? 0x0 : 0xff;
|
|
|
|
}
|
|
|
|
}
|