Dual1456.htm, Dual1456.class and Engine1456.class files.

William Overington

Copyright 2000 William Overington

Here are links to the files needed to run the Dual1456 1456 applet landscape. The Dual1456 1456 applet landscape is a development of the Softboard1456 1456 applet landscape and has available the same softboard toolbar facilities as Softboard1456. The Dual1456.htm file is useable either on-line or off-line. In order to run Dual1456.htm off-line, please download to a directory of your computer the files Dual1456.htm, Dual1456.class and Engine1456.class.

Dual1456.htm

Dual1456.class

Engine1456.class

The Dual1456.htm file starts up with the look and functionality of the demo7.htm program. That is, one may click on the softboard toolbar and characters are displayed on the screen. Text in English and Esperanto may be entered. However, Dual1456 has an extra feature. If one clicks near the top left corner of the white background area, within 20 pixels of the corner, then the softboard toolbar is replaced with another softboard toolbar carrying Greek characters. One may enter one or more Greek characters and then go back to the original softboard toolbar by clicking near the top left corner of the background again. Behind the scenes two 1456 engines are being used. The Java software of the Dual1456 1456 applet landscape and the 1456 object code and data strings used in Dual1456.htm together make the two 1456 engines work together satisfactorily.

In order to run your own customized 1456 object code programs using this 1456 applet landscape, please download to a directory of your computer the files Dual1456.htm, Dual1456.class and Engine1456.class. The Engine1456.class file is exactly the same file as used with the Softboard1456.class 1456 applet landscape, so if you downloaded it to local storage with the Softboard1456.class file and you are using the same local directory for the Dual1456 1456 applet landscape, there is no need to download it again. Make a copy of Dual1456.htm with a different name and then use a text editor, such as Notepad, to edit the source code of this newly created copy of the file Dual1456.htm and then view that file in a browser. Please note that Dual1456.htm on its own already has some 1456 object code contained within it. Unlike previously introduced 1456 applet landscapes, Dual1456 is a demonstration in itself. Although it is possible that other applications of the Dual1456 1456 applet landscape may arise, the Dual1456 1456 applet landscape was designed with a particular application in mind. It thus does not have the wider generality of the 1456 applet landscapes previously introduced.

Customization is possible at two levels. The first level is the intended level of customization and does not involve any alterations to the 1456 software, just alterations to the character strings that are used to generate the display. The second level is to modify the 1456 software, either to improve the present example, for example by allowing a change of colour of the displayed text to be obtained by clicking on a key on the softboard toolbar; or by a completely new application of this 1456 applet landscape. Some notes concerning this are added later in this section. Readers simply wishing to experiment with using other character sets may safely miss out those notes if they so choose.

In order to customize the softboard toolbars, all one needs to do is to alter the values of the four strings in STRING01 through to STRING04 as desired for the softboard toolbar that is available at start up and alter the values of the four strings in STRING101 through to STRING104 as desired for the second softboard toolbar. This alteration is by changing one or more of the characters in the strings. Each character place in the string can be represented by either a single 7 bit ascii printing character or by a sequence of six ascii printing characters in the format of 'u followed by four hexadecimal characters. Each hexadecimal character may be any one of the twenty two characters 0 1 2 3 4 5 6 7 8 9 0 a b c d e f A B C D E F as desired. If entering by keying text, the lowercase letters are recommended. The uppercase facility is available to assist people who might be preparing a string by copying and pasting from some other document where the hexadecimal codes have been entered using uppercase letters. Please know that the system does not like strings with leading spaces or trailing spaces in the strings. So if you wish to have blank squares at the start of a row of a softboard toolbar, please use 'u0020 for each space and if you wish to have blank squares at the end of a row of a softboard toolbar please either use 'u0020 for each space or add an extra character such as a full stop character so that the string does not end with a space character. The 1456 software uses the first 28 characters of the strings for the softboard toolbar. Extra characters are ignored.


In order to customize the 1456 software in order to improve the demonstration or indeed to write a new application, a few matters need to be known. Firstly, Dual1456 is a special purpose 1456 applet landscape. It began as an experiment. The demo7.htm program, which is a customized application of the Softboard1456 1456 applet landscape, creates its effect by generating at start up 112 individual customized routines, one for each of the keys of the softboard toolbar. Switching to another set of characters on the softboard toolbar would require some of those routines to be modified. Thinking about it now, I suppose that each routine could be generated with an if statement built into it so that a flag could be used to choose the character set being used and each click on a character key of the softboard toolbar would look at the state of the flag and decide which of two characters to load. The flag could be an integer stored in one cell of the mi1456 array. Perhaps the system could be implemented using the Softboard1456 1456 applet landscape using just one 1456 engine.

Thinking about the 1456 engine as a component about a week ago I decided that I would like to try having two 1456 engines working in parallel, for the fun of seeing whether I could get the system to work. Now, for this particular application of two 1456 engines working together, the two 1456 engines both run the same software. This is because each of the two 1456 engines at start up generates 112 routines. Each 1456 engine generates 112 routines, yet the routines are different for the two 1456 engines as the one engine would take its character data from STRING01 through to STRING04 and the other engine would take its character data from STRING101 to STRING104. In the event that someone is preparing a different 1456 applet landscape that uses two 1456 engines, it might well be the case that provision would be made to load different software into the two 1456 engines. At the time of writing this document, I cannot think of why someone might wish to have two 1456 engines working together like that other than as an enjoyable exercise in programming it and solving the problems that arise along the way, as the two 1456 engines would need to timeshare on the host processor. However, there may well be applications where this might be useful. One such might be being able to demonstrate several applications of an individual 1456 engine without needing to close down one HTML file and start up another HTML file. Another possibility is that the one 1456 engine could be accessed by a thread at set intervals of time and the use of the two 1456 engines would help to ensure that the state of the data in either 1456 engine were not disturbed by the switching of the host processor between the servicing of user generated events and thread initiated events. It will be interesting to see whether situations where two 1456 engines are working together becomes a much used practice with a practical advantage for so doing.

The method devised for the two 1456 engines to work together is that both 1456 engines are loaded with software, in this case the same software for each processor, and are also loaded with strings, in this case, the first processor is loaded with STRING01 through to STRING09, if they are used, as ms1456[1] to ms1456[9] and the second processor is loaded with STRING101 through to STRING104, if they are used, as ms1456[1] to ms1456[4].

In the Dual1456 1456 applet landscape the first engine is called firefly and the second engine is called northstar. Once the software and strings are loaded and the 1456 applet landscape has carried out its internal setting up of fonts and so on, the firefly engine is made to execute the 1456 object code starting at its label 1 entry point, which code should not include any software interrupts. When firefly has completed this process, the northstar engine is made to execute the 1456 object code starting at its label 1 entry point, which code should not include any software interrupts. The firefly engine is then made to execute the code at its label 2 entry point, which may include software interrupts. The firefly engine is thus in use. When, if ever, the user decides to switch to using the northstar engine, then, as part of the switching process, after the copying across of common variable data as will be explained later, the northstar engine is made to obey the 1456 object code at its label 2 entry point. Upon the user returning back to using the firefly engine, if indeed he or she ever decides to do so, after the transfer of common variable data, the firefly engine is made to obey the 1456 object code at its label 2 entry point. Thus it continues, at each swapping of processor, the common data is copied across and the 1456 object code at label 2 of the processor to become used is obeyed.

The experimenting with a dual processor showed the need to transfer information from one processor to the other. I achieved this by introducing a parameter in the HTML file called COMMON which has as its value a string of text in a specially devised minilanguage. This minilanguage consists of a sequence of items of any one of four formats, namely an integer and a letter d, an integer and a letter i, an integer and a letter c, an integer and a letter s. This permits the transfer of a double, an integer, a character or a string as desired. In this 1456 applet landscape the copying is in both directions, so the effect is as if the designated data items are not in the individual engines but in a common area of data storage. In fact, separate data storage space is used for each process, but the copying across effect controlled by the use of the minilanguage allows one to think of them as being in a common storage area. Please know that switching from one processor to another can only happen by control from the 1456 applet landscape, so the running of 1456 software in the 1456 engine will have stopped in an orderly manner prior to such switching taking place. In the Dual1456.htm file the following is used.

<param name="COMMON" value="13i14i17s">

This means that integers 13 and 14 and string 17 are copied from one processor to the other processor whenever a change of processor is made. Copying is from the processor that is just finishing processing to the processor that is just about to start processing.

This particular dual engine system was produced to achieve a desired result and also to have some fun in experimenting with a dual engine system.


It is hoped that readers may wish to try producing their own demonstrations.

Readers are invited to send feedback by email. Please email the author to send details of usage, stating which type of computer is being used. In particular, I have only tried this on two PCs and would appreciate knowing how the system works on other platforms.

1456 object code

Copyright 2000 William Overington