Increment version number. Now supports pausing and resuming frame capture without disconnecting from the GVRET hardware.

This commit is contained in:
Collin Kidder
2015-06-02 21:53:23 -04:00
parent d03c439ce3
commit e3d67f20fc
5 changed files with 54 additions and 5 deletions
+19
View File
@@ -84,6 +84,8 @@ MainWindow::MainWindow(QWidget *parent) :
connect(worker, &SerialWorker::connectionFailure, this, &MainWindow::connectionFailed, Qt::QueuedConnection);
connect(worker, &SerialWorker::deviceInfo, this, &MainWindow::gotDeviceInfo, Qt::QueuedConnection);
connect(this, &MainWindow::closeSerialPort, worker, &SerialWorker::closeSerialPort, Qt::QueuedConnection);
connect(this, &MainWindow::startFrameCapturing, worker, &SerialWorker::startFrameCapture);
connect(this, &MainWindow::stopFrameCapturing, worker, &SerialWorker::stopFrameCapture);
serialWorkerThread.start();
graphingWindow = NULL;
@@ -113,6 +115,7 @@ MainWindow::MainWindow(QWidget *parent) :
connect(ui->cbInterpret, SIGNAL(toggled(bool)), this, SLOT(interpretToggled(bool)));
connect(ui->cbOverwrite, SIGNAL(toggled(bool)), this, SLOT(overwriteToggled(bool)));
connect(ui->actionEdit_Messages_Signals, SIGNAL(triggered(bool)), this, SLOT(showDBCEditor()));
connect(ui->btnCaptureToggle, SIGNAL(clicked(bool)), this, SLOT(toggleCapture()));
lbStatusConnected.setText(tr("Not connected"));
updateBaudLabel(0,0);
@@ -125,6 +128,7 @@ MainWindow::MainWindow(QWidget *parent) :
ui->lbNumFrames->setText("0");
isConnected = false;
allowCapture = true;
//create a temporary frame to be able to capture the correct
//default height of an item in the table. Need to do this in case
@@ -731,6 +735,21 @@ void MainWindow::connButtonPress()
}
}
void MainWindow::toggleCapture()
{
allowCapture = !allowCapture;
if (allowCapture)
{
ui->btnCaptureToggle->setText("Suspend Capturing");
emit startFrameCapturing();
}
else
{
ui->btnCaptureToggle->setText("Restart Capturing");
emit stopFrameCapturing();
}
}
void MainWindow::connectionSucceeded(int baud0, int baud1)
{
lbStatusConnected.setText(tr("Connected to GVRET"));