From 22f1fce330059ef8a383cf327a023d6a9da5ad3e Mon Sep 17 00:00:00 2001 From: "Matthias P. Braendli" Date: Mon, 15 Feb 2016 02:44:20 +0100 Subject: Include toolame-dab as library --- libtoolame-dab/xpad.h | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 libtoolame-dab/xpad.h (limited to 'libtoolame-dab/xpad.h') diff --git a/libtoolame-dab/xpad.h b/libtoolame-dab/xpad.h new file mode 100644 index 0000000..cd0a434 --- /dev/null +++ b/libtoolame-dab/xpad.h @@ -0,0 +1,28 @@ +#ifndef _XPAD_H_ +#define _XPAD_H_ + +#include + +/* Initialise the xpad reader + * + * pad_fifo is the filename of the FIFO that will be created, and + * can be used with mot-encoder. + * + * pad_len is the XPAD length, that also has to be given + * to mot-encoder. + * + * returns 0 on success + * -1 on failure + */ +int xpad_init(char* pad_fifo, int pad_len); + +/* Get len bytes of x-pad data, write into buf + * returns either + * - len if the read was sucessful + * - 0 if there was no data + * - -1 if there was an error (errno will be set) + */ +int xpad_read_len(uint8_t* buf, int len); + +#endif + -- cgit v1.2.3