ODIS Production.xml
See Also:Sample ODIS_Production.xml File
The ODIS_Production.xml file defines the interface used in Production Mode. The basic format of the ODIS_Production.xml file is as follows:
<Production> <configuration switches> <Input Fields> <Buttons> </Production>
Configuration Switches
Configuration switches in the file that set certain features while in Production mode. The available configuration switches are:
- Autosave
- ChangeResolution
- HideScope
- ShowTools
- ShowWarnings
AutoSave
This tag determines whether scans will be automatically saved to disk after a collection is finished (or aborted), and also configures the filename used to save. The Autosave tag has three attributes, described below.
- value
- sets whether autosave is enabled, either true or false.
- nameformat
- sets the format of the Scan Collection name. This format consists of any combination of:
- User text
- {Fx}, where “x” is the id of an Input Field
- {date}, representing the current date and time.
- dateformat
- sets the format of the {date} special field. The date format uses the following characters:
- Lowercase y: Year (e.g. “yyyy”)
- Captial M: Month (e.g. “MMMM”) Three “M’s” will show the month in abbreviated format (e.g. “Dec”)
- Lowercase d: Day (e.g. “dd”)
- Upper or Lowercase H: Hour (lowercase = 12-hour format, uppercase = 24-hour format)
- Lowercase t: AM or PM (e.g. “tt”)
- Lowercase m: Minutes (e.g. “mm”)
- Lowercase s: Seconds (e.g. “ss”)
So a date format string of “MM-dd-yyyy HH:mm:ss” would create a string like “03-20-2011 15:23:35”
<AutoSave value="true" nameformat="{date} this is a test {F1} {F2}" dateformat="yyyy/MM/dd hh:mm:ss tt"/>
ChangeResolution
This field determines whether or not a drop-down exists that allows the operators to change the resolution of the scan (without changing the scan dimensions). If this tag is missing, the operator cannot change the scan resolution. If the tag is present and the "value" attribute is set to "true", a drop-down list will be visible at the bottom of the screen that lets the user change the resolution to one of several preset increments, or a custom increment if desired.
<ChangeResolution value="true" />
HideScope
This field determines the visibility and functionality of the digital oscilloscope. If this tag is missing, the scope will be visible.
- The "value" attribute is set to “true” or “false” depending on whether or not the scope is visible. If false, the two other attributes can be used.
<HideScope value="true"/>
- If the "lockgates" attribute is present, gate positions on the scope can be moved with the mouse only if lockgates is set to "false". If it is absent, gates will always be locked.
<HideScope value="false" lockgates="true"/>
- If the "lockgains" attribute is present, pulser and A/D gain scroll bars on the scope are hidden if "lockgains" is set to "false". If it is absent, gains will always be hidden.
<HideScope value="false" lockgains="true"/>
ShowTools
This field determines whether or not a small number of image tools are visible on the image windows while in production mode. The visible tools are:
If other tools are needed, the user must run in a different operating mode (such as Offline Analysis or Basic)
<ShowTools value="true" />
ShowWarnings
This tag determines whether or not Scan Warnings (e.g. “Not at Start”, “Not at Focus”, etc.) are displayed. If false, none of these warnings will be displayed while in Production mode. This overrides the setting in the ODIS Configuration.
<ShowWarnings value="false"/>
Input Field Configuration
Input fields are areas in which user text may be entered. The data from input fields will be stored with the Collection data. Data fields can also be set so that a scan cannot continue until the input field is filled. A user can define as many fields as can be displayed on screen.
Fields are defined within the InputFields tag. Each Field tag has up to eight attributes.
Required Attributes
name
This contains the user-displayed field name.
id
Defines the numeric ID of the field. Used in AutoSave, and with certain Button Actions. Each field ID should be unique and greater or equal to 0.
Optional Attributes
autoclear
If present, the field will automatically clear itself after a scan has completed. Combined with the required field, this can be used to force the operator to enter a value in a field for every scan, e.g. the serial number of the part being scanned.
ignore
If present and set to a non-empty string, automatic operations on this field will be skipped if the field value matches the string. This includes broadcasting over TCP/IP client connections, autoclearing, and incrementing.
inputname
Links the field to a particular scan parameter. Currently the possible values are:
- partcount
- sets the number of parts to run in a tray scan. This has the effect of changing the number of rows to scan, e.g. if the tray scan is defined to have a step count of n, the number of rows to scan would be (partcount / n) ( plus 1 if partcount mod n is > 0). The minimum number of rows in a trayscan is 1.
length
This allows the user to set the displayed length of the tag (in screen pixels). A default value will be set if this is missing.
maxchars
sets a limit on the number of characters allowed in the field. Characters beyond this limit are ignored.
required
If present, a scan cannot be run until this field is filled. If empty, an error message will be displayed to the user.
Example Input Field Configuration
<InputFields> <Field name="Work Order #" id="1" length="200" required="true"></Field> <Field name="Recipe" id="2" length="100"></Field> <Field name="Qty" id="3" length="40"></Field> <Field name=Part SN" id="4" length="100" required="true" autoclear="true"/> </InputFields>
Result:
Buttons and Actions
Most of the control in Production Mode is performed through Buttons. Each button has one or more Actions Associated with it.
Button Configuration
Buttons are defined in the Buttons tag. Each Button tag within can contain one or more Action tags. A typical button definition would look like this:
<Button name="Load" id="150" color="green">
<Action type="LoadParams"></Action>
<Action type="SelectField" id="1"></Action>
</Button>
Result:
This button contains two actions, which will be performed in sequence.
A Button tag has the following attributes:
- The name attribute is required, and is the user-displayed button name.
- Note: A button with a name of '---' (three dashes) will be considered a spacer and will be made "invisible", leaving a gap.
- The id attribute is also required, and defines the numeric ID of the button. This is used in other actions for identifying other buttons. Button Ids should be unique among buttons.
- The color attribute is optional, and allows the user to set the background color of the button.
- The textcolor attribute is also optional, and allows the user to set the text color of the button.
- The enabledonstart attribute determines if the button will be enabled when the system is started up. If it is disabled, it must be enabled by an “Enable” Action at some point in order to be used (see the “Enable” Action below).
- The height attribute sets the height of the button (in pixels). This applies whether or not the button is used as a spacer.
Special Buttons
There are two special button names: “Start” and “Stop”. These start and stop the production system, and cannot be removed from the page: however, actions can still be defined within them.
For example, you can have the start button automatically initialize the system:
<Button name="Start">
<Action type="Init"/>
</Button>
Or have the Stop button disable all other buttons:
<Button name="Stop">
<Action type="Disable" id="all"/>
</Button>
Action Configuration
Each button can contain one or more Action tags, which are executed in sequence. An action tag will have different attributes, depending on the type.
The different types of actions currently defined are:
Motion
Setup
- LoadAnalysis
- LoadData
- LoadMegaBoard
- LoadParams
- SetCenter
- SetConfigFile
- SetReportFile
- SetReportFormat
Scanning
Results
User Interface
Action Details
Abort
- Does a hard stop of a scan in progress. All motion and collection is terminated. If no scan is in progress, this action does nothing.
<Button name="ABORT" id="1">
<Action type="Abort"></Action>
</Button>
Analysis
- This will run the currently loaded automatic Analysis on the latest image.
- Attributes:
- If the optional name attribute is present, a particular Analysis file will be loaded from the current Working Directory, as specified in ODIS Config.xml or as overridden in the “Set Working Directory” menu item.
- If the optional useparams attribute is present and set to true, the Analysis setup loaded will be one with the same name as the currently loaded parameter file
- If the optional showreport attribute is present and set to true, an Analysis Report will automatically be generated when the Analysis is complete.
- If the optional name attribute is present, a particular Analysis file will be loaded from the current Working Directory, as specified in ODIS Config.xml or as overridden in the “Set Working Directory” menu item.
Analysis cannot be performed while a scan is in progress.
<Button name="Analysis" id="1">
<Action type="Analysis" showreport="true"></Action>
</Button>
AnalysisReport
- This will display the Analysis Report from the last loaded Scan Collection.
<Button name="Analysis Report" id="1"> <Action type="AnalysisReport"></Action> </Button>
ClearField
- Clears the input on the selected field. Used in conjunction with the “required”attribute of a field, this can be used to force a user to input data at certain times (before a scan, for example) The field is selected with the “id” attribute.
<Button name="Load" id="1">
<Action type="LoadParams"></Action>
<Action type="ClearField" id="1"></Action>
</Button>
Disable/Enable
- These actions disable or enable other buttons, based on the ID#. Also, the text Strings “all” or “none” can be used to enable or disable all buttons, respectively.
<Button name="Stop Scan" id="1">
<Action type="Stop" />
<Action type="Enable" id="1"></Action>
<Action type="Enable" id="2"></Action>
<Action type="Enable" id="3"></Action>
<Action type="Enable" id="4"></Action>
<Action type="Disable" id="5"></Action>
<Action type="Disable" id="6"></Action>
</Button>
Goto
- Moves a selected axis to a specific point. The axis is selected either numerically (1-6) or by character (“abcdef” or “xyztgs”). The velocity used is the last velocity specified on the axis.
- The axis attribute selects the axis
- The position attribute sets where to move (in system units)
- An optional wait field determines if the move will wait before performing the next action. Set to “true” or “false”
A Goto cannot be performed while a scan is in progress.
<Button name="Park" id="500">
<Action type="Goto" axis="A" position="50" wait="false"/>
<Action type="Goto" axis="B" position="50" wait="false"/>
<Action type="Goto" axis="C" position="50" wait="false"/>
</Button>
GotoCenter
- Moves all axes to the Center position, based on the last parameter file to load. A GotoCenter cannot be performed while a scan is in progress.
<Button name="Goto Center" id="1">
<Action type="GotoCenter"></Action>
</Button>
GotoFocus
- Moves all axes to the Focus position, based on the last parameter file to load. A GotoFocus cannot be performed while a scan is in progress.
<Button name="Goto Focus" id="1">
<Action type="GotoFocus"></Action>
</Button>
GotoStart
- Moves all axes to the Start position (i.e. Corner), based on the last parameter file to load. A GotoStart cannot be performed while a scan is in progress.
<Button name="Goto Start" id="1">
<Action type="GotoStart"></Action>
</Button>
Increment
- Increments a number in a field. if the attribute query is present, the user will be prompted if he wishes to continue to increment the field.
<Button name="Skip Part" id="1">
<Action type="Increment" id="2" query="true"></Action>
</Button>
Init
- Sends the “Initialize Motors” command. If the attribute prompt is present and set to “true”, the operator will be given the option to cancel: otherwise this action proceeds silently. Init cannot be performed while a scan is in progress.
<Button name="Initialize" id="1">
<Action type="Init"></Action>
</Button>
LoadAnalysis
- Opens the "Load Analysis Setup" prompt and allows the user to load an Analysis Setup file. If the optional "name" attribute is present, the specified parameter file will be loaded from the DIRS_PARAMETERS directory, as specified in ODIS Config.xml.
<Button name="Load Analysis" id="1">
<Action type="LoadAnalysis" name="default.analysis.xml"></Action>
</Button>
LoadData
- Opens the “Load Data” dialog and allows the user to load data into the system. If the optional mostrecent attribute is present and set to “true”, it will automatically load the most recently created scan collection. This can be useful on a production system if many images are saved but only the most recent one is to be examined.
<Button name="Load Data" id="1">
<Action type="LoadData"></Action>
</Button>
LoadMegaBoard
- Opens the "Load Megaboard" prompt and allows the user to load a Megaboard config file. If the optional “name” attribute is present, the specified megaboard config file will be loaded from the DIR_PARAMETERS directory, as specified in ODIS Config.xml. The directory can be overridden with the "path" attribute.
<Button name="LoadMegaboard" id="991">
<Action type="LoadMegaBoard"/>
</Button>
LoadParams
- Opens the “Load Parameters” prompt and allows the user to load a parameter file. If the optional “name” attribute is present, the specified parameter file will be loaded from the DIR_PARAMETERS directory, as specified in ODIS Config.xml. The directory can be overridden with the "path" attribute.
<Button name="Load" id="1">
<Action type="LoadParams" path="C:\RefStandards"></Action>
<Action type="SelectField" id="1"></Action>
</Button>
LoadState
- Loads the last saved State of the production system. This includes the last loaded parameter file, and the state of any input fields present in the system.
<Button name="Load State" id="1">
<Action type="LoadState"></Action>
</Button>
Logout
- Logs out the current user and exits ODIS. Useful for switching out of Production mode.
<Button name="Logout" id="1">
<Action type="Logout" />
</Button>
Move
- Moves a selected axis a specified distance from the current point. The axis is selected either numerically (1-6) or by character (“abcdef” or “xyztgs”). The velocity used is the last velocity specified on the axis.
- The “axis” attribute selects the axis
- The “distance” attribute sets the distance to move (in system units)
- The “direction” is either 1 or -1, depending on the desire direction
- An optional “wait” field determines if the move will wait before performing the next action. Set to “true” or “false”
A move cannot be performed while a scan is in progress.
<Button name="Lock Plate" id="1">
<Action type="Move" axis="Z" direction="1" distance="30" wait="false"></Action>
</Button>
Pause
- Pauses a scan in progress. If the “textPaused” attribute is not set, the text in the button will change to “Resume” until pressed again. Otherwise, it will show the text specified in the “textpaused” attribute. If no scan is in progress, this action does nothing.
<Button name="Pause Scan" id ="20" color="Yellow" enabledonstart="false">
<Action type="Pause" textpaused="Resume Scan"/>
</Button>
PrintScreen
- Sends a shot of the current screen or screens to an available printer.
<Button name="Print Screen" id="60"> <Action type="PrintScreen"></Action> </Button>
Prompt
- Shows a message box containing the desired text. The text is stored in the text attribute of the action.
<Button name="Move X"> <Action type="Move" axis="X" direction="1" distance="30"></Action> <Action type="Prompt" text="Please wait for motion to finish before continuing."></Action> </Button>
SaveData
- Saves the current dataset to the Working directory.
<Button name="Save" id="1" >
<Action type="SaveData" />
</Button>
SaveScreen
- Saves the current screen or screens, depending on the
modeattribute.
<Button name="Save Screen" id="1"> <Action type="SaveScreen" mode="all"></Action> </Button>
SaveState
- This saves the current state of Production Mode, including the last loaded parameter file and the state of any input fields. State can be recalled with the LoadState action.
<Button name="Save State" id="1"> <Action type="SaveState"> <Button>
SelectField
- Sets the cursor on the selected field. Useful if the user should be prompted to enter data on a field after loading a parameter file, for example. The field is selected with the “id” attribute.
<Button name="Load" id="1" color="green">
<Action type="LoadParams"></Action>
<Action type="SelectField" id="1"></Action>
</Button>
SetCenter
- Temporarily sets the center of the current scan. Useful for minor adjustments to the scan center position. When a new parameter file is loaded, this position is cleared.
<Button name="Set Center" id="1"> <Action type="SetCenter"> <Button>
SetCorner
- Temporarily sets the corner of the current scan. Useful for minor adjustments to the scan corner position. When a new parameter file is loaded, this position is cleared.
<Button name="Set Corner" id="1"> <Action type="SetCorner"> <Button>
SetConfigFile
- Uses a Configuration file to determine field inputs and Parameter files. The path to the file is set in the “path” attribute, and the file name is set in the “configfile” attribute. When the action is invoked, the fields and parameter file specified in the input file are loaded. See Configuration File Format for details.
<Button name="Load From File" id="1"> <Action type="SetConfigFile" path="C:\ODIS_DATA" configfile="Inputfile.txt"/> </Button>
SetField
- Sets a field to a preset value. The field is identified by the "id" attribute.
<Button name="Set Value" id="1"> <Action type="SetField" id="1" value="Started"/> </Button>
SetReportFile
- Sets the location of an output file in which to store Analysis Results. The path to the file is set in the “path” attribute, and output file name is set in the “reportfile” attribute. When the action added, any runs from AutoAnalysis will automatically be saved to the output file. The format is determined by the SetReportFormat Action.
<Button name="Set Report File" id="1"> <Action type="SetReportFile" path="C:\ODIS_DATA" reportFile="Outputfile.txt"/> </Button>
SetReportFormat
- Sets the output format of the report saved the the location specified in SetReportFile. As of this writing, the two options for the "mode" atttribute are "CSV" (Comma-delimited text) or XML.
<Button name="Set Report File Format" id="1"> <Action type="SetReportFileFormat" mode="CSV"/> </Button>
Start
- Starts a scan using the currently loaded scan parameters.
<Button name="Start Scan" id="1">
<Action type="Start" />
</Button>
Stop
- Does a graceful stop of a scan in progress: lets the current scan finish, then recalls position based on Configuration settings. If no scan is in progress, this action does nothing.
<Button name="Stop Scan" id="1">
<Action type="Stop" />
</Button>
Switch
- this action is a toggle between two states. The type of switch depends on the “value” attribute:
- Trayview: toggles a tray scan between single and multi-chip view
- Autoupdate: toggles updating during a scan on and off.
- Gateview: Switches to view the first instance of the selected gate. The gate name is selected with the “select” attribute.
- SwitchUser: prompts to switch users. Useful for logging which operator is on the system when a shift changes.
<Button name="PG 2" id="1">
<Action type="Switch" value="gateview" select="Data1"></Action>
</Button>
<Button name="Tray View" id="2">
<Action type="Switch" value="trayview"></Action>
</Button>
<Button name="Switch User" id="3">
<Action type="Switch" value="switchuser"></Action>
</Button>
Zero
- Zeros all motor positions. If the attribute “prompt” is present and set to “true”, the operator will be given the option to cancel: otherwise this action proceeds silently.
<Button name="Zero" id="8" color="Blue">
<Action type="Zero"></Action>
</Button>
Configuration File Format
A simple text configuration file is used when using the SetConfigFile Action. The format is a series of name/value pairs delimited by a comma. A simple example is as follows:
F1,Field1Input F2,Field2Input Params,MyParameterFile
The possible names are as follows:
- Fx, where "x" is the ID of the field to fill. The text of the field follows the comma. There can be any number of field inputs. Any field IDs which do not exist will be ignored.
- Params or Recipe specifies the name of a parameter file to load, without the postfix ".set.xml". If there is an Analysis configuration with the same name (e.g. "MyParameterFile.analysis.xml"), the Analysis configuration file will also be loaded.
It is up to the system managers to change the file as needed.
