-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdevice.h
46 lines (29 loc) · 762 Bytes
/
device.h
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
46
#ifndef DEVICE_H_INCLUDED
#define DEVICE_H_INCLUDED
#include <sys/types.h>
#include <errno.h>
#define ERR_PUTS(m) \
do \
{ \
if(errno) \
perror(m); \
\
}while(0)
int camera_fd;
typedef struct{
void* start;
size_t length;
}Videobuf;
Videobuf* buffer;
//void suc_err(int res, char* str);
int bufs_num;
int counter;
int okindex;
unsigned char* tmp_buf;
int on_off;
extern void install_dev();
extern void uninstall_dev();
extern int get_frame();
extern int cam_on();
extern int cam_off();
#endif // DEVICE_H_INCLUDED