@@ -283,7 +283,7 class ABSConfiguration(Configuration): | |||||
283 | module_port = self.device.port_address |
|
283 | module_port = self.device.port_address | |
284 | read_route = 'http://'+module_ip+':'+str(module_port)+'/read' |
|
284 | read_route = 'http://'+module_ip+':'+str(module_port)+'/read' | |
285 |
|
285 | |||
286 |
print |
|
286 | print(read_route) | |
287 |
|
287 | |||
288 | answer = '' |
|
288 | answer = '' | |
289 | module_bits = '' |
|
289 | module_bits = '' | |
@@ -410,10 +410,10 class ABSConfiguration(Configuration): | |||||
410 | sock.connect(module_address) |
|
410 | sock.connect(module_address) | |
411 | sock.send(message_tx) |
|
411 | sock.send(message_tx) | |
412 | sock.close() |
|
412 | sock.close() | |
413 |
print |
|
413 | print("Writing abs module:"+module_address[0]+"...") | |
414 | except: |
|
414 | except: | |
415 | sock = None |
|
415 | sock = None | |
416 |
print |
|
416 | print("Problem writing abs module:"+module_address[0]) | |
417 | return 0 |
|
417 | return 0 | |
418 |
|
418 | |||
419 | return 1 |
|
419 | return 1 | |
@@ -427,7 +427,7 class ABSConfiguration(Configuration): | |||||
427 | try: |
|
427 | try: | |
428 | self.beam_selector(i,beam_pos) |
|
428 | self.beam_selector(i,beam_pos) | |
429 | except: |
|
429 | except: | |
430 |
print |
|
430 | print("Problem with module: 192.168.1."+str(i)) | |
431 | self.message = "Problem with module: 192.168.1."+str(i) |
|
431 | self.message = "Problem with module: 192.168.1."+str(i) | |
432 | #return 0 |
|
432 | #return 0 | |
433 | return 1 |
|
433 | return 1 | |
@@ -554,7 +554,7 class ABSConfiguration(Configuration): | |||||
554 | for j in jobs: |
|
554 | for j in jobs: | |
555 | j.join() |
|
555 | j.join() | |
556 |
|
556 | |||
557 |
print |
|
557 | print("List processing complete.") | |
558 | return 1 |
|
558 | return 1 | |
559 |
|
559 | |||
560 |
|
560 |
@@ -1,6 +1,6 | |||||
1 | from django.conf.urls import url |
|
1 | from django.conf.urls import url | |
2 |
|
2 | |||
3 | import views |
|
3 | from apps.abs import views | |
4 |
|
4 | |||
5 | urlpatterns = ( |
|
5 | urlpatterns = ( | |
6 | url(r'^(?P<id_conf>-?\d+)/$', views.abs_conf, name='url_abs_conf'), |
|
6 | url(r'^(?P<id_conf>-?\d+)/$', views.abs_conf, name='url_abs_conf'), |
@@ -4,7 +4,6 from itertools import chain | |||||
4 |
|
4 | |||
5 | from django import forms |
|
5 | from django import forms | |
6 | from django.utils.safestring import mark_safe |
|
6 | from django.utils.safestring import mark_safe | |
7 | from django.utils.encoding import force_unicode |
|
|||
8 | from django.utils.html import conditional_escape |
|
7 | from django.utils.html import conditional_escape | |
9 |
|
8 | |||
10 | style = """<style> |
|
9 | style = """<style> |
@@ -1420,7 +1420,6 def operation(request, id_camp=None): | |||||
1420 | kwargs['experiments'] = experiments |
|
1420 | kwargs['experiments'] = experiments | |
1421 | #---Radar |
|
1421 | #---Radar | |
1422 | kwargs['locations'] = campaign.get_experiments_by_location() |
|
1422 | kwargs['locations'] = campaign.get_experiments_by_location() | |
1423 | print kwargs['locations'] |
|
|||
1424 | #---Else |
|
1423 | #---Else | |
1425 | kwargs['title'] = 'Campaign' |
|
1424 | kwargs['title'] = 'Campaign' | |
1426 | kwargs['suptitle'] = campaign.name |
|
1425 | kwargs['suptitle'] = campaign.name | |
@@ -1586,4 +1585,3 def radar_refresh(request, id_camp, id_radar): | |||||
1586 | return HttpResponseRedirect(reverse('url_operation_search', args=[id_camp])) |
|
1585 | return HttpResponseRedirect(reverse('url_operation_search', args=[id_camp])) | |
1587 | else: |
|
1586 | else: | |
1588 | return HttpResponseRedirect(reverse('url_operation', args=[id_camp])) |
|
1587 | return HttpResponseRedirect(reverse('url_operation', args=[id_camp])) | |
1589 |
|
General Comments 0
You need to be logged in to leave comments.
Login now