quarchpy 2.2.5__py2.py3-none-any.whl → 2.2.7.dev1__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- quarchpy/.idea/misc.xml +4 -1
- quarchpy/.idea/modules.xml +0 -1
- quarchpy/.idea/quarchpy.iml +1 -2
- quarchpy/.idea/workspace.xml +28 -72
- quarchpy/_version.py +1 -1
- quarchpy/config_files/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/config_files/__pycache__/quarch_config_parser.cpython-313.pyc +0 -0
- quarchpy/connection_specific/QPS/win-amd64/app.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/README.txt +2 -2
- quarchpy/connection_specific/QPS/win-amd64/qis/help.txt +2 -2
- quarchpy/connection_specific/QPS/win-amd64/qis/qis.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/{CInterface-2.2.jar → CInterface-2.3.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/QuarchCommon-2.0.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/TorridonCommon-1.0.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/jmdns-3.6.0.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/usb4java-1.3.1.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps-command-reference.html +331 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/JFXUtilities-1.0.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/QuarchCommon-2.0.jar +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/lin-x64/{javafx-base-21.0.4-linux.jar → javafx-base-21.0.5-linux.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/lin-x64/{javafx-controls-21.0.4-linux.jar → javafx-controls-21.0.5-linux.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/lin-x64/{javafx-fxml-21.0.4-linux.jar → javafx-fxml-21.0.5-linux.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/lin-x64/{javafx-graphics-21.0.4-linux.jar → javafx-graphics-21.0.5-linux.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/lin-x64/{javafx-swing-21.0.4-linux.jar → javafx-swing-21.0.5-linux.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-arm64/{javafx-base-21.0.4-mac-aarch64.jar → javafx-base-21.0.5-mac-aarch64.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-arm64/{javafx-controls-21.0.4-mac-aarch64.jar → javafx-controls-21.0.5-mac-aarch64.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-arm64/{javafx-fxml-21.0.4-mac-aarch64.jar → javafx-fxml-21.0.5-mac-aarch64.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-arm64/{javafx-graphics-21.0.4-mac-aarch64.jar → javafx-graphics-21.0.5-mac-aarch64.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-arm64/{javafx-swing-21.0.4-mac-aarch64.jar → javafx-swing-21.0.5-mac-aarch64.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-x64/{javafx-base-21.0.4-mac.jar → javafx-base-21.0.5-mac.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-x64/{javafx-controls-21.0.4-mac.jar → javafx-controls-21.0.5-mac.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-x64/{javafx-fxml-21.0.4-mac.jar → javafx-fxml-21.0.5-mac.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-x64/{javafx-graphics-21.0.4-mac.jar → javafx-graphics-21.0.5-mac.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/mac-x64/{javafx-swing-21.0.4-mac.jar → javafx-swing-21.0.5-mac.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/win-x64/{javafx-base-21.0.4-win.jar → javafx-base-21.0.5-win.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/win-x64/{javafx-controls-21.0.4-win.jar → javafx-controls-21.0.5-win.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/win-x64/{javafx-fxml-21.0.4-win.jar → javafx-fxml-21.0.5-win.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/win-x64/{javafx-graphics-21.0.4-win.jar → javafx-graphics-21.0.5-win.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qps_lib/win-x64/{javafx-swing-21.0.4-win.jar → javafx-swing-21.0.5-win.jar} +0 -0
- quarchpy/connection_specific/QPS/win-amd64/scriptCommands.txt +59 -3
- quarchpy/connection_specific/QPS/win-amd64/whats-new.txt +12 -20
- quarchpy/connection_specific/__pycache__/StreamChannels.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_QIS.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_QPS.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_ReST.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_Serial.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_TCP.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_Telnet.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/connection_USB.cpython-313.pyc +0 -0
- quarchpy/connection_specific/__pycache__/mDNS.cpython-313.pyc +0 -0
- quarchpy/connection_specific/connection_QPS.py +7 -3
- quarchpy/connection_specific/connection_QPS.py.bak +242 -0
- quarchpy/connection_specific/jdk_j21_jres/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/connection_specific/jdk_j21_jres/__pycache__/fix_permissions.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/__pycache__/serialutil.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/__pycache__/serialwin32.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/__pycache__/win32.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/tools/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/tools/__pycache__/list_ports.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/tools/__pycache__/list_ports_common.cpython-313.pyc +0 -0
- quarchpy/connection_specific/serial/tools/__pycache__/list_ports_windows.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/SystemTest.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/module_debug.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/simple_terminal.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/upgrade_quarchpy.cpython-313.pyc +0 -0
- quarchpy/debug/__pycache__/versionCompare.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/device.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/quarchArray.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/quarchPPM.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/quarchQPS.cpython-313.pyc +0 -0
- quarchpy/device/__pycache__/scanDevices.cpython-313.pyc +0 -0
- quarchpy/device/quarchPPM.py +1 -1
- quarchpy/disk_test/__pycache__/AbsDiskFinder.cpython-313.pyc +0 -0
- quarchpy/disk_test/__pycache__/DiskTargetSelection.cpython-313.pyc +0 -0
- quarchpy/disk_test/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/disk_test/__pycache__/iometerDiskFinder.cpython-313.pyc +0 -0
- quarchpy/docs/CHANGES.rst +17 -0
- quarchpy/docs/_build/doctrees/CHANGES.doctree +0 -0
- quarchpy/docs/_build/doctrees/environment.pickle +0 -0
- quarchpy/docs/_build/doctrees/index.doctree +0 -0
- quarchpy/docs/_build/doctrees/readme.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/changelog.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/licenses.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/modules.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.calibration.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.config_files.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.connection_specific.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.debug.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.device.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.disk_test.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.fio.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.iometer.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.qis.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.qps.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.user_interface.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/quarchpy.utilities.doctree +0 -0
- quarchpy/docs/_build/doctrees/source/readme.doctree +0 -0
- quarchpy/docs/_build/html/.buildinfo +2 -2
- quarchpy/docs/_build/html/.buildinfo.bak +4 -0
- quarchpy/docs/_build/html/CHANGES.html +176 -150
- quarchpy/docs/_build/html/_sources/CHANGES.rst.txt +14 -0
- quarchpy/docs/_build/html/_static/alabaster.css +47 -87
- quarchpy/docs/_build/html/_static/basic.css +3 -14
- quarchpy/docs/_build/html/_static/doctools.js +0 -7
- quarchpy/docs/_build/html/_static/github-banner.svg +5 -0
- quarchpy/docs/_build/html/_static/language_data.js +1 -8
- quarchpy/docs/_build/html/_static/pygments.css +2 -1
- quarchpy/docs/_build/html/_static/searchtools.js +129 -71
- quarchpy/docs/_build/html/genindex.html +22 -55
- quarchpy/docs/_build/html/index.html +90 -85
- quarchpy/docs/_build/html/objects.inv +0 -0
- quarchpy/docs/_build/html/py-modindex.html +20 -29
- quarchpy/docs/_build/html/readme.html +20 -19
- quarchpy/docs/_build/html/search.html +14 -14
- quarchpy/docs/_build/html/searchindex.js +1 -1
- quarchpy/docs/_build/html/source/changelog.html +246 -216
- quarchpy/docs/_build/html/source/licenses.html +20 -19
- quarchpy/docs/_build/html/source/modules.html +22 -21
- quarchpy/docs/_build/html/source/quarchpy.calibration.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.config_files.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.connection_specific.html +22 -37
- quarchpy/docs/_build/html/source/quarchpy.debug.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.device.html +21 -20
- quarchpy/docs/_build/html/source/quarchpy.disk_test.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.fio.html +22 -47
- quarchpy/docs/_build/html/source/quarchpy.html +22 -37
- quarchpy/docs/_build/html/source/quarchpy.iometer.html +26 -25
- quarchpy/docs/_build/html/source/quarchpy.qis.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.qps.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.user_interface.html +20 -19
- quarchpy/docs/_build/html/source/quarchpy.utilities.html +20 -19
- quarchpy/docs/_build/html/source/readme.html +20 -19
- quarchpy/fio/FIO_interface.py +255 -1
- quarchpy/fio/FIO_interface.py.bak +317 -0
- quarchpy/fio/__pycache__/FIO_interface.cpython-313.pyc +0 -0
- quarchpy/fio/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/fio/__pycache__/fioDiskFinder.cpython-313.pyc +0 -0
- quarchpy/iometer/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/iometer/__pycache__/gen_iometer_template.cpython-313.pyc +0 -0
- quarchpy/iometer/__pycache__/iometerFuncs.cpython-313.pyc +0 -0
- quarchpy/qis/__pycache__/StreamHeaderInfo.cpython-313.pyc +0 -0
- quarchpy/qis/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/qis/__pycache__/qisFuncs.cpython-313.pyc +0 -0
- quarchpy/qps/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/qps/__pycache__/qpsFuncs.cpython-313.pyc +0 -0
- quarchpy/qps/qpsFuncs.py +1 -1
- quarchpy/user_interface/__pycache__/__init__.cpython-313.pyc +0 -0
- quarchpy/user_interface/__pycache__/user_interface.cpython-313.pyc +0 -0
- quarchpy/utilities/__pycache__/TestCenter.cpython-313.pyc +0 -0
- quarchpy/utilities/__pycache__/TimeValue.cpython-313.pyc +0 -0
- quarchpy/utilities/__pycache__/Version.cpython-313.pyc +0 -0
- quarchpy/utilities/__pycache__/__init__.cpython-313.pyc +0 -0
- {quarchpy-2.2.5.dist-info → quarchpy-2.2.7.dev1.dist-info}/METADATA +29 -3
- {quarchpy-2.2.5.dist-info → quarchpy-2.2.7.dev1.dist-info}/RECORD +161 -104
- {quarchpy-2.2.5.dist-info → quarchpy-2.2.7.dev1.dist-info}/WHEEL +1 -1
- quarchpy/__pycache__/__init__.cpython-311.pyc +0 -0
- quarchpy/__pycache__/_version.cpython-311.pyc +0 -0
- quarchpy/__pycache__/connection.cpython-311.pyc +0 -0
- quarchpy/__pycache__/run.cpython-311.pyc +0 -0
- quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/jmdns-3.5.9.jar +0 -0
- {quarchpy-2.2.5.dist-info → quarchpy-2.2.7.dev1.dist-info}/top_level.txt +0 -0
@@ -1,7 +1,7 @@
|
|
1
1
|
QPS Command Summary
|
2
2
|
Copyright (c) Quarch Ltd
|
3
|
-
QPS v1.44
|
4
|
-
Generated:
|
3
|
+
QPS v1.44.2
|
4
|
+
Generated: 14 Jan 2025
|
5
5
|
|
6
6
|
|
7
7
|
*** Commands ***
|
@@ -774,7 +774,7 @@ To indicate the end marker of an interval then set the value to 'endSeq'; eg : m
|
|
774
774
|
Command: $stream export
|
775
775
|
Description: Saves to a given format
|
776
776
|
Version: 2
|
777
|
-
See also: $save csv
|
777
|
+
See also: $save csv, $stream import
|
778
778
|
Arguments
|
779
779
|
Argument: file
|
780
780
|
Description: The file path to save the export
|
@@ -814,6 +814,60 @@ Argument file is optional and if not specified then a file name is assigned and
|
|
814
814
|
If no fileType file is specified then the following is assigned: .../path to recording directory/fileType+Export+yyyyMMddHHmmss.fileType
|
815
815
|
By default all channels are exported but can be filtered using argument "channel"
|
816
816
|
|
817
|
+
Command: $stream import
|
818
|
+
Description: Imports from a given format
|
819
|
+
Version: 2
|
820
|
+
See also: $stream export
|
821
|
+
Arguments
|
822
|
+
Argument: file
|
823
|
+
Description: The file path to be imported
|
824
|
+
Index: 0
|
825
|
+
Type: STRING
|
826
|
+
Default value: NONE
|
827
|
+
Argument: fileType
|
828
|
+
Description: File type; eg CSV
|
829
|
+
Index: 1
|
830
|
+
Type: STRING
|
831
|
+
Default value: csv
|
832
|
+
Argument: delimiter
|
833
|
+
Description: Value separator; eg ,
|
834
|
+
Index: 2
|
835
|
+
Type: STRING
|
836
|
+
Default value: ,
|
837
|
+
Acceptable values: ["\t", ";", ",", " "]
|
838
|
+
Argument: minTime
|
839
|
+
Description: The minimum time value; eg 100mS. The default value of 0nS indicates reading from the start
|
840
|
+
Index: 3
|
841
|
+
Type: STRING
|
842
|
+
Default value: 0nS
|
843
|
+
Argument: maxTime
|
844
|
+
Description: The maximum time value; eg 800mS. The default value of -1nS indicates reading to the end
|
845
|
+
Index: 4
|
846
|
+
Type: STRING
|
847
|
+
Default value: -1nS
|
848
|
+
Argument: offsetTime
|
849
|
+
Description: The offset time value; eg 10mS. The default value of 0nS indicates there is no offset
|
850
|
+
Index: 5
|
851
|
+
Type: STRING
|
852
|
+
Default value: 0nS
|
853
|
+
Argument: channels
|
854
|
+
Description: List of channels to import; eg "voltage:5v,current:12v" with the default set to "all"
|
855
|
+
Index: 6
|
856
|
+
Type: STRING
|
857
|
+
Default value: all
|
858
|
+
Argument: timeFormat
|
859
|
+
Description: Time format ["elapsed", "unix"]. The default is "elapsed"
|
860
|
+
Index: 7
|
861
|
+
Type: STRING
|
862
|
+
Default value: elapsed
|
863
|
+
Acceptable values: [elapsed, unix]
|
864
|
+
Notes:
|
865
|
+
The file must contain an extension that matches the one specified in fileType. This is used as a check.
|
866
|
+
Examples:
|
867
|
+
$stream import file="C:\Temp\data.csv"
|
868
|
+
$stream import file="C:\Temp\data.csv" channels="voltage:12v,current:12v"
|
869
|
+
$stream import file="C:\Temp\data.csv" channels="voltage:12v,current:12v" minTime=1S maxTime=10S
|
870
|
+
|
817
871
|
Command: $stream read
|
818
872
|
Description: Reads data between from a given start time and either end time or number of records
|
819
873
|
Version: 2
|
@@ -1072,6 +1126,8 @@ $stream data add ~ Adds a channel/group value at a specified time
|
|
1072
1126
|
|
1073
1127
|
$stream export ~ Saves to a given format
|
1074
1128
|
|
1129
|
+
$stream import ~ Imports from a given format
|
1130
|
+
|
1075
1131
|
$stream read ~ Reads data between from a given start time and either end time or number of records
|
1076
1132
|
|
1077
1133
|
$stream record ~ Starts streaming
|
@@ -1,39 +1,31 @@
|
|
1
1
|
*** What's New In Quarch Power Studio ***
|
2
2
|
|
3
|
-
|
3
|
+
14th January 2025
|
4
4
|
|
5
|
-
QPS version 1.
|
6
|
-
QIS version 1.
|
5
|
+
QPS version 1.45
|
6
|
+
QIS version 1.47
|
7
7
|
|
8
8
|
|
9
9
|
|
10
10
|
*** New Features ***
|
11
11
|
|
12
|
-
|
12
|
+
Improved help menu links and additional documentation
|
13
13
|
|
14
|
-
|
14
|
+
Data valid synthetic channel for AC compliance testing
|
15
15
|
|
16
|
-
Improved
|
16
|
+
Improved import speed for custom user data
|
17
17
|
|
18
|
-
|
18
|
+
Reduced time from start stream, until data is first displayed
|
19
19
|
|
20
|
-
|
20
|
+
Added notification for locked devices that are open in other applications
|
21
21
|
|
22
|
-
|
23
|
-
|
24
|
-
Added a simple user debug command to capture all logs
|
25
|
-
|
26
|
-
Improved debug logging when loading traces
|
22
|
+
Improved checking of analysis files when loading
|
27
23
|
|
28
24
|
|
29
25
|
*** Major Fixes ***
|
30
26
|
|
31
|
-
Fixed
|
32
|
-
|
33
|
-
Fixed failure to calculate statistics for very short regions
|
34
|
-
|
35
|
-
Fixed issue where stream start could take a second or so to begin showing data
|
27
|
+
Fixed issues with window resizing on multiple monitors
|
36
28
|
|
37
|
-
|
29
|
+
Improved thread cycling which reduced performance
|
38
30
|
|
39
|
-
Fixed
|
31
|
+
Fixed duplicate logging lines
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -200,11 +200,12 @@ class QpsInterface:
|
|
200
200
|
|
201
201
|
"""
|
202
202
|
#print("Open recording at file : \""+str(file_path)+"\"")
|
203
|
-
|
203
|
+
notLoadingMessageStartTime=None
|
204
204
|
loadingStarted=False
|
205
205
|
message=""
|
206
|
-
|
207
|
-
|
206
|
+
|
207
|
+
openResponse = self.sendCmdVerbose("$open recording qpsFile=\""+str(file_path)+"\"",timeout=cmdTimeout)
|
208
|
+
#print(openResponse)
|
208
209
|
while(1):
|
209
210
|
update=self.sendCmdVerbose("$progress check task=\"open recording\"",timeout=cmdTimeout)
|
210
211
|
#print(update)
|
@@ -216,6 +217,9 @@ class QpsInterface:
|
|
216
217
|
if found > 99.9: # This will catch the case we have 99.9999% or 100% loaded. recording with less that 1mill records auto return 100%
|
217
218
|
message = "Passed, Recording opened, loading detected and complete."
|
218
219
|
break
|
220
|
+
elif "Initialising main chart" in update:
|
221
|
+
loadingStarted = True
|
222
|
+
user_interface.progressBar(found, 100)
|
219
223
|
elif "Chart window is open but no loading is in progress." in update:
|
220
224
|
if loadingStarted == True:
|
221
225
|
# Loading started and has now ended, so we can exit the loop.
|
@@ -0,0 +1,242 @@
|
|
1
|
+
import sys
|
2
|
+
import socket
|
3
|
+
import time
|
4
|
+
import datetime
|
5
|
+
import subprocess
|
6
|
+
import os
|
7
|
+
import random
|
8
|
+
import logging
|
9
|
+
import time
|
10
|
+
import re
|
11
|
+
from quarchpy.user_interface import user_interface
|
12
|
+
|
13
|
+
class QpsInterface:
|
14
|
+
def __init__(self, host='127.0.0.1', port=9822):
|
15
|
+
self.host = host
|
16
|
+
self.port = port
|
17
|
+
|
18
|
+
self.client = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
|
19
|
+
self.client.settimeout(5)
|
20
|
+
self.client.connect((host, port))
|
21
|
+
|
22
|
+
self.client.settimeout(None)
|
23
|
+
time.sleep(1)
|
24
|
+
self.recv()
|
25
|
+
time.sleep(1)
|
26
|
+
|
27
|
+
# Not blocking qps socket so scripts can continue if no read - 22/06
|
28
|
+
self.client.setblocking(False)
|
29
|
+
|
30
|
+
|
31
|
+
def recv(self):
|
32
|
+
try:
|
33
|
+
if sys.hexversion >= 0x03000000:
|
34
|
+
response = self.client.recv(4096)
|
35
|
+
i = 0
|
36
|
+
for b in response: # end buffer on first \0 character/value
|
37
|
+
if b > 0:
|
38
|
+
i += 1
|
39
|
+
else:
|
40
|
+
break;
|
41
|
+
|
42
|
+
return response[:i].decode('utf-8', "ignore")
|
43
|
+
else:
|
44
|
+
return self.client.recv(4096)
|
45
|
+
except Exception as e:
|
46
|
+
# Catching socket timeout caused from non blocking socket
|
47
|
+
return ""
|
48
|
+
|
49
|
+
|
50
|
+
def send(self, data):
|
51
|
+
if sys.hexversion >= 0x03000000:
|
52
|
+
self.client.send( data.encode() )
|
53
|
+
else:
|
54
|
+
self.client.send( data )
|
55
|
+
|
56
|
+
def sendCommand(self, cmd, timeout=20, expectedResponse=True ):
|
57
|
+
cmd = cmd + "\r\n"
|
58
|
+
logging.debug("Sending cmd to QPS: " + str(cmd))
|
59
|
+
self.send(cmd)
|
60
|
+
|
61
|
+
start = time.time()
|
62
|
+
response = self.recv().strip()
|
63
|
+
while response.rfind('\r\n>') == -1: # If true then the resposnse is large and multi packeted
|
64
|
+
time.sleep(0.1)
|
65
|
+
t_response = self.recv().strip()
|
66
|
+
# Add current response to new response
|
67
|
+
response += t_response
|
68
|
+
# Keep reading from the socket if there's stuff that was retreived
|
69
|
+
if len(str(t_response)) == 0:
|
70
|
+
if time.time() - start > timeout:
|
71
|
+
logging.warning("Command : " + str(cmd) + " Hit timeout during QPS read. timeout = " + str(timeout))
|
72
|
+
break
|
73
|
+
|
74
|
+
pos = response.rfind('\r\n>')
|
75
|
+
if pos == -1:
|
76
|
+
logging.warning("Did not retrieve trailing '\\r\\n>' from QPS read, returned full response so far")
|
77
|
+
logging.warning("command : " + cmd.replace('\r\n', '\\r\\n'))
|
78
|
+
logging.warning("returned : " + response.replace('\r\n', '\\r\\n'))
|
79
|
+
pos = len(str(response))
|
80
|
+
return response[:pos]
|
81
|
+
|
82
|
+
def sendCmdVerbose(self, cmd, timeout=20):
|
83
|
+
cmd = cmd + "\r\n"
|
84
|
+
logging.debug("Sending cmd to QPS: "+str(cmd))
|
85
|
+
self.send(cmd)
|
86
|
+
|
87
|
+
start = time.time()
|
88
|
+
response = self.recv().strip()
|
89
|
+
while response.rfind('\r\n>') == -1: #If true then the resposnse is large and multi packeted
|
90
|
+
time.sleep(0.1)
|
91
|
+
t_response = self.recv().strip()
|
92
|
+
# Add current response to new response
|
93
|
+
response += t_response
|
94
|
+
# Keep reading from the socket if there's stuff that was retreived
|
95
|
+
if len(str(t_response)) == 0:
|
96
|
+
if time.time() - start > timeout:
|
97
|
+
logging.warning("Command : "+str(cmd)+ " Hit timeout during QPS read. timeout = " +str(timeout))
|
98
|
+
break
|
99
|
+
|
100
|
+
pos = response.rfind('\r\n>')
|
101
|
+
if pos == -1:
|
102
|
+
logging.warning("Did not retrieve trailing '\\r\\n>' from QPS read, returned full response so far")
|
103
|
+
logging.warning("command : " + cmd.replace('\r\n','\\r\\n'))
|
104
|
+
logging.warning("returned : " + response.replace('\r\n','\\r\\n'))
|
105
|
+
pos = len(str(response))
|
106
|
+
return response[:pos]
|
107
|
+
|
108
|
+
|
109
|
+
def connect(self, targetDevice):
|
110
|
+
cmd="$connect " + targetDevice
|
111
|
+
retVal = self.sendCmdVerbose(cmd)
|
112
|
+
time.sleep(0.3)
|
113
|
+
return retVal
|
114
|
+
|
115
|
+
|
116
|
+
def disconnect(self, targetDevice):
|
117
|
+
self.sendCmdVerbose("$disconnect")
|
118
|
+
|
119
|
+
def closeConnection(self, conString=None):
|
120
|
+
if conString is None:
|
121
|
+
return self.sendCmdVerbose("close")
|
122
|
+
else:
|
123
|
+
return self.sendCmdVerbose(conString+" close")
|
124
|
+
def scanIP(self, ipAddress, sleep=10):
|
125
|
+
"""
|
126
|
+
Triggers QPS to look at a specific IP address for a quarch module
|
127
|
+
|
128
|
+
Parameters
|
129
|
+
----------
|
130
|
+
QpsConnection : QpsInterface
|
131
|
+
The interface to the instance of QPS you would like to use for the scan.
|
132
|
+
ipAddress : str
|
133
|
+
The IP address of the module you are looking for eg '192.168.123.123'
|
134
|
+
sleep : int, optional
|
135
|
+
This optional variable sleeps to allow the network to scan for the module before allowing new commands to be sent to QPS.
|
136
|
+
"""
|
137
|
+
ipAddress = "TCP::" + ipAddress
|
138
|
+
|
139
|
+
self.send("$scan " + ipAddress)
|
140
|
+
# logging.debug("Starting QPS IP Address Lookup")
|
141
|
+
time.sleep(
|
142
|
+
sleep) # Time must be allowed for QPS to Scan. If another scan request is sent it will time out and throw an error.
|
143
|
+
|
144
|
+
def get_list_details(self, sock=None):
|
145
|
+
if sock == None:
|
146
|
+
sock = self.sock
|
147
|
+
devString = self.sendCmdVerbose("$module list details")
|
148
|
+
#devString = self.sendAndReceiveText(sock, '$list details')
|
149
|
+
devString = devString.replace('>', '')
|
150
|
+
devString = devString.replace(r'\d+\) ', '')
|
151
|
+
devString = devString.split('\r\n')
|
152
|
+
devString = [x for x in devString if x] # remove empty elements
|
153
|
+
return devString
|
154
|
+
|
155
|
+
def getDeviceList(self, scan = True, ipAddress = None):
|
156
|
+
deviceList = []
|
157
|
+
scanWait = 2
|
158
|
+
foundDevices = "1"
|
159
|
+
foundDevices2 = "2"
|
160
|
+
if scan:
|
161
|
+
if ipAddress == None:
|
162
|
+
devString = self.sendCmdVerbose('$scan')
|
163
|
+
else:
|
164
|
+
devString = self.sendCmdVerbose('$module scan tcp::' + ipAddress)
|
165
|
+
time.sleep(scanWait)
|
166
|
+
while foundDevices not in foundDevices2:
|
167
|
+
foundDevices = self.sendCmdVerbose('$list')
|
168
|
+
time.sleep(scanWait)
|
169
|
+
foundDevices2 = self.sendCmdVerbose('$list')
|
170
|
+
else:
|
171
|
+
foundDevices = self.sendCmdVerbose('$list')
|
172
|
+
|
173
|
+
response = self.sendCmdVerbose( "$list" )
|
174
|
+
|
175
|
+
time.sleep(2)
|
176
|
+
|
177
|
+
response2 = self.sendCmdVerbose( "$list" )
|
178
|
+
|
179
|
+
while (response != response2):
|
180
|
+
response = response2
|
181
|
+
response2 = self.sendCmdVerbose( "$list" )
|
182
|
+
time.sleep(1)
|
183
|
+
if "no device" in response.lower() or "no module" in response.lower():
|
184
|
+
return [response.strip()]
|
185
|
+
#check if a response was received and the first char was a digit
|
186
|
+
if( len(response) > 0 and response[0].isdigit ):
|
187
|
+
sa = response.split()
|
188
|
+
for s in sa:
|
189
|
+
#checks for invalid chars
|
190
|
+
if( ")" not in s and ">" not in s ):
|
191
|
+
#append to list if conditions met
|
192
|
+
deviceList.append( s )
|
193
|
+
|
194
|
+
#return list of devices
|
195
|
+
return deviceList
|
196
|
+
|
197
|
+
|
198
|
+
def open_recording(self, file_path, cmdTimeout=5, pollInterval=3, startOpenTimout=5):
|
199
|
+
"""
|
200
|
+
|
201
|
+
"""
|
202
|
+
#print("Open recording at file : \""+str(file_path)+"\"")
|
203
|
+
notLoadingMessageStartTime=None
|
204
|
+
loadingStarted=False
|
205
|
+
message=""
|
206
|
+
|
207
|
+
openResponse = self.sendCmdVerbose("$open recording qpsFile=\""+str(file_path)+"\"",timeout=cmdTimeout)
|
208
|
+
print(openResponse)
|
209
|
+
while(1):
|
210
|
+
update=self.sendCmdVerbose("$progress check task=\"open recording\"",timeout=cmdTimeout)
|
211
|
+
#print(update)
|
212
|
+
m = re.search(r'\d+(\.\d+)?%', update)
|
213
|
+
if m: # A percentage was found
|
214
|
+
loadingStarted=True
|
215
|
+
found = float(m.group(0)[:-1])
|
216
|
+
user_interface.progressBar(found,100)
|
217
|
+
if found > 99.9: # This will catch the case we have 99.9999% or 100% loaded. recording with less that 1mill records auto return 100%
|
218
|
+
message = "Passed, Recording opened, loading detected and complete."
|
219
|
+
break
|
220
|
+
elif "Initialising main chart" in update:
|
221
|
+
loadingStarted = True
|
222
|
+
user_interface.progressBar(found, 100)
|
223
|
+
elif "Chart window is open but no loading is in progress." in update:
|
224
|
+
if loadingStarted == True:
|
225
|
+
# Loading started and has now ended, so we can exit the loop.
|
226
|
+
message="Passed, Recording opened, loading detected and complete."
|
227
|
+
break
|
228
|
+
else: # QPS has not started loading a recording.
|
229
|
+
if notLoadingMessageStartTime == None:
|
230
|
+
# Start a timer from now so that if loading doesn't take place between now and a timeout value,
|
231
|
+
# we exit, stating that no loading started within the desired time.
|
232
|
+
notLoadingMessageStartTime = time.time()
|
233
|
+
elif time.time() - notLoadingMessageStartTime> startOpenTimout:
|
234
|
+
message = "No detection that QPS started loading the recording within " + str(startOpenTimout) + "s."
|
235
|
+
break
|
236
|
+
|
237
|
+
time.sleep(pollInterval) #Sleep pollInterval time, so we are not hammering QPS for updates while its busy loading.
|
238
|
+
time.sleep(1) #sleep outside the loop as there is a
|
239
|
+
return message
|
240
|
+
|
241
|
+
|
242
|
+
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
quarchpy/device/quarchPPM.py
CHANGED
@@ -15,7 +15,7 @@ class quarchPPM(quarchDevice):
|
|
15
15
|
numb_colons = self.ConString.count(":")
|
16
16
|
if numb_colons == 1:
|
17
17
|
self.ConString = self.ConString.replace(':', '::')
|
18
|
-
if not skipDefaultSyntheticChannels and self.ConType[:3].upper() == "QIS":
|
18
|
+
if not skipDefaultSyntheticChannels and self.ConType[:3].upper() == "QIS" and "FAIL:" not in self.fixture_definition:
|
19
19
|
self.create_default_synthetic_channels()
|
20
20
|
|
21
21
|
def startStream(self, fileName='streamData.txt', fileMaxMB=200000, streamName ='Stream With No Name', streamDuration = None, streamAverage = None, releaseOnData = False, separator=",", inMemoryData = None):
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
quarchpy/docs/CHANGES.rst
CHANGED
@@ -14,6 +14,23 @@ Change Log
|
|
14
14
|
----------
|
15
15
|
|
16
16
|
|
17
|
+
2.2.6
|
18
|
+
-----
|
19
|
+
- New QPS 1.45 and QIS 1.47
|
20
|
+
|
21
|
+
2.2.5
|
22
|
+
-----
|
23
|
+
- Minor Bug fix and removal of redundant jar
|
24
|
+
|
25
|
+
2.2.4
|
26
|
+
-----
|
27
|
+
- Update to Java libraries to run QPS
|
28
|
+
- Removal of depracated libs saveing space
|
29
|
+
|
30
|
+
2.2.3
|
31
|
+
-----
|
32
|
+
- Minor bug fix
|
33
|
+
|
17
34
|
2.2.2
|
18
35
|
-----
|
19
36
|
- New QPS 1.44 and QIS 1.46
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -1,4 +1,4 @@
|
|
1
1
|
# Sphinx build info version 1
|
2
|
-
# This file
|
3
|
-
config:
|
2
|
+
# This file records the configuration used when building these files. When it is not found, a full rebuild will be done.
|
3
|
+
config: 110145e8a0549736b0b782ab1449dcb9
|
4
4
|
tags: 645f666f9bcd5a90fca523b33c5a78b7
|