quarchpy 2.2.8.dev1__py2.py3-none-any.whl → 2.2.9.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.
Files changed (224) hide show
  1. quarchpy/__pycache__/__init__.cpython-311.pyc +0 -0
  2. quarchpy/__pycache__/__init__.cpython-313.pyc +0 -0
  3. quarchpy/__pycache__/_version.cpython-311.pyc +0 -0
  4. quarchpy/__pycache__/_version.cpython-313.pyc +0 -0
  5. quarchpy/__pycache__/connection.cpython-311.pyc +0 -0
  6. quarchpy/__pycache__/connection.cpython-313.pyc +0 -0
  7. quarchpy/_version.py +1 -1
  8. quarchpy/config_files/__pycache__/__init__.cpython-311.pyc +0 -0
  9. quarchpy/config_files/__pycache__/__init__.cpython-313.pyc +0 -0
  10. quarchpy/config_files/__pycache__/quarch_config_parser.cpython-311.pyc +0 -0
  11. quarchpy/config_files/__pycache__/quarch_config_parser.cpython-313.pyc +0 -0
  12. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/com.sun.istack-license.html +59 -0
  13. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/dorkbox-LICENSE.Apachev2 +218 -0
  14. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jSerialComm-LICENSE-APACHE-2.0 +202 -0
  15. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jSerialComm-LICENSE-LGPL-3.0 +165 -0
  16. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jakarta.activation-license.html +59 -0
  17. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jakarta.xml.bind-api-license.html +59 -0
  18. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/javassist-License.html +381 -0
  19. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jmdns-LICENSE.txt +202 -0
  20. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/jna-AL2.0 +177 -0
  21. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/kotlin-stdlib-LICENSE-2.0.txt +202 -0
  22. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/netty-LICENSE.txt +202 -0
  23. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/netty-NOTICE.txt +239 -0
  24. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/slf4j-LICENSE.txt +24 -0
  25. quarchpy/connection_specific/QPS/win-amd64/qis/3rdPartyLicenses/usb4java-LICENSE.md +20 -0
  26. quarchpy/connection_specific/QPS/win-amd64/qis/help.txt +50 -17
  27. quarchpy/connection_specific/QPS/win-amd64/qis/license.txt +1 -0
  28. quarchpy/connection_specific/QPS/win-amd64/qis/qis.jar +0 -0
  29. quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/CInterface-2.5.jar +0 -0
  30. quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/QuarchCommon-2.0.jar +0 -0
  31. quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/TorridonCommon-1.3.jar +0 -0
  32. quarchpy/connection_specific/QPS/win-amd64/qis/qis_lib/usb4java-1.3.1.jar +0 -0
  33. quarchpy/connection_specific/__pycache__/StreamChannels.cpython-311.pyc +0 -0
  34. quarchpy/connection_specific/__pycache__/StreamChannels.cpython-313.pyc +0 -0
  35. quarchpy/connection_specific/__pycache__/__init__.cpython-311.pyc +0 -0
  36. quarchpy/connection_specific/__pycache__/__init__.cpython-313.pyc +0 -0
  37. quarchpy/connection_specific/__pycache__/connection_QIS.cpython-311.pyc +0 -0
  38. quarchpy/connection_specific/__pycache__/connection_QIS.cpython-313.pyc +0 -0
  39. quarchpy/connection_specific/__pycache__/connection_QPS.cpython-311.pyc +0 -0
  40. quarchpy/connection_specific/__pycache__/connection_QPS.cpython-313.pyc +0 -0
  41. quarchpy/connection_specific/__pycache__/connection_ReST.cpython-311.pyc +0 -0
  42. quarchpy/connection_specific/__pycache__/connection_ReST.cpython-313.pyc +0 -0
  43. quarchpy/connection_specific/__pycache__/connection_Serial.cpython-311.pyc +0 -0
  44. quarchpy/connection_specific/__pycache__/connection_Serial.cpython-313.pyc +0 -0
  45. quarchpy/connection_specific/__pycache__/connection_TCP.cpython-311.pyc +0 -0
  46. quarchpy/connection_specific/__pycache__/connection_TCP.cpython-313.pyc +0 -0
  47. quarchpy/connection_specific/__pycache__/connection_USB.cpython-311.pyc +0 -0
  48. quarchpy/connection_specific/__pycache__/connection_USB.cpython-313.pyc +0 -0
  49. quarchpy/connection_specific/__pycache__/mDNS.cpython-311.pyc +0 -0
  50. quarchpy/connection_specific/__pycache__/mDNS.cpython-313.pyc +0 -0
  51. quarchpy/connection_specific/jdk_j21_jres/__pycache__/__init__.cpython-311.pyc +0 -0
  52. quarchpy/connection_specific/jdk_j21_jres/__pycache__/__init__.cpython-313.pyc +0 -0
  53. quarchpy/connection_specific/jdk_j21_jres/__pycache__/fix_permissions.cpython-311.pyc +0 -0
  54. quarchpy/connection_specific/jdk_j21_jres/__pycache__/fix_permissions.cpython-313.pyc +0 -0
  55. quarchpy/connection_specific/serial/__pycache__/__init__.cpython-311.pyc +0 -0
  56. quarchpy/connection_specific/serial/__pycache__/__init__.cpython-313.pyc +0 -0
  57. quarchpy/connection_specific/serial/__pycache__/serialutil.cpython-311.pyc +0 -0
  58. quarchpy/connection_specific/serial/__pycache__/serialutil.cpython-313.pyc +0 -0
  59. quarchpy/connection_specific/serial/__pycache__/serialwin32.cpython-311.pyc +0 -0
  60. quarchpy/connection_specific/serial/__pycache__/serialwin32.cpython-313.pyc +0 -0
  61. quarchpy/connection_specific/serial/__pycache__/win32.cpython-311.pyc +0 -0
  62. quarchpy/connection_specific/serial/__pycache__/win32.cpython-313.pyc +0 -0
  63. quarchpy/connection_specific/serial/tools/__pycache__/__init__.cpython-311.pyc +0 -0
  64. quarchpy/connection_specific/serial/tools/__pycache__/__init__.cpython-313.pyc +0 -0
  65. quarchpy/connection_specific/serial/tools/__pycache__/list_ports.cpython-311.pyc +0 -0
  66. quarchpy/connection_specific/serial/tools/__pycache__/list_ports.cpython-313.pyc +0 -0
  67. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_common.cpython-311.pyc +0 -0
  68. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_common.cpython-313.pyc +0 -0
  69. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_windows.cpython-311.pyc +0 -0
  70. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_windows.cpython-313.pyc +0 -0
  71. quarchpy/connection_specific/usb_libs/__pycache__/libusb1.cpython-311.pyc +0 -0
  72. quarchpy/connection_specific/usb_libs/__pycache__/usb1.cpython-311.pyc +0 -0
  73. quarchpy/connection_specific/usb_libs/usb1.py +2360 -2360
  74. quarchpy/debug/SystemTest.py +9 -2
  75. quarchpy/debug/__pycache__/SystemTest.cpython-311.pyc +0 -0
  76. quarchpy/debug/__pycache__/SystemTest.cpython-313.pyc +0 -0
  77. quarchpy/debug/__pycache__/__init__.cpython-311.pyc +0 -0
  78. quarchpy/debug/__pycache__/__init__.cpython-313.pyc +0 -0
  79. quarchpy/debug/__pycache__/module_debug.cpython-313.pyc +0 -0
  80. quarchpy/debug/__pycache__/simple_terminal.cpython-313.pyc +0 -0
  81. quarchpy/debug/__pycache__/upgrade_quarchpy.cpython-313.pyc +0 -0
  82. quarchpy/debug/__pycache__/versionCompare.cpython-311.pyc +0 -0
  83. quarchpy/debug/__pycache__/versionCompare.cpython-313.pyc +0 -0
  84. quarchpy/device/__pycache__/__init__.cpython-311.pyc +0 -0
  85. quarchpy/device/__pycache__/__init__.cpython-313.pyc +0 -0
  86. quarchpy/device/__pycache__/device.cpython-311.pyc +0 -0
  87. quarchpy/device/__pycache__/device.cpython-313.pyc +0 -0
  88. quarchpy/device/__pycache__/quarchArray.cpython-311.pyc +0 -0
  89. quarchpy/device/__pycache__/quarchArray.cpython-313.pyc +0 -0
  90. quarchpy/device/__pycache__/quarchPPM.cpython-311.pyc +0 -0
  91. quarchpy/device/__pycache__/quarchPPM.cpython-313.pyc +0 -0
  92. quarchpy/device/__pycache__/quarchQPS.cpython-311.pyc +0 -0
  93. quarchpy/device/__pycache__/quarchQPS.cpython-313.pyc +0 -0
  94. quarchpy/device/__pycache__/scanDevices.cpython-311.pyc +0 -0
  95. quarchpy/device/__pycache__/scanDevices.cpython-313.pyc +0 -0
  96. quarchpy/device/quarchQPS.py +96 -67
  97. quarchpy/disk_test/__pycache__/AbsDiskFinder.cpython-311.pyc +0 -0
  98. quarchpy/disk_test/__pycache__/AbsDiskFinder.cpython-313.pyc +0 -0
  99. quarchpy/disk_test/__pycache__/DiskTargetSelection.cpython-311.pyc +0 -0
  100. quarchpy/disk_test/__pycache__/DiskTargetSelection.cpython-313.pyc +0 -0
  101. quarchpy/disk_test/__pycache__/__init__.cpython-311.pyc +0 -0
  102. quarchpy/disk_test/__pycache__/__init__.cpython-313.pyc +0 -0
  103. quarchpy/disk_test/__pycache__/iometerDiskFinder.cpython-311.pyc +0 -0
  104. quarchpy/disk_test/__pycache__/iometerDiskFinder.cpython-313.pyc +0 -0
  105. quarchpy/docs/CHANGES.rst +4 -0
  106. quarchpy/docs/Makefile +20 -20
  107. quarchpy/docs/_build/html/_static/custom.css +1 -1
  108. quarchpy/docs/_build/html/_static/doctools.js +149 -149
  109. quarchpy/docs/_build/html/_static/jquery-3.4.1.js +10598 -10598
  110. quarchpy/docs/_build/html/_static/jquery.js +2 -2
  111. quarchpy/docs/_build/html/_static/searchtools.js +632 -632
  112. quarchpy/docs/_build/html/_static/sphinx_highlight.js +154 -154
  113. quarchpy/docs/_build/html/_static/underscore-1.3.1.js +999 -999
  114. quarchpy/docs/_build/html/_static/underscore.js +5 -5
  115. quarchpy/fio/__pycache__/FIO_interface.cpython-311.pyc +0 -0
  116. quarchpy/fio/__pycache__/FIO_interface.cpython-313.pyc +0 -0
  117. quarchpy/fio/__pycache__/__init__.cpython-311.pyc +0 -0
  118. quarchpy/fio/__pycache__/__init__.cpython-313.pyc +0 -0
  119. quarchpy/iometer/__pycache__/__init__.cpython-311.pyc +0 -0
  120. quarchpy/iometer/__pycache__/__init__.cpython-313.pyc +0 -0
  121. quarchpy/iometer/__pycache__/gen_iometer_template.cpython-311.pyc +0 -0
  122. quarchpy/iometer/__pycache__/{gen_iometer_template.cpython-312.pyc → gen_iometer_template.cpython-313.pyc} +0 -0
  123. quarchpy/iometer/__pycache__/iometerFuncs.cpython-311.pyc +0 -0
  124. quarchpy/iometer/__pycache__/iometerFuncs.cpython-313.pyc +0 -0
  125. quarchpy/qis/__pycache__/StreamHeaderInfo.cpython-311.pyc +0 -0
  126. quarchpy/qis/__pycache__/StreamHeaderInfo.cpython-313.pyc +0 -0
  127. quarchpy/qis/__pycache__/__init__.cpython-311.pyc +0 -0
  128. quarchpy/qis/__pycache__/__init__.cpython-313.pyc +0 -0
  129. quarchpy/qis/__pycache__/qisFuncs.cpython-311.pyc +0 -0
  130. quarchpy/qis/__pycache__/qisFuncs.cpython-313.pyc +0 -0
  131. quarchpy/qis/qisFuncs.py +4 -2
  132. quarchpy/qps/__pycache__/__init__.cpython-311.pyc +0 -0
  133. quarchpy/qps/__pycache__/__init__.cpython-313.pyc +0 -0
  134. quarchpy/qps/__pycache__/qpsFuncs.cpython-311.pyc +0 -0
  135. quarchpy/qps/__pycache__/qpsFuncs.cpython-313.pyc +0 -0
  136. quarchpy/user_interface/__pycache__/__init__.cpython-311.pyc +0 -0
  137. quarchpy/user_interface/__pycache__/__init__.cpython-313.pyc +0 -0
  138. quarchpy/user_interface/__pycache__/user_interface.cpython-311.pyc +0 -0
  139. quarchpy/user_interface/__pycache__/user_interface.cpython-313.pyc +0 -0
  140. quarchpy/utilities/__pycache__/TestCenter.cpython-311.pyc +0 -0
  141. quarchpy/utilities/__pycache__/TestCenter.cpython-313.pyc +0 -0
  142. quarchpy/utilities/__pycache__/TimeValue.cpython-311.pyc +0 -0
  143. quarchpy/utilities/__pycache__/TimeValue.cpython-313.pyc +0 -0
  144. quarchpy/utilities/__pycache__/Version.cpython-311.pyc +0 -0
  145. quarchpy/utilities/__pycache__/Version.cpython-313.pyc +0 -0
  146. quarchpy/utilities/__pycache__/__init__.cpython-311.pyc +0 -0
  147. quarchpy/utilities/__pycache__/__init__.cpython-313.pyc +0 -0
  148. {quarchpy-2.2.8.dev1.dist-info → quarchpy-2.2.9.dev1.dist-info}/METADATA +5 -1
  149. {quarchpy-2.2.8.dev1.dist-info → quarchpy-2.2.9.dev1.dist-info}/RECORD +152 -150
  150. quarchpy/.idea/.name +0 -1
  151. quarchpy/.idea/inspectionProfiles/Project_Default.xml +0 -50
  152. quarchpy/.idea/inspectionProfiles/profiles_settings.xml +0 -6
  153. quarchpy/.idea/misc.xml +0 -7
  154. quarchpy/.idea/modules.xml +0 -8
  155. quarchpy/.idea/quarchpy.iml +0 -12
  156. quarchpy/.idea/vcs.xml +0 -6
  157. quarchpy/.idea/workspace.xml +0 -173
  158. quarchpy/__pycache__/__init__.cpython-312.pyc +0 -0
  159. quarchpy/__pycache__/_version.cpython-312.pyc +0 -0
  160. quarchpy/__pycache__/connection.cpython-312.pyc +0 -0
  161. quarchpy/__pycache__/run.cpython-311.pyc +0 -0
  162. quarchpy/__pycache__/run.cpython-312.pyc +0 -0
  163. quarchpy/config_files/__pycache__/__init__.cpython-312.pyc +0 -0
  164. quarchpy/config_files/__pycache__/quarch_config_parser.cpython-312.pyc +0 -0
  165. quarchpy/connection_specific/QPS/win-amd64/InstallType.dat +0 -1
  166. quarchpy/connection_specific/QPS/win-amd64/qis/myFile.csv +0 -50
  167. quarchpy/connection_specific/__pycache__/StreamChannels.cpython-312.pyc +0 -0
  168. quarchpy/connection_specific/__pycache__/__init__.cpython-312.pyc +0 -0
  169. quarchpy/connection_specific/__pycache__/connection_QIS.cpython-312.pyc +0 -0
  170. quarchpy/connection_specific/__pycache__/connection_QPS.cpython-312.pyc +0 -0
  171. quarchpy/connection_specific/__pycache__/connection_ReST.cpython-312.pyc +0 -0
  172. quarchpy/connection_specific/__pycache__/connection_Serial.cpython-312.pyc +0 -0
  173. quarchpy/connection_specific/__pycache__/connection_TCP.cpython-312.pyc +0 -0
  174. quarchpy/connection_specific/__pycache__/connection_USB.cpython-312.pyc +0 -0
  175. quarchpy/connection_specific/__pycache__/mDNS.cpython-312.pyc +0 -0
  176. quarchpy/connection_specific/jdk_j21_jres/__pycache__/__init__.cpython-312.pyc +0 -0
  177. quarchpy/connection_specific/jdk_j21_jres/__pycache__/fix_permissions.cpython-312.pyc +0 -0
  178. quarchpy/connection_specific/serial/__pycache__/__init__.cpython-312.pyc +0 -0
  179. quarchpy/connection_specific/serial/__pycache__/serialutil.cpython-312.pyc +0 -0
  180. quarchpy/connection_specific/serial/__pycache__/serialwin32.cpython-312.pyc +0 -0
  181. quarchpy/connection_specific/serial/__pycache__/win32.cpython-312.pyc +0 -0
  182. quarchpy/connection_specific/serial/tools/__pycache__/__init__.cpython-312.pyc +0 -0
  183. quarchpy/connection_specific/serial/tools/__pycache__/list_ports.cpython-312.pyc +0 -0
  184. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_common.cpython-312.pyc +0 -0
  185. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_windows.cpython-312.pyc +0 -0
  186. quarchpy/connection_specific/usb_libs/__pycache__/libusb1.cpython-312.pyc +0 -0
  187. quarchpy/connection_specific/usb_libs/__pycache__/usb1.cpython-312.pyc +0 -0
  188. quarchpy/debug/__pycache__/SystemTest.cpython-312.pyc +0 -0
  189. quarchpy/debug/__pycache__/__init__.cpython-312.pyc +0 -0
  190. quarchpy/debug/__pycache__/module_debug.cpython-311.pyc +0 -0
  191. quarchpy/debug/__pycache__/module_debug.cpython-312.pyc +0 -0
  192. quarchpy/debug/__pycache__/simple_terminal.cpython-311.pyc +0 -0
  193. quarchpy/debug/__pycache__/simple_terminal.cpython-312.pyc +0 -0
  194. quarchpy/debug/__pycache__/upgrade_quarchpy.cpython-311.pyc +0 -0
  195. quarchpy/debug/__pycache__/upgrade_quarchpy.cpython-312.pyc +0 -0
  196. quarchpy/debug/__pycache__/versionCompare.cpython-312.pyc +0 -0
  197. quarchpy/device/__pycache__/__init__.cpython-312.pyc +0 -0
  198. quarchpy/device/__pycache__/device.cpython-312.pyc +0 -0
  199. quarchpy/device/__pycache__/quarchArray.cpython-312.pyc +0 -0
  200. quarchpy/device/__pycache__/quarchPPM.cpython-312.pyc +0 -0
  201. quarchpy/device/__pycache__/quarchQPS.cpython-312.pyc +0 -0
  202. quarchpy/device/__pycache__/scanDevices.cpython-312.pyc +0 -0
  203. quarchpy/disk_test/__pycache__/AbsDiskFinder.cpython-312.pyc +0 -0
  204. quarchpy/disk_test/__pycache__/DiskTargetSelection.cpython-312.pyc +0 -0
  205. quarchpy/disk_test/__pycache__/__init__.cpython-312.pyc +0 -0
  206. quarchpy/disk_test/__pycache__/iometerDiskFinder.cpython-312.pyc +0 -0
  207. quarchpy/fio/__pycache__/FIO_interface.cpython-312.pyc +0 -0
  208. quarchpy/fio/__pycache__/__init__.cpython-312.pyc +0 -0
  209. quarchpy/iometer/__pycache__/__init__.cpython-312.pyc +0 -0
  210. quarchpy/iometer/__pycache__/iometerFuncs.cpython-312.pyc +0 -0
  211. quarchpy/qis/__pycache__/StreamHeaderInfo.cpython-312.pyc +0 -0
  212. quarchpy/qis/__pycache__/__init__.cpython-312.pyc +0 -0
  213. quarchpy/qis/__pycache__/qisFuncs.cpython-312.pyc +0 -0
  214. quarchpy/qps/__pycache__/__init__.cpython-312.pyc +0 -0
  215. quarchpy/qps/__pycache__/qpsFuncs.cpython-312.pyc +0 -0
  216. quarchpy/user_interface/__pycache__/__init__.cpython-312.pyc +0 -0
  217. quarchpy/user_interface/__pycache__/user_interface.cpython-312.pyc +0 -0
  218. quarchpy/utilities/__pycache__/TestCenter.cpython-312.pyc +0 -0
  219. quarchpy/utilities/__pycache__/TimeValue.cpython-312.pyc +0 -0
  220. quarchpy/utilities/__pycache__/Version.cpython-312.pyc +0 -0
  221. quarchpy/utilities/__pycache__/__init__.cpython-312.pyc +0 -0
  222. /quarchpy/fio/{test_performance_class.py → HIDEtest_performance_class.py} +0 -0
  223. {quarchpy-2.2.8.dev1.dist-info → quarchpy-2.2.9.dev1.dist-info}/WHEEL +0 -0
  224. {quarchpy-2.2.8.dev1.dist-info → quarchpy-2.2.9.dev1.dist-info}/top_level.txt +0 -0
@@ -108,7 +108,14 @@ def QuarchSimpleIdentify(device1):
108
108
  print("")
109
109
  # Print the module identify and version information
110
110
  print("Module Identity Information: ")
111
- print(device1.sendCommand("*idn?"))
111
+ idn_info = device1.sendCommand("*idn?")
112
+ print(idn_info)
113
+ if "fixture" in idn_info.lower():
114
+ print("\nFixture Identity Information: ")
115
+
116
+ fixture_info = device1.sendCommand("fix idn?")
117
+ print(fixture_info)
118
+
112
119
 
113
120
 
114
121
  def get_QIS_version():
@@ -169,7 +176,7 @@ def get_quarchpy_version():
169
176
 
170
177
 
171
178
  def fix_usb():
172
- content_to_write = "SUBSYSTEM==\"usb\", ATTRS{idVendor}==\"16d0\", MODE=\"0666\"" \
179
+ content_to_write = "SUBSYSTEM==\"usb\", ATTRS{idVendor}==\"16d0\", MODE=\"0666\"\n" \
173
180
  "SUBSYSTEM==\"usb_device\", ATTRS{idVendor}==\"16d0\", MODE=\"0666\""
174
181
 
175
182
  if "centos" in str(platform.platform()).lower():
@@ -1,6 +1,8 @@
1
1
  from quarchpy.device import quarchDevice
2
2
  from quarchpy.utilities.Version import Version
3
3
  from quarchpy.user_interface.user_interface import requestDialog
4
+ #from quarchpy.utilities.utils import check_stream_stopped_status, check_export_status
5
+
4
6
  import os, time, datetime, sys, logging
5
7
 
6
8
  if sys.version_info[0] < 3:
@@ -29,24 +31,24 @@ class quarchQPS(quarchDevice):
29
31
  self.IP_address = quarchDevice.connectionObj.qps.host
30
32
  self.port_number = quarchDevice.connectionObj.qps.port
31
33
 
32
- def startStream(self, directory, unserInput=True):
34
+ def startStream(self, directory, unserInput=True, streamDuration=""):
33
35
  """
34
36
  directory - str - desired stream dir
35
37
  unserInput=True - if a failure occurs userInput=True allows user to rectify problem with user input. set to False if user interaction is not available (automating).
36
38
  """
37
39
  #time.sleep(1) # TODO remove this sleep once script->QPS timeing issue resolved. This works fine in the meantime
38
- return quarchStream(self.quarchDevice, directory, unserInput)
40
+ return quarchStream(self.quarchDevice, directory, unserInput, streamDuration)
39
41
 
40
42
 
41
43
  class quarchStream:
42
- def __init__(self, quarchQPS, directory, unserInput=True):
44
+ def __init__(self, quarchQPS, directory, unserInput=True, streamDuration=""):
43
45
  self.connectionObj = quarchQPS.connectionObj
44
46
  self.IP_address = quarchQPS.connectionObj.qps.host
45
47
  self.port_number = quarchQPS.connectionObj.qps.port
46
48
  self.ConString = quarchQPS.ConString
47
49
  self.ConType = quarchQPS.ConType
48
- time.sleep(1)
49
- response = self.startQPSStream(directory)
50
+ # time.sleep(1) # TODO Nabil - Is this required?
51
+ response = self.startQPSStream(directory, streamDuration)
50
52
  if not "fail:" in response.lower():
51
53
  return
52
54
  else:
@@ -55,18 +57,19 @@ class quarchStream:
55
57
  else:
56
58
  self.failCheck(response)
57
59
 
58
- def startQPSStream(self, newDirectory):
59
- '''STARTS the stream '''
60
- response = self.connectionObj.qps.sendCmdVerbose("$start stream \"" + str(newDirectory) + "\"")
60
+ def startQPSStream(self, newDirectory, streamDuration=""):
61
+ '''STARTS the QPS stream '''
62
+ # Set the stream duration if required.
63
+ response = self.connectionObj.qps.sendCmdVerbose("$start stream \"" + str(newDirectory) + "\" " + str(streamDuration))
61
64
  if "Error" in response:
62
- response = self.connectionObj.qps.sendCmdVerbose("$start stream " + str(newDirectory))
65
+ response = self.connectionObj.qps.sendCmdVerbose("$start stream " + str(newDirectory) + " " + streamDuration)
63
66
  return response
64
67
 
65
68
  def failCheck(self, response):
66
69
  ''' handles failed starting of stream that requires input from user to fix.'''
67
70
  while "fail:" in response.lower():
68
71
  if "Fail: Directory already exists" in response:
69
- newDir = requestDialog(message=response+" Please enter a new file name:")
72
+ newDir = requestDialog(message=response + " Please enter a new file name:")
70
73
  response = self.startQPSStream(newDir)
71
74
  else: # If its a failure we don't know how to handle.
72
75
  raise Exception(response)
@@ -112,7 +115,7 @@ class quarchStream:
112
115
 
113
116
  return retVal
114
117
 
115
- def stats_to_CSV(self, file_name=""):
118
+ def stats_to_CSV(self, file_name="", poll_till_complete=False, check_interval=0.5):
116
119
  """
117
120
  Saves the statistics grid to a csv file
118
121
 
@@ -130,43 +133,51 @@ class quarchStream:
130
133
  command_response = self.connectionObj.qps.sendCmdVerbose("$stats to csv \"" + file_name + "\"", timeout=60)
131
134
  if command_response.startswith("Fail"):
132
135
  raise Exception(command_response)
136
+
137
+ #UNCOMMENT
138
+ # if poll_till_complete:
139
+ # is_exporting = check_export_status(self.get_stats_export_status())
140
+ # while is_exporting:
141
+ # is_exporting = check_export_status(self.get_stats_export_status())
142
+ # time.sleep(check_interval)
133
143
  return command_response
134
144
 
135
145
  def get_custom_stats_range(self, start_time, end_time):
136
146
  """
137
- Returns the QPS statistics information over a specific time ignoring any set annotations.
138
-
139
- Parameters
140
- ----------
141
- start_time = : str
142
- The time in seconds you would like the stats to start this can be in integer or string format.
143
- or using the following format to specify daysDhours:minutes:seconds.milliseconds
144
- xxxDxx:xx:xx.xxxx
145
- end_time = : str
146
- The time in seconds you would like the stats to stop this can be in integer or string format
147
- or using the following format to specify daysDhours:minutes:seconds.milliseconds
148
- xxxDxx:xx:xx.xxxx
149
- Returns
150
- -------
151
- df = : dataframe
152
- The response text from QPS. If successful "ok. Saving stats to : file_name" otherwise returns the exception thrown
147
+ Returns the QPS statistics information over a specific time ignoring any set annotations.
148
+
149
+ Parameters
150
+ ----------
151
+ start_time = : str
152
+ The time in seconds you would like the stats to start this can be in integer or string format.
153
+ or using the following format to specify daysDhours:minutes:seconds.milliseconds
154
+ xxxDxx:xx:xx.xxxx
155
+ end_time = : str
156
+ The time in seconds you would like the stats to stop this can be in integer or string format
157
+ or using the following format to specify daysDhours:minutes:seconds.milliseconds
158
+ xxxDxx:xx:xx.xxxx
159
+ Returns
160
+ -------
161
+ df = : dataframe
162
+ The response text from QPS. If successful "ok. Saving stats to : file_name" otherwise returns the exception thrown
153
163
  """
154
164
  try:
155
165
  import warnings
156
166
  import pandas as pd
157
167
  warnings.simplefilter(action='ignore', category=FutureWarning)
158
- except:
168
+ except ImportError:
159
169
  logging.warning("pandas not imported correctly")
170
+
160
171
  command_response = self.connectionObj.qps.sendCmdVerbose(
161
172
  "$get custom stats range " + str(start_time) + " " + str(end_time), timeout=60)
173
+
162
174
  if command_response.startswith("Fail"):
163
175
  raise Exception(command_response)
164
176
  test_data = StringIO(command_response)
177
+
165
178
  try:
166
179
  pd.set_option('display.max_columns', None)
167
180
  pd.set_option('display.width', 1024)
168
- # df = pd.read_csv(test_data, sep=",", header=[0,1])
169
- # pandas.read_csv() replaced error_bad_lines with on_bad_lines from v1.3.0
170
181
  if Version.is_v1_ge_v2(pd.__version__, "1.3.0"):
171
182
  df = pd.read_csv(test_data, sep=",", header=[0, 1], on_bad_lines="skip")
172
183
  else:
@@ -187,9 +198,9 @@ class quarchStream:
187
198
 
188
199
  def getStreamState(self):
189
200
  """
190
- Askes QPS for the stream status.
201
+ Asks QPS for the stream status.
191
202
  QPS stream state != Module stream state.
192
- This is different from "rec stream?" cmd to the module as it will return "streaming" when the module is nolonger streaming but QPS is still receiveing stream data from the module.
203
+ This is different from "rec stream?" cmd to the module as it will return "streaming" when the module is no longer streaming but QPS is still receiveing stream data from the module.
193
204
  ei the module has stopped streaming but is emptying the stream buffer.
194
205
  """
195
206
  command_response = self.connectionObj.qps.sendCmdVerbose("$stream state")
@@ -197,8 +208,8 @@ class quarchStream:
197
208
  raise Exception(command_response)
198
209
  return (command_response)
199
210
 
200
-
201
- def addAnnotation(self, title, annotationTime=0, extraText="", yPos="", titleColor="", annotationColor="", annotationType="", annotationGroup="", timeFormat="unix"):
211
+ def addAnnotation(self, title, annotationTime=0, extraText="", yPos="", titleColor="", annotationColor="",
212
+ annotationType="", annotationGroup="", timeFormat="unix"):
202
213
  """
203
214
  Adds a custom annotation to stream with given parameters.
204
215
 
@@ -229,14 +240,15 @@ class quarchStream:
229
240
  annotationType = annotationType.lower()
230
241
  annotationTime = str(annotationTime)
231
242
 
232
- if (annotationTime[0].isalpha() or annotationTime[-1].isalpha()):
233
- timeFormat="elapsed"
234
- if annotationTime.startswith("e"): #Old format allowed e to be used to pass elapsed time in seconds "e2" -> 2s + elapsed
235
- annotationTime=annotationTime[1:]+"s"
243
+ if annotationTime[0].isalpha() or annotationTime[-1].isalpha():
244
+ timeFormat = "elapsed"
245
+ if annotationTime.startswith(
246
+ "e"): #Old format allowed e to be used to pass elapsed time in seconds "e2" -> 2s + elapsed
247
+ annotationTime = annotationTime[1:] + "s"
236
248
 
237
- elif annotationTime=="0":
238
- annotationTime=current_milli_time()
239
- timeFormat="unix"
249
+ elif annotationTime == "0":
250
+ annotationTime = current_milli_time()
251
+ timeFormat = "unix"
240
252
 
241
253
  if annotationType == "" or annotationType == "annotation":
242
254
  annotationType = "annotate"
@@ -248,24 +260,23 @@ class quarchStream:
248
260
  # return retString
249
261
 
250
262
  title = title.replace("\n", "\\n")
251
- cmd="$stream annotation add "+" time="+str(annotationTime)+ " text=\""+title+"\""
252
- if extraText!="":
263
+ cmd = "$stream annotation add " + " time=" + str(annotationTime) + " text=\"" + title + "\""
264
+ if extraText != "":
253
265
  extraText = extraText.replace("\n", "\\n")
254
- cmd+=" extraText=\"" +str(extraText)+"\""
255
- if yPos!= "":
256
- cmd+=" yPos="+str(yPos)
257
- if type!="":
258
- cmd+=" type="+ str(annotationType)
259
- if annotationColor!="":
260
- cmd+=" colour="+str(annotationColor)
261
- if titleColor!="":
262
- cmd+=" textColour="+str(titleColor)
263
- if timeFormat!="":
264
- cmd+=" timeFormat="+str(timeFormat)
266
+ cmd += " extraText=\"" + str(extraText) + "\""
267
+ if yPos != "":
268
+ cmd += " yPos=" + str(yPos)
269
+ if type != "":
270
+ cmd += " type=" + str(annotationType)
271
+ if annotationColor != "":
272
+ cmd += " colour=" + str(annotationColor)
273
+ if titleColor != "":
274
+ cmd += " textColour=" + str(titleColor)
275
+ if timeFormat != "":
276
+ cmd += " timeFormat=" + str(timeFormat)
265
277
 
266
278
  return self.connectionObj.qps.sendCmdVerbose(cmd)
267
279
 
268
-
269
280
  def addComment(self, title, commentTime=0, extraText="", yPos="", titleColor="", commentColor="", annotationType="",
270
281
  annotationGroup="", timeFormat="unix"):
271
282
  # Comments are just annotations that do not affect the statistics grid.
@@ -276,7 +287,8 @@ class quarchStream:
276
287
  titleColor=titleColor, annotationColor=commentColor, annotationType=annotationType,
277
288
  annotationGroup=annotationGroup, timeFormat=timeFormat)
278
289
 
279
- def saveCSV(self, filePath, linesPerFile=None, cr=None, delimiter=None, timeout=60):
290
+ def saveCSV(self, filePath, linesPerFile=None, cr=None, delimiter=None, timeout=60, pollTillComplete=False,
291
+ checkInterval=0.5):
280
292
  """
281
293
  Saves the stream to csv file at specified location
282
294
 
@@ -310,6 +322,12 @@ class quarchStream:
310
322
  if delimiter != None:
311
323
  args += " -s" + delimiter
312
324
 
325
+ # if pollTillComplete:
326
+ # is_exporting = check_export_status(self.get_stream_export_status())
327
+ # while is_exporting:
328
+ # is_exporting = check_export_status(self.get_stream_export_status())
329
+ # time.sleep(checkInterval)
330
+
313
331
  # , filePath, linesPerFile, cr, delimiter
314
332
  return self.connectionObj.qps.sendCmdVerbose("$save csv \"" + filePath + "\" " + args, timeout=timeout)
315
333
 
@@ -335,17 +353,22 @@ class quarchStream:
335
353
  def channels(self):
336
354
  return self.connectionObj.qps.sendCmdVerbose("$channels").splitlines()
337
355
 
338
- def stopStream(self):
339
- return self.connectionObj.qps.sendCmdVerbose("$stop stream")
340
-
341
- def stopStreamAndAllowBufferToEmpty(self, checkInterval=0.5):
342
- self.stopStream()
343
- streamState = self.getStreamState().lower()
344
- while "running" in streamState:
345
- logging.debug("Stream buffer still emptying: " + streamState)
346
- time.sleep(checkInterval)
356
+ def stopStream(self, pollTillComplete=False, checkInterval=0.5):
357
+ # Stop the stream
358
+ response = self.connectionObj.qps.sendCmdVerbose("$stop stream")
359
+ # Poll till stream has completed if required
360
+ if pollTillComplete:
361
+ # Get the current stream status
347
362
  streamState = self.getStreamState().lower()
348
- logging.debug("QPS no longer Streaming: " + streamState)
363
+ # Verify the stream stopped correctly
364
+ # response = check_stream_stopped_status(streamState)
365
+ # while "running" in streamState:
366
+ # logging.debug("Stream buffer still emptying: " + streamState)
367
+ # streamState = self.getStreamState().lower()
368
+ # response = check_stream_stopped_status(streamState)
369
+ # time.sleep(checkInterval)
370
+
371
+ return response
349
372
 
350
373
  def hideAllDefaultChannels(self):
351
374
 
@@ -386,7 +409,13 @@ class quarchStream:
386
409
  else:
387
410
  dataPointTime = int(dataPointTime)
388
411
  logging.warning("$stream data add " + channelName + " " + groupName + " " + str(dataPointTime) + " " + str(
389
- dataValue) + " " + timeFormat)
412
+ dataValue) + " " + timeFormat)
390
413
  self.connectionObj.qps.sendCmdVerbose(
391
414
  "$stream data add " + channelName + " " + groupName + " " + str(dataPointTime) + " " + str(
392
415
  dataValue) + " " + timeFormat)
416
+
417
+ def get_stream_export_status(self):
418
+ return self.connectionObj.qps.sendCmdVerbose("$stream export status")
419
+
420
+ def get_stats_export_status(self):
421
+ return self.connectionObj.qps.sendCmdVerbose("$stream stats export status")
quarchpy/docs/CHANGES.rst CHANGED
@@ -14,6 +14,10 @@ Change Log
14
14
  ----------
15
15
 
16
16
 
17
+ 2.2.8
18
+ -----
19
+ - New QPS 1.46 and QIS 1.48
20
+
17
21
  2.2.7
18
22
  -----
19
23
  - Bug fix for QIS 1.47 missing lib for linux only
quarchpy/docs/Makefile CHANGED
@@ -1,20 +1,20 @@
1
- # Minimal makefile for Sphinx documentation
2
- #
3
-
4
- # You can set these variables from the command line, and also
5
- # from the environment for the first two.
6
- SPHINXOPTS ?=
7
- SPHINXBUILD ?= sphinx-build
8
- SOURCEDIR = .
9
- BUILDDIR = _build
10
-
11
- # Put it first so that "make" without argument is like "make help".
12
- help:
13
- @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14
-
15
- .PHONY: help Makefile
16
-
17
- # Catch-all target: route all unknown targets to Sphinx using the new
18
- # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
- %: Makefile
20
- @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
1
+ # Minimal makefile for Sphinx documentation
2
+ #
3
+
4
+ # You can set these variables from the command line, and also
5
+ # from the environment for the first two.
6
+ SPHINXOPTS ?=
7
+ SPHINXBUILD ?= sphinx-build
8
+ SOURCEDIR = .
9
+ BUILDDIR = _build
10
+
11
+ # Put it first so that "make" without argument is like "make help".
12
+ help:
13
+ @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14
+
15
+ .PHONY: help Makefile
16
+
17
+ # Catch-all target: route all unknown targets to Sphinx using the new
18
+ # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19
+ %: Makefile
20
+ @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
@@ -1 +1 @@
1
- /* This file intentionally left blank. */
1
+ /* This file intentionally left blank. */