blob: ddbeb2d8b1ceeff5a952b4ee407b2687fa7337d0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
//This file defines constants corresponding to gpios and digital input functions.
//
// Authors
// Siddhesh Wani
//
#ifndef __AVRPERIPHERALGPIO_H__
#define __AVRPERIPHERALGPIO_H__
#include <avr/io.h>
#ifdef __cplusplus
extern "C" {
#endif
#include <avr/io.h>
#include "types.h"
//Port definitions
#define PORT_A 1
#define PORT_B 2
#define PORT_C 3
#define PORT_D 4
//Direction definitions
#define INPUT 0
#define OUTPUT 1
//Pin state definitions
#define LOW 0
#define HIGH 1
//Function prototypes
uint8 u8AVRDigitalSetups(uint8 port,uint8 pin,uint8 direction);
uint8 u8AVRDigitalIns(uint8 port,uint8 pin);
uint8 u8AVRDigitalOuts(uint8 port,uint8 pin,uint8 state);
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif /* !__AVRPERIPHERALGPIO_H__ */
|