Updates to cause connection to GVRET to be easier to verify. It should be pretty clear when you are connected now.

This commit is contained in:
Collin Kidder
2015-05-19 22:46:56 -04:00
parent 2841a2a72c
commit feccc2336d
5 changed files with 119 additions and 50 deletions
+6 -2
View File
@@ -15,7 +15,8 @@ enum STATE //keep this enum synchronized with the Arduino firmware project
GET_DIG_INPUTS,
GET_ANALOG_INPUTS,
SET_DIG_OUTPUTS,
SETUP_CANBUS
SETUP_CANBUS,
GET_CANBUS_PARAMS
};
class SerialWorker : public QObject
@@ -29,6 +30,8 @@ public:
signals: //we emit signals
void error(const QString &);
void receivedFrame(CANFrame *);
void connectionSuccess(int, int);
void connectionFailure();
private slots: //we receive things in slots
void readSerialData();
@@ -38,7 +41,6 @@ public slots:
void sendFrame(const CANFrame *, int);
void updateBaudRates(int, int);
private:
QString portName;
bool quit;
@@ -46,6 +48,8 @@ private:
STATE rx_state;
int rx_step;
CANFrame *buildFrame;
int can0Baud, can1Baud;
bool can0Enabled, can1Enabled;
void procRXChar(unsigned char);
};