Subversion Repositories MK3Mag

Rev

Rev 18 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 18 Rev 19
Line -... Line 1...
-
 
1
#ifndef _ANALOG_H_
-
 
2
#define _ANALOG_H_
-
 
3
 
-
 
4
#include <inttypes.h>
-
 
5
#include <avr/io.h>
-
 
6
 
-
 
7
#define FLIP_HIGH  PORTD |=  ((1<<PORTD5)|(1<<PORTD6))
-
 
8
#define FLIP_LOW   PORTD &= ~((1<<PORTD5)|(1<<PORTD6))
-
 
9
 
-
 
10
typedef enum
-
 
11
{
-
 
12
        ADC0 = 0,
-
 
13
        ADC1 = 1,
-
 
14
        ADC2 = 2,
-
 
15
        ADC3 = 3,
-
 
16
        ADC4 = 4,
-
 
17
        ADC5 = 5,
-
 
18
        ADC6 = 6,
-
 
19
        ADC7 = 7,
-
 
20
        REF1V1 = 14,
-
 
21
        AGND = 15
-
 
22
} ADChannel_t;
-
 
23
 
-
 
24
void ADC_Init(void);
-
 
25
uint16_t ADC_GetValue(ADChannel_t channel);
-
 
26
 
-
 
27
#endif // _ANALOG_H_
Line 1... Line -...
1
 
-
 
2
extern void ADC_Init(void);
-
 
3
extern void GetAnalogWerte(void);
-
 
4
extern void AdConvert(void);
-
 
5
extern void FastADConvert(void);
-