diff options
author | Tod E. Kurt <tod@todbot.com> | 2013-04-29 13:08:01 -0700 |
---|---|---|
committer | Tod E. Kurt <tod@todbot.com> | 2013-04-29 13:08:01 -0700 |
commit | ae341e77f3754dbaa194ba40a17ba222e6cb8ebc (patch) | |
tree | a82efebcb925e6b837b86ee326e75d9f6929fbd9 /arduino-serial-lib.h | |
parent | 8c1844393f695e47058bed64f9bc13b31745df1b (diff) | |
download | arduino-serial-ae341e77f3754dbaa194ba40a17ba222e6cb8ebc.tar.gz arduino-serial-ae341e77f3754dbaa194ba40a17ba222e6cb8ebc.tar.bz2 arduino-serial-ae341e77f3754dbaa194ba40a17ba222e6cb8ebc.zip |
whew big commit. many small changes in core arduino-serial functionality too
Diffstat (limited to 'arduino-serial-lib.h')
-rw-r--r-- | arduino-serial-lib.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/arduino-serial-lib.h b/arduino-serial-lib.h new file mode 100644 index 0000000..234ec27 --- /dev/null +++ b/arduino-serial-lib.h @@ -0,0 +1,20 @@ +// +// arduino-serial-lib -- simple library for reading/writing serial ports +// +// 2006-2013, Tod E. Kurt, http://todbot.com/blog/ +// + + +#ifndef __ARDUINO_SERIAL_LIB_H__ +#define __ARDUINO_SERIAL_LIB_H__ + +#include <stdint.h> // Standard types + +int serialport_init(const char* serialport, int baud); +int serialport_writebyte( int fd, uint8_t b); +int serialport_write(int fd, const char* str); +int serialport_read_until(int fd, char* buf, char until, int buf_max); +int serialport_flush(int fd); + +#endif + |