Map27
 All Classes Functions Variables Enumerations Enumerator Pages
Port.h
1 // Port.h
2 //
3 // Author: Mike McCauley (mikem@airspayce.com)
4 // Copyright (C) 2013 Mike McCauley
5 // $Id: Port.h,v 1.5 2013/07/09 23:35:55 mikem Exp $
6 
7 #ifndef MAP27_PORT_H
8 #define MAP27_PORT_H
9 
10 #include <stdint.h>
11 
23 class Map27Port
24 {
25 public:
27  Map27Port();
28 
33  virtual bool configure(uint32_t baud = 9600);
34 
37  virtual bool open();
38 
41  virtual bool close();
42 
47  virtual void send(uint8_t ch);
48 
51  virtual bool canRead();
52 
55  virtual uint8_t read();
56 
57 protected:
59  uint32_t _baud;
60 };
61 
62 
63 #endif
Map27Port()
Constructor.
Definition: Port.cpp:16
uint32_t _baud
The currently configured baud rate.
Definition: Port.h:59
virtual void send(uint8_t ch)
Definition: Port.cpp:37
Abstract superclass for accessing RS232 port on the host.
Definition: Port.h:23
virtual bool configure(uint32_t baud=9600)
Definition: Port.cpp:21
virtual bool canRead()
Definition: Port.cpp:42
virtual uint8_t read()
Definition: Port.cpp:47
virtual bool open()
Definition: Port.cpp:27
virtual bool close()
Definition: Port.cpp:32