Rev 514 | Rev 728 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 514 | Rev 528 | ||
---|---|---|---|
Line 52... | Line 52... | ||
52 | valid_ppm_to_go--; |
52 | valid_ppm_to_go--; |
53 | } else { |
53 | } else { |
54 | ppm = TCNT1 - old_timer1; |
54 | ppm = TCNT1 - old_timer1; |
55 | ppm -= 256; |
55 | ppm -= 256; |
56 | if (ppm < 128) { // we want HUD |
56 | if (ppm < 128) { // we want HUD |
57 | COSD_FLAGS |= COSD_FLAG_HUD; |
57 | COSD_FLAGS_CONFIG |= COSD_FLAG_HUD; |
58 | } else { // we do not want hud |
58 | } else { // we do not want hud |
59 | if (COSD_FLAGS & COSD_FLAG_HUD) { |
59 | if (COSD_FLAGS_CONFIG & COSD_FLAG_HUD) { |
60 | clear(); |
60 | clear(); |
61 | } |
61 | } |
62 | COSD_FLAGS &= ~COSD_FLAG_HUD; |
62 | COSD_FLAGS_CONFIG &= ~COSD_FLAG_HUD; |
63 | } |
63 | } |
64 | } |
64 | } |
65 | EMCUCR |= (1<<ISC2); // next one is rising |
65 | EMCUCR |= (1<<ISC2); // next one is rising |
66 | } |
66 | } |
67 | //write_ndigit_number_u(2, 2, ppm, 1000, 0); // debug |
67 | //write_ndigit_number_u(2, 2, ppm, 1000, 0); // debug |