My Modula-2 System

Compilers

At first I used TopSpeed Modula-2 (Jensen and Partners International, around 1988) on MS DOS 3.0. As the Windows operating system became prevalent, I turned to XDS Modula-2 for Windows (ver 2.51 and 2.60-beta) because it had the TopSpeed extension, making it easy to switch over. Nevertheless there were a few differences in syntax between the two, but could be managed with almost no difficulty. Hereafter the term modula-2 refers to XDS modula-2.

Installation

XDS, and later Excelsior, posted installers on the web site for free. The latest files I have are as follows.

  • xds-260-beta2-win32.exe (6.8 MB, dated 2016-03-22)
  • xds-x86-251-enduser-win32.exe (6.6 MB, dated 2016-05-13)
  • tscp-x86-251-enduser-win32.exe (2.5 MB, dated 2016-03-22)
Recently I made xds file and subsequently tscp file run on my Windows 11 operating system with the destination set to \XDS260. To confirm that installation was successful I compiled and ran sample progtams.

Customizing the modula-2 system

My current directories are shown below. The system is installed at c:\XDS260. The TopSpeed extension is realized by ts*. My own working firectory is \XDS260\mod2, where project files and the resulting exe files are stored. I made subdirectories for main mod files: labmain (scientific earlier), erziehen (scientific later) general (nonscientific), office (nonscientific). I also made lablib, mylib, winlib, and science subdirectories for storing modules.

Making simply directories and files cannot be recognized by the XDS Environment. The redirection file, xc.red, must be edited so that any modification in directories may be reflected in this file.

Graphics package

hgraph** is the place where HGraph system (ver 4.1, 1986, HearLand Software) is stored. I rewote the package so that graphics output to the plotter could be intercepted to generate files in the HPGL (Hewlett-Packard Graphics Language) format. The files are subsequently retouched by CorelDraw.

Application programs

As can be guessed from the above directory structure modula-2 can deal with many problems ranging from scientific anakysis and lab automation to personal data management. The former category include solving differential equations, nonlinear least square analysis, Monte-Carlo simulations, Interfacing GPIB Add-on Boards, etc. Typical tasks of the latter category are storing and plotting of health check data and the merging of address and score data of the students.

Disadvantages

Probably the most serious disadvantage is that Japanese language cannot be dealt with.

The fact that the above-listed installers were dated 2016 and that the programs had no support from the vendor means that the debugger and help work nicely on Windows 8.

I revised HGraph many times but serious errors still remain in the 3D graphics module HGRthree. Also I sometimes encountered with mathematical functions and procedures that had to be written by me; spherical Riccati-Bessel function, Legendre function, and inverse error function, to name a few.

The smallness of the modula-2 comunity results in small-sized libraries. I sometimes had to write codes for mathematical functions such as spherical Bessel functions, Legendre functions, and inverse error function.

9-21-2023, S. Hayashi