1 #ifndef MSP_IO_SERIAL_H_
2 #define MSP_IO_SERIAL_H_
4 #include "eventobject.h"
5 #include "eventreader.h"
11 class Serial: public EventObject
26 Serial(const std::string &);
33 virtual void set_block(bool);
35 void set_baud_rate(unsigned);
36 void set_data_bits(unsigned);
37 void set_parity(Parity);
38 void set_stop_bits(unsigned);
39 void set_parameters(const std::string &);
42 virtual unsigned do_write(const char *, unsigned);
43 virtual unsigned do_read(char *, unsigned);
46 virtual const Handle &get_event_handle() { return reader.get_event(); }