blackbox/lowlevel.c

changeset 6
2405aff29a51
parent 4
58529e14c45c
child 7
f4e250d5402b
equal deleted inserted replaced
5:7319de27d44a 6:2405aff29a51
73 LED(2, 0); _delay_ms(50); 73 LED(2, 0); _delay_ms(50);
74 LED(3, 0); _delay_ms(50); 74 LED(3, 0); _delay_ms(50);
75 LED(4, 0); _delay_ms(50); 75 LED(4, 0); _delay_ms(50);
76 LED(5, 0); _delay_ms(50); 76 LED(5, 0); _delay_ms(50);
77 77
78 //TCCR0 = (1<<CS01); //divide by 8 78
79 // setup response receiver timer
80 TCCR0 = (1<<CS01); //divide by 8
81 // interrupt enable + tcnt0 set in timer2
79 82
80 83
81 // setup data bit timer 84 // setup data bit timer
82 TCCR2 = (1<<CS21); //divide by 8 85 TCCR2 = (1<<CS21); //divide by 8
83 TCCR2 |= (1<<WGM21); // set compare match 86 TCCR2 |= (1<<WGM21); // set compare match

mercurial