Changeset 14458 for fact/tools


Ignore:
Timestamp:
10/03/12 21:27:51 (12 years ago)
Author:
neise
Message:
further evolving
File:
1 edited

Legend:

Unmodified
Added
Removed
  • fact/tools/PyDimCtrl/ScriptsForPyDimCtrl.py

    r14457 r14458  
    1 #!/usr/bin/python
     1#!/usr/bin/python -tti
    22
    33import time
     
    150150  """
    151151
    152   start = time()
     152  start = time.time()
    153153  while (feedback.stn != 12):
    154154    time.sleep(0.1)
    155     if time() > start + 10.:
     155    if time.time() > start + 10.:
    156156      print "==================================================="
    157157      print " feedback is not in state 'CurrentControl' "
     
    166166  bias_control.set_global_dac(1)
    167167
    168   start = time()
     168  start = time.time()
    169169  while (bias_control.stn != 9):
    170170    time.sleep(0.1)
    171     if time() > start + 10.:
     171    if time.time() > start + 10.:
    172172      print '==================================================='
    173173      print ' switching on bias not successfull'
     
    430430
    431431  # Take a DRS-Calibration before beginning to take physics Data
    432   TakeDrsCalibration()
     432  #TakeDrsCalibration()
    433433
    434434  # check feedback state before switching BIAS ON and ramping up to nominal Voltage
     
    983983                          'wobble_angle' : wobble_angle,
    984984                          'source_name' : sourcename }
    985   last_drive_method(**last_drive_kwargs)
     985  kwa = last_drive_kwargs
     986  last_drive_method(kwa['wobble_offset'], kwa['wobble_angle'], kwa['source_name'])
    986987 
    987988  print '... done'
     
    10361037 
    10371038  StopTracking()
     1039
     1040def PrintCurrents( x = 1.0):
     1041  while True:
     1042    time.sleep( x )
     1043    print time.strftime('%d %b %Y %H:%M:%S UTC', time.gmtime()), GetBiasCurrent()
     1044
     1045def WaitForTracking():
     1046  drive_control.wait(7) #Moving
     1047  drive_control.wait(8) #Tracking
     1048  time.sleep(10)
     1049
     1050
     1051if __name__ == '__main__':
     1052  print 'Welcome to PyDimCtrl'
     1053  make_sourcedict()
     1054  print
     1055  print 'possible sources:'
     1056  print sorted( sourcedict.keys() )
Note: See TracChangeset for help on using the changeset viewer.