Rev 1309 | Rev 1311 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | SVN | RSS feed
| Rev 1309 | Rev 1310 | ||
|---|---|---|---|
| Line 6... | Line 6... | ||
| 6 | */ |
6 | */ |
| 7 | 7 | ||
| 8 | #ifndef CANNET_H_ |
8 | #ifndef CANNET_H_ |
| 9 | #define CANNET_H_ |
9 | #define CANNET_H_ |
| 10 | 10 | ||
| 11 | #include " |
11 | #include "broker/Subscriber.h" |
| 12 | #include " |
12 | #include "broker/Broker.h" |
| 13 | #include " |
13 | #include "message/Message.h" |
| 14 | #include " |
14 | #include "message/Header.h" |
| 15 | #include " |
15 | #include "utils/BitBuffer.h" |
| 16 | #include " |
16 | #include "utils/UdpServer.h" |
| 17 | #include " |
17 | #include "utils/Logger.h" |
| 18 | #include <boost/make_shared.hpp> |
18 | #include <boost/make_shared.hpp> |
| 19 | #include <boost/bind.hpp> |
19 | #include <boost/bind.hpp> |
| 20 | #include <boost/signal.hpp> |
20 | #include <boost/signal.hpp> |
| 21 | #include <string> |
21 | #include <string> |
| 22 | #include " |
22 | #include "types.h" |
| 23 | 23 | ||
| 24 | namespace atom { |
24 | namespace atom { |
| 25 | namespace subscribers { |
25 | namespace subscribers { |
| 26 | 26 | ||
| 27 | using namespace |
27 | using namespace broker; |
| 28 | using namespace |
28 | using namespace utils; |
| 29 | using namespace |
29 | using namespace message; |
| 30 | using namespace std; |
30 | using namespace std; |
| 31 | 31 | ||
| 32 | // public boost::signals::trackable, |
32 | // public boost::signals::trackable, |
| 33 | class CanNet : public Subscriber |
33 | class CanNet : public Subscriber |
| 34 | { |
34 | { |
| Line 49... | Line 49... | ||
| 49 | enum |
49 | enum |
| 50 | { |
50 | { |
| 51 | PACKET_START = 253, PACKET_END = 250, PACKET_PING = 251 |
51 | PACKET_START = 253, PACKET_END = 250, PACKET_PING = 251 |
| 52 | }; |
52 | }; |
| 53 | 53 | ||
| 54 |
|
54 | UdpServer::pointer myUdpServer; |
| 55 | udp::endpoint myEndpoint; |
55 | udp::endpoint myEndpoint; |
| 56 | // TODO Add mutex lock for access to the buffer or are we safe? |
56 | // TODO Add mutex lock for access to the buffer or are we safe? |
| 57 | byte_list myBuffer; |
57 | byte_list myBuffer; |
| 58 | 58 | ||
| 59 | private: |
59 | private: |