1. Install Java
-
Install Java SDK SE on your computer: use the 32 bit version on x86 mechines, the 64-bit version on x64 processors. Download it from the java website. Please use the following installation path for SDK: C:\Program Files\Java\jdk18XYZ In order to do this on the beamline computers, you need to have administration privileges. At the time of writing, "UMeasure" was compiled successfully using JAVA SDK 1.8.0131.
-
Don't forget to update the path variable, so that java and javac can be found by the computer OS: C:\Program Files\Java\jdk18XYZ\bin
-
In your Windows environment variable, create a variable "JAVA_HOME" and set it to the compiler directory, e.g. "C:\Program Files\Java\18XYZ".
2. Install Ant
A "build" utility called Apache ant is used to compile Umeasure into a single jar distribution file, organising the source files and the various classes into subfolders.
-
Get apache from the ant website. Extract the apache ant zip file into a dedicated directory. We suggest to unzip to:
C:\ant\apache-ant-1.X.Y. At the time of writing, apache-ant-1.9.3 was successfully installed.
-
Set the appropriate path variables. Go to control panel > system > change settings > advanced > Envrionment Variables:
-
In your Windows environment variables, create a variable "ANT_HOME" and set it to the desired Ant home directory, e.g. "C:\ant\apache-ant-1.9.3".
-
Update the Windows path, so that ant can be invoked from the command prompt. For example, add the following line to the Windows path variable:
" ...;C:\ant\apache-ant-1.9.3\bin".
-
To initialize ant, open the command prompt: go to "C:\ant" and type "ant" on the command prompt. You should get the following message: "Buildfile.xml does not exist! Build failed". You can check the ant version by typing "ant -version". If this fails, you need to copy the archive "tool.jar" into "jre18XYZ/lib" (copy past it from the corresponding library available in jdk).
3. Install Jython
-
Go to http://www.jython.org/downloads.html and download the latest Jython installer. Run the installer, selecting "All (everything, including sources)", as installation type. Choose a path like: "C:\jython\jython270"
-
Download the corresponding executable jar archive, which later will have to be copied into the Umeasure lib directory. At the time of writing, UMeasure was successfully compiled with jython-2.7.0
4. Install RXTX archive and dll
The archive is needed for RS232 and USB communication with TTi: please download the appropriate package (RXTXx86.zip or RXTXx64.zip) depending whethere the computer is x86 or x64. More info on the x64 version can be found at: http://mfizz.com/oss/rxtx-for-java
-
copy RXTXcomm.jar to the JRE and JDK directories, e.g.:
-
C:\Program Files\Java\jre180131\lib\ext\RXTXcomm.jar
-
C:\Program Files\Java\jdk180131\jre\lib\ext\RXTXcomm.jar
-
copy rxtxserial.dll to the JRE and JDK directories, e.g.:
-
C:\program files\java\jre180131\bin
-
C:\Program Files\Java\jdk180131\bin\
-
C:\Program Files\Java\jdk180131\jre\bin
5. Install JSerialComm
The archive is needed for RS232 communication with all other instruments: please download the appropriate x64 version from: jSerialComm (fazecast.github.io)
-
copy the jar file jSerialComm-2.9.X to the JRE and JDK directories, e.g.:
-
C:\Program Files\Java\jre180131\lib\ext\jSerialComm-2.9.X.jar
-
C:\Program Files\Java\jdk180131\jre\lib\ext\jSerialComm-2.9.X.jar
-
copy the jar to the GUI\lib directory and ths path to the classpath:
-
C:\gui\lib\jSerialComm-2.9.X.jar
6. Installe the webcam
We use the Logitec 310 webcam. To have it running, first install the camera control software, which you can find on the Internet at:
http://support.logitech.com/en_ch/product/hd-webcam-c310
To connect the webcam to UMeasure we use the webcam-capture.sarxos API. To do this, add the suitable jar files to the GUI libraries and to the jre\lib\ext\ directory. Here's the link to the jar files.
7. Copy OmniORB (skip, not necessary)
Go to omniorb.sourceforge.net and download the laterst version of OmniORB. Untar it to, "C:\omniORB\omniORB414". Then, you have to compile it! Otherwise, install a compiled copy from one of our backups.
|
8. Configuring the CORBA nameserver (skip, not necessary)
If you need to re-install Umeasure on "pnano6", you do not need to change configuration files. Please check that the batch file gui.bat the variable "NAMESERVICE" is set to: "NameService=corbaloc::pnano6:2500/NameService". If the nameserver runs from a different computer, change the NAMESERVICE value accordingly, by replacing the string "pnano6" with the name of the host computer., e.g. pc-nano5. In this case you also have to do the following:
-
Go to the "C:\omniORB\omniORB414" direcotory and delete the omninames log and bak files: "omninames-COMPUTERNAME.bak" and "omninames-COMPUTERNAME.log".
-
Reset omnninames! In order to do this, you need to open a command window, and change the path to: "C:\omniORB\omniORB414\bin\x86_win32" then type the command: omniNames -start PORTNUMBER -logdir C:\omniORB\omniORB414. From now on, it will be possible to start the nameserver using the following commandline: C:\omniORB\omniORB414\bin\x86_win32\omniNames.exe -logdir C:\omniORB\omniORB414. This batch can be found in the GUI main directory in the "nameserver.bat" file. At this point, edit all batchfiles, i.e. beamlineserver.bat, leemserver.bat etc., and check out that the COMPUTER NAME and the PORTNUMBER are correctly set.
-
Change the CORBA parameters in LEEM2000 and UView2002 (startupORB.txt). If Uview is configured such that LEEM2000 and CCbridge start automatically ,you will find startupORB.txt in"..\program files\Uview2000\"
-
The "NAMESERVICE" variable have to be accordingly updated the gui.bat file, e.g.: java -cp SOMECLASSPATH gui.GUI -ORBInitRef NameService = corbaloc::SOMECOMPUTERNAME:PORTNUMBER/NameService.
9. Copy Umeasure
-
Get Umeasure from the Iomega hard disk on top of the data acquisition computer, where it is backed up daily, or from ESCE. Alternatively, another copy can be found on: "\\sincro-share\public\nanospectroscopy\GUI".
-
Copy Umeasure to "C:\GUI.
-
Copy the Jython executable jar archive to "C:\GUI\lib" and rename it to "Jython.jar"
-
In your Windows environment variables, create (or update) the system variable "CLASSPATH" and set it to: C:\GUI\lib\jython.jar; C:\GUI\lib\Ob.jar; C:\GUI\lib\OBBiDir.jar;C:\GUI\lib\OBEvent.jar; C:\GUI\lib\OBIMR.jar;C:\GUI\lib\OBNaming.jar;C:\GUI\lib\OBproperty.jar; C:\GUI\lib\OBTest.jar;C:\GUI\lib\OBTime.jar; C:\GUI\lib\OBUtil.jar; C:\GUI\lib\plotapplication.jar; C:\GUI\lib\JimiProClasses.zip;
10. Compiling UMeasure
open a new command prompt window, change directory to "C:\GUI" and type: ant clean
This command cleans the old classes, archives and folders. If the operation is successful, type ant dist, to compile.
11. Configuring UMeasure ouput directories
The configuration directory is defined in the gui.properties file in C:\gui\sources. The default value is C:\GUI\gui_conf. The file gui.properties must be edited BEFORE compiling Umeasure.
-
C:\GUI\gui_conf\umeasure_config.txt is the configuration file where you find all of the exeprimental parameters that are read or set.
-
C:\GUI\gui_conf\gapdata\ is the folder containing the calibration of the undulator gap as a function of the monochromator energy.
-
C:\\gui_conf\umeasure_bcs.txt is the file containing the internet address, port number of the BCS server. The timeout of the communications with the BCS is set here.
-
C:\GUI\sources\umeasure_folders.txt is the file defining the working directories of the GUI:
-
expRootFolder: where the data are saved, usually "C:\data".
-
backupRootFolder: where the data is backed up.
-
scansDir: where you can find script files.
-
configFolder: where you can find all configuration files.
-
iconsFolder: icons used by Umeasure.
-
jythonFolder: where to find the Jython libraries, called by the class RunPhyton.
A copy of the configuration files can be found here.
Back to Nanospectroscopy manuals.
|