IEEE 802.15.4 subsystem
Sign in or create your account | Project List | Help
IEEE 802.15.4 subsystem Git Source Tree
Root/
| Source at commit b0a3001ca23e9ba9a0d004b9971563cc5ef659ea created 7 years 3 months ago. By Werner Almesberger, atusb/atusb.kicad_pcb (C15): resolve silk screen on pad; add via | |
|---|---|
| 1 | /* |
| 2 | * include/netio.h - Helper functions for socket I/O |
| 3 | * |
| 4 | * Written 2011 by Werner Almesberger |
| 5 | * Copyright 2011 Werner Almesberger |
| 6 | * |
| 7 | * This program is free software; you can redistribute it and/or modify |
| 8 | * it under the terms of the GNU General Public License as published by |
| 9 | * the Free Software Foundation; either version 2 of the License, or |
| 10 | * (at your option) any later version. |
| 11 | */ |
| 12 | |
| 13 | |
| 14 | #ifndef NETIO_H |
| 15 | #define NETIO_H |
| 16 | |
| 17 | #include <stdint.h> |
| 18 | #include <sys/types.h> |
| 19 | |
| 20 | |
| 21 | struct netio; |
| 22 | |
| 23 | extern int netio_verbose; |
| 24 | |
| 25 | int netio_getc(struct netio *dsc, uint8_t *res); |
| 26 | ssize_t netio_read_until(struct netio *dsc, const char *end, void *buf, |
| 27 | size_t len, char *last); |
| 28 | ssize_t netio_read(struct netio *dsc, void *buf, size_t len); |
| 29 | int netio_write(struct netio *dsc, const void *data, size_t len); |
| 30 | int netio_printf(struct netio *dsc, const char *fmt, ...); |
| 31 | struct netio *netio_open(int s); |
| 32 | void netio_close(struct netio *dsc); |
| 33 | |
| 34 | #endif /* !NETIO_H */ |
| 35 | |
