quarchpy 2.1.22__py2.py3-none-any.whl → 2.1.23__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 (158) hide show
  1. quarchpy/.idea/modules.xml +1 -0
  2. quarchpy/.idea/quarchpy.iml +1 -0
  3. quarchpy/.idea/workspace.xml +49 -29
  4. quarchpy/__init__.py +6 -6
  5. quarchpy/__pycache__/__init__.cpython-311.pyc +0 -0
  6. quarchpy/__pycache__/_version.cpython-311.pyc +0 -0
  7. quarchpy/__pycache__/connection.cpython-311.pyc +0 -0
  8. quarchpy/_version.py +1 -1
  9. quarchpy/config_files/__pycache__/__init__.cpython-311.pyc +0 -0
  10. quarchpy/config_files/__pycache__/quarch_config_parser.cpython-311.pyc +0 -0
  11. quarchpy/connection_specific/QPS/qis/qis_lib/CInterface-1.7.04.jar +0 -0
  12. quarchpy/connection_specific/QPS/qis/qis_lib/CInterface-1.7.8.jar +0 -0
  13. quarchpy/connection_specific/QPS/qis/qis_lib/CInterface-1.7.9.jar +0 -0
  14. quarchpy/connection_specific/QPS/qis/qis_lib/QuarchCommon-0.2.6.jar +0 -0
  15. quarchpy/connection_specific/QPS/qis/qis_lib/QuarchCommon-0.2.9.jar +0 -0
  16. quarchpy/connection_specific/QPS/qis/qis_lib/commons-csv-1.8.jar +0 -0
  17. quarchpy/connection_specific/QPS/qis/qis_lib/commons-lang3-3.2.1.jar +0 -0
  18. quarchpy/connection_specific/QPS/qis/resources/filters/filters.csv +1004 -0
  19. quarchpy/connection_specific/QPS/qps_lib/QuarchCommon-0.2.6.jar +0 -0
  20. quarchpy/connection_specific/QPS/qps_lib/QuarchCommon-0.2.9.jar +0 -0
  21. quarchpy/connection_specific/QPS/qps_lib/commons-lang3-3.12.0.jar +0 -0
  22. quarchpy/connection_specific/QPS/qps_lib/jfxtras-labs-8.0-r6.jar +0 -0
  23. quarchpy/connection_specific/QPS/qps_lib/opencsv-5.9.jar +0 -0
  24. quarchpy/connection_specific/QPS/qps_lib/qis-1.39.jar +0 -0
  25. quarchpy/connection_specific/QPS/qps_lib/qis-1.40.jar +0 -0
  26. quarchpy/connection_specific/__pycache__/StreamChannels.cpython-311.pyc +0 -0
  27. quarchpy/connection_specific/__pycache__/__init__.cpython-311.pyc +0 -0
  28. quarchpy/connection_specific/__pycache__/connection_QIS.cpython-311.pyc +0 -0
  29. quarchpy/connection_specific/__pycache__/connection_QPS.cpython-311.pyc +0 -0
  30. quarchpy/connection_specific/__pycache__/connection_ReST.cpython-311.pyc +0 -0
  31. quarchpy/connection_specific/__pycache__/connection_Serial.cpython-311.pyc +0 -0
  32. quarchpy/connection_specific/__pycache__/connection_USB.cpython-311.pyc +0 -0
  33. quarchpy/connection_specific/__pycache__/connection_mDNS.cpython-311.pyc +0 -0
  34. quarchpy/connection_specific/connection_QIS.py +19 -8
  35. quarchpy/connection_specific/connection_QPS.py +25 -1
  36. quarchpy/connection_specific/connection_ReST.py +3 -2
  37. quarchpy/connection_specific/serial/__pycache__/__init__.cpython-311.pyc +0 -0
  38. quarchpy/connection_specific/serial/__pycache__/serialutil.cpython-311.pyc +0 -0
  39. quarchpy/connection_specific/serial/__pycache__/serialwin32.cpython-311.pyc +0 -0
  40. quarchpy/connection_specific/serial/__pycache__/win32.cpython-311.pyc +0 -0
  41. quarchpy/connection_specific/serial/tools/__pycache__/__init__.cpython-311.pyc +0 -0
  42. quarchpy/connection_specific/serial/tools/__pycache__/list_ports.cpython-311.pyc +0 -0
  43. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_common.cpython-311.pyc +0 -0
  44. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_windows.cpython-311.pyc +0 -0
  45. quarchpy/debug/__pycache__/SystemTest.cpython-311.pyc +0 -0
  46. quarchpy/debug/__pycache__/__init__.cpython-311.pyc +0 -0
  47. quarchpy/debug/__pycache__/versionCompare.cpython-311.pyc +0 -0
  48. quarchpy/debug/upgrade_quarchpy.py +3 -3
  49. quarchpy/device/__pycache__/__init__.cpython-311.pyc +0 -0
  50. quarchpy/device/__pycache__/device.cpython-311.pyc +0 -0
  51. quarchpy/device/__pycache__/quarchArray.cpython-311.pyc +0 -0
  52. quarchpy/device/__pycache__/quarchPPM.cpython-311.pyc +0 -0
  53. quarchpy/device/__pycache__/quarchQPS.cpython-311.pyc +0 -0
  54. quarchpy/device/__pycache__/scanDevices.cpython-311.pyc +0 -0
  55. quarchpy/device/device.py +10 -6
  56. quarchpy/device/quarchQPS.py +0 -3
  57. quarchpy/device/scanDevices.py +0 -2
  58. quarchpy/disk_test/__pycache__/AbsDiskFinder.cpython-311.pyc +0 -0
  59. quarchpy/disk_test/__pycache__/DiskTargetSelection.cpython-311.pyc +0 -0
  60. quarchpy/disk_test/__pycache__/__init__.cpython-311.pyc +0 -0
  61. quarchpy/disk_test/__pycache__/iometerDiskFinder.cpython-311.pyc +0 -0
  62. quarchpy/docs/CHANGES.rst +13 -7
  63. quarchpy/docs/_build/doctrees/CHANGES.doctree +0 -0
  64. quarchpy/docs/_build/doctrees/environment.pickle +0 -0
  65. quarchpy/docs/_build/doctrees/index.doctree +0 -0
  66. quarchpy/docs/_build/doctrees/readme.doctree +0 -0
  67. quarchpy/docs/_build/doctrees/source/changelog.doctree +0 -0
  68. quarchpy/docs/_build/doctrees/source/licenses.doctree +0 -0
  69. quarchpy/docs/_build/doctrees/source/modules.doctree +0 -0
  70. quarchpy/docs/_build/doctrees/source/quarchpy.calibration.doctree +0 -0
  71. quarchpy/docs/_build/doctrees/source/quarchpy.config_files.doctree +0 -0
  72. quarchpy/docs/_build/doctrees/source/quarchpy.connection_specific.doctree +0 -0
  73. quarchpy/docs/_build/doctrees/source/quarchpy.debug.doctree +0 -0
  74. quarchpy/docs/_build/doctrees/source/quarchpy.device.doctree +0 -0
  75. quarchpy/docs/_build/doctrees/source/quarchpy.disk_test.doctree +0 -0
  76. quarchpy/docs/_build/doctrees/source/quarchpy.doctree +0 -0
  77. quarchpy/docs/_build/doctrees/source/quarchpy.fio.doctree +0 -0
  78. quarchpy/docs/_build/doctrees/source/quarchpy.iometer.doctree +0 -0
  79. quarchpy/docs/_build/doctrees/source/quarchpy.qis.doctree +0 -0
  80. quarchpy/docs/_build/doctrees/source/quarchpy.qps.doctree +0 -0
  81. quarchpy/docs/_build/doctrees/source/quarchpy.user_interface.doctree +0 -0
  82. quarchpy/docs/_build/doctrees/source/quarchpy.utilities.doctree +0 -0
  83. quarchpy/docs/_build/doctrees/source/readme.doctree +0 -0
  84. quarchpy/docs/_build/html/CHANGES.html +129 -122
  85. quarchpy/docs/_build/html/_sources/CHANGES.rst.txt +13 -7
  86. quarchpy/docs/_build/html/genindex.html +9 -3
  87. quarchpy/docs/_build/html/index.html +60 -59
  88. quarchpy/docs/_build/html/objects.inv +0 -0
  89. quarchpy/docs/_build/html/readme.html +7 -6
  90. quarchpy/docs/_build/html/searchindex.js +1 -1
  91. quarchpy/docs/_build/html/source/changelog.html +189 -181
  92. quarchpy/docs/_build/html/source/licenses.html +7 -6
  93. quarchpy/docs/_build/html/source/quarchpy.connection_specific.html +12 -1
  94. quarchpy/docs/_build/html/source/quarchpy.html +3 -0
  95. quarchpy/docs/_build/html/source/quarchpy.iometer.html +7 -6
  96. quarchpy/docs/_build/html/source/quarchpy.qis.html +6 -0
  97. quarchpy/docs/_build/html/source/quarchpy.utilities.html +7 -6
  98. quarchpy/docs/_build/html/source/readme.html +7 -6
  99. quarchpy/fio/__pycache__/FIO_interface.cpython-311.pyc +0 -0
  100. quarchpy/fio/__pycache__/__init__.cpython-311.pyc +0 -0
  101. quarchpy/fio/fioDiskFinder.py +1 -1
  102. quarchpy/iometer/__pycache__/__init__.cpython-311.pyc +0 -0
  103. quarchpy/iometer/__pycache__/gen_iometer_template.cpython-311.pyc +0 -0
  104. quarchpy/iometer/__pycache__/iometerFuncs.cpython-311.pyc +0 -0
  105. quarchpy/qis/__pycache__/StreamHeaderInfo.cpython-311.pyc +0 -0
  106. quarchpy/qis/__pycache__/__init__.cpython-311.pyc +0 -0
  107. quarchpy/qis/__pycache__/qisFuncs.cpython-311.pyc +0 -0
  108. quarchpy/qis/qisFuncs.py +0 -4
  109. quarchpy/qps/__pycache__/__init__.cpython-311.pyc +0 -0
  110. quarchpy/qps/__pycache__/qpsFuncs.cpython-311.pyc +0 -0
  111. quarchpy/run.py +4 -4
  112. quarchpy/user_interface/__pycache__/__init__.cpython-311.pyc +0 -0
  113. quarchpy/user_interface/__pycache__/user_interface.cpython-311.pyc +0 -0
  114. quarchpy/user_interface/user_interface.py +1 -0
  115. quarchpy/utilities/__pycache__/TestCenter.cpython-311.pyc +0 -0
  116. quarchpy/utilities/__pycache__/TimeValue.cpython-311.pyc +0 -0
  117. quarchpy/utilities/__pycache__/Version.cpython-311.pyc +0 -0
  118. quarchpy/utilities/__pycache__/__init__.cpython-311.pyc +0 -0
  119. {quarchpy-2.1.22.dist-info → quarchpy-2.1.23.dist-info}/METADATA +14 -8
  120. {quarchpy-2.1.22.dist-info → quarchpy-2.1.23.dist-info}/RECORD +122 -143
  121. quarchpy/__pycache__/run.cpython-311.pyc +0 -0
  122. quarchpy/connection_specific/__pycache__/connection_TCP.cpython-311.pyc +0 -0
  123. quarchpy/connection_specific/__pycache__/connection_Telnet.cpython-311.pyc +0 -0
  124. quarchpy/connection_specific/serial/__pycache__/rfc2217.cpython-311.pyc +0 -0
  125. quarchpy/connection_specific/serial/__pycache__/rs485.cpython-311.pyc +0 -0
  126. quarchpy/connection_specific/serial/__pycache__/serialcli.cpython-311.pyc +0 -0
  127. quarchpy/connection_specific/serial/__pycache__/serialjava.cpython-311.pyc +0 -0
  128. quarchpy/connection_specific/serial/__pycache__/serialposix.cpython-311.pyc +0 -0
  129. quarchpy/connection_specific/serial/threaded/__pycache__/__init__.cpython-311.pyc +0 -0
  130. quarchpy/connection_specific/serial/tools/__pycache__/hexlify_codec.cpython-311.pyc +0 -0
  131. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_linux.cpython-311.pyc +0 -0
  132. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_osx.cpython-311.pyc +0 -0
  133. quarchpy/connection_specific/serial/tools/__pycache__/list_ports_posix.cpython-311.pyc +0 -0
  134. quarchpy/connection_specific/serial/tools/__pycache__/miniterm.cpython-311.pyc +0 -0
  135. quarchpy/connection_specific/serial/urlhandler/__pycache__/__init__.cpython-311.pyc +0 -0
  136. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_alt.cpython-311.pyc +0 -0
  137. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_hwgrep.cpython-311.pyc +0 -0
  138. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_loop.cpython-311.pyc +0 -0
  139. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_rfc2217.cpython-311.pyc +0 -0
  140. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_socket.cpython-311.pyc +0 -0
  141. quarchpy/connection_specific/serial/urlhandler/__pycache__/protocol_spy.cpython-311.pyc +0 -0
  142. quarchpy/connection_specific/usb_libs/MS32/__pycache__/__init__.cpython-311.pyc +0 -0
  143. quarchpy/connection_specific/usb_libs/MS64/__pycache__/__init__.cpython-311.pyc +0 -0
  144. quarchpy/connection_specific/usb_libs/__pycache__/__init__.cpython-311.pyc +0 -0
  145. quarchpy/connection_specific/usb_libs/__pycache__/libusb1.cpython-311.pyc +0 -0
  146. quarchpy/connection_specific/usb_libs/__pycache__/usb1.cpython-311.pyc +0 -0
  147. quarchpy/debug/__pycache__/__main__.cpython-311.pyc +0 -0
  148. quarchpy/debug/__pycache__/module_debug.cpython-311.pyc +0 -0
  149. quarchpy/debug/__pycache__/simple_terminal.cpython-311.pyc +0 -0
  150. quarchpy/debug/__pycache__/upgrade_quarchpy.cpython-311.pyc +0 -0
  151. quarchpy/docs/__pycache__/__init__.cpython-311.pyc +0 -0
  152. quarchpy/docs/__pycache__/conf.cpython-311.pyc +0 -0
  153. quarchpy/fio/__pycache__/fioDiskFinder.cpython-311.pyc +0 -0
  154. quarchpy/fio/__pycache__/performanceClass.cpython-311.pyc +0 -0
  155. quarchpy/fio/__pycache__/test_performance_class.cpython-311.pyc +0 -0
  156. quarchpy/utilities/__pycache__/BitManipulation.cpython-311.pyc +0 -0
  157. {quarchpy-2.1.22.dist-info → quarchpy-2.1.23.dist-info}/WHEEL +0 -0
  158. {quarchpy-2.1.22.dist-info → quarchpy-2.1.23.dist-info}/top_level.txt +0 -0
@@ -171,10 +171,6 @@ class QisInterface:
171
171
  moduleStreaming= module.sendCommand("rec stream?").lower() #checking if module thinks its streaming.
172
172
  moduleStreaming2= module.sendCommand("stream?").lower() #checking if the module has told qis it has stopped streaming.
173
173
 
174
- #print("thread list = " + str(threadNameList))
175
- #print("moduleStreaming rec stream? = " + str(moduleStreaming))
176
- #print("moduleStreaming stream? = " + str(moduleStreaming2))
177
-
178
174
  if (moduleName in threadNameList or "running" in moduleStreaming or "running" in moduleStreaming2):
179
175
  time.sleep(0.1)
180
176
 
@@ -276,7 +272,6 @@ class QisInterface:
276
272
  #now = time.time()
277
273
  streamOverrun, removeChar, newStripes = self.streamGetStripesText(self.streamSock, module, numStripesPerRead)
278
274
  newStripes = newStripes.replace(' ', separator)
279
- #print (time.time() - now)
280
275
  if streamOverrun:
281
276
  self.deviceDict[module][0:3] = [True, 'Stopped', 'Device buffer overrun']
282
277
  # TODO: MD Why don't we return isEmpty in the tuple, instead of having this confusing test?
@@ -498,10 +493,7 @@ class QisInterface:
498
493
  streamOverrun, removeChar, newStripes = self.streamGetStripesText(self.streamSock, module,
499
494
  numStripesPerRead)
500
495
  newStripes = newStripes.replace(' ',separator)
501
- # print(newStripes)
502
- # print(len(newStripes))
503
496
 
504
- # print (time.time() - now)
505
497
  if streamOverrun:
506
498
  self.deviceDict[module][0:3] = [True, 'Stopped', 'Device buffer overrun']
507
499
  if (removeChar == -6 and len(newStripes) == 6):
@@ -1565,6 +1557,25 @@ class QisInterface:
1565
1557
  f.write("Saved: "+x+ "\n")
1566
1558
 
1567
1559
 
1560
+ def sendCommand(self, cmd, device="", timeout=20,sock=None,readUntilCursor=True, betweenCommandDelay=0.0, expectedResponse=True):
1561
+ '''Send command is used to send a command to QIS and as far as I can see it has no difference than sendAndReceiveCmd'''
1562
+ if expectedResponse is True:
1563
+ if sock == None:
1564
+ sock = self.sock
1565
+ if not (device == ''):
1566
+ self.deviceDictSetup(device)
1567
+ res = self.sendAndReceiveText(sock, cmd, device, readUntilCursor)
1568
+ if (betweenCommandDelay > 0):
1569
+ time.sleep(betweenCommandDelay)
1570
+ # If ends with cursor get rid of it
1571
+ if res[-1:] == '>':
1572
+ res = res[:-3] # remove last three chars - hopefully '\r\n>'
1573
+ return res
1574
+
1575
+ else :
1576
+ self.sendText(sock, cmd, device)
1577
+ return
1578
+
1568
1579
  # when sending commands to module (as opposed to back end)
1569
1580
  # If read until cursor is set to True (which is default) then keep reading response until a cursor is returned as the last character of result string
1570
1581
  # After command is sent wait for betweenCommandDelay which defaults to 0 but can be specified to add a delay between commands
@@ -52,6 +52,31 @@ class QpsInterface:
52
52
  else:
53
53
  self.client.send( data )
54
54
 
55
+ def sendCommand(self, cmd, timeout=20, expectedResponse=True ):
56
+ cmd = cmd + "\r\n"
57
+ logging.debug("Sending cmd to QPS: " + str(cmd))
58
+ self.send(cmd)
59
+
60
+ start = time.time()
61
+ response = self.recv().strip()
62
+ while response.rfind('\r\n>') == -1: # If true then the resposnse is large and multi packeted
63
+ time.sleep(0.1)
64
+ t_response = self.recv().strip()
65
+ # Add current response to new response
66
+ response += t_response
67
+ # Keep reading from the socket if there's stuff that was retreived
68
+ if len(str(t_response)) == 0:
69
+ if time.time() - start > timeout:
70
+ logging.warning("Command : " + str(cmd) + " Hit timeout during QPS read. timeout = " + str(timeout))
71
+ break
72
+
73
+ pos = response.rfind('\r\n>')
74
+ if pos == -1:
75
+ logging.warning("Did not retrieve trailing '\\r\\n>' from QPS read, returned full response so far")
76
+ logging.warning("command : " + cmd.replace('\r\n', '\\r\\n'))
77
+ logging.warning("returned : " + response.replace('\r\n', '\\r\\n'))
78
+ pos = len(str(response))
79
+ return response[:pos]
55
80
 
56
81
  def sendCmdVerbose(self, cmd, timeout=20):
57
82
  cmd = cmd + "\r\n"
@@ -83,7 +108,6 @@ class QpsInterface:
83
108
  def connect(self, targetDevice):
84
109
  cmd="$connect " + targetDevice
85
110
  retVal = self.sendCmdVerbose(cmd)
86
- #print(cmd+" : "+retVal)
87
111
  time.sleep(0.3)
88
112
  return retVal
89
113
 
@@ -15,9 +15,9 @@ class ReSTConn:
15
15
  def close(self):
16
16
  return True
17
17
 
18
- def sendCommand(self, Command, expectedResponse = True, max_retries=1):
18
+ def sendCommand(self, Command, expectedResponse = True, max_retries=2):
19
19
  Command = "/" + Command.replace(" ", "%20")
20
- for attempt in range(1, max_retries + 1):
20
+ for attempt in range(0, max_retries ):
21
21
  try:
22
22
  self.Connection.request("GET", Command)
23
23
  if expectedResponse == True:
@@ -37,6 +37,7 @@ class ReSTConn:
37
37
  except socket.timeout as e:
38
38
  if attempt < max_retries:
39
39
  logging.warning("Socket timed out, retrying command...")
40
+ time.sleep(0.1)
40
41
  else:
41
42
  logging.error("Maximum number of retries reached on module at: "+self.ConnTarget+". Exiting.")
42
43
  raise e
@@ -1,7 +1,7 @@
1
1
  """
2
2
  Functions to allow automatic update and checking of the quarchpy package.
3
3
  """
4
- from quarchpy import isQisRunning, closeQIS, isQpsRunning, closeQPS
4
+ from quarchpy import isQisRunning, isQpsRunning, closeQps, closeQis
5
5
  import subprocess, sys
6
6
  from quarchpy.user_interface import *
7
7
 
@@ -89,11 +89,11 @@ def check_if_update(auto_update):
89
89
  if update_desired:
90
90
  if isQpsRunning() == True:
91
91
  usr_input = requestDialog(title="", message="QPS must be closed to update. Close QPS Y/N?")
92
- if auto_update or usr_input == "Y" or usr_input == "y": closeQPS()
92
+ if auto_update or usr_input == "Y" or usr_input == "y": closeQps()
93
93
  else: return False
94
94
  if isQisRunning() == True:
95
95
  usr_input = requestDialog(title="", message="QIS must be closed to update. Close QIS Y/N?")
96
- if auto_update or usr_input == "Y" or usr_input == "y": closeQIS()
96
+ if auto_update or usr_input == "Y" or usr_input == "y": closeQis()
97
97
  else: return False
98
98
  else:
99
99
  return False
quarchpy/device/device.py CHANGED
@@ -214,7 +214,6 @@ class quarchDevice:
214
214
 
215
215
  # def setCanStream(self):
216
216
  # ask module name if = name in list
217
- # TODO: expectedResponse does nothing can it be removed
218
217
  # TODO: The connectionObj should be an instance of a common base class such that the IF block here is not needed
219
218
  def sendCommand(self, CommandString, expectedResponse = True):
220
219
  """
@@ -245,33 +244,35 @@ class quarchDevice:
245
244
  if numb_colons == 1:
246
245
  self.ConString = self.ConString.replace(':', '::')
247
246
 
248
- response = self.connectionObj.qis.sendCmd(self.ConString, CommandString)
247
+ response = self.connectionObj.qis.sendCommand(CommandString, device=self.ConString, expectedResponse=expectedResponse)
249
248
  # send response to log
250
249
  logging.debug(os.path.basename(__file__) + ": "+self.ConType[:3]+" received: " + response)
251
250
  return response
252
251
 
253
252
  elif self.ConType == "PY":
254
- response = self.connectionObj.connection.sendCommand(CommandString)
253
+ response = self.connectionObj.connection.sendCommand(CommandString, expectedResponse=expectedResponse)
255
254
  # send response to log
256
255
  logging.debug(os.path.basename(__file__) + ": "+self.ConType[:3]+" received: " + response)
257
256
  return response
258
257
 
259
258
  elif self.ConType[:3] == "QPS":
260
- # checking if the command string passed has a $ as first char
259
+ # If "$" CMD is for QPS, else its for the specific module. Since QPS can talk to many modules we must added the conString.
261
260
  if CommandString[0] != '$':
262
261
  CommandString = self.ConString + " " + CommandString
263
262
 
264
- response = self.connectionObj.qps.sendCmdVerbose(CommandString)
263
+ response = self.connectionObj.qps.sendCommand(CommandString, expectedResponse)
265
264
  # send response to log
266
265
  logging.debug(os.path.basename(__file__) + ": "+self.ConType[:3]+" received: " + response)
267
266
  return response
268
267
 
268
+
269
269
  # Only works for usb
270
270
  # TODO: Can this be marked '_' for private use only
271
271
  def sendBinaryCommand(self, cmd):
272
272
  self.connectionObj.connection.Connection.SendCommand(cmd)
273
273
  return self.connectionObj.connection.Connection.BulkRead()
274
274
 
275
+
275
276
  # TODO: Not using class hierarchy based connectionObj, recreation of PYConnection may not release the previous handle in time.
276
277
  # QPS and QIS actions are different despite the underlying connection being the same!
277
278
  def openConnection(self):
@@ -297,6 +298,7 @@ class quarchDevice:
297
298
  else:
298
299
  raise Exception("Connection type not recognised")
299
300
 
301
+
300
302
  # TODO: Not using class hierarchy based connectionObj. QPS and QIS actions are different despite the underlying connection being the same!
301
303
  def closeConnection(self):
302
304
  """
@@ -317,7 +319,7 @@ class quarchDevice:
317
319
 
318
320
  return "OK"
319
321
 
320
-
322
+
321
323
  # TODO: Not using class hierarchy based connectionObj.
322
324
  def resetDevice(self, timeout=10):
323
325
  """
@@ -427,6 +429,7 @@ class quarchDevice:
427
429
  else:
428
430
  return True
429
431
 
432
+
430
433
  def getRuntime(self, command="conf:runtimes?"):
431
434
  '''
432
435
 
@@ -468,6 +471,7 @@ def _check_ip_in_qis_list(ip_address, detailed_device_list):
468
471
  # If the ip address wasn't found, then return none
469
472
  return None
470
473
 
474
+
471
475
  # TODO: Can we make this an '_' internal function?
472
476
  def checkModuleFormat(ConString):
473
477
  ConnectionTypes = ["USB", "SERIAL", "TELNET", "REST", "TCP"] # acceptable conTypes
@@ -393,9 +393,6 @@ class quarchStream:
393
393
  else:
394
394
  dataPointTime = toQpsTimeStamp(dataPointTime)
395
395
 
396
- # print ("printing command: $log " + channelName + " " + groupName + " " + str(dataPointTime) + " " + str(dataValue))
397
- # self.connectionObj.qps.sendCmdVerbose("$log " + channelName + " " + groupName + " " + str(dataPointTime) + " " + str(dataValue))
398
-
399
396
  self.connectionObj.qps.sendCmdVerbose(
400
397
  "$stream data add " + channelName + " " + groupName + " " + str(dataPointTime) + " " + str(
401
398
  dataValue) + " " + timeFormat)
@@ -220,7 +220,6 @@ def list_network(target_conn="all", debugPring=False, lanTimeout=1, ipAddressLoo
220
220
  break
221
221
  cont = 0
222
222
 
223
- # print(msg_received)
224
223
  # Used split \r\n since values of 13 or 10 were looked at as /r and /n when using splitlines
225
224
  # This fixes for all cases except if 13 is followed by 10.
226
225
  splits = msg_received[0].split(b"\r\n")
@@ -480,7 +479,6 @@ def scanDevices(target_conn="all", lanTimeout=1, scanInArray=True, favouriteOnly
480
479
  except Exception as e:
481
480
  logging.error(e)
482
481
  logging.warning("Network scan failed, check network connection")
483
- # print(foundDevices)
484
482
 
485
483
  if target_conn.lower() == "serial":
486
484
  foundDevices = list_serial()
quarchpy/docs/CHANGES.rst CHANGED
@@ -13,9 +13,15 @@ Quarchpy
13
13
  Change Log
14
14
  ----------
15
15
 
16
- 2.1.21
16
+ 2.1.23
17
+ ------
18
+ - QIS and QPS devices and interfaces can use sendCommand to send comannds to the modules and to the applications uniformly
19
+ - Tidy up of print statments and comments.
20
+
21
+ 2.1.22
17
22
  ------
18
- - Bug fix QPS v1.39 QIS v1.42 reverting mDNS scanning change.
23
+ - QIS and QPS patch containing mDNS removal
24
+
19
25
 
20
26
  2.1.21
21
27
  ------
@@ -24,7 +30,7 @@ Change Log
24
30
 
25
31
  2.1.20
26
32
  ------
27
- - Improved direct IP scanning for quarch modules.
33
+ - Improved direct IP scanning for quarch modules
28
34
  - New QPS v1.37 and QIS v1.40
29
35
 
30
36
  2.1.19
@@ -53,19 +59,19 @@ Change Log
53
59
 
54
60
  2.1.14
55
61
  ------
56
- - minor bug fixes and logging improvements.
62
+ - minor bug fixes and logging improvements
57
63
 
58
64
  2.1.13
59
65
  ------
60
66
  - New QPS v1.36
61
67
  - New QIS v1.39
62
- - minor bug fixes and logging improvements.
68
+ - minor bug fixes and logging improvements
63
69
 
64
70
  2.1.12
65
71
  ------
66
72
  - New QPS v1.35
67
73
  - New QIS v1.38
68
- - minor bug fixes and removal of depracated code.
74
+ - minor bug fixes and removal of depracated code
69
75
 
70
76
  2.1.11
71
77
  ------
@@ -104,7 +110,7 @@ Change Log
104
110
  2.1.3
105
111
  -----
106
112
  - New QPS v1.22
107
- - modules on the network can now be connected to using conType:QTLNumber eg. TCP:QTL1999-02-001.
113
+ - modules on the network can now be connected to using conType:QTLNumber eg. TCP:QTL1999-02-001
108
114
  - fixed QIS not closing with QPS when launch with by QPS
109
115
  - closeConnection added to QIS api
110
116
  - display table formats multiline items and handles empty cells
Binary file