cons.h 352 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
#ifndef EXCIT_CONS_H
#define EXCIT_CONS_H

#include "excit.h"
#include "dev/excit.h"

struct circular_fifo_s {
	ssize_t length;
	ssize_t start;
	ssize_t end;
	ssize_t size;
	ssize_t *buffer;
};

struct cons_it_s {
	excit_t it;
	ssize_t n;
	struct circular_fifo_s fifo;
};

extern struct excit_func_table_s excit_cons_func_table;

#endif //EXCIT_CONS_H