From 22abeefacf0927f7a82b2175664c4a752fa9677a Mon Sep 17 00:00:00 2001 From: gac-S_Changer Date: Tue, 5 Apr 2022 09:13:02 +0200 Subject: [PATCH] mount.py plus settings --- config/config.properties | 41 +++++++++++++++++++++----------- config/devices-modbus.properties | 1 + config/devices.properties | 6 ++--- config/jcae.properties | 17 ++++++------- config/settings.properties | 4 ++-- config/setup.properties | 29 ++++++++++++---------- config/variables.properties | 6 +++-- devices/A3.properties | 4 ++-- devices/B2.properties | 4 ++-- devices/C1.properties | 4 ++-- devices/C5.properties | 4 ++-- devices/E1.properties | 4 ++-- devices/E3.properties | 2 +- devices/F3.properties | 4 ++-- devices/led_ctrl_1.properties | 2 +- devices/led_ctrl_2.properties | 2 +- devices/led_ctrl_3.properties | 2 +- script/motion/mount.py | 6 ++--- 18 files changed, 81 insertions(+), 61 deletions(-) diff --git a/config/config.properties b/config/config.properties index 3ad0aa0..44d108b 100644 --- a/config/config.properties +++ b/config/config.properties @@ -1,37 +1,50 @@ -#Fri Aug 14 09:21:30 CEST 2020 +#Wed Mar 02 10:57:08 CET 2022 +autoSaveScanData=true +simulation=false +commandExecutionEvents=false +logDaysToLive=30 +dataScanSaveOutput=false +userAuthenticator= +logLevelConsole=Off +filePermissionsConfig=Default +scanStreamerPort=-1 +dataScanSaveScript=false +dataScanSaveSetpoints=false +notifiedTasks= +parallelInitialization=false +dataTransferPath= +saveConsoleSessionFiles=false +versionTrackingManual=true +dataTransferMode=Off hostName=null userManagement=false instanceName=X10SA -autoSaveScanData=true -simulation=false +disableEmbeddedAttributes=false dataServerPort=-1 hideServerMessages=true serverPort=8080 versionTrackingEnabled=true dataPath={data}/{year}_{month}/{date}/{date}_{time}_{name} serverEnabled=true -commandExecutionEvents=false -logDaysToLive=30 dataScanReleaseRecords=false depthDimension=0 dataScanPreserveTypes=false logLevel=Fine -dataScanSaveOutput=false dataScanFlushRecords=true logPath={logs}/{date}_{time} +filePermissionsLogs=Default dataLayout=table +disableDataFileLogs=false +sessionHandling=Off terminalEnabled=false -notificationLevel=null -userAuthenticator= -logLevelConsole=Off +notificationLevel=Off +filePermissionsScripts=Default terminalPort=3579 -scanStreamerPort=-1 -dataScanSaveScript=false -dataScanSaveSetpoints=false -parallelInitialization=false +dataTransferUser= +filePermissionsData=Default createSessionFiles=true versionTrackingLogin={context}/svcusr-hlapp_robot -versionTrackingManual=true +noBytecodeFiles=false versionTrackingRemote=git@git.psi.ch\:tell/X10SA.git dataProvider=txt saveCommandStatistics=true diff --git a/config/devices-modbus.properties b/config/devices-modbus.properties index d1313b0..4a1eebf 100644 --- a/config/devices-modbus.properties +++ b/config/devices-modbus.properties @@ -1,6 +1,7 @@ th2e=ch.psi.pshell.modbus.ModbusTCP|129.129.118.200:502||| temperature=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 1||10000| humidity=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 5||10000| + #dew_point=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 9||1000| wago=ch.psi.pshell.modbus.ModbusTCP|tell10s-wago:502||| led_ok_1=ch.psi.pshell.modbus.DigitalInput|wago 0||1000| diff --git a/config/devices.properties b/config/devices.properties index dddde06..4be0157 100644 --- a/config/devices.properties +++ b/config/devices.properties @@ -2,9 +2,9 @@ aerotech_x=ch.psi.pshell.epics.ChannelDouble|X10SA-ES-DF1:GMX-RBV|Read|1000|fals cryopos=ch.psi.pshell.epics.Motor|X10SA-ES-CJ:TRY1|||true magnet_position=ch.psi.pshell.epics.ChannelDouble|X10SA-ES-DFS:CBOX-SENSOR1|Read||true magnet_position_ok=ch.psi.pshell.epics.ChannelString|X10SA-ES-DF1:SN1-CMP|Read||true -th2e=ch.psi.pshell.modbus.ModbusTCP|129.129.118.200:502||| -temperature=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 1||10000| -humidity=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 5||10000| +#th2e=ch.psi.pshell.modbus.ModbusTCP|129.129.118.200:502||| +#temperature=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 1||10000| +#humidity=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 5||10000| #dew_point=ch.psi.pshell.modbus.ReadonlyProcessVariable|th2e 9||1000| #img=ch.psi.pshell.prosilica.Prosilica|204464 "PacketSize=1504;PixelFormat=Mono8;BinningX=1;BinningY=1;RegionX=290;RegionY=130;Width=1000;Height=1000;MulticastEnable=Off"||-200|false #gripper_cam=ch.psi.pshell.imaging.MjpegSource|http://axis-accc8ea5e463.psi.ch/axis-cgi/mjpg/video.cgi?camera=1 reopen||-200|false diff --git a/config/jcae.properties b/config/jcae.properties index 7f9e889..cb045f3 100644 --- a/config/jcae.properties +++ b/config/jcae.properties @@ -1,11 +1,12 @@ -#Tue Sep 06 15:10:24 CEST 2016 -ch.psi.jcae.ContextFactory.addressList= -ch.psi.jcae.ContextFactory.serverPort= +#Mon Mar 14 10:49:28 CET 2022 ch.psi.jcae.ContextFactory.maxArrayBytes=20000000 -ch.psi.jcae.ChannelFactory.retries=1 -ch.psi.jcae.ChannelFactory.timeout=500 -ch.psi.jcae.impl.DefaultChannelService.retries=2 ch.psi.jcae.impl.DefaultChannelService.timeout=1000 -ch.psi.jcae.ContextFactory.autoAddressList=true +ch.psi.jcae.ChannelFactory.timeout=1000 +ch.psi.jcae.ContextFactory.maxSendArrayBytes= +ch.psi.jcae.ChannelFactory.retries=1 ch.psi.jcae.ContextFactory.useShellVariables=false -ch.psi.jcae.ContextFactory.addLocalBroadcastInterfaces=false +ch.psi.jcae.ContextFactory.addLocalBroadcastInterfaces=true +ch.psi.jcae.ContextFactory.addressList=X10SA-VME-ES1.psi.ch +ch.psi.jcae.ContextFactory.serverPort= +ch.psi.jcae.impl.DefaultChannelService.retries=2 +ch.psi.jcae.ContextFactory.autoAddressList=true diff --git a/config/settings.properties b/config/settings.properties index f8a6e31..39c38ec 100644 --- a/config/settings.properties +++ b/config/settings.properties @@ -1,10 +1,10 @@ -#Thu Dec 09 11:39:57 CET 2021 +#Tue Apr 05 09:11:38 CEST 2022 dry_mount_counter=0 room_temperature_enabled=false pin_offset=-0.0 puck_types=true imaging_enabled=false -dry_timestamp=1.639039691589E9 +dry_timestamp=1.649142698729E9 roi_h=1000 led_level=0.0 beamline_status_enabled=false diff --git a/config/setup.properties b/config/setup.properties index 87a13e8..9e76330 100644 --- a/config/setup.properties +++ b/config/setup.properties @@ -1,20 +1,23 @@ -#Tue Sep 17 15:06:05 CEST 2019 -configFile={config}/config.properties +#Wed Mar 02 10:57:08 CET 2022 +scriptPath={home}/script +sessionsPath={outp}/sessions +pluginsPath={home}/plugins configFileDevices={config}/devices.properties +consoleSessionsPath={sessions}/console +libraryPath={script}; {script}/Lib configFilePlugins={config}/plugins.properties -configFileSettings={config}/settings.properties -configFileTasks={config}/tasks.properties -configFileVariables={config}/variables.properties -configPath={home}/config contextPath={outp}/context +extensionsPath={home}/extensions +configPath={home}/config +configFileSessions={config}/sessions.properties +userSessionsPath={sessions}/user dataPath={outp}/data devicesPath={home}/devices -extensionsPath={home}/extensions -imagesPath={outp}/images -libraryPath={script}; {script}/Lib +configFileVariables={config}/variables.properties +configFileSettings={config}/settings.properties logPath={outp}/log -pluginsPath={home}/plugins -scriptPath={home}/script -scriptType=py -sessionsPath={outp}/sessions wwwPath={home}/www +configFile={config}/config.properties +imagesPath={outp}/images +scriptType=py +configFileTasks={config}/tasks.properties diff --git a/config/variables.properties b/config/variables.properties index e311f46..339ddb1 100644 --- a/config/variables.properties +++ b/config/variables.properties @@ -1,2 +1,4 @@ -#Wed Dec 01 11:40:27 CET 2021 -FileSequentialNumber=180 +#Wed Mar 02 10:58:36 CET 2022 +LastRunDate=220302 +FileSequentialNumber=206 +DaySequentialNumber=2 diff --git a/devices/A3.properties b/devices/A3.properties index bf41c19..0ccae8b 100644 --- a/devices/A3.properties +++ b/devices/A3.properties @@ -1,3 +1,3 @@ -#Wed Apr 07 10:28:05 CEST 2021 +#Sat Apr 02 16:26:23 CEST 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/B2.properties b/devices/B2.properties index 3578e25..d5a21f0 100644 --- a/devices/B2.properties +++ b/devices/B2.properties @@ -1,3 +1,3 @@ -#Tue Nov 30 11:36:27 CET 2021 +#Fri Apr 01 11:06:19 CEST 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/C1.properties b/devices/C1.properties index e11ae37..66e728f 100644 --- a/devices/C1.properties +++ b/devices/C1.properties @@ -1,3 +1,3 @@ -#Tue Aug 03 11:50:02 CEST 2021 +#Fri Apr 01 11:06:42 CEST 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/C5.properties b/devices/C5.properties index 4c03039..c3e62a7 100644 --- a/devices/C5.properties +++ b/devices/C5.properties @@ -1,3 +1,3 @@ -#Tue Oct 06 13:31:33 CEST 2020 +#Wed Mar 23 13:38:45 CET 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/E1.properties b/devices/E1.properties index 9f7ea22..dad038a 100644 --- a/devices/E1.properties +++ b/devices/E1.properties @@ -1,3 +1,3 @@ -#Tue Oct 05 08:32:25 CEST 2021 +#Wed Mar 23 13:38:50 CET 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/E3.properties b/devices/E3.properties index 17307f8..8aba9a4 100644 --- a/devices/E3.properties +++ b/devices/E3.properties @@ -1,3 +1,3 @@ -#Mon Nov 15 08:51:11 CET 2021 +#Tue Jan 18 10:28:22 CET 2022 detection=Mechanical disabled=false diff --git a/devices/F3.properties b/devices/F3.properties index 865645d..ce76fd6 100644 --- a/devices/F3.properties +++ b/devices/F3.properties @@ -1,3 +1,3 @@ -#Wed Aug 25 10:06:24 CEST 2021 +#Fri Apr 01 11:06:30 CEST 2022 detection=Mechanical -disabled=false +disabled=true diff --git a/devices/led_ctrl_1.properties b/devices/led_ctrl_1.properties index afcfe54..4c9f4e5 100644 --- a/devices/led_ctrl_1.properties +++ b/devices/led_ctrl_1.properties @@ -1,4 +1,4 @@ -#Wed Dec 01 11:21:24 CET 2021 +#Fri Mar 11 13:48:49 CET 2022 minValue=0.0 unit=V offset=0.0 diff --git a/devices/led_ctrl_2.properties b/devices/led_ctrl_2.properties index afcfe54..4c9f4e5 100644 --- a/devices/led_ctrl_2.properties +++ b/devices/led_ctrl_2.properties @@ -1,4 +1,4 @@ -#Wed Dec 01 11:21:24 CET 2021 +#Fri Mar 11 13:48:49 CET 2022 minValue=0.0 unit=V offset=0.0 diff --git a/devices/led_ctrl_3.properties b/devices/led_ctrl_3.properties index afcfe54..4c9f4e5 100644 --- a/devices/led_ctrl_3.properties +++ b/devices/led_ctrl_3.properties @@ -1,4 +1,4 @@ -#Wed Dec 01 11:21:24 CET 2021 +#Fri Mar 11 13:48:49 CET 2022 minValue=0.0 unit=V offset=0.0 diff --git a/script/motion/mount.py b/script/motion/mount.py index cf7c2d3..33e7f41 100644 --- a/script/motion/mount.py +++ b/script/motion/mount.py @@ -15,6 +15,7 @@ def mount(segment, puck, sample, force=True, read_dm=False, auto_unmount=False): previous_mounted = get_setting("mounted_sample_position") if previous_mounted is not None: + print "here now" previous_segment, previous_puck, previous_sample = previous_mounted[0], int(previous_mounted[1]), int(previous_mounted[2:]) else: previous_segment, previous_puck, previous_sample = "-", 0, 0 @@ -163,8 +164,7 @@ def mount(segment, puck, sample, force=True, read_dm=False, auto_unmount=False): mount_sample_id = barcode_reader.get_readout() evlog("mount() read pin barcode: %s" % (mount_sample_id,)) else: - mount_sample_id = None - + mount_sample_id = None curpos = cryopos.getPosition() if is_room_temperature_enabled(): if curpos < 50: @@ -174,7 +174,7 @@ def mount(segment, puck, sample, force=True, read_dm=False, auto_unmount=False): movetime = int(round(3000 + (15. - curpos) / speed)) cryopos.move(15.0, movetime) cryopos.waitValueInRange(15.0, 1.0, movetime) - + robot.put_gonio() robot.close_tool() # closes gripper