Project

General

Profile

Feature #994 » cabling_detector_from_file.py

Wilson, Antony, 17 July 2012 09:41

 
1
#!/usr/bin/env python
2
""" Write tracker cablings from file"""
3

    
4
from cdb import CablingSuperMouse
5

    
6
_TEST_SERVER = 'http://rgma19.pp.rl.ac.uk:8080'
7
_CABLING_SM = CablingSuperMouse(_TEST_SERVER)
8

    
9
print "API Version: " + _CABLING_SM.get_version()
10
print "Server name: " + _CABLING_SM.get_name()
11

    
12
print _CABLING_SM
13

    
14
_DEVICE = 'EMR'
15
_TS = "2011-05-27 12:00:00.0"
16
_F = open('/home/wilsona/Documents/mice/data', 'r')
17
_DATA = _F.read()
18

    
19
print _CABLING_SM.set_detector(_DEVICE, _TS, _DATA) 
20

    
(2-2/2)