VISUAL's main program, runnig on a local computer, acquires measurement and state information from the controlling PLC and/or other measuring devices via serial connections or ethernet. This data is fed into certain locations of a spreadsheet. The spreadsheet stores the most recent data and performs calculations which are mostly scaling and limit comparision operations. To display this data and allow interaction with the machine, a second program runs on the same or a second computer, communicating with the first. It displays the data in graphical pages containing display elements and control widgets.
I shall call the second program HMI(human machine interface) viewer. I think it's operation is best shown by the HMI demo screen. The first mentioned program consists of the main application and two sets of loadable modules. The first kind of modules are used to interface to a specific PLC type (PLC drivers). The second kind of modules I will call data recorders or "recorders" for short. A recorder stores data to a nonvolatile storage whenever the data changes or at regular times. The rest of the main program consists of the spreadsheet management and an editor/viewer component to create and modify the spreadsheets.
Why a spreadsheet? The spreadsheet itself is a well known concept for office calculation programs. It provides an easy aproach to creating, editing testing and debugging of formulas. The advantage over other concepts for similar applications, which may use a database, instruction lists and compiler like development tools is that you see the effect of modifications on the fly.
Data loggers will record data in different forms for documentation or later evaluation. One type of recorder writes the actual value from one spreadsheet coordinate (cell) to a corresponding binary file in consecutive order. This is usefull to store large amounts of data in order to display them in trendgraphs, like paper based data recorders do. A second recorder will store data from different sources in a text file, the values embedded in some text. This will serve for alarm message history or protocol printing. A third recorder module may take data from diffferent cells and store them into a database.
The Web Viewer
Currently there is a viewer implemented as a JAVA applet. It connects to the server module of the main application, fetches the required data and displys it. The changes in values resulting from user interaction are forwarded over the same connection. The viewer applet takes the definitions of dynamic elements from its parameters. HTML pages which embed this applet can be generated using PHP or other CGI programs which provide parameters according to the machine name or limits given in recipes in a database. Page changes can either be effected by links in the embedding HTML or by dynamic elements in the applet itself. Thus you might access a detailed page by clicking on a symbol in an overview page. The JAVA viewer is easily extensible by providing new classes. At the beginning of each value tag, a class name is given. This is evaluated using JAVA's class for name. Write your own classes if you need special indicator elements.