Input
- 1. Overview
- 2. Configuration File
- 3. Calibration Files
- 4. Parameter File
- 5. Command File
- 6. Shell Script
- 7. Images
- 8. Carousel File
- 9. License File
- 10. XPS Data and Definitions
1. Overview
Program mar345dtb/mardtb uses the following input files. Some of them are mandatory, others optional.
Table 1: mar345dtb input files.
File type | File name | Mandatory | Description |
---|---|---|---|
Configuration | $MARTABLEDIR/mar(345)dtb.cfg or $MARTABLEDIR/config.### | yes | Configuration parameters for dtb and detector |
Calibration | $MARTABLEDIR/mar2300.### $MARTABLEDIR/mar3450.### | yes for mar345 detector | Calibration files for mar345-detector |
License | $MARTABLEDIR/mardtb.license | yes for DECTRIS detectors | Encrypted license for mardtb with EIGER or PILATUS |
Parameter | $MARLOGDIR/mar(345)dtb.dat | no | Saved parameters from "Edit" |
Shell script | $MARLOGDIR/dtb.csh | no | Shell script template for executing external commands |
Command | $MARLOGDIR/dtb.com | no | Parameter file for triggering an action of the dtb or the scanner |
Images | ... | no | Image files in several formats |
Carousel data | $MARLOGDIR/csc/CSC.csv | no | Saved parameters from "CSC" |
XDS data | $MARLOGDIR/xps/XPS.dat | no | Saved parameters from "XPS" |
### denotes a 3-digit serial number and usually is defined as $MAR_SCANNER_NO
(or $MAR_DTB_NO if program mar345dtb is used without mar345 support). As of
version 9, program mar345dtb tries to read file mar345dtb.cfg as configuration
file, in the first place. To be compatible with older versions, if that
file is not present, the program falls back to config.###.
The idea is to only use INCLUDE lines to file mar345dtb.cfg and thus
separate parameters that are specific to the desktop beamline from
those that are specific to the detector.
2. Configuration File
While all parameters used within program mar345dtb are set to reasonable defaults, there are quite a number of parameters that are specific for either a particular model of the desktop beamline or the mar345 image plate detector or the DECTRIS detectors. Therefore, the program must read in a configuration file for proper function. The configuration file is called config.$MAR_SCANNER_NO and resides in directory $MARTABLEDIR. If the configuration file doesn't exist, the program can't be started. The file is a keyworded ASCII-file which may be edited. Keep in mind that many of the parameters can be absolutely critical for hardware functions, so for editing you really have to know what you are doing!
Please note, that program mar345dtb is for support of the mar345 image plate detector, but for DECTRIS detectors the program is called mardtb and the corresponding configuration file is called mardtb.cfg.
2.1 Keywords
The configuration file is a keyworded ASCII-file in free format. Lines starting with # or ! are treated as comment lines. Almost all keywords and subkeywords can be truncated to 4 characters. A number of keywords are of general program use, other affect the dtb only and others the mar345-detector only:
2.1.1 General
The following keywords are of general importance to run the program:
- USE | IGNORE [options]
There are a number of options that can be turned on (USE) or off (IGNORE):
- DTB | BASE
Try to establish a connection to the dtb at program startup. - MAR345 | SCANNER
Try to establish a connection to the mar345-detector at program startup. - MAR345S
Use fast mar345s scan modes 5 to 8 (1150, 1000, 800 or 600). - DECTRIS
Use DECTRIS PILATUS detectors 200k/300k/1M. - EIGER
Use DECTRIS EIGER detectors 1M/4M. - AMPTEK
AMPTEK is a device that can optionally be fitted to the dtb and is used on synchrotron beam lines to choose a proper wavelength for MAD-data collection. This device produces additional restraints of movements for DISTANCE, THETA and CHI (collision protection). If this device is physically present, it it therefore ESSENTIAL to add the line USE AMPTEK to the configuration file. - CRYO
A cryogenic cooling device can optionally be fitted to the dtb and is used on most protein setups. This device produces additional restraints of movements for DISTANCE, THETA and CHI (collision protection). If this device is physically present, it it therefore ESSENTIAL to add the line USE CRYO to the configuration file. The collision parameters depend to a certain extent on the dimension of the cryo-cooler in use. Those can be modified by keyword CRYOPARAM (see below). - SPY_MAR
Log native mar345-controller messages into file $MARLOGDIR/spy/mar.spy.#. This is very important for backtracing hardware problems of the detector. - SPY_DTB
Log native dtb-controller messages into file $MARLOGDIR/spy/dtb.spy.#. This is very important for backtracing hardware problems of the dtb. - SPY
Equivalent to SPY_MAR + SPY_DTB. - STATS
For each image plate readout ome statistical values of the resulting image (average, sigma of total and of a box of 100x100 pixels in the 10:30 position of the detector) are calculated and the results are logged into the separate output file $MARLOGDIR/lp/mar.lp.# - SUMMARY
Create a summary file in ASCII format for each collected data set. This file contains all relevant parameters used for collecting this data set: motor positions, exposure times, etc.. Useful for archiving. The file will be created in the current data directory and will be named rootname.#.SUMMARY, where # is a number starting at 1. This number will be incremented automatically if a file of the same name already exists in the data directory. - HTML
Same as SUMMARY, but file is in HTML format. File name is rootname.#.html - AUTOMAR
Create a file called rootname.sync that can be used by program marProcess out of the automar suite to process data as they are coming in. Option added in version 5.5.0. - DISK
Issue a warning message when trying to write data into a disk that is almost full. - NFS
Issue a warning message when trying to write data out to an NFS mounted disk. Many users may not be aware of potential problems of using NFS mounted disks as data directory. Any problem on the network is going to make the data collection stop, so using NFS directories is definitely not recommended. - CENTER
Some mar345 image plate detectors suffer from a relatively strong artificial increase of intensities in the inner 5 mm of the IP. This is due to some electronical artifacts in the used controllers. Usually, this is considered as a non-critical problem since this area is mostly covered by the beamstop. However, it is possible to correct for those artifacts by applying a center offset correction. These are additional calibration files that optionally reside in directory $MARTABLEDIR and are called center2300.$MAR_SCANNER_NO and center3450.$MAR_SCANNER_NO. The corrections will be applied with each scanned image, but only if keyword USE CENTER is provided. - ERASE
Watch erase lamp status and stop data collection if erase lamps fail - XRAY
Watch X-ray intensities as read by the ionization chambers and stop data collection if X-ray intensities drop significantly - HARDWARE
Make the "HARDWARE"-page available as a tab. - XTAL
Make the "Crystal"-page available - VIDEO
Use the frame grabber output within the "Crystal"-page - LIGHT or ILLUMINATION
Make the Illumination buttons available in the "Crystal"-page. - CSC
Make the "CSC"-page (sample changer) available - SHUTTER
Provides a "Open/Close Shutter" button in the "Crystal"-page. - TTL
Uses the TTL output of the mar345 scanner (at the X25 connector). This signal can be used to operate a generator shutter if wired accordingly. On the "Misc." page of the GUI, you get a button to open and close the generator shutter. You also get a choice of automatically closing the generator shutter at the end of a data collection. See chapter "Shutter" in GUI ⇒ User Interface ⇒ Main Window ⇒ Pages ⇒ Misc. ⇒ Shutter for more details.Default: USE MAR DTB CRYO SPY ERASE XRAY XTAL VIDEO NFS DISK
Default: IGNORE AMPTEK ADC STATS CSC HARDWARE LIGHT TTL
- DTB | BASE
- DTB | MAR345 [PORT <number>] [HOST <IP-address>] [TIMEOUT <sec>]
Defines the IP-address to which to talk to either dtb and mar345 and the socket ports. The timeout is a time given in seconds after which the program automatically closes and reopens the TCP/IP-sockets to the hardware.
When using the mar555 detector, only USE | IGNORE should be given. All other arguments are meaningless.
Default: DTB PORT 4451 HOST 192.0.2.3 TIMEOUT 30
Default: MAR PORT 4441 HOST 192.0.2.1 TIMEOUT 30
- DECTRIS 200K|300K|1M|EIGER1M|EIGER4M [PORT <number>] [HOST <IP-address>] [TIMEOUT <sec>] [ZEROMQ <port>] USE|IGNORE
Adds support for Pilatus 200K/300/1M detectors as well as EIGER1M and EIGER4M detectors. For Eiger detectors, the PORT number given refers to the RESTful command interface while the ZEROMQ port is the data stream interface. For Pilatus detectors, only the PORT number is required.
Examples: DECTRIS 1M PORT 41234 HOST 10.0.0.1
Examples: DECTRIS EIGER4M PORT 4010 HOST 10.0.0.1 ZEROMQ 9999
- MARMUX [IUS|USB] [PORT <number>] [HOST <IP-address>] [INTErval <sec>] [LICENSE <key>] [WARMup <hrs>] [CONDition <days>] USE|IGNore
Defines the IP-address to which to talk to the marμX generator (typically 192.0.2.100) and the TCP/IP-port (502). The interval is a time given in milliseconds to update information.
The LICENSE key is a computer specific ASCII-string that you may obtain from marXperts GmbH. For this purpose you need to run program 'marlicense' (typically contained in the automar program suite) on the mar345dtb PC and mail its output to marXperts. Without a valid license key, the program will automatically set "MARMUX IGNORE". With a valid license, the page "marμX" is added to the user interface and the generator can be operated from with the mar345dtb program. This license key is NOT required for the Incoatec IuS source but only for the Xenocs source.
For the Incoated IuS source, the program mar345dtb keeps track when the generator has been completely turned off. It gives suggestion when to run a warm-up procedure (> 8 hrs) or a conditioning procedure (> 56 days).
Default: MARMUX PORT 502 HOST 192.0.2.3 INTERVAL 1000 LICENSE none IGNORE WARMUP 8 CONDITION 56
- MARMUX [IUS|USB] [PORT <number>] [HOST <IP-address>] [INTErval <sec>] [LICENSE <key>] [WARMup <hrs>] [CONDition <days>] USE|IGNore
- INCLUDE <filename>
Include an entire configuration file to be read by the program. Instead of using a monolithic configuration file, you may split up the configuration parameters into a file containing keywords only for the mardtb and another file with keywords only for the mar345 scanner.
Default: none - METALJET [PORT <number>] [HOST <IP-address>] [INTErval <sec>] [SHUTTER <number>] [LEFT|RIGHT] [USER <name>] [PASS <password>] USE|IGNore
Defines the IP-address to which to talk to the metaljet generator safety control box (typically 192.0.2.112) and its TCP/IP-port (45678). The interval is a time given in milliseconds to update information.
You will have to specify which shutter to use: the one on the right hand side (RIGHT or SHUTTER 1) or the one on the left hand side (LEFT or SHUTTER 2).
You will also have to specify a user name (default: mar) and a password (default: metaljet) in order to connect to the metaljet safety control box.
Default: METALJET IGNORE PORT 45678 HOST metaljet SHUTTER 1 USER mar PASS metaljet INTERVAL 1000 - EDITOR <command>
Command to use when opening an editor, e.g. for changing the configuration file.
Default: xedit - DIRECTORY <name> [DATE] [TIME]
Default directory to write data images if textfield for directory in the GUI is empty or if it says "auto". If option DATE is given, the data directory will be a subdirectory of name with name YYMMDD (eg 190622) that is being created if it does not exist. With option TIME the subdirectory will be called HHMM (e.g. 1409), with options DATE and TIME, the name is YYMMDD_HHMM.
Default: current working directory - BROWSER <command>
Command to run html browser for displaying documentation.
Default: firefox - IMAGEVIEWER <command>
Command to use to view graphics image formats (jpg).
Default: display (from ImageMagick suite) - LOOPFIND <command>
Command to use for analyzing a photo for the purpose of automatic centering.
Default: loopfind - MONTAGE <command>
Command to use for assembling several photos taken during crystal centering into a combined graphics file. This command is called from the user interface after the last centering step and the resulting file is automatically shown on the DISPLAY tab.
Default: montagedtb.csh - STREAMER <command>
Command to use to dump video still photos in jpg. The default is to call shell script marstreamer which again calls a special version of program streamer out of xawtv-package.
Default: marstreamer - V4L <command>
Command arguments to use for program v4lctl from the V4L (video for linux) interface. If arguments are present, they will be appended to string "v4lctl" and the entire command will be executed before opening the frame grabber device. Please note, that v4lctl will only accept one command per call. If you want to set several parameters via v4lctl, you need to provide several lines starting with keyword V4L.
Default: no arguments - VIDEO (USE|INTERNAL|V4L2)|LIBXV|EXTERNAL|SHMEM|IGNORE [FORMAT] [WIDTH <w>] [HEIGHT <h>] [ORIGIN <x> <y>]
[CLASS <name>]
[SCALE <x> <y> <z>] [TICK <x> <y>] [FPS <rate>] [AVERAGE <n>]
[BRIGHTNESS <value>]
[HUE <value>]
[CONTRAST <value>]
[SATURATION <value>]
[RED <value>]
[GREEN <value>]
[BLUE <value>]
[DEVICE <name>]
[NO]OVERLAY
[NO]CURSOR
[GREY|RGB|YUV420|YUYV|UYVY|422P|MJPEG|AUTO]
[INPUT <name>]
[NORM <name>]
[IDLE <value>]
Settings relevant for the frame grabber output on the "Crystal"-page:
- (USE | INTERNAL | V4L2 ) | LIBXV | EXTERNAL | SHMEM | IGNORE
Enable or disable frame grabber handling. With version 8.1, you have a choice of using the built-in video display model or an external program. With version 10.0 the built-in video defaults to the V4L2 interface, while older version made use of the libXvideo interface. While the latter one put the load of displaying the frame grabber data, its functionality depended heavily on the video card driver. For video chips produced by Nvidia or ATI/AMD or Intel in 2014 there are no driver any more supporting this feature. The V4L2 interface, instead, grabs the data from the frame grabber and individually puts them on the screen. This adds some load to the CPU, but is a more reliable approach. The new V4L2 interface should work an older hardware as well as on new hardware. Another benefit of using the new V4L2 interface is that shooting photos now is dealt with much less overhead. Essentially, using 2 TV-cards, one being dedicated for shooting photos now should be obsolete.
Option SHMEM has been added in program version 10.3. In this mode, the program mar345dtb does not grab the frames directly from the video device but rather uses program margrabber to talk to the device. The actual video frames are made available to program mar345dtb via a shared memory segment. There seems to be no obvious benefit from using this approach over the V4L2 option, but it seems as if using the V4L2 option on certain combinations of hardware can produce random problems in the synchronization of the mardtb operations with the mar345dtb program. In those rare cases, using SHMEM can be a useful option.
In any case, in order to display the video stream, the X configuration file (e.g. /etc/X11/xorg.conf) needs to load module "v4l" in the Section "Module".
Before adding V4L2, the only choice to display the TV-stream if the internal interface did not work to use the EXTERNAL mode. While this now should be regarded as obsolete, it is still functional in version 10.x. To use it, you may use either program tvtime or its slightly modified clone "martv" (version ≥ 4). This is a separate program and may be run stand-alone, but when used within program "mar345dtb", it is "hijacked" by the interface, i.e. the mar345dtb program removes all window decorations from the application and pretends that martv/tvtime is an integral part of the mar345dtb program. When using external mode, you must have a "martv.csh" shell script in the binary search path. When using other programs than martv/tvtime you will also have to supply a window class name string with the VIDEO CLASS keyword (see below). The default is to use the INTERNAL built-in video support. Note that VIDEO USE is the same as VIDEO INTERNAL and in program version 10.x the same as VIDEO V4L2. Please also note, that to exchange information between program martv and program mar345dtb, program mar345dtb must be run either as TCP/IP-server or in COMMAND mode. See keyword "COMMAND" and section Command File" for more details. Exchange of information is required for (semi-)automatic centering. When using VIDEO EXTERNAL, the video settings light BRIGHTNESS and CONTRAST will become meaningless, since they will be controlled by the external application. - CLASS <name>
When using the VIDEO EXTERNAL video mode you can specify the window class name in order for program mar345dtb to learn which external application is going to display the TV stream. The default is: "TVWindow.tvtime" which is the class name of program martv and tvtime. - OVERLAY | NOOVERLAY
Tells the program that video overlay does or doesn't work on this system. This depends on the video card (driver). If overlay doesn't work, than you won't see the digital crosshair. You can get around that problem by providing NOOVERLAY. For the new V4L2 interface, OVERLAY is the recommended option. - CURSOR | NOCURSOR
Tells the program to use a special cursor on the video output field. On some Linux distributions there might be problems when switching cursors. In those cases, option VIDEO NOCURSOR should be used. Applies only to the VIDEO LIBXV interface. - FORMAT
Default format for output still images. One of JPG, PNG, PPM or PGM. - WIDTH <w>
Width of video frame, typically 768 or 720 pixels. - HEIGHT <h>
Height of video frame, typically 576 pixels. - ORIGIN <x> <y>
Beam center with respect to video image. Coordinates xy have their origin in upper left corner. This needs to be given when using the automatic centering routines with the sample changer or self-centering PHI-axis. - SCALE <x> <y> <z>
Conversion factor for converting x,y and z-pixel coordinates into mm. These values must have been calibrated once for a specific system. - TICK <x> <y>
When painting the digital cross-hair also some tick marks are painted, typically all 100 microns. - FPS <rate>
Frame rate per second. When using the VIDEO V4L2 interface, you may reduce the CPU load by lowering the frame rate from 25 to 20 or 15. - AVERAGE <n>
Form average out of <n> single images before saving them into a file. This is to smooth out some noise and may play an important role in the automatic crystal finding algorithm. - BRIGHTNESS <value>
At initialization of the video output, set brightness to <value> - HUE <value>
At initialization of the video output, set hue to <value> - CONTRAST <value>
At initialization of the video output, set contrast to <value> - SATURATION <value>
At initialization of the video output, set saturation to <value> - RED <value>
At initialization of the video output, set red to <value> - GREEN <value>
At initialization of the video output, set green to <value> - BLUE <value>
At initialization of the video output, set blue to <value> - DEVICE <name>
Name of frame grabber device. It is possible to use 2 frame grabber devices. In particular, for operation with the sample changer, it is advisable. For the VIDEO V4L2 interface it is not required. - INPUT <name>
Frame grabber devices usually come with several interfaces for generating frames. TV-card typically have a an input called "Television" which is the stream from the TV-tuner. They also come with one more input for connecting external video devices. Those input are called Composite0,1,2,3 and S-Video. The dtb camera usually plugs in into one of the Composite inputs, most typically Composite1 which is the default. If the particular input of the device comes with a blank space in the name, the blank must be replaced with a # or _ character, like "Camera#1" instead of "Camera 1". Used only with VIDEO V4L2. - NORM <name>
Frame grabber devices may generate data using different TV-norms. The most typical in Europe is PAL (768x576 pixels, interlaced) and in the U.S. it is NTSC. For both PAL and NTSC there are some choices (PAL-BG, PAL-DK, PAL-Nc, NTSC-M, etc.). If the image looks strange, try out those choices. - IDLE[time] <value>
Since the V4L2 interface keeps the CPU somewhat busy, while collecting data or doing nothing at the PC it is better to leave the "Crystal" page. This is done automatically after some idle period given in seconds. If the value is 0, the feature will be ignored. - GREY|RGB|YUV420|YUYV|UYVY|422P|MJPEG|AUTO
Frame grabbers may produce full coloured RGB images with 24 or 32-bits/pixel or somewhat smaller 16-bit color information (YUV420,YUYV,UYVY,YV422P,MJPEG) or 8-bit grey-scale images. Since the mardtb camera is black/white only, it does not make too much sense to read full RGB data. This adds unnecessary traffic to the PCI-bus. Therefore, the default is to use GREY as colorspace. This option applies to the VIDEO V4L2 interface only. In version 10.4, the default is 'AUTO' which is going to try first GREY, then MJPEG, YUYV, UYVY, YUV420 and RGB.
Default: VIDEO V4L2 PNG WIDTH 768 HEIGHT 578 FPS 25 AVE 5 TICK 100 100 SCALE 450 450 DEVICE /dev/video0 INPUT Composite1 NORM PAL IDLE 300 AUTO - (USE | INTERNAL | V4L2 ) | LIBXV | EXTERNAL | SHMEM | IGNORE
- THUMBNAIL <command>
Command to use to convert mar data images into graphical thumbnail images.
Default: mar2thumb (shell script) - SOUND <command>
Play sound files when issuing warning, errors, etc. The soundfiles must reside in directory $MARDOCDIR and must be called mar_errorX.wav (X=1,2,3) and mar_warning.wav. The command to use to actually play those sound file must be provided here. If it is left empty, this feature will be ignored.
Default: none - SHOW [NO]RESOLUTION [NO]TOWTHETA
When displaying images, normally only the resolution is shown in Angstroem. In addition (or alternatively) the corresponding 2-theta values may be printed
Default: SHOW RESOLUTION - COLORS <number>
Number of grey shades for image display.
Default: COLORS 64 - RETRIES <number>
Number of retries for recovering a hardware problem.
Default: RETRIES 5 - STARTUP USE | SKIP [TIME] [SHUTTER] [HV] [LOCK] [VERSION] [ADC] [REMOTE] [CRYO|ROOM] [CYCLE]
Hardware commands to be optionally executed at program startup. To turn off, use SKIP, otherwise USE.
- TIME
Synchronize controller time with computer time. This is generally useful. - SHUTTER
Close shutter (for safety reasons). It doesn't hurt! - HV
Turn on high voltage of ion. chambers. The HV is usually turned on, already, but better be sure... - LOCK
Lock image plate. If the plate is locked already, the better! - VERSION
Obtain firmware versions of controllers. This is good to know in certain occasions, but not really essential. - ADC
Adjust ADC using the values given on ADC keyword. This procedure is a bit critical, since you would have to sure that there are no X-rays entering the collimator and you can't be sure about that if the program is not up yet. Therefore it is recommended to skip this step. - REMOTE
Finds out wether the remote control unit is enabled or disabled. Useful, but not essential. - CRYO | ROOM
Assumes that the sample changer operates under cryogenic or under room temperature conditions. This has an impact on some motor movements. With a sample changer attached, the corresponding bit is usually set to CRYO mode and there should not be a necessity to explicitely set or override this bit. - CYCLE
Send the controller a command to automatically send status information every 1000 ms. This is useful in situations where a marCCD software is used simultaneously. Program marCCD disables automatic status sending. This option should not be necessary for normal usage and is not the default.
Default: STARTUP USE TIME SHUTTER HV LOCK VERSION SKIP ADC REMOTE CRYO RROOM - TIME
- SETS <number>
Number of data sets to be programmed. Either 15 or 30
Default: SETS 30 - STATUS [DTB <interval>] [MAR345 <interval>]
<interval> defines the period of time in milliseconds after which a status file dtb.status or mar.status will be periodically written to directory $MARLOGDIR. This ASCII files contains some information about what the scanner and dtb is currently doing. The purpose for this is to give any other program a chance to exchange information with the mar hardware. A value of "0" means that no status file will be written.
Default: STATUS DTB 0 MAR345 0 - COMMAND [<interval>] [PORT <port>] [WRITE <interval>] [REST <port> TOKEN <len;>]
<interval> defines the period of time in milliseconds after which an ASCII-formatted command file $MARLOGDIR/dtb.com will be periodically checked and parsed. This file may contain commands for either the dtb or the mar345 and is the interface for external programs to interact with the mar hardware. A value of "0" means that no dtb.com file will be checked. If the keyword PORT is supplied commands are read using exactly the same syntax from a TCP/IP-socket on port <port>. In this configuration you may choose to only read from that socket or to write something back. In order to cooperate with the video frame grabber program margrabber, e.g. for point-and-click-centering of a crystal from within program margrabber, it is mandatory to use ports in the range from 9000 to 9010.
If keyword WRITE <interval> is supplied with a positive number, then a status block is sent every <interval> ms to the socket. The format of the status block is described in chapter "Status File" in section Output). If a negative value is given for <interval>, then the same information that goes into both the scanner and dtb spy files is written to the socket. If the value is 0, then no strings will be written.
Please note, that it is the client program's responsibility to read back information from the socket. If the program mar345dtb sends data to the socket, but the client doesn't read it, the program is going to freeze within short time.
If keyword REST <port> is supplied with a positive number, then the program starts to listen for commands send via HTTP requests in a REST-like API. HTTP requests require authentication and on successful authentication, a so called web token is returned with a default length of 16 characters. When providing TOKEN <len> this value may be modified. Sending commands via the REST interface is described in section "REST API"
Default: COMMAND 0 PORT 0 WRITE 0 REST 0 TOKEN 16 - UNITS [STEPS <number>] [SPEED <number>] [ACCEL <number>] [TIME <number>] [MAXTIME <number>] [MULTiple <number>
With this keyword an additional conversion factor can be applied to convert step units into mm. The hardware doesn't know anything about mm or degrees and deals only with steps and microsteps. The values here are supposed to be constant and are rather of historical importance. Do NOT modify them!
The MAXTIME value only applies to the mar555dtb program version. The issue is that the mar555 detector can be used with relatively short exposure times only. The maximum is 60 sec (60000 msec), but usage of 30 sec or less is strongly recommended. If a positive value in sec is given for MAXTIME, the program will automatically split an exposure longer than MAXTIME seconds into shorter ones by dividing the exposure time by 2 until the resulting exposure time is < MULTIPLE seconds. If only MAXTIME is > 0, and MULTI has not been specified, MULTIPLE is set to MAXTIME. At the same time, the PHI movement for the exposure is divided by 2. On output, the images will automatically be added and averaged to give a single image over with the total exposure time and total PHI range as specified in the GUI. By default, this feature is turned off.
Default: UNITS STEPS 1 SPEED 1 ACCEL 1 TIME 2.5 MAXTIME 0 MULTI 0 - WAVELENGTH DEFAULT <lambda> USE|IGNORE INTERN|EXTERN
Wavelength of X-rays. This number will be written into the corresponding section of the resulting images.
Default: WAVELENGTH DEFAULT 1.54178 USE INTERN - WINDOWS [MAIN <x y>] [VIEW <x y [width height]>]
[x,y]-coordinates for main window and display window at program startup. The main window has a fixed size. For the display window also the width and the height can be configured. This allows the program to be fit to any screen resolution (>=1280x1024 pixels) and window manager.
Default: Depends on screen resolution and operating system - VERSION [LOG <N>] [SPY <N>] [STATS <N>] [SCAN <N>] [TIME <N>] [PROFILE <N>] [XTAL <N>] [FIRMWARE <Version>]
The program creates a new version of several log files to be stored in directory $MARLOGDIR and subdirectories log, spy, lp, beam and xtal. Here you specify how many versions you want to keep. Note, that spy files can take quite some disk space, but for keeping track of hardware problems you will want to keep a reasonable number of copies. After reaching version N, the first file (with N=1) will be overwritten.
XTAL only becomes relevant for automatic centering with the sample changer. N sets the number of sample photos that are kept. This might be useful only to find out which samples failed to be centered correctly.
With advent of the sample changer (CSC) major work had to be done to the dtb firmware. Usually the program determines automatically which dtb firmware version is in use but only if keyword STARTUP VERSION is given.
Default: VERSION LOG 99 etc. (all N=99)
2.1.2 Keywords for dtb
The following keywords affect the dtb only:
- ADC CHAMBER 1 | 2 [OFFSET <off>] [TOLERANCE <d>] [HIGH|LOW] VARIANCE LOW <dlow> HIGH <dhigh>
Default values for ADC offset adjustment for ionization chambers 1 and 2. <off> is the target offset without X-rays and <d> the tolerance for reaching the target, typically within 10 % of the offset. For each ionization chamber a gain selector can be set to HIGH for weak X-ray sources (rotating anode, sealed tube) or to LOW for synchrotrons. A suitable target offset for HIGH gain is 1000 +/- 20 and for LOW GAIN is 20 +/- 2. Note, that HIGH gain is roughly 300 times as sensitive as LOW gain. The VARIANCE for LOW gain (<dlow>) and HIGH gain (<dhigh>) should reflect the typical fluctuations of the ADC readings (without beam) and are typically +/- 2 for LOW gain and +/- 20 for HIGH gain. These values will play a role in the "Find beam" and "Optimize beam" procedures. They will decide define suitable thresholds for the start and end of a peak. The program usually expects a peak to be at least above the ADC <off> + 3*<dhigh> (or 3*<dlow>)
Default: ADC CHAMBER 1 OFFSET 1000 TOLERANCE 20 HIGH VARIANCE LOW 2 HIGH 20
Default: ADC CHAMBER 2 OFFSET 1000 TOLERANCE 20 HIGH VARIANCE LOW 2 HIGH 20
- INTENSITY [MIN <min>] [WARN <warn>] [DOSEMIN <dose>]
<min> gives the minimum acceptable X-ray reading of chamber 2 during one exposure. If reading is lower than this, data collection stops since it will be assumed that the X-rays went away. To turn this off, enter a negative value. Otherwise, provide a value that is at least twice as large as the intensity reading of the 2. chamber without beam. This reading - of course - depends on the selected gain and the chosen ADC offset. Typically for rotating anode generators running with an ADC offset of 1000, a MIN value of 2000 should be suitable. For operation at a synchrotron with low gain settings and an ADC offset of 20, a MIN value of 30 is suggested.
<warn> gives the allowed variation of X-ray intensity inbetween the start and the end of one exposure in percent. If the variation is larger than this, a warning message is issued and the data collection stops. This is to avoid unnecessary scans if the X-ray generator fails. To turn this off, enter a very large value for <warn>.
<dose> is the minimum intensity required to actually start an exposure when working in DOSE mode. If the intensity is less than <dose>, the exposure will not even be started but waits until the X-ray intensity as measured by the ionization chamber exceeds <dose>.
Default: INTENSITY MIN 2.0 WARNING 50.0 DOSEMIN 0.1 - SHUTTER <delay>
Here we enter the delay in mseconds the shutter takes to actually be closed and makes exposure times more accurate. This value has been calibrated in the factory and is specific for a dtb but usually in the range 20 to 40 msec.
Default: SHUTTER 0 - FIND CHAMBER 1 | 2 [X <start end> Y <start end> % | MM ] [SLIT <hor ver>]
Default parameters for the "Find Beam"-procedure of the automatic alignment. The start and end values for X and Y are given either as percentages (subkey "%") of the available driving range (e.g 25 to 75) or in absolute millimeters (subkey "MM") which would be rather inconvenient. The 2 values following the SLIT subkey define the aperture of the horizontal and vertical slits for this procedure.
The method used for doing the beamsearch can be influenced by subkeywords FAST or SLOW on the OPTIMIZE keyword (see below)!
Default: FIND CHAMBER 1 X 25 75 Y 25 75 % SLIT 4.0 4.0
Default: FIND CHAMBER 2 X 15 85 Y 15 85 % SLIT 4.0 4.0 - OPTIMIZE CHAMBER 1 | 2 [SPEED <hor ver>] [SLIT <hor ver>] [FIRST <hor ver>] [RANGE <hor ver>] [THRESHOLD <pct>] [SMOOTH <avg>] [FAST | SLOW] [FWHM | MAX]
Default parameters for the "Optimize Beam"-procedure of the automatic alignment. The speed values for horizontal and vertical movement are specified separately and are a percentage of the maximum speed.
The 2 values following the SLIT subkey define the aperture of the horizontal and vertical slits for this procedure.
The 2 values following the FIRST subkey define the aperture of the horizontal and vertical slits of chamber 1 used for optimizing chamber 2. The slit apertures to be used depend on the nature of the beam. The defaults are appropriate for Osmic mirrors but should be decreased for a synchrotron beam.
The 2 values for the RANGE subkey define the default range for horizontal and vertical translation or rotation motors used during the optimization. The values to be entered are supposed to be multiples of the used slit size, typically 3 for a beam produces by a standard generator with standard optics. The range should be increased for very fine beams on synchtrotrons when using slit sizes of 0.1 to 0.2 mm.
For values > 1 for the SMOOTH parameter (since version 9) the program computes a running average out of the intensity curve. This is going to remove small spikes and may make the optimization procedure more robust. Very weak peaks are likely to further be reduced by smoothing. Reasonable values for SMOOTH are 3, 5, 7 or 9.
The FAST or SLOW subkeys define the optimization method. In FAST mode (available since version 2.2), vertical movements are interrupted as soon as the instrument moves out of the beam. The decision when beam is going to be lost is marked by subkey THRESHOLD. If the intensity drops below <pct> percent of the seen maximum, the movement is stopped. This speeds up the optimization and also the beamsearch procedure by a factor of 1.5 to 2.
The FWHM or MAX subkeys (since version 9) define wether the motor drives to the absolute max. of the intensity readings (MAX) or to full width half maximum (FWHM) after a scan. For assymetric beam profiles, you can expect a difference of some fractions of millimeters, while for a Gaussian peak the results should be the same. It probably doesn't matter which method you choose, but you should stick to the choice!
Default: OPTI CHAMBER 1 SPEED 10 100 SLIT 0.6 0.6 RANGE 3.0 2.0
Default: OPTI CHAMBER 2 SPEED 20 30 SLIT 0.3 0.3 FIRST 0.3 0.3 RANGE 3.0 3.0
Default: OPTI SHORT THRESHOLD 75 SMOOTH 5 FWHM - MOTOR [options]
MOTOR stands for a particular motor and is any of:
- SLIT FIRST HOR
- SLIT FIRST VER
- SLIT SECOND HOR
- SLIT SECOND VER
- BEAMSTOP
- PHI
- THETA
- DISTANCE
- TRANSlation HOR
- TRANSlation VER
- ROTation HOR
- ROTation VER
- CRYSTAL Z or CRYSTAL
- CHI
- SERVER (sample changer/easymount only)
- ROTOR (sample changer/easymount only)
- LIFTER (sample changer only)
- PICKER (sample changer only)
- CAROUSEL (sample changer only)
- CRYSTAL X (automatic PHI-axis only)
- CRYSTAL Y (automatic PHI-axis only)
- WAVELENGTH
- XPS_X (crystal plate scanner only)
- XPS_Y (crystal plate scanner only)
The following subkeywords define the specifications of the corresponding motor:
- ID <number>: CAN-bus identifier of motor
- SPEED <steps/sec>: Max. speed in steps/sec
- SLOW <steps/sec>: Speed in steps/sec used for slow movements
- FAST <steps/sec>: Speed in steps/sec used for fast movements
- STEPS <steps/mm>: Translation of motor steps into mm or deg.
- BACKLASH <mm or deg>: Backlash correction in mm or deg. used for accurate motor movements (PHI).
- DEFAULT <mm or deg>: Default position in mm or deg.
- ACCEL <steps/sec2>: Acceleration in steps/(sec2)
- TIMEOUT <sec>: Time in sec in which a movement has to be finished before treating it as error
- OFFSET <mm or deg.>:
A motor offset is only used in very special situations.
For CRYSTAL X and Y it defines the deviation of the theoretical
PHI position in degrees
where the camera view is exactly perpendicular to the axis.
For CRYSTAL Y, the theoretical PHI position should be
0 or 180 deg.
and for CRYSTAL X it should be 90 or 270 deg. In real life
there might be an offset of +/- a couple of degrees.
For ROT_VER, the OFFSET has a different meaning. If the collimator is not perfectly aligned with the camera and the PHI axis, it is possible to compensate for small misalignments by driving the VERTICAL ROTATION motor by a fraction of a mm beyond the found maximum during optimization. This is something that must be obtained experimentally. - MINVAL <mm or deg>: Minimum value in mm or deg. that can be entered within program. Used to restrict movement beyond a certain limit.
- MAXVAL <mm or deg>: Maximum value in mm or deg. that can be entered within program. Used to restrict movement beyond a certain limit.
- REFERENCE METHOD <number>: Method for referencing this motor (PHI and BEAMSTOP only)
- REFERENCE MIN <mm or deg>: Reference position in mm or deg. at NEAR end of movement
- REFERENCE MAX <mm or deg>: Reference position in mm or deg. at FAR end of movement
- REFERENCE SPEED <steps/sec>: Speed in steps/sec used during referencing
- REFERENCE ACCEL <steps/sec2>: Acceleration in steps/sec2 used during referencing
For each motor there are additional keywords to define certain properties:
- USE | IGNORE: Use or ignore this motor
- INTERN | EXTERN: Motor is [NOT] built-in in dtb
- ABSOLUTE | RELATIVE : Motor commands are issued as movements to an absolute position or relative to current position
- HAS[NO]MIN;: Motor has [does not have] a NEAR end reference switch
- HAS[NO]MAX;: Motor has [does not have] a FAR end reference switch
- HAS[NO]REF;: Motor has [does not have] a single reference position
- [NO]INITMIN : Motor is [NOT] allowed to reference at NEAR end reference switch
- [NO]INITMAX : Motor is [NOT] allowed to reference at FAR end reference switch
- [NO]INITAUTO: Motor is [NOT] allowed to initialize automatically when reaching a reference switch
- [NO]MOD360: Motor positions are [NOT] kept in range 0 to 360 (PHI only)
- [NO]CONFIRM: Motor movements must [NOT] be confirmed before driving
- REMOTE USE | IGNORE [CHECK] [MASK >mask<] [component options]
Use or ignore remote control. Optional keyword CHECK means that the "Remote Control"-window cannot be closed until the remote control is explicitely disabled from the software. This option prevents users from accidentally operating the remote control manually while motors are operated from the software.
Optional keyword MASK specifies which buttons of the remote control unit can be activated at all. This differs from standard dtb's to the ones that come with sample changer. The sample changer requires an extended remote control unit with buttons to move the carousel etc. The mask to use is a bit mask and is either: 131071 for a plain dtb, 16777215 for a dtbcsc with cryo actuator and 16777214 for a dtbcsc without cryo actuator.
The following components are availabe:
- ADC
- THETA
- DISTANCE
- CHI
- CRYO | BEAMSTOP | PHI
Note that as by early 2002 the CRYO button is not being used and may be reassign to drive either the BEAMSTOP or the PHI-motor. It can be handy to drive the beamstop out of the way when mounting the crystal. The beamstop may be moved manually but if this has been done the motor needs to reinitialized afterwards. Alternatively, it can be useful to drive PHI to 0.0 with the remote control before mounting a new crystal. The user can make her/his own choice but the instructions in Appendix: "How to Assign Motors to the Buttons of the Local Motor Control" . must be followed before the keyword given here is going to take effect.
For each components, the following otions are available:
- ENABLE | DISABLE
Enable or disable this component - EDIT | NOEDIT
(Dis-)allow editing of parameters in the "Remote Control"-window - POS1 <value>
Target value for position 1 (meaningless for ADC). Special keyword POS1 DYNAMIC means that position 1 will be updated automatically as the corresponding motor moves. - POS2 <value>
Target value for position 2 (meaningless for ADC)
Default: REMOTE IGNORE [component DISABLE NOEDIT]
- CRYOPARAM [CRYOSTREAM | XTREME] [DISTANCE <d1> [<d2>] ] [THETA <t1> [<t2>] ] [WIDTH <w>] [HEIGHT <h>]
The values given for d1 and optionally d2 define the collision criteria when moving the detector along the distance translation and those for t1 and optionally t2 when moving 2-theta. The formulas for driving the motors are as follows:
dsafe = d2*tan(2-theta) + dmin + d1
tsafe = asin [ (distance - dmin - t1) / t2 ];
- dsafe = the shortest distance considered to be safe
- tsafe = the largest 2-theta angle considered to be safe
- dmin = min. possible distance (as configured)
- d1 = 0.0 for Oxford Cryostream and MSC XTREME
- d2 = 240.0 (constant) for Cryostream and 170. for XTREME
- t1 = 25.0 for Cryostream and -17.0 for XTREME
- t2 = 320.0 for Cryostream and 230.0 for XTREME
For other cryo-cooling devices, it is suggested to modify d1 and t1 and check for collisions. By providing subkeys CRYOSTREAM or XTREME the parameters for the Oxford Cryostream and the Rigaku/MSC Xtreme will be used, respectively.
The width and the height specified here are only relevant for CSC operations. They define the width and height of the actual coldstream and set the allowed limits for automatic centering. I.e. a crystal should not be allowed to move outside the coldstream. The values provided are in mm and default to 8.0 mm
Default: CRYOPARAM DISTANCE 0.0 240. THETA 25.0 320. WIDTH 8 HEIGHT 8
- dsafe = the shortest distance considered to be safe
- CSC USE |IGNORE AUTO | NOAUTO SHIFT | NOSHIFT INIT_Z | NOINIT_Z [BARCODELEN <N>] [CAP USE|CHECK|IGNORE] [MINHSIFT <N>] [MAXHSIFT <N>] [CORREL <c>] [ZMAX <z>] [METHOD <N>] [PHOTOS <N>] [CYCLES <M>] [DPHI <dphi>] [START <phi0>] [TOLERANCE <mm>]
Option for using or ignoring the sample changer.
- USE | IGNORE
Enable or disable marcsc usage. - AUTO | NOAUTO
Enable/disable automatic centering options. - SHIFT | NOSHIFT
Enable/disable automatic xyz-shift correction method. With program version 4.3, a procedure to correct for xyz-shifts after remounting a sample has been implemented. To make use of it, the keyword SHIFT has to be provided. The way it works is described in chapter "Move Sample to Stored xyz in section Csc). In order to prevent too large movements, a minimum and a maximum shift can be given in pixels. Also, since it is assumed that a particular sample should look quite similar after remounting, the correlation between pictures of the sample when determining xyz and after remounting may be restricted to a value. Typically, correlations should be larger than 0.9 but if pictures don't match the resulting correlation typically is well below 0.5. - INIT_Z | NOINIT_Z
Force or disable initialization of crystal Z axis when initializing the goniometer head or all CSC motors. Forcing the initialization of the Z axis bears the risk to move a sample out of the cold stream. - MAXSHIFT <N>
Max. allowed shift (in pixels) for shift corrections. - MINSHIFT <N>
Min. shift (in pixels) for shift corrections. For shift less than MINSHIFT, the shift will be ignored. - CORREL <N>
Min. correlation for crystal photos from the same crystal. Applies only to shift correction method. - CAP USE | CHECK | IGNORE
For all sample changer operations, one has to specify wether the recognition of a cap is mandatory for ALL operations to complete successfully (CAP USE), only critical ones (CAP CHECK) or none (CAP IGNORE). For CAP USE, all failures to recognize a cap will constitute an error condition. - BARCODELEN <N>
Max. number of characters that barcode encodes - ZMAX <z>
Max. range in mm the dtb is allowed to move the Z-axis during automatic centering. If the number is exceeded, the automatic centering for this sample will be abandoned. The crystal should stay within the cold stream. Therefore, the Z-axis movement should be limited to a reasonable amount (2-3 mm). - TOLERANCE <MM>
When automatically centering a crystal, the adjustments taken from 2 consecutive images at a given Delta-PHI should be fairly small. They should fall below <MM> millimeters, otherwise the centering will be regarded as being unsuccessful. Suitable values should be inbetween 0.1 (default) and 0.3 mm. This option applies only to methodS 1 and 2 (see below). - METHOD <N>
Method used for automatic centering. Must be either 0, 1 or 2. For method 0, the procedure is the following:
- Drive sample to starting PHI
- Shoot and evaluate photo and apply xyz-shifts
- Drive PHI to DPHI and shoot and evaluate another photo
- Repeat previous step for N photos
Method 1 differs from method 0 by not evaluating single photos. Instead, a series of N photos is taken in PHI intervals given by DPHI. Only after taking the last photo, the entire series of photos will be evaluated and a set of xyz-movements will be computed.
Method 2 uses the same strategy as method 0, but after going once through 4 photos the program will continue to center the center the crystal until either the desired number N of photos has been reached or if the deviations inbetween 2 adjacent photos drops below a tolerance of MM millimeters. If N has been reached and the last movement was still above TOLERANCE, the centering will be treated as unsuccessful (see above). - PHOTOS <N>
During automatic centering, take N photos at PHI intervales given by DPHI. - DPHI <dphi>
During automatic centering, move PHI by dphi degrees inbetween 2 photos. - START <phi0>
Start automatic centering at the PHI position given by phi0. - CYCLES <M>
During automatic centering, repeat the entire procedure of shooting N photos M times. - CSV [[NO]PIN] [[NO]BARCODE] [[NO]IDENTIFIER]]
Enables or disables optional fields for each sample in the carousel. Usage of barcode strings, crystal identifier strings and the pin lengths is purely optional. Default is CSC CSV NOPIN BAR ID.
Default: CSC IGNORE NOAUTO NOSHIFT NOINIT_Z BARCODELEN 8 CAP USE MINSHIFT 1 MAXSHIFT 350 CORREL 0.8 ZMAX 3.0 METHOD 0 START 0.0 DPHI 90.0 PHOTOS 4 CYCLES 1 TOLERANCE 0.1
CSV NOPIN BARCODE IDENTIFIER
- USE | IGNORE
2.1.3 Keywords for mar345
The following keywords affect the mar345-detector only:
- IGNORE ERROR <n1> [<n2> [<n3>] [...]]
Most hardware errors will make a data collection stop when encountered. Some hardware errors may, however, not be fatal, and it may be desirable to continue data collection, anyway. Also, some hard- ware errors may not be real. For instance, when the scanners reports that an erase lamp is off during erase, it is possible that only the light sensor is broken but the lamp itself works fine. In such cases, the error number as produced by the hardware can safely be ignored. The error numbers can be looked up in the mar.spy file. There, each message (error or not) has got a unique message number. Up to 20 hardware errors may be ignored but all must go in only one line. If there are multiple "IGNORE ERROR" lines, only the last one will be used.
Default: no errors ignored - MONOCHROMATOR <synchtrotron | mirrors | graphite>
Type of monochromator. This string will be written into the corresponding section of the resulting images.
Default: MONOCHROMATOR MIRRORS - GENERATOR <synchrotron | rotating anode | sealed tube>
Type of X-ray source. This string will be written into the corresponding section of the resulting images.
Default: GENERATOR ROTATING ANODE - GAIN [100u <f1>] [150u <f2>]
Gain for conversion of X-rays into ADC-units for the image plate detector. These gain factors differ between the 100 micron and 150 micron scanmodes due to double sampling in the latter one. The values will be written into the image header and play a role only later during data processing when it comes to a statistically correct estimate of the variances of the reflection intensities. The values provided by marxperts are calibrated and scanner specific.
Default: GAIN 100u 1.0 150u 0.65 - CENTER USE |IGNORE [MIN <min>]
Choice for using a center correction table during transformation. This implies the existence of files center2300.$MAR_SCANNER_NO and center3450.$MAR_SCANNER_NO in $MARTABLEDIR. Technically, from each pixel in a transformed image a calibrated fixed count is subtracted. By providing a minimum pixel count, pixels will be forced not to drop below a given count (default to 5).
Default: CENTER IGNORE MIN 5 - MODE <scanmode> [ROFF <roff>] [ADC <off>] [AADD <a>] [BADD <b>] [PIXELSIZE <mm>]
Here you specifiy scanner specific values for ADC properties and radial offset corrections for each scanmode (one of 2300, 2000, 1600, 1200, 3450, 3000, 2400, 1800). In particular the ROFF value is really scanner specific and is calibrated during the manufacturing process. The AADD and BADD values are rather dependent on the controller of the detector and have to do with finding an optimal baseline for the ADCs used for digitizing the data. For the mar345s versions of the mar345 detector, it is also required to provide the pixelsize in mm for each scanmode. The fast mar345s scan modes are 1150, 1000, 800 and 600 and are modes 5 to 8. Either the normal 150 micron or 100 micron scanmodes are in positions 1 to 4.
Default: MODE <all scanmodes> ROFF 0 ADC 0 AADD 0 BADD 0 PIXELSIZE 0.15 - FLAG <number>
The scan command of the mar345-detector may be used with some special flags used for debugging. The number can be any hexadecimal combination of the following codes:
- 0: normal scan
- 1: scan with laser turned OFF
- 2: scan with high voltage turned OFF
- 4: scan with erase lamps turned OFF
- 10: scan with rotation encoder index line turned ON
- 16: scan without data transfer
- 32: scan with ADC offset set to input values
- 64: scan with profile skipped
- : scan with debug protocol turned ON
- 256: scan with ADC adjustment turned OFF
Default: FLAG 0 - MEMORY <number> MB | KB
The program reads a large calibration file during each scan. To improve reading efficiency, data are read in in larger blocks. Only used in program versions < 2.
Default: MEMORY 1 MB - GAPS <345mm> <300mm> <240mm> <180mm> [TOLERANCE <N>]
The scanning head of the mar345-detector is mounted on a translation stage. During a scan the scanning head passes a couple of especially marked positions (gap) that serve as a reference for the correct scanning head positions. The positions are hardwired and scanner specific. For a scan at a certain diameter the positions should always stay the same. The posi tions are given in relative motor steps. The expected tolerance normally is +/- 5 steps. Larger variations of the found "gap" positions may indicate a problem with the scaning head spindle. The observed gaps will be written into image headers, so those values can be verified. If the "GAP" keyword is given and the observed gap for a scan at a certain diameter is not within the tolerance, an error message will be produced and data collection stops. Under normal conditions, the GAP keyword should be left out or the tolerance set to large values, e.g. 99999.
Default: GAPS 89600 78600 63900 49100 TOLERANCE 99999 - DATA_INTERVAL <t1> <t2> <t3>
These values are very ciritical program parameters concerning timing of data transfer across the network during scan. <t1> is the timeout in millisec- onds to wait for new data to come in before looking again on the network socket after a block of data has been successfully transformed, <t2> is the time to wait in the case <t1> is a timeout after a block of data has been received and transformed before looking for more incoming data. <t2> is a timeout that occurs if a previous call with a timeout of <t1> has not been successful. <t3> is another timeout that happens only at the end of a scan if there are still some data missing. Most relevant is <t1>. However, these parameters are considered strictly internal and modification will have seri- ous consequences on overall program preformance.
Default: DATA_INTERVAL 3 3 10
2.2 Example
The following file listing is a typical configuration file for a mar345-detector mounted on the dtb:
! _____________________________________________________________________________ ! ! Configuration file for mar345 S/N 184 and dtb S/N 010 ! _____________________________________________________________________________ ! ! ============================================================================= ! ============================================================================= ! == == ! == Keywords for general program usage == ! == == ! ============================================================================= ! ============================================================================= ! USE DTB USE SCANNER DTB PORT 4451 HOST 192.0.2.3 TIMEOUT 0 MAR345 PORT 4441 HOST 192.0.2.1 TIMEOUT 0 MARMUX PORT 502 HOST 192.0.2.100 INTERVAL 1000 IGNORE ! INTENSITY MIN 2000 WARN 20.0 DOSEMIN 2.0 ! USE SPY USE STATS ! USE HTML IGNORE SUMMARY IGNORE SHELL ! IGNORE TTL ! COLORS 64 SETS 30 ! BROWSER firefox EDITOR kedit MONTAGE montagedtb.csh SOUND play ! ! ! Video params ! ============ ! ! VIDEO V4L2 or LIBXV or EXTERNAL or IGNORE ! VIDEO V4L2 GREY DEVICE /dev/video0 VIDEO INPUT Composite1 NORM PAL IDLE 300 VIDEO BRIGHTNESS 60 CONTRAST 55 AVERAGE 5 VIDEO WIDTH 768 HEIGHT 576 SCALE 474 474 474 VIDEO ORIGIN 368 285 VIDEO OVERLAY JPG ! THUMBNAIL mar2thumb LOOPFINDER loopfind ! ! Sample changer params ! ==================== ! CSC IGNORE CSC CAP CHECK BARCODELEN 10 CSC MAXSHIFT 250 CORREL 0.7 NOSHIFT AUTO CSC ZMAX 2.0 XMAX 1.0 YMAX 1.0 !CSC METHOD 1 CYCLES 1 PHOTOS 8 DPHI 45.0 START 0.0 TOLE 0.3 !CSC METHOD 0 CYCLES 1 PHOTOS 4 DPHI 90.0 START 0.0 TOLE 0.3 CSC METHOD 2 CYCLES 1 PHOTOS 12 DPHI 90.0 START 0.0 TOLE 0.3 ! ! ! WINDOWS params for Linux:KDE (1280x1024 pixels) ! =============================================== ! WINDOWS MAIN 1123 0 VIEW 45 0 1070 970 ! ! WINDOWS params for Linux:GNOME (1280x1024 pixels) ! ================================================ ! WINDOWS MAIN 1122 22 VIEW 15 22 1095 942 ! ! WINDOWS params for Linux:KDE (1680x1050) ! ======================================== ! WINDOWS MAIN 1525 0 VIEW 445 0 1070 1020 ! ! WINDOWS params for Linux:KDE (1600x1200) ! ======================================== ! WINDOWS MAIN 1444 0 VIEW 45 0 1392 1174 ! ! WINDOWS params for Linux:KDE (1920x1200) ! ======================================== ! WINDOWS MAIN 1765 0 VIEW 585 0 1170 1170 ! ! WINDOWS params for Linux:KDE (1920x1080) ! ======================================== ! WINDOWS MAIN 1765 0 VIEW 585 0 1170 1050 ! MONOCHROMATOR Mirrors GENERATOR Synchrotron WAVE DEFAULT 1.000 USE ! ! Log file versions to maintain: ! VERSIONS LOG 99 SPY 99 STATS 10 SCAN 99 TIME 99 PROFILE 99 ! ! ============================================================================= ! ============================================================================= ! == == ! == Keywords affecting dtb only == ! == == ! ============================================================================= ! ============================================================================= ! ! ADC values to start with: ! ADC CHAMBER 1 OFFSET 1000 TOLERANCE 20 HIGH VARIANCE LOW 2 HIGH 20 EDIT ADC CHAMBER 2 OFFSET 1000 TOLERANCE 20 HIGH VARIANCE LOW 2 HIGH 20 EDIT ! ! Initialization commands ! STARTUP USE TIME LOCK VERSION REMOTE STARTUP SKIP ADC SHUTTER HV CYCLE ! ! Shutter close delay in [millisec] ! SHUTTER 25 ! ! Find beam params ! FIND CHAMBER 1 X 25 75 Y 25 75 % SLIT 4.0 4.0 FIND CHAMBER 2 X 15 85 Y 15 85 % SLIT 4.0 4.0 ! ! Optimize beam params ! OPTI CHAMBER 1 SPEED 10 100 SLIT 0.6 0.6 RANGE 2.0 2.0 OPTI CHAMBER 2 SPEED 20 30 SLIT 0.3 0.3 FIRST 0.3 0.3 RANGE 2.0 2.0 OPTI SHORT FWHM SMOOTH 5 ! ! Scaling factors for all motors: ! UNITS STEPS 1 SPEED 1 ACCEL 1 TIME 2.5 ! ! Slits: Basecon-modul 1-4 (ID = 1-4) ! 1 mm = 200 fsteps ! V = 100 fsteps/sec ! A = 4000 fsteps/s*s ! SLIT FIRST VER STEPS 200 SPEED 100 ACC 4000 TIMEOUT 10 DEF 0.4 ID 1 SLIT FIRST HOR STEPS 200 SPEED 100 ACC 4000 TIMEOUT 10 DEF 0.4 ID 2 SLIT SECOND VER STEPS 200 SPEED 100 ACC 4000 TIMEOUT 10 DEF 0.3 ID 3 SLIT SECOND HOR STEPS 200 SPEED 100 ACC 4000 TIMEOUT 10 DEF 0.3 ID 4 ! SLIT FIRST VER MIN -0.03 MAX 4.0 SPEED 100 ACC 4000 BACK 0.2 SLIT FIRST HOR MIN -0.04 MAX 4.0 SPEED 100 ACC 4000 BACK 0.2 SLIT SECOND VER MIN -0.04 MAX 4.0 SPEED 100 ACC 4000 BACK 0.2 SLIT SECOND HOR MIN -0.07 MAX 4.0 SPEED 100 ACC 4000 BACK 0.2 ! SLIT FIRST HOR INITMIN NOINITMAX HASNOREF ABSOL HASMIN SLIT FIRST VER INITMIN NOINITMAX HASNOREF ABSOL HASMIN SLIT SECOND HOR INITMIN NOINITMAX HASNOREF ABSOL HASMIN SLIT SECOND VER INITMIN NOINITMAX HASNOREF ABSOL HASMIN ! ! Beamstop: Basecon-modul 5 (ID = 5) ! 0.15 mm = 1 fsteps ! 1 mm = 6.666 ! V = 2000 fsteps/sec ! A = 500 fsteps/s*s ! BEAMSTOP STEPS 6.6666666 SPEED 100 ACC 500 ID 5 BEAMSTOP MINVAL 5.0 MAXVAL 45.0 DEFAULT 15.0 BEAMSTOP REFERENCE 18.6 SPEED 50 SLOW 20 ACC 30000 TIMEOUT 20 METHOD 19 BEAMSTOP HASNOMIN HASNOMAX HASREF NOINITMIN NOINITMAX NEGATIVE NOINITAUTO ! ! Phi: Basecon-modul 6 (ID = 6) ! 1 deg = 800 fsteps ! V = 10000 fsteps/sec ! A = 20000 fsteps/s*s ! PHI STEPS 800 SPEED 10000 ACC 20000 BACKLASH -0.5 DEF 0.0 ID 6 PHI REFERENCE -0.125 SPEED 4000 SLOW 200 ACC 20000 TIMEOUT 180 METHOD 20 PHI HASNOMIN HASNOMAX HASREF NOINITMIN NOINITMAX NEGATIVE NOINITAUTO ! ! Theta: CAN-modul 1 (ID = 11) ! 1 mm = 400 fsteps ! V = 2000 fsteps/sec ! A = 1000 fsteps/s*s ! THETA STEPS 400 SPEED 2000 ACC 1000 TIMEOUT 120 ID 11 THETA MINVAL 0.0 MAXVAL 30.0 DEFAULT 0.0 THETA REFERENCE MIN -0.115 MAX 30.0 SPEED 2000 ACC 20000 SLOW 500 THETA HASMIN HASMAX INITMIN NOINITMAX NEGATIVE NOINITAUTO ! ! Distance: CAN-modul 2 (ID = 12) ! 1 mm = 400 fsteps ! V = 4000 fsteps/sec ! A = 4000 fsteps/s*s ! DISTANCE STEPS 400 SPEED 4000 ACC 4000 DEF 400.0 TIMEOUT 120 ID 12 DISTANCE REFERENCE MIN 75.0 MAX 425.6 SPEED 2000 ACC 20000 SLOW 500 DISTANCE HASMIN HASMAX NOINITMIN INITMAX POSITIVE NOINITAUTO ! ! Vertical translation: CAN-modul 3 (ID = 13) ! 1 mm = 20000 fsteps ! V = 800 fsteps/sec ! A = 2000 fsteps/s*s ! TRANS VER STEPS 20000 SPEED 800 ACC 2000 TIMEOUT 333 ID 13 TRANS VER MINVAL -7.5 MAXVAL 7.5 DEFAULT 0.0 TRANS VER REFERENCE MIN -7.80 MAX 7.80 SPEED 800 SLOW 500 ACC 2000 TRANS VER HASMIN HASMAX INITMIN INITMAX POSITIVE NOINITAUTO ! ! Vertical rotation: CAN-modul 4 (ID = 14) ! 1 mm = 2500 fsteps ! V = 4000 fsteps/sec ! A = 2000 fsteps/s*s ! ROTAT VER STEPS 2500 SPEED 3000 ACC 2000 DEF 0.0 TIMEOUT 444 ID 14 ROTAT VER MINVAL -17.0 MAXVAL 35.0 DEFAULT 0.0 ROTAT VER REFERENCE MIN -18.0 MAX 37.00 SPEED 3000 SLOW 500 ACC 10000 ROTAT VER HASMIN HASMAX INITMIN INITMAX POSITIVE NOINITAUTO ! ! Horizontal translation: CAN-modul 5 (ID = 15) ! 1 mm = 1600 fsteps ! V = 4000 fsteps/sec ! A = 10000 fsteps/s*s ! TRANS HOR STEPS 1600 SPEED 4000 ACC 10000 DEF 0.0 TIMEOUT 555 ID 15 TRANS HOR MINVAL -9.8 MAXVAL 9.8 DEFAULT 0.0 TRANS HOR REFERENCE MIN -10.00 MAX 10.00 SPEED 4000 SLOW 500 ACC 10000 TRANS HOR HASMIN HASMAX INITMIN INITMAX POSITIVE NOINITAUTO ! ! Horizontal rotation: CAN-modul 6 (ID = 16) ! 1 mm = 1600 fsteps ! V = 4000 fsteps/sec ! A = 10000 fsteps/s*s ! ROTAT HOR STEPS 1600 SPEED 4000 ACC 10000 DEF 0.0 TIMEOUT 666 ID 16 ROTAT HOR MINVAL -33.0 MAXVAL 33.0 DEFAULT 0.0 ROTAT HOR REFERENCE MIN -34.00 MAX 34.00 SPEED 4000 SLOW 500 ACC 10000 ROTAT HOR HASMIN HASMAX INITMIN INITMAX NEGATIVE NOINITAUTO ! ! Crystal Z-translation: CAN-modul 7 (ID = 17) ! 1 mm = 1600 fsteps ! V = 4000 fsteps/sec ! A = 10000 fsteps/s*s ! CRYSTAL Z STEPS 1600 SPEED 4000 ACC 10000 DEF 0.0 TIMEOUT 777 ID 17 CRYSTAL Z REFERENCE MIN -20.00 MAX 20.00 SPEED 4000 SLOW 500 ACC 20000 CRYSTAL Z HASMIN HASMAX NOINITMIN INITMAX NEGATIVE NOINITAUTO ! ! Chi: CAN-modul 8 (ID = 18) ! 1 deg = 437.5 fsteps ! V = 2000 fsteps/sec ! A = 10000 fsteps/s*s ! CHI USE CHI MAXVAL 90.0 DEFAULT 0.0 BACKLASH 0.5 CHI STEPS 437.5 SPEED 2000 ACC 10000 TIMEOUT 888 ID 18 CHI REFERENCE MIN -0.00 MAX 90.00 SPEED 1000 SLOW 100 ACC 20000 CHI HASMIN HASMAX INITMIN NOINITMAX NEGATIVE NOINITAUTO ! ! ============================================================================ ! Optional additional motors, e.g. for sample changer ... ! ============================================================================ ! ! Crystal x-translation: CAN-modul 9 (ID = 25) ! 1 deg = 20480/360 = 56.888 steps ! 1 mm = R*sin(x) with R=3.0 ! V = 1000 fsteps/sec ! A = 5000 fsteps/s*s ! CRYSTAL X USE CRYSTAL X STEPS 56.888 SPEED 800 ACC 5000 DEF 0.0 BACK 0.0 TIMEOUT 777 ID 26 CRYSTAL X REFERENCE MIN -1.650 MAX 1.300 SPEED 500 SLOW 500 ACC 3000 CRYSTAL X INITMIN INITMAX HASMIN HASMAX NEGATIVE NOINITAUTO CRYSTAL X OFFSET 0.0 ! ! Crystal y-translation: CAN-modul 10 (ID = 26) ! 1 deg = 20480/360 = 56.888 steps ! 1 mm = R*sin(x) with R=3.0 ! V = 1000 fsteps/sec ! A = 5000 fsteps/s*s ! CRYSTAL Y USE CRYSTAL Y STEPS 56.888 SPEED 800 ACC 5000 DEF 0.0 BACK 0.0 TIMEOUT 777 ID 27 CRYSTAL Y REFERENCE MIN -1.801 MAX 1.300 SPEED 500 SLOW 500 ACC 3000 CRYSTAL Y INITMIN INITMAX HASMIN HASMAX POSITIVE NOINITAUTO CRYSTAL Y OFFSET 0.0 ! ! Cryo actuator: CAN-modul 11 (ID = 24) ! 1 mm = 1600 fsteps ! V = 4000 fsteps/sec ! A = 10000 fsteps/s*s ! ACTUATOR USE ACTUATOR STEPS 1600 SPEED 3000 ACC 10000 DEF 0.0 TIMEOUT 888 ID 24 ACTUATOR BACKLASH 0.0 MINVAL 0.0 MAXVAL 24.9 ACTUATOR REFERENCE MIN 0.00 SPEED 3000 SLOW 1500 ACC 10000 ACTUATOR HASMIN HASNOMAX INITMIN NOINITMAX HASNOREF POSITIVE NOINITAUTO ! ! ============================================================================ ! Optional additional motors, e.g. for crystal plate scanner XPS ! ============================================================================ ! ! ! Crystal plate scanner module 18 (ID = 28) ! 1 mm = 1600 fsteps ! V = 3000 fsteps/sec ! A = 10000 fsteps/s*s XPS_X IGNORE XPS_X STEPS 1600 SPEED 3000 ACC 10000 DEF 0.0 TIMEOUT 888 ID 28 XPS_X BACKLASH 0.0 MINVAL 1.0 MAXVAL 89.0 XPS_X REFERENCE MIN 0.00 MAX 90.0 SPEED 3000 SLOW 1000 ACC 10000 XPS_X HASMIN HASMAX INITMIN INITMAX HASNOREF POSITIVE ABSOL ! ! Crystal plate scanner module 19 (ID = 29) ! 1 mm = 1600 fsteps ! V = 2000 fsteps/sec ! A = 10000 fsteps/s*s ! XPS_Y IGNORE XPS_Y STEPS 1600 SPEED 3000 ACC 10000 DEF 0.0 TIMEOUT 888 ID 29 XPS_Y BACKLASH 0.0 MINVAL 1.0 MAXVAL 1390.0 XPS_Y REFERENCE MIN 0.00 MAX 140.0 SPEED 3000 SLOW 1000 ACC 10000 XPS_Y HASMIN HASMAX INITMIN INITMAX HASNOREF POSITIVE ABSOL ! ============================================================================ ! Remote control settings ! ============================================================================ ! REMOTE USE REMOTE MASK 16777215 ! for csc, without actuator use: 16777214 REMOTE ADC ENABLE NOEDIT REMOTE THETA POS1 0.0 POS2 5.0 ENABLE EDIT REMOTE DISTANCE POS1 DYNAMIC POS2 300.0 ENABLE EDIT REMOTE CHI POS1 0.0 POS2 60.0 ENABLE EDIT REMOTE BEAMSTOP POS1 18.0 POS2 45.0 ENABLE EDIT ! ! To enable beamstop on button CRYO run the following commands first: ! dtbcmd 103,1,41,5 ! dtbcmd 103,1,40,100 ! dtbcmd 103,1,39,500 ! dtbcmd 103,1,38,-300 ! dtbcmd 103,1,37,-120 ! These commands need to be given only once and the dtb needs to be rebooted ! afterwards. ! ! ============================================================================= ! WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARNING WARN ! ============================================================================= ! ! USE CRYO and USE AMPTEK protect the detector from ! driving into collision. If these keywords are removed while ! the cryo-system INCLUDING cryo-mount (!!!) or AMPTEK are present ! considerable damage to both detector and dtb can be produced. ! ! When setting IGNORE CRYO it is ESSENTIAL to also remove ! the cryo-mount (by removing part of the cryo-stream exhaust). ! ! ============================================================================= ! USE CRYO CRYOPARAM OXFORD ! CRYOPARAM XTREME ! CRYOPARAM DISTANCE 0 THETA 25 IGNORE AMPTEK ! ! ============================================================================= ! ============================================================================= ! == == ! == Keywords affecting mar345 only == ! == == ! ============================================================================= ! ============================================================================= ! GAIN 100U 1.00 150U 0.63 ! ! Never ever change keywords from here on ! MODE 2300 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.15 MODE 2000 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.15 MODE 1600 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.15 MODE 1200 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.15 ! MODE 3450 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.10 MODE 3000 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.10 MODE 2400 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.10 MODE 1800 ROFF 120 ADC 50 AADD -42 BADD -42 PIXELSIZE 0.10 ! FLAG 0 ! !IP-Diameter: 345mm 300mm 240mm 180mm !GAPS 89659 78656 63903 49146 (08:49 on 30-Oct-2000) !
3. Calibration Files
If used with a mar345-detector, program mar345dtb requires calibration files. Those calibration files contain flood field correction factors as well as the geometrical information required to transform spiral coordinates into a Cartesian grid system. The file names are:
- $MARLOGDIR/mar2300.$MAR_SCANNER_NO
- $MARLOGDIR/mar3450.$MAR_SCANNER_NO
4. Parameter File
Program mar345dtb continuously saves parameters whenever they change within the program. When starting the program, the saved parameters are read back so the user always finds the latest changes after quitting a mar345dtb session. The parameter file read at startup is called dtb.dat and resides in directory $MARLOGDIR. If the parameter file doesn't exist, program defaults will be used. The program, however, will always create a new parameter file dtb.dat. The parameter file is a keyworded ASCII-file which may be edited.
Parameter files can be created and loaded from within the program. This is useful when working on a project where you always apply the same set of parameters. The parameter files carry the extension ".set" and may be saved using the "Edit -> Save Parameters ..." menu option in the main window. The parameters can be read back by using the "Edit -> Load Parameters ..." menu option ( also see chapter 6.2 in section Edit).
4.1 Keywords
The keywords used in the parameter file dtb.dat are as follows:
Table 2: Keywords in dtb.dat
Keyword | Arguments | Example | Description |
---|---|---|---|
SET | N USE|SKIP | 10. USE | N is the data set number followed either by string USE or SKIP |
DIRECTORY | STR | /data | STR is a string with a path name |
ROOT | STR | xtal | STR is a string with image root name |
SCANMODE | N | 0 | N is one of 8 scanmodes, either 1200, 1600, 1800, 2000, 2300, 2400, 3000 or 3450 |
FORMAT | mar|cbf | mar | Image output format: either "mar" or "cbf" |
COLLECT | TIME|DOSE | TIME | Exposure mode, either TIME or DOSE |
BLOCKS | N | 1 | N is the number of PHI-blocks |
NFRM | N | 50 | N is the number of images per block |
FFRM | N | 1 | N is the first image number |
OSCI | N | 1 | N is the number of oscillations |
DPHI | F | 0.5 | F is the Delta-PHI per image |
IPHI | F | 0.0 | F is the PHI-increment between images |
DISTANCE | F | 220.0 | F is the distance detector-to-sample |
PHI | F | 45.0 | F is the starting PHI angle |
CHI | F | 0.0 | F is the current CHI angle |
THETA | F | 0.0 | F is the current 2-theta angle |
WAVE | F | 1.54178 | F is the current wavelength |
BEAMSTOP | F | 18.5 | F is the current beamstop position |
XTAL_Z | F | 0.0 | F is the relative crystal translation |
SLIT1 | F G | 0.71 0.63 | F and G are hor. and ver. slit apertures for chamber 1 slits |
SLIT2 | F G | 0.45 0.43 | F and G are hor. and ver. slit apertures for chamber 2 slits |
ERASE | Erase plate before starting data collection | ||
PHOTO | Save crystal photo after each image | ||
THUMBNAIL | Produce thumbnails from data images during data collection | ||
SPIRAL | Also create raw spiral images during data collection | ||
OPTIMIZE START | Optimize beam before starting data set | ||
OPTIMIZE | [-]N IMAGE|HRS|MIN|LOSS | 30 LOSS | Optimize beam during data collection after given time or after N images or after N percent loss of X-ray intensity. A negative sign preceding N indicates this option to become deselected. |
APPEND | [SET] [VIAL] [BARCODE] | SET BARCODE | Append set and/or vial no. and/or barcode (+identifier) to file root on image creation |
VIAL | N | 14 | Carousel position to take sample from |
CENT | NONE|MANUAL|XYZ|AUTO [CONFIRM] [SHIFT] | XYZ CONFIRM | Crystal centering method, XYZ and AUTO may be followed by CONFIRM, XYZ may also be followd by SHIFT |
COMOPT | [1][+2][+3][+4][+5] | 2+5 | Selection of parameters to pass to shell script dtb.csh |
COM1/2/3/4/5 | STR | sleep 1 | Custom argument for shell script dtb.csh |
Up to here, the keywords are valid for the "SET" number given on the top. With a new SET keyword, the following keywords will be valid for that new set, so a dtb.dat may contain data for all 30 possible sets and the corresponding entries will be used to update the "Edit"-page. A couple of keywords have to be given only once since they are not related to that page:
Keyword | Type | Value | Description |
---|---|---|---|
SOURCE | STR | Rotating Anode | STR is the id of the X-ray source as given in the "Header Info"-window |
POWER | F G | 50.0 100.0 | F and G are kV and mA settings of X-ray source as given in the "Header Info"-window |
FILTER | STR | Mirrors | STR is the id of the monochromator as given in the "Header Info"-window |
CENT | F G | 0.0 0.0 | Deviations of center coordinates as given in the "Header Info"-window |
TRANSLATIONS | F G | -2.048 -1.888 | Refined beam positions of motors TRANS_HOR and TRANS_VER |
ROTATIONS | F G | -3.241 1.435 | Refined beam positions of motors ROT_HOR and ROT_VER |
ADVANCED|SIMPLE | Choice of advanced or standard layout for "Edit..."-window | ||
CSC | N1 N2 N3 N4 N5 N6 [NO]SHIFT [NO]STORE | 3 2 5 4 4 18 | Values to fill in into the "CSC operation"-fields on the "CSC"-page (Change sample, etc.). |
MARMUX | N or STR | 1 or TTL | Choice of "Close generator shutter after finishing data collection" |
4.2 Example
The following example contains parameters for only 1 data set.
#===================================================== # Date: Mon Feb 18 19:03:08 2002 # Automatically saved by mar345dtb: DO NOT EDIT!!! #===================================================== # ---------------------------------- SET 1 USE DIRECTORY /home/mar345/data/ ROOT xtal SCANMODE 1200 FORMAT mar COLLECT DOSE TIME 10 BLOCKS 1 NFRM 1 FFRM 2 OSCI 1 DPHI 1.000 IPHI 89.000 DISTANCE 350.000 PHI 45.000 CHI -0.000 THETA 0.000 WAVE 1.541790 BEAMSTOP 10.050 XTAL_Z 0.000 SLIT1 0.710 0.630 SLIT2 0.400 0.400 OPTIMIZE START OPTIMIZE -30 images ERASE PHOTO THUMBNAIL # ---------------------------------- # --- Shell commands --- COMOPT 1+5 COM1 COM2 COM3 COM4 # --- Optional Header Info --- SOURCE Rotating Anode POWER 50.00 100.00 FILTER Mirrors POLAR 0.000 CENT 0.0 0.0 REMARK # --- Refined X-ray beam positions --- TRANSLATIONS -2.048 -1.888 ROTATIONS -3.261 -2.508 # --- Edit Data Collection in expert mode --- ADVANCED DATA COLLECTION FEATURES # --- Crystal translation disabled in Edit --- XTAL_Z DISABLED # --- Sample Changer Settings: Change, Load, Unload, Give, Take, Pin --- CSC 1 2 1 2 2 18 SHIFT NOSTORE MARMUX 1
5. Command File
Program mar345dtb may be completely driven by external commands, i.e. all relevant settings and push-button actions can be bypassed. The command interface comes into variants:
- a plain ASCII-file $MARLGODIR/dtb.com with a syntax identical to the Parameter File with some extensions.
- a TCP/IP-socket
The TCP/IP-interface becoms active, if the configuration file has a negative argument on keyword COMMAND. A typical value would be "COMMAND -8678", i.e. the program would listen on UNIX port 8678 for connections. The program allows for multiple connections on the same port. The syntax for commands to be accepted via the TCP/IP-port is identical to the dtb.com file, i.e. ASCII strings will be evaluated. In return, the TCP/IP-socket writes ASCII-strings back to the same socket containing status information. The syntax is the same as used in the dtb.status file. The frequency is approx. 1/sec.
Note, that the command interface can be used together with the GUI but bears a considerable risk of unwanted or unforeseen dtb or mar345 activity. It must be stated that usage of the command interface is beyond the responsibility of marxperts and all damage produced by running commands using that command interface are not within our liability!
As stated above, all the syntax of the parameter file is used to modify settings of the data collection parameters, i.e. all parameters belonging to a given "SET" will be used to override the corresponding parameters on the "Edit"-pages. The main difference is that the command file in addition to the (optional) keywords of the data collection parameters requires additional lines that actually provide a command to be executed. This line always starts with keyword COMMAND followed by the following arguments:
Table 3: Arguments for keywords COMMAND in dtb.com
Arguments | Example | Description |
---|---|---|
ERASE | ERASE | Erase the image plate |
SCAN filename [scanmode] | SCAN /data/lysozyme_001.mar1200 1200 | The filename must follow the mar345dtb conventions. The scanmode and format will be taken from the image extension. If the scanmode is provided as additional argument, it will have precedence. When using the mar345s versions of the detector, it is mandatory to provide the scanmode to make a scan with a fast mode, since the image name extension for modes 1 and 5 in both cases is .mar2300. The scanmode is either a number from 1 to 8 or 2300, 2000, 1600, 1200, 1150, 1000, 800, 600 for mar345s detectors with a combination of normal (1-4) and fast (5-8) 150 micron scan modes. For a combination of 100 micron scan modes (1-4) and fast 150 micron scan modes (5-8), the scanmode parameter would be one of 3450, 3000, 2400, 1800, 1150, 1000, 800 or 600. |
CHANGE <mode> | CHANGE 1200 | Change the scanmode. Scanmode can be 1 to 8 or one of the modes given in the configuration file, typically 1200, 1600, 2000, 2300, 1800, 2400, 3000 or 3450. For mar345s variants, the scanmode might be 1150, 1000, 800 or 600. |
IPS n1,n2,... | IPS 4,0 | Native controller command for the mar345 image plate. |
DTB n1,n2,... | DTB 101,0 | Native controller command for the dtb. |
SHUTTER [OPEN|CLOSE] | SHUTTER CLOSE | Open or closes the shutter (or toggles current state). |
MOVE <motor> <value> | MOVE PHI 90.0 | Drive <motor> to <value>. The motor must be a string as given in chapter Motors in section Introduction. |
DEFINE <motor> <value> | DEFINE DISTANCE 250.0 | Define position of <motor> to be <value>. Beware: this command is VERY CRITICAL and should normally not be used. |
INIT <motor> MIN|MAX|REF | INIT THETA MIN | Initialize <motor> motor at minimum (near end), maximum (far end) or reference. |
OPTIMIZE [FIRST] [SECOND] | OPTIMIZE | Optimization beam in first and/or second chamber. Omitting FIRST and SECOND means using BOTH. COMMAND OPTIMIZE requires additional parameters to be provided on the OPTIMIZE keyword (see below). |
FIND [FIRST] [SECOND] | FIND SECOND | Find the beam in first and/or second chamber. COMMAND FIND requires additional parameters to be provided on the FIND keyword (see below). |
PROFILE [SLIT <h> <v>] [HOR <hor>] [VER <ver>] [PITCH <val>] | PROFILE HOR 1.5 VER 1.5 SLIT 0.1 0.1 PITCH 0.05 | Produce a beam profile covering <hor> mm in HORIZONTAL direction and <ver> mm in VERTICAL direction using slit apertures in chamber 1 of <h> and <v> mm, respectively. The advance per vertical movement will be <valr> mm. If some arguments are missing, the current settings of the GUI will be used. |
SHAPE [CHAMBER] 1|2 [HOR|VER <val>] [TRUNCATE <t>] [SPEED <per>] | SHAPE 1 HOR 0.9 TRUNCATE 15 SPEED 20 | Produce a beam shape plot for chamber 1 or 2 for the HORIZONTAL or VERTICAL slit, using an aperture for the non-moving slit of <val> mm at a speed of <per> percent . If some arguments are missing, the current settings of the GUI will be used. |
ADJUST [CHAMBER] 1|2 [WEAK|STRONG] [[OFFSET] <v>] [TOLERANCE <tr>] | ADJUST CHAMBER 1 OFFSET 1000 TOL 10 CHAMBER 2 OFF 1000 TOL 20 | Reset the ADC readings of chambers 1 or 2 to <v> units with a tolerance of <t> units. If some arguments are missing, the current settings of the GUI will be used. |
COLLECT [<s1>] [<s2>] [<s3>] ... | COLLECT 3 8 24 | Collect data for sets <s1>, <s2>, etc. Please note, that unless the sets are being reprogrammed by the same command file (using the syntax of the dtb.dat file), the current values in the Edit-page of the GUI for the desired set are going to be used. |
STOP [AFTER IMAGE|SET] [NOW] | STOP AFTER SET | Stop a data collection after finishing current IMAGE or current SET, or stop a motor movement NOW. |
CONTINUE [AFTER] IMAGE|SET | CONTINUE AFTER IMAGE | Undoes the effect of STOP AFTER IMAGE or STOP AFTER SET. |
ABORT | ABORT | Immediately stops current activity. |
QUIT | QUIT | Makes program mar345dtb shutdown. |
CSC {CHANGE <vial>} | {LOAD <vial>} | UNLOAD {GIVE <vial>} | {TAKE <vial>} | INIT | RESET | {MAGNET ON|OFF} | {SAVE <file>} | {READ <file>} | | CSC LOAD 18 | Sample changer operations as described in chapter CSC Operations in section CSC. The commands CSC SAVE and CSC READ will save or read sample status files, respectively. |
CRYSTAL FIND |{CENTER [XY] [<x> <y> <z>]} | CRYSTAL CENTER | Triggers a crystal finding or centering procedure as described in chapter Crystal Centering in section Crystal. While FIND works without further options, CENTER may be followed by xyz-coordinates. If they are omitted, the automatic procedure will be tried. |
6. Shell Script
Program mar345dtb allows to run external commands at certain times during data collection:
- before starting a data set
- before starting an exposure
- after finishing an exposure
- after finishing a detector readout
The following listing contains a very simple template for file dtb.csh.
#!/bin/csh -f set argc = $#argv set NUM = 2 set cmd = $1 set LOG = ( $MARLOGDIR/dtb.csh.log ) while ( $NUM <= $argc ) set cmd = ( $cmd $argv[$NUM] ) @ NUM++ end # echo "===============================================================" >> $LOG echo "Time: `date`" >> $LOG echo "Command: $cmd" >> $LOG echo "===============================================================" >> $LOG # # Actual command # echo $cmd sleep 2 # exit
7. Images
mar(345)dtb autodetects image file formats. The program actually looks at contents of files rather than at file names only. mar(345)dtb accepts the following image formats:
Table 4: Image formats accepted by mar(345)dtb
Format | Name suffix | Description |
---|---|---|
mar345 | .marXXXX | Images produced by mar345 detector |
cbf | .cbfXXXX | Images produced by mar software in CBF format |
image | .image | Original format of 180mm/300mm scanners |
pck | .pck | Images of 180mm/300mm scanners, "pck"-compressed. |
marccd | .mccd or .#### | Images of marCCD detector |
raw | .raw | Raw 32-bit data arrays without header |
tiff | .tif | TIFF files with 32-bit data array for DECTRIS detectors |
8. Carousel File
Program mar345dtb continuously saves carousel data whenever they change within the program. When starting the program, the saved parameters are read back so the user always finds the latest changes after quitting a mar345dtb session. The carousel file read at startup and updated during program execution is called $MARLOGDIR/csc/CSC.csv. The format is described in chapter Carousel File in section Output.
9. License File
Program mardtb needs a specific license file to operate together with DECTRIS detectors, either Pilatus3 or EIGER versions. This license file must be obtained from marXperts GmbH and requires program "mardtblicense" to be run on the target PC which is going to control the detector and mardtb goniostat. This license file is specific for a given installation and cannot be used for other setups. Please contact marXperts GmbH in case of doubt. When running program mardtblicense it is mandatory to run it on the host that connect to the mardtb hardware. Also, it is mandatory, that the mardtb is turned on at the time to run program mardtblicense and that the host is capable to connect to the mardtb hardware. In case of doubt, please check that you can login into the hardware with command "telnet 192.0.2.3". If this command does not succeed, the program mardtblicense will not be able to create the license information.
10. XPS Data and Definitions
When used with the crystal plate scanner, the program reads and stores data of a currently mounted crystallization plate from directory $MARLOGDIR/xps. In that directory XPS.dat stores current information of assigned drops that will be loaded automatically after reentering the software. File XPS.def however contains definitions for specific types of crystallization plates. This plain ASCII-file can be edited and new entries can be added to it. A crystallization plate definition section must contain the following entries:
- NAME string Arbitrart descriptive string
- ROWS n SEPARATION x Number of rows on plate (e.g. 12) and separation of wells in mm
- COLS n SEPARATION x Number of columns on plate (e.g. 8) and separation
- ORIGIN x y [TOP] [BOTTOM] x,y-offset in mm of first drop in upper right corner of platei. TOP means: A1a is in upper right corner
- DROPS n DX1 x1 DY1 y1 [DX2 x2 DY2 y2] Number of drops per well and translation in x,y to go from one drop to the next drop. Translations can be negative!
- DIMENSION w h Width and length in mm of the oplate
Example:
NAME Greiner CrystalQuick-X 2-Drops ROWS 12 SEP 9.0 COLS 8 SEP 9.0 ORIGIN 12.43 9.79 TOP DROPS 2 DX1 3.0 DY1 0.0 DIMENS 85.48 127.76