Not Yet Another EPICS Display Manager!?
Kay Kasemir, Xihui [email protected] [email protected]
Kobe EPICS Meeting
October 2009
2 Managed by UT-Battellefor the U.S. Department of Energy
EDM …
serves us well at the SNS– Stable
– Many deployed screens
But:
• Somewhat dated, especially the ‘edit’ part:– Fixed-size configuration panels;
pop up in unexpected places– Limited editing of shared properties for multiple widgets– Limited integration with other tools
• Keep maintaining it?– Coded in C++ for Unix, X11, Motif– Fedora dropped OpenMotif
3 Managed by UT-Battellefor the U.S. Department of Energy
Use CSS Synoptic Display (SDS)?
Good Ideas– Java, SWT (Windows, Linux GTK, Mac OS X)
– Eclipse Graphical Editor Framework (GEF)
– Generic Data Access Layer (DAL) for EPICS, Tine, Simulated PVs, …
Every widget propertycan be ‘dynamic’
“Label” with static “Text”
Label with“Text” linkedto PV
4 Managed by UT-Battellefor the U.S. Department of Energy
Are simple things simple?
• EDM: Add Text Update1) Create Text Update 2) Enter PV Name 3) Save & Run
• EDM widgets with PV connectivity: Show the PV’s value (with units) Show PV name on middle-button click Reflect PV’s severity via e.g. border color Use PV’s display limits as default range for “meter” widget etc. Indicate ‘disconnected’ state via e.g. white-out appearance
• SDS: Same accomplished via dynamic properties– ‘Text’: Link to PV’s value
– Border color: Link to PV’s severity and connection state
– Tool Tip: Show PV’s name
– Involved manual process
– “Initializers” automate this, but we couldn’t reach EDM functionality
5 Managed by UT-Battellefor the U.S. Department of Energy
Re-think Dynamic Properties
• EDM describes meaning– “Text Update” for PV, “Alarm Sensitive”
• SDS’ dynamic properties implement representation– Text = value of PV
– Border = red if value of PV’s severity is 2, yellow if …, white if severity is 3 or connection state is …
6 Managed by UT-Battellefor the U.S. Department of Energy
Concept for Best OPI, Yet (BOY) Prototype
• Best of SDSJava portabilityCSS integrationGreat GEF editing
• Best of EDMSimple things (Label, Text Update, …) are simpleConfigure the meaning, leave representation to tool
• Combined withProduction-tested PV layerPV-triggered scripts can make everything dynamic
7 Managed by UT-Battellefor the U.S. Department of Energy
Basic “Editor” Perspective
• Navigator, Outline, Palette, Properties can be rearranged
8 Managed by UT-Battellefor the U.S. Department of Energy
Adding Widgets
• Select widget on Palette– Draw outline in display or drag/drop to display
• Configure Properties– Label ‘Text’ also editable via double-click– Can configure common properties of all selected widgets
9 Managed by UT-Battellefor the U.S. Department of Energy
Editor Features (GEF)
• Context menu, keyboard shortcuts:– Copy/cut/paste/delete– Change front/back order– Full undo/redo
• Snap to grid, geometry, align, distribute
• Duplicate widgets via Alt-Drag
• Select any types of widgets,edit common properties
• Zoom, Outline view
• Snap-to-Geometry
10 Managed by UT-Battellefor the U.S. Department of Energy
PV Connectivity
1. Create“Text Update”
2. Enter “PV Name” EPICS CA, local, simulated, …
3. Save & Run
Simple things are simple:
By default, widgets use PV Metadata(units, precision, limits, …)and are sensitive to alarms
(Note use of rulers to align widgets)
11 Managed by UT-Battellefor the U.S. Department of Energy
Macros
• Macros can be defineda) In CSS preferencesb) As ‘display’ propertiesc) In actions that invoke related displays
• Use:a) $(macro_name)b) ${macro_name}
• Every property isavailable as a macro;Example: Tooltip
12 Managed by UT-Battellefor the U.S. Department of Energy
Screen Navigation• Idea: Minimize number of open screens.
• Similar to Web Browser links:– Default: Related displays replace the current display.
– Optional open in ‘tabs’ or new window
– Allow previous/next navigation over display historyDisplays in ‘Tabs’
13 Managed by UT-Battellefor the U.S. Department of Energy
Scripts…– are written in JavaScript
– can be attached to any Display or Widget
– are executed whenever one of the input PVs change
– can read/write widget properties, PVs,open dialogs, access any Java code
Example: Dynamic Visibility
14 Managed by UT-Battellefor the U.S. Department of Energy
More Script Examples
• React to operator input,possibly correct it
15 Managed by UT-Battellefor the U.S. Department of Energy
More Scripting Ideas
• Arbitrary ‘color rules’
• Animation
16 Managed by UT-Battellefor the U.S. Department of Energy
Widgets …
• So far 23 widgets– More to come– Eclipse plug-in
mechanism;add site-specificwidgets
• Arc, polygon, …– Rotation– Fill-level
• Buttons– “Are you sure?”– Password
17 Managed by UT-Battellefor the U.S. Department of Energy
Grouping Container‘Group’ in EDM:
1. Rectangle around widgets
2. Label on top of Rectangle for group name
Looks OK, hard to edit/move
Grouping Container Example:1. Create from context of
selected widgets,or drop widgets into it
2. Configure name,move,(auto-)size,even remove.
3. When movingwidgets,highlight indicatesif they’re still‘inside’ container
Optical feedback when moving widget in group
18 Managed by UT-Battellefor the U.S. Department of Energy
Linking Container
• Like EDM ‘embedded display’
• Common EDM use: ‘Tabs’1. Invisible button writes
to local PV2. Rectangle etc. show/hide
depending on value of that PV3. Embedded display shows
different file depending on PV
Plan for OPI (not yet):Designated ‘Tab’ support
19 Managed by UT-Battellefor the U.S. Department of Energy
XY Graph Widget• Chart types: Line, Scatter, Bar, Steps, Area, ...
• Five Zoom Types, Panning, Auto Scale
• Add/Remove Annotations, Undo/Redo, Take snapshot.
• Multiple axes: Linear, Log, Date/time
• Configure properties during runtime
• Generic SWT code, usable outside of CSS– Plan: Replace Data Browser’s plot
20 Managed by UT-Battellefor the U.S. Department of Energy
Transition from EDM
• Translator for basics in the works– Rectangles, Label, Text Update, Text Entry, …– Includes handling of colors
• Harder to translate:– “Tabs” simulated by invisible Message Buttons
writing to local PVs, …– Rectangles that are really meant to create a ‘Group’– Invisible related display buttons that could now be ‘actions’
attached to visible widgets
21 Managed by UT-Battellefor the U.S. Department of Energy
Summary
• Initial Demo available for download fromhttp://ics-web.sns.ornl.gov/css/products.html
• Please try it out:– Online Help:
CSS Menu Help/Help Content/CSS Applications/Display– Tutorial for first steps: See Online Help
• Send comments on issues or suggestions!