Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1 | ingob | 1 | /*############################################################################ |
2 | ############################################################################*/ |
||
3 | |||
4 | extern volatile unsigned int PPM_Signal; |
||
50 | holgerb | 5 | extern volatile unsigned char PPM_Timeout, anz_ppm_werte; |
1 | ingob | 6 | void InitPPM(void); |
7 | |||
8 | |||
9 | #define INT0_ENABLE GIMSK |= 0x40 |
||
10 | #define INT0_DISABLE GIMSK &= ~0x40 |
||
11 | #define TIM0_START TIMSK |= 0x01 |
||
12 | #define TIM0_STOPP TIMSK &= ~0x01 |
||
13 | #define ICP_INT_ENABLE TIMSK |= 0x20 |
||
14 | #define ICP_INT_DISABLE TIMSK &= ~0x20 |
||
15 | #define TIMER1_INT_ENABLE TIMSK |= 0x04 |
||
16 | #define TIMER1_INT_DISABLE TIMSK &= ~0x04 |
||
17 | #define TIMER2_INT_ENABLE TIMSK |= 0x40 |
||
18 | #define TIMER2_INT_DISABLE TIMSK &= ~0x40 |
||
19 | #define INT0_POS_FLANKE MCUCR |= 0x01 |
||
20 | #define INT0_ANY_FLANKE MCUCR |= 0x01 |
||
21 | #define INT0_NEG_FLANKE MCUCR &= ~0x01 |
||
22 | #define CLR_INT0_FLAG GIFR &= ~0x40 |
||
23 | #define INIT_INT0_FLANKE MCUCR &= ~0x03; MCUCR |= 0x02; |
||
24 | #define TIMER0_PRESCALER TCCR0 |
||
25 | #define ICP_POS_FLANKE TCCR1B |= (1<<ICES1) |
||
26 | #define ICP_NEG_FLANKE TCCR1B &= ~(1<<ICES1) |
||
27 |