Fix potential crash bug in serial worker, add ability to define ECU
scanning range in UDS scanner
This commit is contained in:
@@ -435,6 +435,7 @@ void SerialWorker::handleTick()
|
||||
{
|
||||
if (!gotValidated)
|
||||
{
|
||||
if (serial == NULL) return;
|
||||
if (serial->isOpen()) //if it's still false we have a problem...
|
||||
{
|
||||
qDebug() << "Comm validation failed. ";
|
||||
|
||||
+4
-1
@@ -36,13 +36,16 @@ void UDSScanWindow::scanUDS()
|
||||
sendingFrames.clear();
|
||||
|
||||
CANFrame frame;
|
||||
int startID, endID;
|
||||
startID = Utility::ParseStringToNum(ui->txtStartID->text());
|
||||
endID = Utility::ParseStringToNum(ui->txtEndID->text());
|
||||
|
||||
int buses = ui->cbBuses->currentIndex();
|
||||
buses++;
|
||||
if (buses < 1) buses = 1;
|
||||
for (int typ = 1; typ < 5; typ++)
|
||||
{
|
||||
for (int id = 0x7E0; id < 0x7E8; id++)
|
||||
for (int id = startID; id < endID; id++)
|
||||
{
|
||||
frame.ID = id;
|
||||
frame.len = 8;
|
||||
|
||||
@@ -24,6 +24,46 @@
|
||||
<item>
|
||||
<widget class="QListWidget" name="listResults"/>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_4">
|
||||
<property name="text">
|
||||
<string>Starting ID</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="txtStartID">
|
||||
<property name="text">
|
||||
<string>0x7E0</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_3">
|
||||
<property name="text">
|
||||
<string>Ending ID</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="txtEndID">
|
||||
<property name="text">
|
||||
<string>0x7E7</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
|
||||
Reference in New Issue
Block a user