2018-02-26 21:04:46 -08:00
|
|
|
#ifndef __BAD_H__
|
|
|
|
|
#define __BAD_H__
|
|
|
|
|
|
|
|
|
|
#include <stdbool.h>
|
2020-06-27 22:34:13 -07:00
|
|
|
#include <termios.h>
|
2018-02-26 21:04:46 -08:00
|
|
|
|
2018-02-26 21:09:49 -08:00
|
|
|
#include "cdba.h"
|
2018-02-26 21:04:46 -08:00
|
|
|
|
|
|
|
|
void watch_add_readfd(int fd, int (*cb)(int, void*), void *data);
|
|
|
|
|
int watch_add_quit(int (*cb)(int, void*), void *data);
|
2020-10-29 23:43:35 -05:00
|
|
|
void watch_timer_add(int timeout_ms, void (*cb)(void *), void *data);
|
2018-02-26 21:04:46 -08:00
|
|
|
void watch_quit(void);
|
|
|
|
|
int watch_run(void);
|
|
|
|
|
|
2020-06-27 22:34:13 -07:00
|
|
|
int tty_open(const char *tty, struct termios *old);
|
|
|
|
|
|
2023-09-23 21:31:14 +03:00
|
|
|
void cdba_send_buf(int type, size_t len, const void *buf);
|
|
|
|
|
#define cdba_send(type) cdba_send_buf(type, 0, NULL)
|
|
|
|
|
|
2018-02-26 21:04:46 -08:00
|
|
|
#endif
|