Rev 449 | Rev 451 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 449 | Rev 450 | ||
---|---|---|---|
1 | #ifndef QT_SERIAL_COMMUNICATION_H |
1 | #ifndef QT_SERIAL_COMMUNICATION_H |
2 | #define QT_SERIAL_COMMUNICATION_H |
2 | #define QT_SERIAL_COMMUNICATION_H |
3 | #include "Communication.h" |
3 | #include "Communication.h" |
4 | #include "../SerialPort/ManageSerialPort.h" |
4 | #include "../SerialPort/ManageSerialPort.h" |
5 | 5 | ||
6 | /** |
6 | /** |
7 | * QT specific communication class |
7 | * QT specific communication class |
8 | * based on the communication interface |
8 | * based on the communication interface |
9 | * using the SerialPort implementation |
9 | * using the SerialPort implementation |
10 | * by VIANNEY-LIAUD Philippe |
10 | * by VIANNEY-LIAUD Philippe |
11 | * ( philippe.vianney.liaud gmail.com ) |
11 | * ( philippe.vianney.liaud gmail.com ) |
12 | */ |
12 | */ |
13 | 13 | ||
14 | using namespace std; |
14 | using namespace std; |
15 | 15 | ||
16 | class QTSerialCommunication : public Communication { |
16 | class QTSerialCommunication : public Communication { |
17 | private: |
17 | private: |
18 | ManageSerialPort * serial; |
18 | ManageSerialPort * serial; |
19 | public: |
19 | public: |
20 | QTSerialCommunication(); |
20 | QTSerialCommunication(); |
21 | void connect_MK(string addr); |
21 | void connect_MK(char * addr); |
22 | bool send_cmd(char cmd, int address, char data[150], unsigned int length, bool resend); |
22 | void send_cmd(char cmd, int address, char data[150], unsigned int length, bool resend); |
23 | void stop_resend(); |
23 | void stop_resend(); |
24 | }; |
24 | }; |
25 | #endif |
25 | #endif |