##// END OF EJS Templates
api jars functions have been modificated: stop, configure, read, status and created: start...
Fiorella Quino -
r210:8db2b04b1bbf
parent child
Show More
@@ -365,6 +365,27 class ABSConfiguration(Configuration):
365
365
366 return True
366 return True
367
367
368 def moni(self):
369
370 monitoreo_tx = 'JROABSClnt_01CeCnMod000000MNTR10'
371 beam_tx = 'JROABSCeCnModCnMod01000001CHGB10'
372
373 beam_pos = 1
374 module_address = ('192.168.1.63', 5500)
375
376 message_tx = monitoreo_tx
377 # Create the datagram socket
378 sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
379 sock.connect(module_address)
380
381 sock.send(message_tx)
382 t = sock.recv(1024)
383 print 'Respuesta: \n',t
384 sock.close()
385 sock = None
386
387 return True
388
368
389
369 def module_conf(self, module_num, beams):
390 def module_conf(self, module_num, beams):
370 """
391 """
@@ -36,6 +36,7 CMD_SET_EXEPATH = 0X12
36 CMD_ECHO = 0XFE
36 CMD_ECHO = 0XFE
37 CMD_READ = 0X08
37 CMD_READ = 0X08
38 CMD_STOP = 0X09
38 CMD_STOP = 0X09
39 CMD_START = 0x05
39
40
40 @eth_device(ID_CLASS)
41 @eth_device(ID_CLASS)
41 def reset():
42 def reset():
@@ -46,6 +47,14 def reset():
46 return cmd, payload
47 return cmd, payload
47
48
48 @eth_device(ID_CLASS)
49 @eth_device(ID_CLASS)
50 def start():
51
52 cmd = CMD_START
53 payload = ''
54
55 return cmd, payload
56
57 @eth_device(ID_CLASS)
49 def stop():
58 def stop():
50
59
51 cmd = CMD_STOP
60 cmd = CMD_STOP
@@ -100,7 +109,7 def set_exepath(path):
100 # data['configurations']['dds']=''
109 # data['configurations']['dds']=''
101 # data['configurations']['rc']['pulses']=''
110 # data['configurations']['rc']['pulses']=''
102 # data['configurations']['rc']['delays']=''
111 # data['configurations']['rc']['delays']=''
103
112
104 #data = json.dumps(data)
113 #data = json.dumps(data)
105 #-----------------------------------
114 #-----------------------------------
106
115
General Comments 0
You need to be logged in to leave comments. Login now