Experimental Physics and Industrial Control System
Brian McAllister wrote:
Matthias -
Some questions your pages don't seem to address:
First of all I have to thank Brian for the questions.
It's always the same story - the developer clearly knows what he is describing
and nobody understands him.
We'll clearly have to add a chapter with the answers to your questions.
In general there are several presentations on the Web which should give some
hints why we started this development:
An XML Driven
Graphical User Interface and Application Management
http://www.slac.stanford.edu/econf/C011127/THCT005.pdf
http://www-mks.desy.de/documents/Conferences/ICALEPCS-2001/JoiMint-2001-11-28-II.ppt
JoiMint update during EPICS workshop 2002 @ JLAB
http://www.jlab.org/intralab/calendar/archive02/epics/talks/clausen3.pdf
Here's a first attempt to answer them:
1) Why would a typical EPICS (or other) site want to use this ?
Maybe you find your own answer after reading and testing JoiMint
What are the advantages/disadvantages versus other tools,
such as MEDM ?
First of all I think that we are in a transition phase of moving from X-Windows
towards Java based applications.
Some candidates are already known: VDCT, the Java cmlog browser, Java probe.
Some are available as prototypes: JoiMint - others?
Some are announced: channel archive viewer (by Chris)
So JoiMint is a first attempt to create a general tool to display life data
from your equipment. But it is more...
Over the next weeks to come we will hopefully finish the implementation of
all existing dm2k widgets. This would mean - you can displays anything you
used to display on dm2k also on JoiMint. In addition we added JoiCalc which
is also known from EDM - the online calculation like the EPICS calc record.
What do we want to achieve?
- Another display tool?
Besides all the Java beans implementations JoiMint is implemented to give
you the same freedom in graphics development like medm, dm2k or EDM give
you. You do not have to write a single line of code. No 'C' and X-Windows
code for MEDM... and no Java code for JoiMint. This is a main difference
from the beans implementations where you still need a programming environment
to program you beans applications!
The advantage of the A-Beans though is that they already connect to the underlying
control system. In the Cosylab approach they use graphic beans and network
beans this eliminates the control system specific beans because you can replace
the network beans to communicate with other control systems. But - you still
need to program your specific application and if you want to modify your
application you need the programming environment too.
In the JoiMint approach we keep the idea of configuring your graphic. The
configuration of your graphic resides in a XML file. This is ASCII text which
can be altered with a text editor. But you do not have to. JoiMint only runs
in the runtime mode. You can create/ edit your graphics online.
And you add more to the standard graphic tools functionality:
Connect to control systems:
JoiMint allows to talk to several underlying control systems.
We already implemented the DESY TINE protocol.
Also EPICS channel access is implemented.
Another DESY/ TINE flavor for transient recorder data is on the way.
Thus -> JoiMint is not EPICS specific! We tried to make it as flexible
as possible for any underlying protocol. Joimint doesn't know anything about
record.field or device/property any property displayed is an individual entry
in the registry of JoiMint (as an ASCII string). If the value of the the
channel/device/property whatever it represents changes, the graphic objects
which have subscribed or registered for that 'string' will get an update
with the new value. The value itself is an object which as a default is a
string. The string is a single value or a string containing an array of values.
This way bits floats waveforms or strings can be forwarded from the control
system through the registry to the graphic elements waiting to be updated.
The idea for this approach was designed during my stay at SLAC where we looked
to a tool to connect to their CORBA/AIDA data as well as to native EPICS
data.
Poll / Push approach
An additional requirement was not only to poll data from the graphic application
but also to push data from outside.
For JoiMint this means that JoiMint has implemented several scantimes (like
in an EPICS IOC) and also allows to subscribe/ monitor to channels. In both
cases JoiMint is the active part of this communication. The initial connection
to the devices is performed by JoiMint. But - JoiMint also accepts an outside
request to display another graphic ( you can send a graphic config file to
JoiMint - now only from the DIXI server) and you can send a command to JoiMint
to perform any other action you have implemented as a method in JoiMint.
I.e. it's already possible to change the value of any property of a graphic
object from outside. This way an object could change it's color, position,
size controlled by commands(no process variables) from outside.
Also this idea was designed because it should be possible to communicate
between a server based application and JoiMint. I.e. you send a command to
an application on your control system's server. The application will send
back a command (i.e. a new graphic) and continue to communicate with your
JoiMint graphic by sending additional commands controlling the objects of
the previously loaded graphic. JoiMint will just perform as a transmitter
between the outside application and the graphic objects it displays.
The all graphic properties control approach
Known from the Java beans - you can control/ change values of the properties
of the graphic objects. Now this is not new, unless you can do this online
and you can assign devicenames (or EPICS records) to each property.
If you start JoiMint and have a look at the Help->Samples->Position
and Shapes example you will find out that you can alter x, y, with and height
of the graphic object on the screen. Move the mouse over the numbers on the
graphic and you will see the tip text displaying the pseudo device names
like NEW|x, NEW|y, NEW|height and NEW|width. In this case NEW is the pseudo
data source name and x,y,width and height are device names of that pseudo
data source. All these device names can be modified in the registry (local
in JoiMint). So the slider will change the value of NEW|x. To display the
value of this device name we use the text update which displays NEW|x. Use
the right mouse button over the text field select transfor. Now you can move
this graphic element over the display.
Now right click again and select properties. Go to the main window. In the
property window you will find that the property 'Value' is connected to the
deviceName NEW|x. The behavior is 'dynamic', this means that the displayed
value is not static, but the value is updated whenever the value of NEW|x
changes in the registry. Now back to the slider which is changing the value
of NEW|x: Right mouse click -> properties and you'll see that the value
of the slider is connected to the same deviceName - but - it's active! The
slider is the one writing to the registry since it's active.
Now it's easy to guess how the box is moving around?
Right click on the box -> Properties. Have a look at the deviceName for
the x property. The deviceName is NEW|x and the behaviour is dynamic. Also
the x property of the box is being updated from the registry whenever you
change the value in the registry by the slider.
Now - what will happen if you change the property y of the slider by the
value of the slider???
Give it a try!
Change the behavior of the y property to dynamic.(double click on the string
static)
Change the deviceName:
- Double click on the empty field
- Since NEW is a pseudo data source you can not select it from the known
ones - just type it in.
- On the right hand side type in x. The result will be NEW|x the '|' will
be added automatically.
- Now press return - or click on another field.
Your done.
Now move the slider...
Sorry the slider is gone somewhere - but you learned the lession how to connect
graphic objects to names in the registry.
Since we used a pseudo data source there will be no attempt to connect to
'real' data from your control system. If you used one of the existing data
sources the data would be taken from there depending on the access type you
selected -> see the scan time property.
Have a try with the data source 'LOCAL' and click on the [...] button.
The built in name space browser
The built in name space browser allows you to select a device name from a
list of the device names (of a specific data source). You access the name
space browser by pressing the [...] button in the field of the deviceName
column.
This has also been implemented for EPICS. In this case we use flat files
to display projects, the related IOC's, the records in the IOC's and the
record's fields. Which leads to a four column name space browser.Other control
systems (like DESY/TINE) provide access to their name server through their
native protocol. This way we've got a name space browser for TINE too. (others
will follow)
2) The overall implementation architecture is unclear.
Where do the various components of the system reside ?
I would like to refer to the 3rd page of the EPICS presentation JoiMint update
-> 'Basics'.
Please have a look at it. All you see there is part of the JoiMint application.
On the left:
- Operator Log is a class which connects to our Oracle database and allows
online operator log entries
(not part of the http version)
- Mail: Send mail directly from JoiMint (not working from http-version)
- VDCT: Start VDCT from JoiMint
On the bottom:
- Connect as many data sources to JoiMint as you like.
An abstract base class helps you to implement them.
- A special datasource type is the http datasource.
Specify a lot of data sources which talk XML over http to a DIXI-type server.
This is the basis to get data from your control system without being on site.
Check out the display from: Help-> Samples-> Weather at DESY.
You'll get actual weather data through the DIXI server from our local IOC
at DESY.
This way DIXI is a server on an http port talking XML with JoiMint clients.
It also is a channel access client which fetches the data from EPICS.
Is the Core Registry an application on a server, to which clients
connect ?
As mentioned above the registry is part of JoiMint. It's implemented as a
Java class. The core is a hash table keeping the device names as an index
and the graphic objects as objects to the indexing device names.
One on each client system ? One for each client ? Part of the client ?
What happens if multiple clients are run on the same system, by
different users ?
You can start as many JoiMint applications on a system as you like.
Access security issues are treated by channel access security if you use
JoiMint with the direct channel access JCA classes. ( see HTTP/ DIXI access
as a different approach)
Since there's no native channel access implementation for channel access
we cannot use WebStart together with channel access. WebStart only offers
the XML/DIXI data access which give you the same functionality but at slower
speed.
JoiMint is also an HTTP server - does it implement access controls
and other security features ?
The built in http-server was ment to be used as a management tool.
-> Ask JoiMint which channels are currently on display and other statistic
information. It's not part of the standard distribution any more
3) What is involved in installing at a new site ?
Installation on a server ?
Installation on client machines ?
Installation for each user ?
If you use WebStart you need a DIXI serve to talk to.
Install a DIXI server on your local control net. Open a port for the http/XML
protocol to the outside and you can use JoiMint from outside of your fire
walls to run all your dm2k graphics.
We have a adl2xml converter program which converts our dm2k graphics into
JoiMint graphics.
I have the full directory tree of our EPICS graphics on my home PC. Either
I can run JoiMint from WebStart or I run the native version with channel
access support to see what's going on at DESY. Native channel access runs
through our VPN connection. In case I have no VPN connection available the
quickest way is to start the WebStart version.
==> This is the main use of JoiMint currently. To be able to get the full
information about the control system from remote. We are on call in a round
robin fashion. Therefore we implemented also the access to the operator log
book directly into JoiMint. The active (write) access is still restricted
to native channel access and thus a VPN connection.
A user for a beam line would probably only have to install WebStart and call
up JoiMint this way.
A copy of the graphic configuration files should be available on the local
machine ( any machine where WebStart works). The files could be also available
through the web server. JoiMint also supports the access to config files
with the URL access method.
So the answer is the remote user will only need WebStart. Everything else
can be remote.
The local and the remote operator will need the native version and start
it locally.
Here you have to install the necessary channel access files into C.\WINNT\system32\
like
JCA.dll, ca.dll, com.dll and caRepeater.exe
If you are remote you'll need full access to your network (VPN will help)
4) What are the practical differences between the various versions
(HTTP, Full, Light-HTTP) ?
How do we choose which one to install ?
We should restrict ourselves to the http and the full version. (as described
above)
5) Can you describe the architecture, implementation and usage in terms
comprehensible by those of us with little or no knowledge of Java
or XML ?
If you want to 'just use' JoiMint as is.
You do not have to know anything about Java or XML.
If you want to add a data source or a new graphic, you have to know Java.
If you want to modify the DIXI protocol you'll need to know XML (a little).
The configuration of JoiMint graphics is created by the graphic objects themselves.
You do not have to know how it works. Even if you add new ones.
6) Do I need to learn Java/XML to make full use of JoiMint ?
This leads me to the last important argument for JoiMint: it's extensibility.
Let's have a look at some code - sorry - maybe the length of the code is
argument enough...
This is the implementation of a JoiCircle graphic element. As you can see
it is using the implementation of the
symantec.itools.awt.shape.Circle();
The rest of the code is enough to make the symantec.itools.awt.shape.Circle();
circle a JoiCircle.
import java.awt.Color;
public class JoiCircle extends VisibleObj implements LoadableObject
{
symantec.itools.awt.shape.Circle c;
final static int DEFAULT_WIDTH = 100;
final static int DEFAULT_HEIGHT = 100;
public static SourceInfo info = new SourceInfo("Dmitrovski Alexei","0.5",
"22.03.2002");
JoiCircle(ObjContainerFrame parentFrame){
super(parentFrame);
c = new symantec.itools.awt.shape.Circle();
add(c);
setDefaultSize(DEFAULT_WIDTH, DEFAULT_HEIGHT);
MainFrame.propertyTableShow(this, false);
}
public void setOpaque(String so){
try {c.setFillMode((new Boolean(so)).booleanValue());}
catch(Exception e){MainFrame.errlog("Error: "+joiGetName()+" - setOpaque(boolean)");
}
}
public void setBackground(int r, int g, int b){
try {c.setFillColor(new Color(r,g,b));}
catch(Exception e){MainFrame.errlog("Error: "+joiGetName()+" - setBackground(Color)");
}
}
public void setSize(int width, int height)
{
super.setSize(width,width);
c.setBounds(5,5,width-10,width-10);
}
}
The only additional implementation is the entry in the configuration file:
...
<section>
<caption>Shapes</caption>
<element>JoiLine</element>
<element>JoiHorizontalLine</element>
<element>JoiVerticalLine</element>
<element>JoiCircle</element>
<element>JoiEllipse</element>
<element>JoiRectangle</element>
<element>JoiPolygon</element>
<element>JoiArc</element>
</section>
....
If you add a new graphic element:
- Create JoiYourElement.java -> create class file
- Add <element>JoiYourElement</element>
You're done.
I call this easy...
It may not be an argument for you - but adding another data source is nearly
as easy.
Well - this should be enough before Christmas.
Maybe you found your reason to start with JoiMint?
If yes - I am looking forward to many more email from you asking all the
questions others might not want to ask. I am more than happy to answer them.
Take care!
Matthias
- References:
- Re: some JOImint for xmas Brian McAllister
- Navigate by Date:
- Prev:
Re: tnetDev and missing hardware Matthieu Bec
- Next:
Electronic scale scale
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
<2002>
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
- Navigate by Thread:
- Prev:
Re: some JOImint for xmas Brian McAllister
- Next:
EPICS base R3.14.1 Marty Kraimer
- Index:
1994
1995
1996
1997
1998
1999
2000
2001
<2002>
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025