##// END OF EJS Templates
ABS Monitoring changes
imanay -
r146:147
parent child
Show More
@@ -69,9 +69,16
69 data = self.__ConnectionWithCentralControl(cmd = "ANST", data = data)
69 data = self.__ConnectionWithCentralControl(cmd = "ANST", data = data)
70 self.__writeFile("report.txt", data)
70 self.__writeFile("report.txt", data)
71
71
72 def getControlModulePhase(self, data):
72 def getControlModulePhase(self, opt, u = "50", pw = "10"):
73
73
74 data = self.__ConnectionWithCentralControl(cmd = "ANPH", data = data)
74 if opt == '0':
75 data = self.__ConnectionWithCentralControl(cmd = "LWPH", data = u + '/' + pw + '/')
76 elif opt == '1':
77 data = self.__ConnectionWithCentralControl(cmd = "BGPH", data = u + '/' + pw + '/')
78 elif opt == '2':
79 data = self.__ConnectionWithCentralControl(cmd = "cBPH", data = u + '/' + pw + '/')
80 else:
81 data = self.__ConnectionWithCentralControl(cmd = "cLPH", data = u + '/' + pw + '/')
75 # self.__writeFile("report.txt", data)
82 # self.__writeFile("report.txt", data)
76
83
77 def getConnectionStatus(self):
84 def getConnectionStatus(self):
@@ -43,11 +43,16
43 #Using tx buffer
43 #Using tx buffer
44 datarpta = self.tx_buffer
44 datarpta = self.tx_buffer
45
45
46 if cmd == "ANPH":
46 if cmd == "BGPH":
47 self.__getControlModulePhase(cmd = cmd)
47 self.__getControlModuleBigPhase(cmd = cmd)
48 #Using tx buffer
48 #Using tx buffer
49 datarpta = self.tx_buffer
49 datarpta = self.tx_buffer
50
50
51 if cmd == "LWPH":
52 self.__getControlModuleLowPhase(cmd = cmd)
53 #Using tx buffer
54 datarpta = self.tx_buffer
55
51 if cmd == "NTST":
56 if cmd == "NTST":
52 #Using tx buffer
57 #Using tx buffer
53 datarpta = self.__getConnectionStatus(cmd = cmd)
58 datarpta = self.__getConnectionStatus(cmd = cmd)
@@ -206,7 +211,24
206 print all_blocks
211 print all_blocks
207 self.tx_buffer = all_blocks
212 self.tx_buffer = all_blocks
208
213
209 def __getControlModulePhase(self, cmd):
214 def __getControlModuleBigPhase(self, cmd):
215
216 all_blocks = ""
217 # enaModules = self.checkAntenna()
218 # enaModules = [11,12,13,14]
219
220 for id in range(1,65):
221 if id not in self.enaModules:
222 continue
223
224 one_block = self.__ConnectionWithControlModules(self.rx_buffer,cmd,id)
225
226 all_blocks = all_blocks + one_block
227 #Using tx buffer
228 print all_blocks
229 self.tx_buffer = all_blocks
230
231 def __getControlModuleLowPhase(self, cmd):
210
232
211 all_blocks = ""
233 all_blocks = ""
212 # enaModules = self.checkAntenna()
234 # enaModules = self.checkAntenna()
General Comments 0
You need to be logged in to leave comments. Login now