summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXaviDCR92 <xavi.dcr@gmail.com>2018-06-12 23:08:23 +0200
committerXaviDCR92 <xavi.dcr@gmail.com>2018-06-12 23:08:23 +0200
commit76bfdf2712f64ce645ee4b3b60876c0e69806761 (patch)
tree1096b8ddecb98f17caafd32d9b02d7719051587e
parent1c3712dfa33757b11ff9b3082903e92f038e7b3d (diff)
+ Added project file.
* Minor changes.
-rw-r--r--QPSXSerial.pro22
-rw-r--r--qpsxserial.cpp11
-rw-r--r--qpsxserial.h4
-rw-r--r--release/QPSXSerial.exebin87552 -> 90112 bytes
-rw-r--r--stdout.ui50
5 files changed, 61 insertions, 26 deletions
diff --git a/QPSXSerial.pro b/QPSXSerial.pro
new file mode 100644
index 0000000..d34d98d
--- /dev/null
+++ b/QPSXSerial.pro
@@ -0,0 +1,22 @@
+#-------------------------------------------------
+#
+# Project created by QtCreator 2017-06-08T22:41:39
+#
+#-------------------------------------------------
+
+QT += core gui serialport
+CONFIG += console
+
+greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
+
+TARGET = QPSXSerial
+TEMPLATE = app
+win32:QT += winextras
+
+SOURCES += main.cpp\
+ qpsxserial.cpp
+
+HEADERS += qpsxserial.h
+
+FORMS += qpsxserial.ui \
+ stdout.ui
diff --git a/qpsxserial.cpp b/qpsxserial.cpp
index 0da333c..8e774e3 100644
--- a/qpsxserial.cpp
+++ b/qpsxserial.cpp
@@ -17,6 +17,7 @@ QPSXSerial::QPSXSerial(QWidget *parent, APP_INTERFACE interface) :
lost_packet_timer = new QTimer();
+ disable_psx_stdout = false;
connect(lost_packet_timer, SIGNAL(timeout()), this, SLOT(onPacketLost()));
connect(&serial, SIGNAL(bytesWritten(qint64)), this, SLOT(onBytesWritten(qint64)));
@@ -38,8 +39,12 @@ QPSXSerial::QPSXSerial(QWidget *parent, APP_INTERFACE interface) :
stdout_ui->setupUi(stdout_dialog);
+ connect(stdout_ui->clean_Btn, SIGNAL(released()), stdout_ui->stdout_Log, SLOT(clear()));
connect(stdout_ui->close_Btn, SIGNAL(released()), stdout_dialog, SLOT(close()));
connect(this, SIGNAL(debug_frame_received(QString)), stdout_ui->stdout_Log, SLOT(append(QString)));
+
+ setWindowTitle( "QPSXSerial " +
+ QString(QPSXSERIAL_VERSION_STR) );
}
ack = false;
@@ -240,6 +245,8 @@ void QPSXSerial::onReadyRead(void)
}
}
+ qDebug() << data;
+
if(cdrom_petition == true)
{
if(data.contains("#") == true)
@@ -529,7 +536,9 @@ void QPSXSerial::sendData(QByteArray data, QString fileName)
}
else if(app_interface == CLI_APP)
{
- if( (i - last_i) > data.count() >> 7)
+ if( ( (i - last_i) > (data.count() >> 7))
+ ||
+ (i > (data.count() - (data.count() >> 7) ) ) )
{
int j;
bool draw_arrow = true;
diff --git a/qpsxserial.h b/qpsxserial.h
index 10b7faa..18b2c12 100644
--- a/qpsxserial.h
+++ b/qpsxserial.h
@@ -13,8 +13,8 @@
#include <iostream>
#include "ui_stdout.h"
-#define QPSXSERIAL_VERSION_NUMBER 0.3
-#define QPSXSERIAL_VERSION_STR "0.3"
+#define QPSXSERIAL_VERSION_NUMBER 0.4
+#define QPSXSERIAL_VERSION_STR "0.4"
#define QPSXSERIAL_URL "https://github.com/XaviDCR92/OpenSend"
#define OPENSEND_URL "https://github.com/XaviDCR92/QPSXSerial/"
diff --git a/release/QPSXSerial.exe b/release/QPSXSerial.exe
index d60c080..2602781 100644
--- a/release/QPSXSerial.exe
+++ b/release/QPSXSerial.exe
Binary files differ
diff --git a/stdout.ui b/stdout.ui
index 9263723..da178fd 100644
--- a/stdout.ui
+++ b/stdout.ui
@@ -13,29 +13,33 @@
<property name="windowTitle">
<string>Stdout Console</string>
</property>
- <widget class="QPushButton" name="close_Btn">
- <property name="geometry">
- <rect>
- <x>280</x>
- <y>260</y>
- <width>75</width>
- <height>23</height>
- </rect>
- </property>
- <property name="text">
- <string>Close</string>
- </property>
- </widget>
- <widget class="QTextEdit" name="stdout_Log">
- <property name="geometry">
- <rect>
- <x>30</x>
- <y>20</y>
- <width>321</width>
- <height>231</height>
- </rect>
- </property>
- </widget>
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QTextEdit" name="stdout_Log">
+ <property name="readOnly">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item row="1" column="0">
+ <layout class="QHBoxLayout" name="horizontalLayout">
+ <item>
+ <widget class="QPushButton" name="clean_Btn">
+ <property name="text">
+ <string>Clean</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="close_Btn">
+ <property name="text">
+ <string>Close</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
+ </item>
+ </layout>
</widget>
<resources/>
<connections/>