| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previous commit 76f293bfb0fd7bab391f96ac822eacc40e4c5176 with adding of
this test to the benchmarks were hasty.
After all it makes sense to place it to auto tests to have opportunity to
run with others together.
Besides, this test is renamed since it is not a loopback, it is an I/O
test with the synchronous approach.
Change-Id: I043a6e0075561167bb29a59a384554ef98dbbd4a
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In case of communication event is triggered in the
waitForBytesWritten() method then necessary to process it with
the _q_completeAsyncCommunication() method, but not with the
_q_completeAsyncRead() method.
Otherwise it leads to false filling of the readBuffer with the
data that were read earlier (or with garbage) which remained in
readChunkBuffer.
The synchronous loopback autotest reproduces a bug without of
this patch.
Tested on Windows 7/8 with the on-board and USB serial ports,
using Qt5.
Task-number: QTBUG-40344
Change-Id: I679109b60f4058c4c6f7e5f02c1f70ba6039d8d8
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Good reason to check of data correctness at transferring and receiving.
In this test are used two serial ports, connected in a null-modem mode:
http://en.wikipedia.org/wiki/Null_modem .
The sender port transfers data to the receiver port. After data are
received is carried out check of equivalence of the transferred and
received data.
Before run of testing it is necessary to set two variable environments
QTEST_SERIALPORT_SENDER and QTEST_SERIALPORT_RECEIVER to specify names
of used serial ports.
This test can reveal errors related with the internal data processing
and also errors of synchronous I/O inside of QSerialPort.
This test is placed in separate "benchmarks" category not to mix-up
with "manual" and "auto" categories, because this test is closer to
"benchmarks" by own functionality.
Tested on Windows 7/8 with the virtual com0com serial ports, using
Qt4 and then Qt5.
Change-Id: Ie6f87b50784bce211cf68c16cf75f79d12a8564f
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Building in OS X uses some shared code from the serialportinfo_unix.cpp
module with the OS X specific code from the serialportinfo_mac.cpp module.
Thus, all code of the serialportinfo_unix.cpp module, which not related
with the OS X, is shielded by a macro. It adds an excessive garbage for
readability in this module and also some confusion in the *.pri file.
It makes sense to make implementation of the serialportinfo_mac.cpp
module completely independent, that will simplify maintaining of source
code.
Besides are added tests which can reveal declared but not implemented
methods in building, and also to check a correctness of default values
at running.
Tested build on OS X 10.8.4 with Qt4, an then on Android with Qt5.
Change-Id: I67935b64e2b623fb8d4c14d59e1b87f1eac71c3e
Reviewed-by: Bernard Pratz <guyzmo+qt@m0g.net>
Reviewed-by: Peter Kümmel <syntheticpp@gmx.net>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The commit 2360c401ae2012ed1b5a2b470a088cbbdb0d7f27 introduced an
regression into waitForReadyRead(). Before this commit each read
transaction was started again until the zero number of bytes will
returns from FIFO. When FIFO is empty, all data has been read, and
only then the waitForReadyRead() return true. I.e. condition
"qint64(readBuffer.size()) != currentReadBufferSize" does not mean
that reading is finished.
But after that commit this condition is incorrect, because now each
read operation started once and can not return zero bytes (in case
the number of read bytes less than ReadChunkSize). Thus it led to
returning of TimeoutError error.
Now, this issue has been fixed. Also is added the set of auto-tests
to testing of the waitForReadyRead() method.
Tested on Windows 7/8 using Qt5 and then Qt4.
Task-number: QTBUG-39314
Change-Id: I8abbf986c2a1cc77af634ddbc1747fb46f416a39
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
| |
Change-Id: I4a6767196d205cf1f0715edfb9ea117a2d7fa5c9
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. The QCOMPARE macro can not make type cast between "int" and
"qint64", though on qt5 there are no problems.
2. The QSKIP macro should accept two input parameters.
Tested build on Lixux 64bit and Windows with Qt4 and then Qt5.
Change-Id: I1f8497201e8d704098faea789bc61829f0d2f9e4
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
In qt4 the macro QCOMPARE can not make type cast between "int" and
"qint64", though on qt5 there are no problems.
Tested build on Lixux 64bit with Qt4 and then Qt5.
Change-Id: I258f8ee4d26b65cc81720d66714ef69df23e7266
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
| |
On Windows a test will be skipped since flush() does not work there
Change-Id: Ibda38401aff5f1c50644c6d61f9802217146a4fb
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
| |
Commit 7c737e0edcb93585856c65890ef34e5c5a28ee6b introduced
this regression by changing the default baud rate from 0 to 9600.
Change-Id: If20315eb53c3416646541dda82add0f4fc12d4a3
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Laszlo Papp <lpapp@kde.org>
|
|
|
|
|
|
|
|
|
|
| |
On QNX, the combination (IHFLOW | OHFLOW) is equivalent to the CRTSCTS flag.
Only /dev/ser* ports can be enumerated.
Tested on SVTronics UEVM5432 Omap5 board with QNX 6.6
Change-Id: I64b149258a525835e63f231b5291fa86637e3d2a
Reviewed-by: Laszlo Papp <lpapp@kde.org>
|
|
|
|
|
|
|
|
|
| |
Now that the settings detection is removed, it would be better to make this API
deprecate because it does not make much sense anymore. It was a bad idea to add
this, but we cannot remove it for now, hence the obsoletion.
Change-Id: I5e02959cb54281995b911ff0f64bd2fa36b80060
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Thanks go to Massimo Callegari for the initial patch and the request to remind
us again. Thanks also go to Denis and Sergey for working on the windows serial
number parser.
Task-number: QTBUG-31981
Change-Id: I60d882280f481eb99d275e0a9c81da50292b1c61
Reviewed-by: Massimo Callegari <massimocallegari@yahoo.it>
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added two types of tests: the constructing tests and the opening tests.
The construction tests are checking of the getters to return of default values.
Also are checking a correctness work of the constructor of class with different
types of a port name.
The opening tests are checking the open() method with the valid/invalid open
modes and with the valid/invalid port names. The results are compared with the
expected behavior (with the error codes and the return values).
Change-Id: I503adf629cf613844bf9b96d8704ff017ea5fcdb
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
|
|
|
|
|
| |
Change-Id: I23025d79468650a62c881d3c8cbedfcb7d039495
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
|
|
|
|
|
|
|
|
|
| |
Nobody tested the serial port and it does not
compile as CRTSCTS is not defined. Lets disable
it until its fixed.
Change-Id: Ifc032194773b166a7fd9502f5d7f518019d80c7c
Reviewed-by: Laszlo Papp <lpapp@kde.org>
|
|
|
|
|
| |
Change-Id: I406517f216e7c73c20439ca2f9a17e60709ef661
Reviewed-by: Laszlo Papp <lpapp@kde.org>
|
|
|
|
|
|
|
|
| |
Manual tests are not suppossed to be run by the CI system, so
removing CONFIG += testcase from the .pro files.
Change-Id: I43a729a22a25d9656a1cf76cf3489b3abb893fbd
Reviewed-by: Laszlo Papp <lpapp@kde.org>
|
|
|
|
|
| |
Change-Id: I6c227b10dd4cb4f5cd8390fa5fae3a282b676f9e
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* This is more intuitive as it is not setting the port with all its settings
like baud rate, flow control, stop bits, parity, and so forth, but only the port
name.
* This will allow in upcoming change to establish a property for the port name
along with a port name changed signal to be useful from different threads, QML,
and so forth.
* Clean up the documentation not to provide internal information to the end
users, and also make the text a bit more concise and better readable.
* Examples are also changed accordingly, to use the new API.
Change-Id: Idbaa8ee2dee17c63fc0278f687ccc231c5ab670f
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
| |
* This is for following the convention in the Qt Project with the rest.
* This fixes examples and tests to build now as all of them are broken due to
the regression.
Change-Id: I3f4d64d97466520aea621da582a64a0d97e32136
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
| |
Not sure an assignment test is needed at all, but it does not hurt either on the
other hand.
Change-Id: I937e8ce41421b457da438eb447b0422257efeb39
Reviewed-by: Thiago Augusto Correa <thiago.correa@gmail.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: Id8af629c2b488050b8accd4c552e9b0ebf366e32
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
| |
"git log --follow /path/to/the/file/in/question" can be used, for instance, for
the renamed files to get the whole history.
Change-Id: I20da087ca88e2c179a6c3232772fa21575e0aa6a
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: Ic19f6843d32260404f72038cf77aa6f686e7a3ff
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Unfortunately, the rename has to happen in a separate commit because of the
limitations of "git":
"git does not track renames of files in history, git only records tree
snapshots. It can try to guess whether a change was a rename, or just unrelated
removal+addition, when asked. You can help this by making the rename in a
different commit from a modification. See man git-log -C and -M"
... so the rename will happen in the next change.
Change-Id: Ibe56eba0a0d2c7489db48a6c519d60d3315c00de
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: I08609cb9c679002262a24b52fc46bbfcabb512d7
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: I8c564f68bb32423957f2171e1c76d8a428f16eb3
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
| |
Use the QTSERIALPORT as a term for internal variables as well to remain
consistent with the freshly chosen module name.
Change-Id: Ia780b105649b39a1eca46702466da5bc31ec5af0
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: Id6414c91a0bc700734873cd798807868865cd453
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
| |
Change-Id: Id5db378b6da89f672cb55fa312e325cd1e9b88ce
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For optimization and build correction for Qt4/Qt5 there was a need for
unification and modification of a tree of projects.
The previous structure of the project didn't meet the changed requirements
for Qt5 that led to errors of build and complication of possibility of
correction of errors of build.
It is necessary to note the main changes:
* Removed not used /modules direcrory with all content, because it is
autogenerated.
* Moved all contents from /src directory to /src/serialport directory. It
was necessary for simplification of the qmake commands at building
for Qt5 (in particular, there is no need to fill out a module name since
it is the name of directory /serialport).
* Changed the exported macro defines Q_ADDON_SERIALPORT_EXPORT to
Q_SERIALPORT_EXPORT and QT_ADDON_SERIALPORT_LIB to QT_SERIALPORT_LIB. It
was necessary for fixing compilation error for unknown reason on Windows
and Qt5 when used MSVC compiler.
Checked on Windows and Gnu/Linux, also this patch fixes bug:
Task-number: QTPLAYGROUND-5
Change-Id: Idc9ba98115d5961a22ae307c0e4034a56f3223b5
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
| |
QSKIP went through a source incompatible change from Qt4 migration to Qt5.
Therefore, the customers cannot build the project with tests (default build)
without such a fix like this.
Change-Id: I376e88db723c61358d00cb737a30cde46e03c3a1
Reviewed-by: Sergey Belyashov <Sergey.Belyashov@gmail.com>
Reviewed-by: Debao Zhang <dbzhang800@gmail.com>
Reviewed-by: Denis Shienkov <scapig@yandex.ru>
|
|
|
|
|
|
|
|
| |
This test checks access to the all available ports, as well do the validation a configuring each port.
Change-Id: Ic3f58b43d9427be9164fae431f4775fb26afc5ca
Reviewed-by: Laszlo Papp <lpapp@kde.org>
Reviewed-by: Denis Shienkov <scapig@yandex.ru>
|
|
|
|
|
|
|
| |
of "Creating a new module or tool for Qt"
Change-Id: I62bba3590a8873bfd03ed6836ac105e0a30d35ba
Reviewed-by: Denis Shienkov <scapig@yandex.ru>
|
| |
|
|
|
|
| |
*nix/bsd OS.
|
|
|
|
|
| |
the data array given size. In this case, control characters 11h and 13h
(XON/XOFF) are not added to the array.
|
|
|
|
|
| |
transmitted/received data packet. In this case, the data in the log are
sorted in a table of 32 characters.
|
|
|
|
| |
whole data packet to 700 msec.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
are created in stack.
|
| |
|
| |
|
| |
|
| |
|
| |
|