Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Famos Iii

Download as pdf or txt
Download as pdf or txt
You are on page 1of 44

imc ACADEMY

Training Material

imc FAMOS III


Panel, Data Browser, Dialogs
12th Edition - 2017-02-15

© 2017
imc Meßsysteme GmbH • Voltastraße 5 • 13355 Berlin • Germany
imc Test & Measurement GmbH • Max-Planck-Str. 22b • 61381 Friedrichsdorf • Germany
About imc ACADEMY
Welcome to the imc ACADEMY training program. We thank you for joining us for today’s training session.

imc ACADEMY has existed since 1998 and offers a broad scope of instruction on measurement
technology from imc. For this purpose, you have a choice of different paths of knowledge transfer, for
instance training sessions, workshops and seminars. To cover the various topics, several traininers are
available who each focus on a different specialized area.

Learn more about imc ACADEMY at www.imc-academy.de.

For any questions which may arise, imc's support department is happy to help:
By e-Mail: hotline@imc-berlin.de hotline@imc-frankfurt.de
By telephone: +49 (0)30 467090-26 +49 (0)6172 59672-40
By fax: +49 (0)30 463157-6 +49 (0)6172 59672-222

About this training


imc FAMOS (Fast Analysing and Monitoring of Signals) is a program for fast analysis and visualization of
measurement data. The basis for this tool kit's high processing power is the structure of the data sets
used. Only data sets having this structure yield useful, meaning interpretable, results.

In this course, the use of Panels is imparted in the interaction with the Data Browser and the Dialog
Editor.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Disclaimer of liability
The contents of this documentation have been carefully checked for consistency with the hardware and
software systems described. Nevertheless, it is impossible to completely rule out inconsistencies, so that
we decline to offer any guarantee of total conformity.
We gratefully accept any suggestions for improvements, please contact our Hotline (hotline@imc-
berlin.de).

We reserve the right to make technical modifications of the systems.

Copyright
© 2017 imc Meßsysteme GmbH, Berlin, Germany
© 2017 imc Test & Measurement GmbH, Friedrichsdorf, Germany

This documentation is the intellectual property of imc Meßsysteme GmbH and imc Test & Measurement
GmbH. imc Meßsysteme GmbH and imc Test & Measurement GmbH reserve all rights to this
documentation. The applicable provisions are stipulated in the "imc Software License Agreement".
The software described in this document may only be used in accordance with the provisions of the "imc
Software License Agreement".

imc Software and Microsoft® Windows


imc software runs on the Microsoft® Windows operating system.

GPL Sources
Some components of our hardware use software, that is licensed under GNU General Public License
(GPL). If you would like a copy of the GPL source code contained in this product please contact our
Hotline.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Table of Contents 5

1 Introduction ..................................................................................................... 6
2 Panel and Data-Browser ................................................................................... 7
2.1 How to use Panels ...................................................................................................... 8
2.2 Exercise: Panel pages ................................................................................................ 10
2.2.1 Exercise: Page Measurement ........................................................................................................ 10
2.2.2 Exercise: Page Report ................................................................................................................... 19
2.2.3 Exercise: Advanced ....................................................................................................................... 25
3 User-defined dialogs ....................................................................................... 31
3.1 Introduction to the Dialog Editor .............................................................................. 32
3.2 Event sequences for the dialog ................................................................................. 33
3.3 A first, simple dialog ................................................................................................. 34
3.4 Searching for errors in a dialog ................................................................................. 37
4 Miscellaneous ................................................................................................. 39
4.1 Favorites .................................................................................................................. 39
4.2 Entering a waveform’s Y-unit ................................................................................... 40
4.3 File structure ............................................................................................................ 41
4.3.1 Keys .............................................................................................................................................. 41
4.3.2 Variable types (imc FAMOS Chapter 6.3) ...................................................................................... 41
4.3.3 Data format for results ................................................................................................................. 41
4.3.4 Folders .......................................................................................................................................... 41
4.3.5 Remote calling of a sequence ....................................................................................................... 42
4.3.6 Placeholder ?, * and # ................................................................................................................... 42
4.4 Kits (brief overview) ................................................................................................. 43
Index ................................................................................................................... 0

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
6 Introduction

1 Introduction
The first two days of the training session presented the fundamentals of working with imc FAMOS and of
creating sequences. On this day, the skills already learned will be strengthened. For creating analysis
sequences, there is not only the possibility of including the “little” text boxes and prompts, but also
whole Panels and dialogs. Panels and Dialogs offer substantially more possibilities for user interaction,
allowing the creation of user-defined analyses which can be performed even without imc FAMOS skills.
In the following chapters, you will be introduced to imc FAMOS’ main Panel and dialog elements by
means of concrete examples. Since the functionality of the Panels and dialogs is determined by
sequences in reference to specific elements, this introductory session will also involve practicing the
creation of complex sequences.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
7

2 Panel and Data-Browser


The Panel is a tool for quick and easy viewing of measured data.
The Panel supplements the curve window functions with flexible assignment of measurement channels.
The panels and the Data-Browser combine the properties of dialogs and reports.

Presentation with Panels


For display and documentation of measured data, panels are used. A panel contains one or more
pages. You can arrange a variety of display elements on a page. Typical elements include curve
windows, tables and text boxes. It is also possible to position interactive elements such as buttons and
input boxes for text in the forms. Such interactive elements can either start sequences or be linked
directly with imc FAMOS variables (data binding).
Design Mode / Run Mode
To create or edit panels, you switch the to Design Mode.
In this mode, there are additional tools available:
· Toolbar for selecting the panel elements
· Editors with which to determine the panel element properties
Panels designed in this way (file extension: *.panel) can later be loaded during the run and either
automatically or manually "filled" with the current measured data. You can use the input boxes and
buttons, and print out the presentation of data, as well as save them in a variety of formats such as
Adobe Acrobat PDF, PNG, BMP .
Data selection
The Data-Browser solves two commonly occurring situations.
· Multiple channels often have the same name. Using the imc FAMOS curve window alone, the
only way to simultaneously edit or view multiple files with the same name is to first rename
them or to take similar steps (e.g. explicit merging to data groups).
· Display elements such as curve windows are normally designed in such a way that the data to be
displayed can be specified using their (channel-) names. In the presentation, either the channels
currently desired must be renamed, or replaced in the curve window.
Data selection is governed by two principles:
· Assigning the channels to measurements
When opening files of measured data, the associated channels are automatically assigned to a
"Measurement". The measurement's name can be derived from, for example, the name of the file of
measured values (for multi-channel files), from the name of the folder to which the files belong.
· Selection/Numbering
The names of measurements and channels recorded in imc FAMOS are displayed in separate list boxes
and can be selected by the user. To each measurement and each channel one contains, it is possible
to assign a unique number.
Curve windows and other display elements for measured data can now be configured in such a way
that references to the current selection can be entered in these lists instead of concrete channel
names.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
8 Panel and Data-Browser

2.1 How to use Panels


A convenient illustration of how to work with the Panel is provided by the install sample project "Data-
Browser Demo".
Open the project "Data-Browser Demo" by means of the menu item File\open\Project.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
How to use Panels 9

The Panel pages contain a step-by-step tutorial in blue font. Read the explanations and instructions and
then click on Next. Unfortunately, there is no Back-button.
When you reach the place when the data are loaded, you must go to the Browser-page.

Continue to work through the tutorial to become familiar with the operation of the Panel page.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
10 Panel and Data-Browser

2.2 Exercise: Panel pages


In this exercise, you will learn how to:
· configure curve windows,
· perform calculations and display single values,
· create and display data sets,
· save created data in the measurement data path,
· compose reports.
Use the project DataBrowser-Demo, located in the Project folder, as a model.

2.2.1 Exercise: Page Measurement


2.2.1.1 Creating a Panel
· Load the project DataBrowser-Demo.

· Close the existing Panel "Demo".

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 11

· Create a new panel as Standard Dialog.

· Rename "Page1" to "Measurement" by double-clicking on the page name "Page 1".

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
12 Panel and Data-Browser

2.2.1.2 Creating curve windows


1. Drag a curve window to the Panel.

2. Load the data...

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 13

3. Select a measurement. Then drag all four channels to the curve window.

4. Right-click the mouse in the curve window and select "Configuration\Display". Display the channels
with their Y-axes stacked one on top of the other.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
14 Panel and Data-Browser

Double-click on a Y-axis and set all Y-axes to Range selection auto.

2.2.1.3 Calculations performed upon switching measurements


When we jump to a different measurement, we wish for certain regions, such as where the signal "Level"
is above 40 mm/s^2, to be located automatically. For this purpose, the signal must first be smoothed.
The statistics maximum value, mean value and duration are to be determined.
1. Ensure that the Design mode is activated. Then go to imc FAMOS and enter the following lines into
the region "Data selection Changed":

A new channel is calculated. This channel’s Max, RMS and Mean values are determined.

Run these command lines one by one. The results are graphed as they are produced.

Remarks: The command SelUseMeasurement(1) checks whether a measurement is selected. The


number 1 stands for the index of the first selected measurement. If multiple measurements are to be
selected, it is thus possible to access the second, third, etc. measurement. With this command,
FAMOS generates a reference to the channels available in the Variables list. For example, the channel
Level in the measurement 0001 appears in the Variables list as Level@0001. If measurement 0001 is
selected, the function SelUseMeasurement(1) now internally generates the suffix "@0001" for the
variable Level, which then is directly available for use within the sequence.
The calculated static values are to be displayed later in a little analysis table.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 15

2. Display the results in an additional curve window. To do this, drag the channel Level from the
Channels list to the Panel and create an additional standard curve window.
You can place the channel "Level_Smo" by means of the dialog More Waveforms in curve Window. By
means of the filter "Level_s*" in the box "Wildcards", it is easy to find the variable.

3. Select various measurements in succession and test whether the calculated channel is also updated.
Note that the sequence is only run if the Panel is no longer in Design mode .

2.2.1.4 Calculations at value changes


The window width for the smoothing, and the signal range threshold are to be adjusted using input
boxes. When the user enter a changed value, the system is to perform the calculation again.
1. Insert a "label" and an "Editbox (Single line)".

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
16 Panel and Data-Browser

2. Link the input box with the variable "t_smo" via the variable name. We will set up this link
subsequently but we can already prepare for it. As the text, enter "<VAR.VALUE("#.#")> s". This
placeholder will adopt the value of the variable "t_smo" and format the number to have one decimal
digit. The "s" for seconds simply appears after it.

3. Copy the text box and the input box and insert them again. Repeat the last step for the threshold
specification. The variable's name is "Threshold"; the unit "mm/s^2"

4. In the initialization, create the variable "t_smo" (=1) and "Threshold" (=40).

5. Now create a sequence from the branch Data Selection Changed:


- Select Data Selection Changed, select and copy the whole branch
- Create a new sequence and insert the contents
- Save the sequence under "Calculation.seq"
6. Next, replace the content of the branch Data Selection Changed with the call SEQ Calculation

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 17

7. Insert the same sequence call in the branch Buttons>input1

8. In order for the variables to take effect, they must be incorporated into the sequence. The sequence
now appears as follows:

Note that the threshold must be divided by a factor of 1000, since the values belonging to Level lie in
the range mm/s^2. The curve window automatically scales the unit m/s^2 to mm/s^2 um.
9. Change the values for the smoothing window width and the threshold and click on the button. As
always, execution of the function can occur only when Design mode is deactivated.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
18 Panel and Data-Browser

2.2.1.5 Display of single values in a table


A table is filled in, and the maximum, mean values and duration are listed.
1. Add a table to the Data Browser.
2. The table is structured as 2 columns and 3 rows. Note that the table itself possesses different
properties than a cell in the table. For that reason, no cell may be currently selected, while you intend
to enter the amount of columns.

3. Click in the cells of the left column and write “Max”, “Mean” and “Duration”. In the right column, set
the link to the single values and under “Text” set the placeholder as " <VAR.VALUE("0.#")> mm/s^2.
Format the table as desired.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 19

2.2.1.6 Page Measurement

2.2.2 Exercise: Page Report


2.2.2.1 Creating a panel page
1. Create a new Panel page.
2. Select Report (Landscape format)
3. Name this page "Report"

2.2.2.2 Incorporate the curve window and the table


1. Go to the page "Measurement" and select the two curve windows and the table. To do this, hold
down the key CTRL.)
2. Copy these controls by pressing the keys CTRL+C. Switch over to the Report page and insert these
elements by clicking CTRL+V.

2.2.2.3 Table Header


1. Arrange the elements/controls in such a way that there is enough room at the top for a table.
2. Insert a table: Structure: 3 columns, 3 rows.
3. The table presents information on the experiment. The information is represented by variables. These
in turn can also be saved and later loaded again as texts.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
20 Panel and Data-Browser

4. Go to Initialization and create the following variables:

5. Link the table cells with the variables:

Observe the box "Text": "Test Object:". The permanent text "Test Object: " is combined with the contents
of the Variable Test_object.
Proceed in the same way with the variable "Tester" and "Department".

6. The Date box indicates the current date. Enter into the text box just the text" Date: <SYSTEM.DATE>".

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 21

2.2.2.4 Enter additional info by page Measurement


1. Add three labels and three edit fields at the measurement page for Tested by, Test object und
Department.
2. Link the edit fields to the variables.
3. Set the property Format to Text, otherwise it shows "???" when entering.

4. Create a "Group box" around the controls. Click the context menu of the group box and set it "To
Backround"

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
22 Panel and Data-Browser

2.2.2.5 Add a picture


1. The company logo will be added as image and placed inside into the table. To get enough space,
connect the three cells of the left column.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 23

2.2.2.6 Creating or printing a PDF


1. Each Panel page has the property "Print/PDF-Export". Set only such pages to "Yes" which you wish to
print out.

2. Printout is performed by means of the Panel menu or by means of the toolbar icons.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
24 Panel and Data-Browser

2.2.2.7 Page Report

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 25

2.2.3 Exercise: Advanced


2.2.3.1 Saving result data sets
1. A "Pushbutton" is inserted for the purpose of saving data.

2. In imc FAMOS, the following command lines are added:

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
26 Panel and Data-Browser

2.2.3.2 Remember last settings


At the end of the measurement, the settings are to be saved to a file. Once this has been done, these
settings can be restored upon the next launch of the program.
To do this, insert the following sequence into the branch End:
; Get project path and add filename for settings.
project_Ini = GetOption("Dir.CurrentProject")+"\settings.ini"
; Save all variables into "settings.ini"
If FileSave(project_Ini, "", 0, threshold, t_smo, Tester, Department,
Test_sample)= 0
BoxMessage("Save panel settings", "Saving failed!!", "S1")
End

The branch Initialization is altered as follows:


; Default values
t_smo= 1 ; time interval for smo function
threshold= 40 ; in mm/s^2

; Report text variables


Tester= "Name Surname"
Department= "My Department"
Test_sample= "My test sample"

; If setting.ini exists, use last settings


project_Ini = GetOption("Dir.CurrentProject")+"\settings.ini"
If FsGetFileSize(project_Ini) > 0
FileLoad(project_Ini, "", 0)
End

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 27

2.2.3.3 Set markers at threshold


The following code must be inserted at the end of the sequence Calculation.

CwSelectWindow( "Curve2") ; select curve window

CwSelectByIndex("marker", 1) ; Delete previous markers


CwDeleteElement("marker")
CwSelectByIndex("marker", 1)
CwDeleteElement("marker")

; Set markers
CwNewElement("marker") ; Create first marker
CwMarkerSet("x.type", 1) ; physical units
CwMarkerSet("y.type", 1)

CwMarkerSet("x", start[1].X) ; Set left position


CwMarkerSet("y", start[1].Y)
CwMarkerSet("angle", 120) ; Set left angle
CwMarkerSet("border", 0) ; no border
CwMarkerSet("text", "Threshold of "+ TForm(threshold, "F00")+"mm/s^2
("+TForm(start[1].x, "F01")+"s )")

CwNewElement("marker") ; Create second marker


CwMarkerSet("x.type", 1) ; physical units
CwMarkerSet("y.type", 1)
CwMarkerSet("x", stop[1].X) ; Set right position
CwMarkerSet("y", stop[1].Y)
CwMarkerSet("angle", 190) ; Set right angle
CwMarkerSet("border", 0)
CwMarkerSet("text", "("+TForm(stop[1].x, "F01")+"s )")

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
28 Panel and Data-Browser

2.2.3.4 Quickview Window


2.2.3.4.1 Creating a page
· Add an additional page to the Panel as a standard dialog. Name the page "Quickview"

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Exercise: Panel pages 29

2.2.3.4.2 Creating a curve window


1. Select all (!) the measurements. Then select some random channel and drag it from its index number
into the curve window. Select the standard curve window.

2. Right-click the mouse over the cross and select the context menu item "Fill". This completely fill the
Panel with the curve window.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
30 Panel and Data-Browser

3. Now change the number of measurements selected. Then change the channels.
Result: The curve window always shows the first channel selected among all the measurement
selected. If an additional channel is selected, it is not displayed.
4. Next, in the curve window open the dialog Configuration > More waveforms...

The curve window shows placeholders which are linked via their index. You can subsequently change
the index for each entry under Adapting channel selection.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
31

3 User-defined dialogs
What are user-defined dialogs?
imc FAMOS contains an editor for creating dialog, similarly to a Panel-page in the Layout "dialog". There
is an extensive library of widgets, which even exceeds the scope of the Panel-widgets. When using the
widgets, events are triggered which can be associated with sequences. In this way, it is possible to design
a FAMOS analysis having a simple input interface. Advanced skills in imc FAMOS are not necessary to use
it.

Is it possible to compile an executable program from a dialog?


No. Dialogs are simply a operating interface attached to the FAMOS-engine. To run a dialog, you always
need a licensed FAMOS installation, which includes all function libraries used. If the dialog created is
sufficient for operation, it can also be run with imc FAMOS Runtime.

What is the difference between user-defined dialogs and Panels?


Panels can directly access data which were loaded with the Data Browser. For purposes of lab reports,
Panel-pages can be designed as report pages and either directly printed out or exported in PDF format.
User-defined dialogs can only be part of the GUI part. The user is responsible for loading data by means
of sequence functions in the background. Report composition is also only possible by means of the
Report Generator's remote control. For that reason, the Panel has completely replaced the dialog for
many users over time.

What are dialogs still good for?


Dialogs are useful, for instance, for creating input masks. These can then be called from within a Panel,
for example. Dialogs can also call other dialogs and then enable structured input of parameters or of text
entries.
Furthermore, there are some widgets in the dialog, which have not (yet) been implemented in the Panel.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
32 User-defined dialogs

3.1 Introduction to the Dialog Editor


The Dialog Editor starts in a separate window. In the imc FAMOS main window, a page for the dialog is
generated, in which all widget-events, as well as branches for the initialization and the end are entered.

Structure of Dialog Editors window

Toolbox
The toolbox contains the widgets grouped by Standard-elements (buttons, text boxes, etc.), Lists and
tables and Curve window. In the group Menu, the menu structure is set up, whose elements appear as
events in the main window.

Properties
The respective settings available for the selected widgets are listed in the Properties and are edited
there.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Event sequences for the dialog 33

3.2 Event sequences for the dialog


As soon as the Dialog Editor is started from within imc FAMOS, a new tab automatically appears in the
imc FAMOS input box . The difference from the normal input box is that on the left side of the input box,
there is a tree diagram containing practically all components which had been added in the Dialog Editor.

Structures for a dialog in the Sequence Editor

The event Init is triggered once creation of the dialog is concluded. Here, dialog elements are initialized
which are linked with FAMOS variables.
The event End is triggered upon closing the dialog by the function DlgCloseDialog(). it is the last event
triggered by the dialog. Although the dialog is then no longer visible, all dialog elements are still valid. In
this event, it is possible to delete any variables no longer required.
The event Close is triggered when the user wishes to close the assigned dialog at runtime by means of
the function DlgCloseDialog(). With this event, it is possible to have automatic validation of user inputs.
In case of input errors, the user is informed and the dialog can only be closed once all inputs are valid.
Below this, the widget's events are entered.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
34 User-defined dialogs

3.3 A first, simple dialog


Assignment: Use the Dialog Editor to create a dialog in which it is possible to open a waveform. Then,
the maximum, minimum and mean value of the waveform are to be determined,
besides the relative extrema with a 1 Volt hysteresis. The results are to be visualized for
the user in a curve window.

Procedure: 1. Create a new project for the dialogs, and use the name SimpleWaveform.
2. Start the Dialog Editor (menu item Extra : Dialog-Editor or the toolbar button ).
3. Create a dialog with the view as in fig. below. To do this, first set the title bar content
under the Properties for a dialog to "Static parameters" . Then add buttons and the
curve window from the toolbox. The symbols on the buttons are entered as part of
the properties “image” for the respective buttons.
The names of the added elements are decisive for controlling the sequence
structure. For this reason, name the buttons as follows:
BN_Load – for the Load button
BN_Calculation – for the Calculate button
CV_Curve1 – for the curve window
4. Save the dialog under the name “Simple1”
5. Now for the functionality:
Create sequences of which the sections produce the corresponding results. Toward
this end, it is possible to carry out the command lines step-by-step while making
them, in order to save work typing.

Loading the waveform


We begin by loading data. This data is then processed upon the event Calculation:
VG:FileName = DlgFileName("c:\imc\dat","dat","Select data set",0)
VG:File = FileOpenDSF(VG:FileName,0)
if VG:File > 0
VG:Count = FileObjNum?(VG:File)
VG:DataSet = FileObjName?(VG:File,1)
<VG:DataSet> = FileObjRead(VG:File,1)
VG:file = FileClose(VG:File)
VG:error = CvConfig("CV_Curve1","MaxMinMean.ccv")
CwSelectWindow("CV_Curve1")
VG:replaced = CvReplaceChannel("CV_Curve1",<VG:DataSet>,"Slope")
else ; here is where to insert error handling in case of invalid file
; BoxMessage("Loading failed",VG:FileName , "!1")
VG:Error = FileErrText?()
end
At the moment, the command CwReplace causes an error message to be posted, since the curve
window is still selected and configured.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
A first, simple dialog 35

Calculation
Here is where calculations are performed
Maximum = max(<VG:DataSet>)
Minimum = min(<VG:DataSet>)
Mean_value = Mean(<VG:DataSet>)

; Search peaks
VG:PosRelmax = xmax(hyst(<VG:DataSet>,1),-1e20)
VG:valuerelmax = value(<VG:DataSet>,VG:posrelmax)
RelativeMaxima = XYOf(VG:PosRelmax,VG:valuerelmax)

Creating a curve window and saving the CCV


After executing these lines, all data are available which are needed for creating a curve window. Now
go the Dialog-Editor and configure the curve window via "More Waveforms in Curve
Window" (context menu: "Configuration>More Waveforms...").

Click to "Topic" and go to the "Lines..." and mark the points for "RelativeMaxima" with thick dots.
Save the configuration as "MaxMinMean.ccv".
Initialization
Now we can fill out the Initialization. Here, the variables used/generated in the sequence are deleted.
This ensures that upon starting a dialog, there are no impeding values in the sequence. Also, the
previously saved configuration is loaded.
; Dialog for calculating statistical variables
; The sub-group VG for local variables is used
; If the dialog is used in conjunction with other sequences
; pay attention to potential crossover effects in the following lines
del RelativeMaxima
del maximum
del minimum
del mean_value
del VG
; for the curve window, the CCV is opened
; as a precaution
VG:error = CvConfig("CV_Curve1","MaxMinMean.ccv")
© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH
CwSelectWindow("CV_Curve1") imc FAMOS III, 12th Edition - 2017-02-15

End
36 User-defined dialogs

Result: Run the dialog and test its responses.


Remarks The dialog still has room for a few improvements. For instance, try to open another data
set, and you will find that the display is not updated.
The cause is the fixed encoding when replacing a waveform in the command
CvChannelReplace in the File Load part. In order to be able to see this, the dialogs have
error searching capabilities. These are the topic of the next exercise.

User interface for first, simple dialog

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Searching for errors in a dialog 37

3.4 Searching for errors in a dialog


In contrast to a normal sequence, a dialog does not proceed in a fixed order, but rather, the user can
influence in which order individual parts of sequences within a section can be run. For this reason, it is
also not possible to work here with a step-by-step technique for finding errors.
For finding errors in dialogs, there are two techniques available:
1. Use of breakpoints
You can set breakpoints in the sequences for a dialog, just like for normal sequences. What is
important is that neither this dialog nor the sequence calling it is called with either the F7 key or the
Start toolbar button, but by CTRL-F7 or the command Start (Debug) (see image below).

After such a breakpoint, it is possible to use Shift+F7 or the corresponding icon or command in order
to subsequently continue the dialog normally.
Assignment: Change the dialog from Chapter 2.3 so that when a new additional waveform, it will also
be displayed.

Procedure: 1. Open the dialog from the chapter above, load a file and perform a calculation. Now,
before opening another waveform, select "Interrupt (upon next next command)" from
the task bar. Now load the waveform and observe why it is not displayed as the
sequence unfolds one step at a time.

2. Next, load the waveform. imc FAMOS jumps to the first row in the event "Load data".
Now observe the sequence as it is executed step-by-step why it is not displayed.
3. The cause is indicated by the value of the variable VG:replaced, which is a zero,
although a waveform actually is to be replaced. The reason is that CwReplace is trying
to find the position "slope". However, after the last loading, this is no longer available.
4. As a remedy, repeat the loading of the curve configuration. To do this, paste the
command line VG:error = CvConfig("CV_Curve1","MaxMinMean.ccv") from
the Initialization in front of the line with CwReplace.
Save the dialog under the name "Simple2"

Result: Now each time the Load button is pressed, the loaded waveform is displayed in the curve
window.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
38 User-defined dialogs

Remarks: Two other minor issues may possibly cause problems:


1. After restarting the dialog, the Calculation button is enabled. However, pressing on
this button causes an error message to be posted. The happens all the more
frequently in complex dialogs, since in contrast to sequences they do not ensure that
the user applies the controls and actions in the desired order.
As a remedy for the case of buttons, these can be enabled or disabled; to do this, the
command DlgEnable from the kit for the dialogs/General is used.
2. If when opening waveforms you switch to a waveform featuring other quantities,
then the previously calculated quantities remain in the curve window. Here deleting
the corresponding variables would prevent this.
3. This dialog is found among the sample solutions in the same project under the name
“simple3”.

In particular when creating dialogs for other users, it is necessary to pay close attention that no errors
arise from the fact that the user has almost unlimited choice in the order in which to select list elements
or to press buttons, or to initiate other actions.
Another common source of errors in using dialog is that elements of the graphical display are renamed
after already having been assigned permanent names in the sequence part. In this case, imc FAMOS
opens a new curve window instead of updating the curve window in the dialog.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Favorites 39

4 Miscellaneous
4.1 Favorites
How is a new function group created?
· Right-click on mouse: New group
How is a function key created?
· Right-click on mouse: New entry
How do I transfer my personal favorites to a different computer?
· In the folder IMC\Bin there is a program named Xconfig.exe. This can be used to save either all or
selected imc FAMOS settings in a file. This file is then loaded by the same program to the target
computer.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
40 Miscellaneous

4.2 Entering a waveform’s Y-unit


In the Operation window with an apostrophe:
· Waveforms: “channel = ramp(0, 1, 100)* 1 ‘m’ ”
· Single value: “g= 9.80665 ‘m/s^2’”
In the Properties dialog
· Use the command “Unit?” in the Variables > Properties > Units group. This function can also be
automated in a sequence.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
File structure 41

4.3 File structure


4.3.1 Keys
Explained in detail in chapter 5.14.2 of manual "imc Software - Shared Components" > "File Assistant" >.
"File Format" > "Key structure".

4.3.2 Variable types (imc FAMOS Chapter 6.3)


· Normal waveform (Y-time)
· ComplexAP (Y1-time/Y2-time) amplitude/phase
· ComplexRI (Y1-time/Y2-time) real/imaginary
· ComplexDP (Y1-time/Y2-time) decibel/phase: Like AP, but the amplitude expressed in dB( 20*
logarithm) e.g.: db_Channel = db( fftÞnoise))
· XYmonoton (Y-X) (e.g. time-reduced data: XYMonoton= TransRec(square,2))
· XYNotMonoton (characteristic curves)
· Single value
· Text variable
· Text arrays
· Empty waveform
· Digital data (5-20)
· Groups
· A list of waveforms bundled together in a group with a common name. The advantages
are in ease of importing, processing in sequences and loading/saving. To address a
particular channel in a group, a colon is written after the group name and the channel is
selected by its index or its name:
· Groupname:channel001 or Groupname:[1]
· Exercise:
· Create three channels with the ramp function
· Group them as a group in the context menu
· Apply a function to the whole group, e.g. the sine function: sin_group = sin( group)

4.3.3 Data format for results


Menu: Options Þ Function Þ Result data type
Only pertains to the result. The internal calculation is always in 8-byte Real

4.3.4 Folders
- How can the default folders be changed?
o Extras Þ Options Þ Folders
o Within a sequence by using LDIR or better yet SetOption

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
42 Miscellaneous

4.3.5 Remote calling of a sequence


· With the parameter "/S" (capitalization is important!) e.g.
o Windows-Start Þ run "C:\imc\bin\Famos.exe /S Report1"
o report1Windows-Start Þ Run C:\imc\bin\Famos.exe /S "CreateSine 5 2 10 20 erg"
If the sequence name contains a space or if the sequence uses parameters, the invocation must be
made in quotation marks.
· Via transfer function from the curve window

4.3.6 Placeholder ?, * and #

? imc FAMOS supports the placeholder “?”. For instance, if you wish to load all waveforms from
sintest1 through sintest5, simply enter LOAD sintest?.
The placeholder “?” can be positioned anywhere, but there may only be one at a time.

* The placeholder “*” is different from “?”, which does not only stand for one letter, but for all
subsequent ones. LOAD s* loads all waveforms whose first letter is an “S”.
The placeholder “*” can be used at any position and even multiple times, e.g. LOAD *test*
It is also possible to mix the two placeholders. DELETE k?l* deletes all waveforms beginning with a
“k” and whose third letter is an “L”.

# The placeholder “#” stands for sequential numbers. THIS FUNCTION ONLY APPLIES TO SEQUENCES!
Example: Within a sequence, you perform a calculation on more than one result waveform having the
same name. Add an “#” in order to ensure that your results are not overwritten.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
Kits (brief overview) 43

4.4 Kits (brief overview)


Class counting (Enterprise edition): Various class-counting procedures
Spectral kit (Professional or higher): Spectral analysis functions for one or two input channels, such as
cross-power spectrum, frequency response.
The Kit comprises functions for spectral calculations with moving and overlapping windows.
Amplitude spectrum, Complex spectrum, power density spectrum, power spectrum, and cepstrum are
available.
For two-channel measurement data, the coherence, cross power density, standards-compliant cross-
power density and transfer function are possible.
Most of the functions are based on an FFT calculation, where the window of observation sweeps
across the input data. This, for one channel many FFTs are calculated. The individual FFTs are then
treated in accordance with the function and averaged. The windows also can overlap and produce
useful data.
For the averaging, the possibilities are linear averaging, exponential averaging (with a specified time
constant) and peak-hold functions.
The functions which return a series of results over time thus produce segmented data, in other words
a matrix. This could be, for instance, a series of 500 amplitude spectra.
Order Tracking Kit (Enterprise edition)
Function for analysis and signature analysis of rotating machinery.

Time to Stamp ASCII: File format for writing ASCII texts with time base. Þµ-Musycs( J-Bus)
· tsa_channel= TsaCreateEmpty( 0.0, 1e-3, "s")
· TsaAppendText(tsa_channel, "Alarm1", 11)
· TsaAppendText(tsa_channel, "Alarm2", 12)
Curves
· Remote control devices for editing of the curve window
Report Generator
· Remote control commands for filling out a report
File-Kit
· Functions for file and folder handling
Panels
· Remote control of panels.
Dialogs
· Remote control for user defined dialogs.
Excel
· Remote control to read and write Excel-sheets.
Video Player (ab Professional)
· Remote control for playing video files.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15
44 Miscellaneous

ASAM-ODS-Browser (Enterprise edition)


· Functions for accessing data provided by ASAM-ODS servers.
Railway Comfort Kit
· Evaluation of vibration, e.g. in accordance of UIC 513.1
Sound Kit
· Saving and playback of files via the soundcard
· Example: Conversion of Windows Question.wav to DAT, then and playback and filtering of it
SndPlayM( FiltLP( question, 0, 0, 8,2000),8)
Format Kit
· Opening of Multireg files (SIEMENS)
· Bsave: Saves data sets, texts or single values in binary format
· Msave: Saves multiple curves to a multi-column ASCII file. For legacy reasons. As of imc FAMOS4.0
easier to run with export functions.

© 2017 imc Meßsysteme GmbH, imc Test & Measurement GmbH imc FAMOS III, 12th Edition - 2017-02-15

You might also like