17 #define TWG_MAX_BUF 512
22 typedef struct wg_data_T {
26 uint8_t buff[ TWG_MAX_BUF/8];
35 void null_sock(
void) { memset( this->sock, 0, 64); }
42 int x_open(
const char *_sock,
const char *_what,
int _flags);
45 if ( this->f_rw) close( this->f_rw);
55 ~
CWg(
void) { this->x_close(); }
61 int init(
const char *_sock);
64 inline char *
cur_sock(
void) {
return( this->sock); }
int out0_set(uint8_t _val)
int R(wg_data_t &_buf)
Read Wiegand buffer After this function call Wiegand device buffer gets empty This call is non-blocki...
int mode_get(void)
Get/Set current Tibbit#08 mode.
int init(const char *_sock)
Open Wiegand device on socket _sock.
int mode_set(uint8_t _mode)
I2C bus name to # mapping structure.
int conr_get(void)
Get/Set value of 'clear on read' flag.
int out0_get(void)
Get/Set value of open collector pin.
char * cur_sock(void)
Get current socket name.
Definition: CWg.h:64
int conr_set(uint8_t _val)
Wiegand Tibbit#08 I/O class.
Definition: CWg.h:31