QTools  6.6.0
Revision History

Version 6.6.0, 2019-08-30

The main purpose of this release is the change in distribution of the QTools collection, which is now bundled together with the QP frameworks (QP/C, QP/C++ and QP-nano) as well as QM into "QP-bundle". This "QP-bundle" provides a single, streamlined and simplified download and installation of all QP frameworks and all the accompanying tools.

Also this release brings significant changes to QTools for Windows. Specifically, the location of the MinGW compiler and Tcl/Tk have been moved to separate directories (as opposed to being co-located in the qtools/bin directory). This facilitates easier upgrades of these 3-rd party tools, and indeed, they have been upgraded in this QTools/Windows release as follows:

  • MinGW-32-bit 8.2.0
  • Tcl/Tk 8.6
Note
The directory re-organization means that the MinGW compiler is no longer available in the qtools/bin directory and therefore the QTools installer for Windows adds to the PATH both qtools/bin and qtools/MinGW/bin directories.

Also, this release makes the following changes to the QSPY host application:

  • The command-line defaults have been changed such that qspy is equivalent to the former qspy -u -t. In other words, QSPY by default opens the UDP port and opens the TCP/IP port for Target connection.
  • The QSPY host application now supports a new QP-compatibility version 6.6.0, in which the Application-Specific QS Trace Records start at offset 100 instead of 70. This is only activated with the -v 660 command-line option, but is in preparation for the future changes in QP/C and QP/C++ frameworks (the upcoming QP/C/C++ 6.6.0).

Version 6.5.1, 2019-06-08

This release adds the debug mode to the QUTest scripting (in Python). Specifically, you can now provide a special value DEBUG to the qutest.py Python script launcher, in which case qutest.py will start in the debug mode, in which it will not launch the host executable and will not reset the Target. Instead, qutest.py will wait for the Target reset and other responses from the Target.

Additionally, this release improves the QTools installation on Windows. Specifically the Windows installer now installs Python and has been re-designed to automatically setup the QTOOLS environment variable and to add QTOOLS%\bin;QTOOLS%\python to the PATH. The uninstaller reverses these changes.


Version 6.4.0, 2019-02-10

This release speeds up the QSPY host application by tweaking the timing constants in the TCP and UDP communication interfaces. The resulting QSPY 6.4.0 runs QUTest tests significantly faster (at least twice as fast) as before.


Version 6.3.8, 2018-12-31

The main purpose of this release is the update of the GNU-ARM toolchain (included in QTools for Windows) to the latest GCC 8. Specifically, this QTools release switches to the official GNU-ARM Embedded Toolchain for Arm Cortex-M and Cortex-R processors maintained by ARM Ltd..

Note
For consistency with the GNU-ARM Embedded Toolchain, the toolchain is now located in the directory qtools\gnu_arm-none-eabi and contains tools with the prefix arm-none-eabi-. This is different than the GNU-ARM toolchain used previously (which was located in qtools\gnu_arm-eabi and used the tools prefix arm-eabi-). This change requires adjusting the existing Makefiles and other build commands for the GNU-ARM toolchain, which has been done in the matching QP/C/C++/nano release 6.3.8.

Additionally, this release makes further improvements to the "qutest.py" Python interface. Specifically, the skip() command can now be used anywhere in the test scripts to skip the commands. (Previously, the skip() command could only be legitimately used right before the test() command).


Version 6.3.7, 2018-11-19

This release brings a completely re-designed and simplified Python interface for QUTest unit testing harness. Specifically, this release adds a new scripting engine called simply qutest.py, which replaces the previous "qspypy".

Note
The new scripting interface qutest.py is now the primary supported QUTest scripting interface. The older interfaces, such as TCL ("qutest.tcl") and "qspypy" are still provided in this release, but they are considered obsolete and are not recommended for writing new test scripts.

The new qutest.py Python interface is a simple single-threaded application that no longer requires PyTest or other such external Python packages, as did "qspypy" previously. The new Python interface is now also compatible with both Python 2 (2.7+) and Python 3 (3.4+), which means that virtually any contemporary Python version without extensions can be used for running QUTest Python scripts.

Note
The new Python interface "qutest.py" implements a different (simpler) structure of QUTest test scripts than "qspypy" before. Examples of the new Python test scripts are provided in the matching QP/C/C++ release 6.3.7.

Additionally, this release fixes the problem in the "QSPY host utility" to correctly format signed integers (I8, I16, I32), which didn't work correctly on 64-bit Linux platforms. Also, the QSPY utility on Windows now uses the newer Windows socket library "ws2_32", which replaced the old "wsock32".

Finally, the QTools release for Windows updates the provided MinGW GNU-C/C++ compiler to version 6.3.0.


Version 6.3.6, 2018-10-03

The main purpose of this release is to improve the QUTest support. Specifically, this release adds a feature of querying and reporting the status of the current objects, such as the current State-Machine (SM), Active-Object (AO), current Memory-Pool(MP), current Event-Queue (EQ), and current Time-Event (TE). The feature impacts the following facilities:

Note
This feature requires matching QP/C/C++ 6.3.6.

Also, the following bugs related to Python scripting have been fixed in the qspypy 6.3.6 included in this release:

Note
If you already have the previous version of qspypy, you need to re-install it by means of the following command:

pip install %QTOOLS%\qspy

Finally, this release of QTools collection contains the Unity unit testing harness (framework).


Version 6.3.4, 2018-08-16

This release adds the official support for writing QUTest test scripts in Python. Also, this release fixes some minor typos in error messages generated by QSpy.


Version 6.3.1, 2018-05-24

This minor release corrects the QSPY utility. Specifically, the application-specific output from the macros QS_FUN(), QS_OBJ() and QS_SIG() contained extra space (' ') before the function/object/signal name. This extra space has been now removed.

Note
The change might impact existing QUTest test scripts, which parse the QS_FUN(), QS_OBJ() or QS_SIG() output.
The corrected QS_FUN(), QS_OBJ() and QS_SIG() output (without the extra space) is assumed in the QUTest examples that ship in QP/C/C++ 6.3.1.

Version 6.3.0, 2018-05-10

This release simplifies the usage of the QUTest (qutest.tcl) and QSpyView (qspyview.tcl) utilities by reducing the number of parameters required by these scripts. Specifically, the "local_port" parameter might be now omitted and still every instance of qutest.tcl / qspyview.tcl will be given a unique local UDP port. Additionally, the "port" parameter has been combined with the "host" parameter in the form host[:port].

Here is the new usage of qutest.tcl script:

tclsh qutest.tcl [test-scripts] [host_exe] [host[:port]] [local_port]

Here is the new usage of qspyview.tcl script:

wish qspyview.tcl [extension_script] [host[:port]] [local_port]

For example, to attach to QSPY running on the host 192.168.1.100 and port 7705, you now can launch these scripts as follows:

tclsh qutest.tcl *.tcl test_fixture.exe 192.168.1.100:7705
wish qspyview.tcl dpp.tcl 192.168.1.100:7705

Modified files:

  • qspy.tcl
  • qspyview.tcl
  • qutest.tcl

Also, this release adds the LMFlash utility to QTools for Windows for flash programming of TM4C MCUs.

Note
The changes should be transparent for most existing QSpyView and QUTest projects (this include all examples shipped in QP/C and QP/C++). However, projects that run QSPY at non-default UDP ports might need to be adjusted.

Version 6.2.0, 2018-03-13

This release updates QSPY host utility as well as the qutest.tcl and qspyview.tcl scripts for the following new QS records introduced in QP/C/C++ 6.2.0:

The global filter settings in the qutest.tcl and qspyview.tcl scripts have been updated to the augmented and re-organized QS trace records.

Additionally, new commands post() and publish() have been added to the QUTest "testing DSL" (qutest.tcl script). Examples of use of these new commands are provided in QP/C/C++ directory <qpc|qpcpp>\examples\qutest\defer\.


Version 6.1.1, 2018-02-06

This release fixes the following bug in QSPY:

Additionally, this release simplifies the format of the external dictionary files, so that they can be potentially generated from .map files or .elf files. The new format no longer requires storing the number of entries in the dictionary and the entries don't need to be sorted by the key-value. The new dictionary format allows also to add comments and empty lines between the dictionary blocks.

Additionally, the QSPY for POSIX (Linux, MacOS, etc.) corrects the problem with reading input from a file (-f[bin_file] command-line option).

Finally, this release increases the QCLEAN maximum size limit to 10MB per file.


Version 6.1.0, 2018-01-20

This release improves the QSPY command-line option processing by allowing option parameters to be separated by spaces from the option letter (including the optional parameters). For example, the following command-line would not work in the previous version, but will work now:

qspy -t 6602

At the same time, the option parameters can follow immediately the option letter, so the following command line will work as well (backwards compatiblity):

qspy -t6602

This release also improves the handling of external dictionary files in QSPY host application. Specifically, the -d command-line option has been extended to allow no parameter, in which case external dictionary file is opened automatically as soon as QSPY receives the target reset or target information. When -d <file> option is used, the provided dictionary file is used right away, but the dictioray information might get discarded when the target information does not match the configuration and time-stamp obtained from the dictionary file.


Version 6.0.3, 2017-12-12

Fixed compilation and linkage on MacOS for qspy, qclean, qfsgen

Fixed bug#180 qspyview.tcl for peek is not in sync with the qs_rx parsing of peek.

Used unsigned integer math in qcalc.tcl

In QTools for Windows, updated the GNU-ARM toolchain to the latest available GCC 7.2.0 adapted from SysProgs Prebuilt GNU toolchain for arm-eabi:

http://gnutoolchains.com/arm-eabi/


Version 5.9.3, 2017-07-04

Fixed bug#175 "QS_QF_ACTIVE_GET & QS_QF_EQUEUE_GET Record Mislabeled in QSPY Output" (https://sourceforge.net/p/qpc/bugs/175/ )

Added bin/qcalc.tcl to the GIT repository (so that it shows up on GitHub).


Version 5.9.1, 2017-05-19

Added the GNU-ARM (EABI) toolset to the QTools Collection for Windows in the directory qtools/gnu_arm-eabi. The addition of the GNU-ARM toolset matches the changes made to Makefiles in QP/C/C++/nano 5.9.2.

To reduce the size of the QTools for Windows download, the self-extracting archive qtools_win32_<ver>.exe has been prepared with the 7-Zip utility.


Version 5.9.0, 2017-05-19

This release adds the QUTest (pronounced 'cutest') Unit Testing support to QP/Spy software tracing. Specifically, this release adds a new head-less (console-based) QSPY front-end that, which runs unit tests.

This release also adapts the QSPY host utility to support QUTest unit testing. Several new commands have been added and the structure of the code has been expanded.

Also, the QSpyView Visualization extension has been moved to the tcl\ sub-directory (the Tcl script tcl\qspyview.tcl).

The other Quantum Leaps utilities, like QClean, QFSGen, and QCalc have been updated and greatly improved.

Finally, all utilities in the QTools collection have been documented in the new QTools Manual available online at: https://www.state-machine.com/qtools


Version 5.7.0, 2016-09-08

Corrected QSPY software tracing host application to properly display floating point numbers in user-defined trace records (QS_F32() and QS_F64() macros). The problem was with incompatibility between Microsoft VC++ and GCC floating-point format specifications. In the GCC software build (which produces the QSPY executable in the qtools/bin directory), the MS-VC++ floating point format resulted in all zeros (e.g., 0.0000e+000).


Version 5.6.4, 2016-05-04

Added QWIN GUI to the collection (sub-directory qwin_gui).

Updated the QSPY software tracing host application for the QS trace record name changes introduced in QP 5.6.2.


Version 5.5.0, 2015-08-21

Extended the QSPY software tracing host application for bi-directional communication with embedded targets (output and input into the target). Added a UDP socket to QSPY, as an extensibility mechanism for adding external unit testing, GUIs and other "front-ends" to control the embedded targets.

Provided new QSpyView Tcl/Tk extension of the QSPY host application for control testing, and visualization of the real-time tracing data from embedded targets at real-time. QSpyView enables developers to rapidly build both GUI-based and "headless" scripts for their specific applications (see https://www.state-machine.com/qpc/arm-cm_dpp_ek-tm4c123gxl.html)


Version 5.3.1, 2014-04-21

Corrected the version representation from hex to decimal, to match the change in the QP framework. The version representation missmatch caused problems in parsing newly modified trace records, when the qspy.c implementation was inserted directly into the projects.


Version 5.3.0, 2014-03-31

Added new trace records to QSPY host application: QS_QEP_TRAN_HIST, QS_QEP_TRAN_EP, and QS_QEP_TRAN_XP. Changed labels for standard records from Q_ENTRY, Q_EXIT, Q_INIT to ENTRY, EXIT, INIT.


Version 5.1.1, 2013-10-15

Fixed the bug in the QSPY host application, which didn't handle correctly object/functions/signal names longer than 32 characters. The name limit has been raised to 64 characters and this version also correctly truncates the names at the limit without printing any garbage characters.


Version 5.1.0a, 2013-09-18

Modified QSPY utility to support changes in QP 5.1.x:

-improved handling of target resets by adding an empty QS record before the QS_QP_RESET record. The empty record provides the frame delimiter in case the last record in incomplete, so that the following QS_QP_RESET record can be recognized.

-improved hanlding of internal object/function/signal dictionaries so that symbolic information is displayd for all occurrences of an object/function/signal, for which a dictionary record was received.


Version 5.0.0a, 2013-09-08

Modified QSPY utility to support changes in QP 5.0.x:

-modified the standard trace records QS_QF_TICK, and QS_QF_TIMEEVT_* to contain the tick-rate number.

-added trace records QS_TEST_RUN and QS_TEST_FAIL for unit testing.

-added version compatibility level 5.0, whereas specifying version -v 4.5 runs qspy in the compatibility mode with QP 4.5.x.

-added Find And Replace Text (FART) utility for Windows


Version 4.5.02, 2012-07-21

Re-designed the QSPY interface to support more flexible parsing of the trace records in desktop-based simulations (such as Windows or Qt). Users can provide a custom parsing callback function to QSPY_config(). Also added QS_RESET() macro to reset the internal dictionaries (and other cleanup in the future) when the target resets.


Version 4.5.01, 2012-06-25

Added the QS_USR_DICTIONARY() entry for storing dictionaries of the user trace records. Replaced all remaining sprintf() calls with snprintf().


Version 4.5.00, 2012-05-26

Re-designed the implementation of the QSPY host application, so that it can be convenienty included as part of the QP library. This allows direct QS tracing output to the screen for QP applications running on the desktop. The QSPY application has been converted from C++ to plain C for easier integration with QP/C.


Version 4.3.00, 2011-11-03

This QSPY version mataches the changes to the critical section macros made in QP 4.3.00. The QS record names QS_QF_INT_LOCK and QS_QF_INT_UNLOCK have been replaced with QS_QF_CRIT_ENTRY and QS_QF_CRIT_EXIT, respectively.


Version 4.2.04, 2011-09-27

This QSPY version fixes the bug of incorrect reporting function or object pointers for which the dictionary records are not provided and which are repeated in one format line (bug #3405904). For example, trace record AO.FIFO would report (incorrectly) as follows:

0014004078 AO.FIFO: Sndr=200009B4 Obj=200009B4 Evt(Sig=00000009,Obj=200009B4, Pool= 0, Ref= 0) Queue(nFree= 5, nMin= 5)

The Sndr= and Obj= are reported to be the same, but they were not.


Version 4.2.01, 2011-08-01

This QSPY version adds generation of sequence diagrams as files to be processed by MscGen (www.mcternan.me.uk/mscgen/). This version adds the option -g<msc_file> to generate .msc file.

Also, this version of QSPY for Windows allows COM ports larger than COM9.


Version 4.2.00, 2011-07-13

This QSPY version matches the changes made to QS target code in QP/C/C++ 4.2.xx. These changes include sending the additinal byte of sender priority in trace records:

  • QS_QF_ACTIVE_POST_FIFO,
  • QS_QF_ACTIVE_POST_LIFO,

Additional changes include sending the poolID and refCtr of events in two bytes instead of just one byte. The changes affect the following trace records:

  • QS_QF_ACTIVE_POST_FIFO,
  • QS_QF_ACTIVE_POST_LIFO,
  • QS_QF_ACTIVE_GET,
  • QS_QF_EQUEUE_GET,
  • QS_QF_ACTIVE_GET_LAST,
  • QS_QF_EQUEUE_GET_LAST,
  • QS_QF_EQUEUE_POST_FIFO,
  • QS_QF_EQUEUE_POST_LIFO,
  • QS_QF_PUBLISH,
  • QS_QF_GC_ATTEMPT, and
  • QS_QF_GC.

Also, for compatibility with the QP 4.2.xx, this version changes the defaults as follows:

signal size (-S) from 1 byte to 2 bytes, and

baud rate (-b) from 38400 to 115200

This version adds the following trace record:

QS_QF_TIMEEVT_CTR

The version also adds compatiblity with 64-bit targets (such as 64-bit linux). This version can accept 8-byte pointers (both object pointers and function pointers) as well as 64-bit integers sent in user-defined trace records.

This version also adds the hex format for uint32_t integers sent in the user-defined trace records.

Finally, this version adds command-line option -v to specify the corresponding QP version running on the target. The default version is -v4.2, but by specifying version -v4.1 or -v4.0 will switch QSPY into the backwards-compatibility mode with the earlier versions of QP.


Version 4.1.06, 2011-02-09

This is the intial standalone release of the QSPY host application. QSPY is still available in the QP/C and QP/C++ distributions, but other rapid prototyping platforms (such as mbed or Arduino) do not use the standard QP distributions and have no easy access to the QSPY tool. For these users, this pre-compiled standalone release is more convenient.

qutest
Definition: qutest.py:1
qutest_dsl.test
def test(title, opt=0)
start a new test
Definition: qutest_dsl.py:33