Scripting Commands for OM1's Resolve3D

1.5MAG

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
setscopemag CCDCommand.c

ACTIVE

Description
Sensitizes or desensitizes the histogram, display, autorange, and autoscale toggles in the Resolve3D control panel.
Usage
ACTIVE [onoff]
Parameters
onoff (optional)
If this string contains "On", the toggles are sensitized. If the string is not present, no action is taken. Otherwise, the toggles are desensitized.
Handler
Resolve3D
Location
setsensitive Resolve3D.c

AUTOSCALE

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
set_autorange CCDCommand.c

BIN

Description
Set the camera to combine n x n squares of pixels in the CCD as single pixels in the image.
Usage
BIN value
Parameters
value
value is an integer specify the number of pixels in each direction to bin a single pixel in the image. value must be one of the allowed bin settings for the camera, and the given value times the current size of the image must be less than the total size of the CCD excluding the pixels skipped on the edge (for the current camera there are 6 pixels skipped in each direction).
Handler
Resolve3D.c
Location
setbin CCDCommand.c

CLF

Description
Closes the currently open file. In the process it sets several items in the file header including the number of waves, number of times, z step, wavelength values, and wave minima and maxima.
Usage
CLF
Parameters
none
Handler
Resolve3D
Location
closefile CCDCommand.c

DEFAULTTITLE

Description
Each data file that is opened can have a title that is put in the first label in the header. Typically Resolve3D prompts for the title when the file is opened (this behavios can be changed with PROMPTTITLE); when it does not prompt for the title, the default title set by DEFAULTTITLE (or from the Param menu in Resolve3D) is used. The default title is saved when the save defaults button is pushed in the dialogs or a SAVEDEF command is issued.
Usage
DEFAULTTITLE [title]
Parameters
title (optional)
title is the string that will be used when Resolve3D does not prompt for a title when a file is opened. If title is omitted, the default title is set to the empty string and no title is included when files are written.
Handler
Resolve3D
Location
comchange_defaulttitle CCDCommand.c

DISBANK

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
comchange_disbank CCDCommand.c

DISPLAY

Description
Turns on or off whether or not images should be displayed to the screen after they read from the CCD.
Usage
DISDATA onoff
Parameters
onoff
If onoff contains "ON" or "on", images read from the CCD will be displayed to the screen. If onoff contains "OFF" or "Off", the images will not be displayed. If onoff is not specified or has some other value, nothing is done.
Handler
Resolve3D
Location
disdata CCDCommand.c

DISWIN

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
comchange_diswid CCDCommand.c

DMODE

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
comchange_dmode CCDCommand.c

EXP

Description
Sets the default exposure time in seconds. This default exposure time is used by the picture taking commands (CCD, CCDNW, DARK, SHADE, AVG) when they are not passed the exposure time as a parameter. This function calls CCDSetup as a side effect. The default exposure setting is saved when a SAVEDEF command is issued or the save defaults button is pushed in the Resolve3D dialogs.
Usage
EXP exposure
Parameters
exposure
exposure is a floating point value that represents the exposure time in seconds. If exposure is not supplied or is less than 0.001, an error message is displayed and the default exposure time is not changed.
Handler
Resolve3D
Location
setexp CCDCommand.c

FLIP

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
setflip CCDCommand.c

GAIN

Description
Sets the amplifier gain. Calls CCDSETUP as a side effect.
Usage
GAIN value
Parameters
value
value is an integer specifying the amplifier gain. Allowed values are one, four, and eight; if value has some other value nothing is done.
Handler
Resolve3D
Location
setgain CCDCommand.c

LENS

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
comselectlens CCDCommand.c

OPF

Description
Opens a data file. If there is already a file open, the user has the option of keeping it open and aborting the OPF command or of closing it and opening the new file. If the open is successful, Resolve3D will prompt for a title for the file unless PROMPTTITLE or the entry in the Param menu has been used to turn off the prompt. Then several items in the file's header are initialized including the image size, image x and y pixel size. Because of this the image size should not be changed while a file is open (any images taken and saved to the file after the size is changed won't be interpreted correctly). TAvoid changing the binning or magnification while a file is open as well since the corresponding change in the pixel size won't be reflected; in the header; similarly, changing the stage position in X or Y or changing it in Z before the first image is stored will not be reflected in the image origin information.
Usage
OPF [file]
Parameters
file
file is the name of the file to open. If it is not specified, Resolve3D will prompt the user for the file name. If file does not begin with a / or a ., then the file name is treated as ${IVE_DATA}/file if the environment variable IVE_DATA is defined. In the case the file name does not begin with a / or a . and IVE_DATA is not defined, the file name will be treated as ./file. If a file already exists with the given name, the user is prompted for whether or not the file should be overwritten.
Handler
Resolve3D
Location
openfile CCDCommand.c

PROMPTTITLE

Description
Turns on or off the prompt that Resolve3D issues for a file title when a file is opened. When the prompt is turned off, the default title set by DEFAULTTITLE (or from the Param menu in Resolve3D) is used. When the save defaults button is pushed in the dialogs or a SAVEDEF command is issued, the setting for whether or not to prompt for a title is saved.
Usage
PROMPTTITLE onoff
Parameters
onoff (optional)
If onoff is "ON" (case-insensitive), Resolve3D will prompt for a title each time a file is opened. If onoff is "OFF" (case-insensitive) no prompting will be done and the title set by DEFAULTTITLE or from the Param menu will be used. If onoff is something else or is not supplied, no action is taken.
Handler
Resolve3D
Location
comchange_prompttitle CCDCommand.c

SAVEDEF

Description
The initial settings for some Resolve3D settings can be customized by the user. SAVEDEF saves the configurable values so that they will be the initial values the next time Resolve3D is started; the values are saved in ${HOME}/OM1Resolve3D.def. Settings which are saved are:
Usage
SAVEDEF
Handler
Resolve3D
Location
savedef funcs.c

SHOWSETUP

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
showsetup CCDCommand.c

SIZE

Description
Sets the size of images taken by the camera.
Usage
SIZE nx ny
Parameters
nx
nx is an integer specifying the number of pixels in the x direction. nx times the binning factor must be less than the number of x pixels that the CCD has minus any pixels skipped in the x direction (6 for the current camera). nx must also be a multiple of a camera dependent size factor (4 for the current camera).
ny
ny is an integer specifying the number of pixels in the y direction. ny times the binning factor must be less than the number of y pixels that the CCD has minus any pixels skipped in the y direction (6 for the current camera). ny must also be a multiple of a camera dependent size factor (4 for the current camera).
Handler
Resolve3D.c
Location
ccd_changesize CCDCommand.c

SPEED

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
setccdspeed CCDCommand.c

STATS

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
change_calcstats CCDCommand.c

UPDATE_CORF

Description
Updates the image size display and then effectively invokes UPDATECAL.
Usage
UPDATE_CORF
Handler
Resolve3D
Location
UpdateCorf CCDCommand.c

UPDATECAL

Description
If using a correction file, verifies that the current settings match those of one of correction files available. If there is a correction file that matches the current settings, switches to using that correction file.
Usage
UPDATECAL
Handler
Resolve3D
Location
update_corf CCDCommand.c

UPDATESCR

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
update_scr CCDCommand.c

USECAL

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
setcorf CCDCommand.c

VERBOSE

Description
In verbose mode, Resolve3D will write more messages about what it is doing to the status window; also the display of the current filters in the dialogs is only updated when in verbose mode. The VERBOSE command is used to turn on and off verbose mode.
Usage
VERBOSE onoff
Parameters
onoff
If onoff contains "ON" or "on", then verbose mode is turned on. If it contains "OFF" or "off", then verbose mode is turned off. Otherwise, nothing is done.
Handler
Resolve3D
Location
setverbose CCDCommand.c

WRT

Description
?
Usage
?
Parameters
?
Handler
Resolve3D
Location
savedata CCDCommand.c

TOGAUFIL

Description
?
Usage
?
Parameters
?
Handler
IPFilter
Location
togautofilter IPFilter.c

KAUFILTER

Description
Tells the IPFilter process to exit.
Usage
KAUFILTER
Handler
IPFilter
Location
kautofilter IPFilter.c

MESSAGE

Description
Appends a message to the status window.
Usage
MESSAGE [string]
Parameters
string (optional)
This is the message to append to the status window. If not supplied a blank line is appended to the status window.
Handler
IVEStatus
Location
put_message IVEStatus.c

BEEP

Description
Rings the keyboard bell.
Usage
BEEP
Handler
IVEStatus
Location
beep IVEStatus.c

CCD

Description
Takes a picture and saves the image if a file is open. Implicitly invokes PD or PC to read the photodiode or photon counter values if the hardware is available.
Usage
CCD [exposure]
Parameters
exposure (optional)
exposure is a floating point value that sets the exposure time in seconds. Exposure values which are less than 0.001 are ignored and the current default value is used (this is set with the EXP command or by the exposure field in the Resolve3D dialogs). If the exposure value is not specified, the default value is used.
Handler
R3DCam
Location
take_pic R3DCam.c

CCDNW

Description
Takes a picture but does not save the image. Implicitly invokes PD,R or PC to read the photodiode or photon counter values if the hardware is available.
Usage
CCDNW [exposure]
Parameters
exposure (optional)
exposure is a floating point value that sets the exposure time in seconds. Exposure values which are less than 0.001 are ignored and the current default value is used (this is set with the EXP command or by the exposure field in the Resolve3D dialogs). If the exposure value is not specified, the default value is used.
Handler
R3DCam
Location
take_pic_nw R3DCam.c

AVG

Description
Takes a number of images and adds them with the option (set by the flag parameter) to either report the sum or the average.The result is saved if a file is open. Implicitly invokes PD,R or PC to read the photodiode or photon counter values for each image if the hardware is available. The photodiode or photon counter result that is reported is the sum or average (depending on the setting of flag) of the individual measurements for each image.
The accumulation is done in a buffer with 32 bits per pixel, but the final data is only recorded with 16 bits so the option to report the sum can result in overflow errors.
Usage
AVG [nframes [exposure [flag]]]
Parameters
nframes (optional, but must be supplied if exposure and flag are)
nframes is the number of images to take. If not specified or less than one, eight images are taken and averaged.
exposure (optional, but must be supplied if flag is)
exposure is a floating point value that sets the exposure time in seconds for each image. Exposure values less than 0.001 are ignored and the current default value is used (this is set with the EXP command or by the exposure field in the Resolve3D dialogs). If the exposure value is not specified, the default value is used.
flag (optional)
If flag is one, the sum of the images is reported. If it is not specified or has another value, the mean of the images is reported
Handler
R3DCam
Location
take_avg_pic R3DCam.c

DARK

Description
Takes an image with the shutter to the CCD closed.
Usage
DARK [exposure]
Parameters
exposure (optional)
exposure is a floating point value that sets the exposure time in seconds. Exposure values which are less than 0.001 are ignored and the current default value is used (this is set with the EXP command or by the exposure field in the Resolve3D dialogs). If the exposure value is not specified, the default value is used.
Handler
R3DCam
Location
take_dar R3DCam.c

SHADE

Description
?
Usage
?
Parameters
?
Handler
R3DCam
Location
take_shade R3DCam.c

CCDSETUP

Description
Initializes the camera with the current settings for the size, gain exposure, temperature (any others ?). The camera speed used is 2 (what does that mean?).
Usage
CCDSETUP
Handler
R3DCam
Location
setupcam R3DCam.c

CAMTEST

Description
Using the current camera settings, takes 32 images and averages them; the result is displayed on the screen and is written to a currently open image file (if there is one). Then 32 more exposures are taken and read out in 3 ways (no flip & no rotation, flip & no rotation, and flip & rotation). These are combined to give a standard deviation image which is displayed and saved to a currently open image file (if there is one).
Usage
CAMTEST [file]
Parameters
file (optional)
file is base name for the file to which a summary of the test results will be written. The full filename is ${IVE_DATA}/file.cam if the IVE_DATA environment variable is set or ${HOME}/file.cam if it is not. If the file argument is not supplied, the results will be saved in ${IVE_DATA}/file.cam if IVE_DATA is defined and ${HOME}/file.cam if it is not.
Handler
R3D
Location
camtest R3DCam.c

BITTEST

Description
Takes a series of exposures (no more than 20) to identify the exposure time for which the minimum pixel value is approximately 4096. If an image file is currenly open, these images are appended to it. Then a series of 40 exposures is taken for linearly increasing exposure times (ranging from 0 to the exposure time identified in the first step). These images are also appended to the currently open image file if there is one. Histograms for each line in this series of exposures are used to flag missing values or dropped bits. These results are written to the summary results file.
Usage
BITTEST [file]
Parameters
file (optional)
file is the base name of the file to which a summary of the test results will be written. The full file name is ${IVE_DATA}/file.cam if the IVE_DATA environment variable is set ir ${HOME}/file.cam if it is not. If the file file argument is not specified, the results will be saved in ${IVE_DATA}/bittst.cam if IVE_DATA is defined or ${HOME}/bittst.cam if it is not.
Handler
R3DCam
Location
bittest R3DCam.c

PC

Description
Starts the photodiode or reads out its value (depending on the argument supplied). Reads the photon counter value. The value is stored internally and is copied to the extended header of the data file when an image is written. Because the CCD, CCDNW, and AVG functions all call PC if the photon counter is available, there shouldn't be a need to call this function from a script.
Usage
PC
Handler
pctalk
Location
getpc pctalk.c

PD

Description
Resets the photodiode or reads out its value (depending on the argument supplied). When the value is read, it is stored internally and is copied to the extended header of the data file when an image is written. Because the CCD, CCDNW, and AVG functions all call PD if the photodiode is available, there shouldn't be a need to call this function from a script.
Usage
PD option
Parameters
option
If option begins with an A, then the photodiode is reset and begins to accumulate counts. If option begins with an R, the photodiode value is read out. Otherwise nothing is done.
Handler
pctalk
Location
getpd pctalk.c

SETSTICK

Description
Sends "PC,I" (what does that do?) to the PC.
Usage
SETSTICK
Handler
pctalk
Location
set_joystick pctalk.c

PCEXIT

Description
Signals the pctalk process to exit.
Usage
PCEXIT
Handler
pctalk
Location
pcexit pctalk.c

SCAN

Description
Sets the joystick if not set (see SETSTICK) and issues a "SCAN,arg" to the PC (what does that do?).
Usage
SCAN arg
Parameters
arg
arg is the argument passed to the PC's SCAN command. If not arg is specified, nothing is done.
Handler
pctalk
Location
scan pctalk.c

GETXY

Description
Reads the current x and y positions of the stage. The values are stored internally and aren't available to a script.
Usage
GETXY
Handler
pctalk
Location
getxy pctalk.c

GETZ

Description
Reads the current z position of the stage. The value is stored internally and is not available to a script.
Usage
GETZ
Handler
pctalk
Location
getz pctalk.c

PCTALK

Description
Passes its argument to the PC to be executed as a command.
Usage
PCTALK command
Parameters
command
command is the command string to be passed to the PC. If not specified, no action is taken.
Handler
pctalk
Location
passcom pctalk.c

MASTAGE

Description
Moves the stage in x and y to the specified position. Both the x and y arguments must be specified or nothing is done.
Usage
MASTAGE x y
Parameters
x
x specifies the x position of the destination. It is measured in microns and can range from 0 to 25000.
y
y specifies the y position of the destination. It is measured in microns and can range from 0 to 25000.
Handler
pctalk
Location
mastage pctalk.c

MRSTAGE

Description
Shifts the stage in x and y from its current position. Both the x and y shifts must be specified or nothing is done.
Usage
MRSTAGE x y
Parameters
x
x is the shift in microns that should be applied to the x position of the stage.
y
y is the shift in microns that should be applied to the y position of the stage.
Handler
pctalk
Location
mrstage pctalk

MZSTAGE

Description
Moves the stage in z.
Usage
MZSTAGE z
Parameters
z
?
Handler
pctalk
Location
mzstage pctalk.c

NP

Description
Issues "NP;" to the PC then does a CCDEchoCommand.
Usage
NP
Handler
pctalk
Location
np pctalk.c

IPPOS

Description
Issues "PC,I" to the PC then does a CCDEchoCommand.
Usage
IPPOS
Handler
pctalk
Location
ippos pctalk.c

DIAL

Description
Sets the global variable joystick. If dialmode, another global, was 0, issues a "DIAL" to the PC and sets dialmode to 1, otherwise issues a "PC,I" to the PC and sets dialmode to 0.
Usage
DIAL
Handler
pctalk
Location
setdial pctalk

EM

Description
Issues a "EM,<argument(s)>" to the PC.
Handler
pctalk
Location
NANO_emfilter pctalk.c

EX

Description
Issues a "EX,<argument(s)>" to the PC.
Handler
pctalk
Location
NANO_exfilter pctalk.c

ND

Description
Issues a "ND,<argument(s)>" to the PC.
Handler
pctalk
Location
NANO_ndfilter pctalk.c

EXEM

Description
Issues a "EXEM,<argument(s)>" to the PC.
Handler
pctalk
Location
NANO_exemfilter pctalk.c

SYNCMODE

Description
Sends the command "JOY" to the PC.
Usage
SYNCMODE
Handler
pctalk
Location
syncmode pctalk.c

SETSYNC

Description
Sends "SYNC,<mode>" to the PC.
Usage
SETSYNC mode
Parameters
mode
?
Handler
pctalk
Location
setsyncmode pctalk.c

SETLMC

Description
Issues a "WLM,0,<x>" command to the PC for each of the translation direction of the stage (z and possibly x & y). x is -5 if flag begins with "1"; otherwise x is 0.
Usage
SETLMC flag
Parameters
flag
?
Handler
pctalk
Location
setlmc pctalk.c

C4000

Description
Passes a command to the C4000.
Usage
C4000 command
Parameters
command
Is the command to pass. If command begins with "3PX", a "C4,16,3PX" is sent to the PC and a CCDCommand is issued. If command begins with "SYNC", "C4,3,1CR;C4,3,2CR;C4,3,4CR;" is issued to the PC. Otherwise, "C4,0,<command>" is issued to the PC.
Handler
pctalk
Location
c4000 pctalk.c

HOME

Description
Returns the filter wheels to their home positions.
Usage
HOME
Handler
pctalk
Location
gohome pctalk.c

XSTEP

Description
Sets the value for the distance to increment in x and updates the value shown in the user interface (displayed with two decimal places).
Usage
SETXSTEP increment
Parameters
increment
Is the floating point distance to move (microns?) with each step in x.
Handler
CCDStage (if have a XY motor and NANOMOVER isn't used for Z)
Location
setxstep CCDStage.c

YSTEP

Description
Sets the value for the distance to increment in y and updates the value shown in the user interface (displayed with two decimal places).
Usage
SETYSTEP increment
Parameters
increment
Is the floating point distance to move (microns?) with each step in y
Handler
CCDStage (if have a XY motor and NANOMOVER isn't used for Z)
Location
setystep CCDStage.c

ZSTEP

Description
Sets the value for the distance to increment in z and updates the value shown in the user interface (displayed with one decimal place).
Usage
SETZSTEP increment
Parameters
increment
Is the floating point distance to move (microns?) with each step in z.
Handler
CCDStage
Location
setzstep CCDStage.c

FOCUS

Description
Moves the stage a given distance in z and updates the user interface display of the current z position. If NANOMOVER is being used, this command issues a MZSTAGE command.
Usage
FOCUS distance
Parameters
distance
Is the floating point distance to move (in microns?).
Handler
CCDStage
Location
nfocus CCDStage.c

ENGAGE

Description
?
Usage
ENGAGE
Handler
CCDStage (except when there is an XY motor and Z is controlled by NANOMOVER)
Location
engagemot CCDStage.c

DISENGAGE

Description
?
Usage
DISENGAGE
Handler
CCDStage (except when there is an XY motor and Z is controlled by NANOMOVER)
Location
disengage CCDStage.c

MOVEXY

Description
Currently does nothing.
Usage
MOVEXY
Handler
CCDStage (when an XY motor is used)
Location
movexy CCDStage.c

RECORD

Description
Adds the current position (x, y, and z) to the list of positions recorded (at most 300 points can be recorded). To get the current position, issues a GETXY and GETZ command.
Usage
RECORD
Handler
CCDStage (when an XY motor is used)
Location
record CCDStage.c

VISIT

Description
Moves the stage to a position previously stored with RECORD. Issues a MASTAGE,x,y and PCTALK MA,2,z to complete its action (x, y, z are specified to two decimal places).
Usage
VISIT [point_number]
Parameters
point_number
Specifies which point in the recorded list (numbered 1 through the number of points). If point_number is not specified or is greater than the number of points currently recorded, no action is taken.
Handler
CCDStage (when an XY motor is used)
Location
visit CCDStage.c

EXFILTER

Description
Changes the excitation filter used (if the filters are coupled the emission filter is also changed).
Usage
EXFILTER name
Parameters
name
Is the name of the filter to use.
Handler
CCDFilter
Location
exfilter CCDFilter.c

EMFILTER

Description
?
Usage
EMFILTER name
Parameters
?
Handler
CCDFilter
Location
emfilter CCDFilter.c

NDFilter

Description
?
Usage
?
Parameters
?
Handler
CCDFilter
Location
ndfilter CCDFilter.c

PAIR

Description
?
Usage
?
Parameters
?
Handler
CCDFilter
Location
pair CCDFilter.c

SAVESCREEN

Description
Does a window dump?
Usage
SAVESCREEN
Handler
CCDSaveScreen
Location
savescreen CCDSaveScreen.c

modified December 8, 2003

Eric Branlund (eric@msg.ucsf.edu)
Macromolecular Structure Group, UCSF (http://www.msg.ucsf.edu)