Skip to content

Commit

Permalink
7.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
quantum-leaps committed Aug 29, 2022
1 parent e9c6f29 commit 0529923
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 13 deletions.
Binary file added bin/qspy
Binary file not shown.
2 changes: 1 addition & 1 deletion doxygen/Doxyfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#---------------------------------------------------------------------------
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = "QTools"
PROJECT_NUMBER = 7.1.0
PROJECT_NUMBER = 7.1.1
PROJECT_BRIEF = "Collection of Host-Based Tools"
PROJECT_LOGO = ../../ql-doxygen/images/logo_ql.png
OUTPUT_DIRECTORY =
Expand Down
4 changes: 4 additions & 0 deletions doxygen/history.dox
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
/**
@page history Revision History

@section qtools_7_1_1 Version 7.1.0, 2022-08-30
Slightly restructured QSPY source code to better integrate directly with QP applications. Specifically, moved QSPY_cleanup() to qspy.c, so it is available to the applications.


@section qtools_7_1_0 Version 7.1.0, 2022-08-22

__Changes in QSpy__
Expand Down
6 changes: 3 additions & 3 deletions qspy/include/qspy.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
* <[email protected]>
============================================================================*/
/*!
* @date Last updated on: 2022-08-22
* @version Last updated for version: 7.1.0
* @date Last updated on: 2022-08-29
* @version Last updated for version: 7.1.1
*
* @file
* @brief Host API
Expand All @@ -33,7 +33,7 @@
#ifndef QSPY_H
#define QSPY_H

#define QSPY_VER "7.1.0"
#define QSPY_VER "7.1.1"

#ifdef __cplusplus
extern "C" {
Expand Down
8 changes: 6 additions & 2 deletions qspy/source/qspy.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
* <[email protected]>
============================================================================*/
/*!
* @date Last updated on: 2022-08-22
* @version Last updated for version: 7.1.0
* @date Last updated on: 2022-08-29
* @version Last updated for version: 7.1.1
*
* @file
* @brief QSPY host utility: main parser
Expand Down Expand Up @@ -282,6 +282,10 @@ void QSPY_config(QSpyConfig const *config,
l_userRec = ((QSPY_conf.version < 660U) ? OLD_QS_USER : QS_USER);
}
/*..........................................................................*/
void QSPY_cleanup(void) {
QSPY_configMatFile((void*)0);
}
/*..........................................................................*/
void QSPY_configTxReset(QSPY_resetFun txResetFun) {
l_txResetFun = txResetFun;
}
Expand Down
16 changes: 9 additions & 7 deletions qspy/source/qspy_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,9 @@ static char l_seqList[QS_SEQ_LIST_LEN_MAX];

static int l_bePort = 7701; /* default UDP port */
static int l_tcpPort = 6601; /* default TCP port */
static int l_baudRate = 115200; /* default serial baudrate */
static int l_baudRate = 115200; /* default serial baud rate */

/* color rendeing */
/* color rendering */
extern char const * const l_darkPalette[];
extern char const * const l_lightPalette[];
static char const * const *l_colorPalette = l_darkPalette;
Expand Down Expand Up @@ -144,6 +144,7 @@ static char const l_kbdHelpStr[] =

/*..........................................................................*/
static QSpyStatus configure(int argc, char *argv[]);
static void cleanup(void);
static void colorPrintLn(void);
static uint8_t l_buf[8*1024]; /* process input in 8K chunks */

Expand Down Expand Up @@ -203,12 +204,14 @@ int main(int argc, char *argv[]) {
}

/* cleanup .............................................................*/
QSPY_cleanup();
cleanup();
return status;
}

/*..........................................................................*/
void QSPY_cleanup(void) {
static void cleanup(void) {
QSPY_cleanup();

PAL_closeKbd(); /* close the keyboard input (if open) */

if (l_savFile != (FILE *)0) {
Expand All @@ -218,11 +221,10 @@ void QSPY_cleanup(void) {
fclose(l_outFile);
}

QSPY_configMatFile((void*)0);
QSEQ_configFile((void*)0);

if (l_bePort != 0) {
PAL_closeBE(); /* close the Back-End connection */
PAL_closeBE(); /* close the Back-End connection */
}

if (PAL_vtbl.cleanup != 0) {
Expand All @@ -236,7 +238,7 @@ void QSPY_cleanup(void) {
void Q_onAssert(char const * const module, int loc) {
PRINTF_S("\n <ERROR> QSPY ASSERTION failed in Module=%s:%d\n",
module, loc);
QSPY_cleanup();
cleanup();
exit(-1);
}

Expand Down

0 comments on commit 0529923

Please sign in to comment.