Pascal and MSX

Pascal compilers for the MSX

The Pascal language was named for Blaise Pascal (see picture), a French mathematician who was a pioneer in computer development history. In 1641, at the age of eighteen, Pascal constructed the first arithmetical machine, arguably the first computer. He would improve upon the instrument eight years later. In 1650, Pascal left the world of geometry and physics, and shifted his focus towards religious studies, or, as Pascal wrote, to “contemplate the greatness and the misery of man.” Pascal died in Paris on August 19, 1662.

Niklaus Wirth completed development of the original Pascal programming language in 1970. He based it upon the block structured style of the Algol programming language. There were two original goals for Pascal. According to the Pascal Standard (ISO 7185), these goals were to a) make available a language suitable for teaching programming as a systematic discipline based on fundamental concepts clearly and naturally reflected by the language, and b) to define a language whose implementations could be both reliable and efficient on then-available computers.

Pascal was used in the seventies and eighties as the computer language in programming education. It served as the main programming language to teach structured programming.Many compilers were available for all current platforms these days. The language itself is a standard now (ANSI) but also served as model used by Wirth for more advanced (modular) languages such as Modula and Oberon.

Borland produced Turbo Pascal both for CP/M and MS-DOS, version 3 was a huge success and much of the software in the eighties on small computers is written with Turbo Pascal. Alas it was not standard Pascal, instead very practical adapted to the CP/M and MS-DOS environment.
Version 3 was the last version for CP/M, on the PC many versions followed (Borland Pascal 7 was the last DOS-based) and eventually evolved to Delphi (Windows) and Kylix (Linux), and lives on in Freepascal and Lazarus with ObjectPascal. The Pascal version for MSX is much closer to the original procedural Pascal defined by Wirth.

Read this great introduction how to write GOOD programs!

Turbo Pascal may not be the only Pascal compiler running on MSX, it is the best supported one.

The untouched and not installed version(see the Pascal course in MCCM part 1!):
Turbo Pascal 3.01 for CP/M

A version of Turbo Pascal was distributed by Philips. In the package you find:

  • Turbo Pascal 8 bits MSX This version was a real Borland product, as you can see on the floppy label.
  • A book by Jeff Dunteman with demo disk “Turbo Pascal Compleet”,
No picture

Manual, Front and Back Cover

Below are scanned images of the front and back covers of the Turbo Pascal 3 manual. Back in those days the manual was the product. The floppy disk placed inside the manual cover along with the license agreement, invitation to join on CompuServe forums and other paper marketing pieces. Click on each image to display a larger version of each cover.
The manual of Turbo Pascal 3.0 (MS-DOS, CP/M-86 and CP/M/MSX-DOS) is also available, thanks to Fred Kraan

A patched and installed version
MSX-2 version of Turbo Pascal 3

Made by MCE aka Frits Hilderink including the GIOS and a PC version!
This is the official distribution placed here with permission of Frits Hilderink!
Turbo Pascal 3.3f

Slotman has made an IDE for Turbo Pascal 3.3 running on the PC (Windows). MSXPAD. You can find it here, manual is here.

And  it comes with all include files  used to make SnowFighter!

Turbo Pascal DataBASE Toolkit 1.2 , official add-on by Borland

For MS-DOS with debugger (handy crosscompiling!)
Turbo Pascal 3.01 for the PC

Untouched (and now freeware!)
Turbo Pascal 3.02 for the PC

Another Pascal compiler: Hisoft Pascal 80

Pascal development environments

Turbo Pascal out of the box is not able to use the MSX facilities. Other than MSX-Basic there are no instructions to do more than text output.

Luckily it is not too difficult to give access to all MSX secrets with socalled include files containing pieces of machinecode as INLINE statements.

Here a rich collection of powerful environments is given that allow you to do anything possible on a MSX with easy to write and understand Pascal programs.

Martijn Dekker, the author of the Turbo Pascal package MDL-LIB has given permission to publish the latest and greatest version 2.2 and declared it public domain.
Some of the enhancements are:
– .typ-, .var- and .con- filesbestanden (type-, variable- and constant declarations) are integrated in the .lib- files, avoids many includes.
– works with turbo Pascal 3.3

See the leesmij.txt in the archive MDL-LIB v2.2

Slotman has made an IDE MSXPAD for Turbo Pascal 3.3 running on the PC (Windows). You can find it here, manual is here.
Included are include files for developing games in Pascal! The very funny game Snow fighters in the Our games section (throwing snowballs) is interesting for the MSX Info pages since he included the sources in Turbo Pascal.

HansO Pascal programs

Pascal source with examples of filter programs: while copying a text file make adjustments like stripping to 7 bits or adding/removing text.

Pascal source by me of two programs: split (makes two halves of a file) and combine (glue the two halves together again) for MSX-DOS and CP/M.

CNVS and MSX12CNV

I have written programs to convert the MSX graphical screen formats back and forth to the PC.
When i wrote them it was the dark age of MS-DOS, so i used Turbo Pascal and as graphical file format PCX. It still works, even under Windows 95/98. And I finally finished MSXCNV12 to convert to screen 12 in may 1999 after working on it for 8 years!

Paintshop Pro is highly recommended to manipulate the graphics on the PC.

All sources are included. All programs are freeware. MS-DOS programs!

CNVS version 2.3 : MS-DOS program to convert MSX screen 0-8 to PCX and back including sources

This 2.3 version is a recent update (june 1999), is now in English and with a cleaner syntax.

CNVS version 2.1 : old MS-DOS program to convert MSX screen 0-8 to PCX and back in dutch only.

MSX12CNV: MS-DOS program to show or convert MSX screen 12 (in full color)

MSXCNV12: MS-DOS program to show or convert PCX on the PC to MSX screen 12 (in full color)

Quickbasic program to convert RAW file (create with Paintshop PRO) to screen 12 full color by Hans Schoormans

On request: a Windows 95/98 program to convert MSX screens to and from PCX
(actually a wrap around CNVS, MSX12CNV and MSXCNV12)

CNVSW as Windows installable program. Note the readme.txt.

PCX format description the official guide how PCX is done

INDEX

INDEX: MSX and MS-DOS programs to build a database of files on your floppies with Pascal sources

My MSX pascal include libraries

To write intelligent programs on MSX I used Turbo Pascal v3.00.

To access the MSX 1 and 2 facilities I developed Pascal libraries a long time ago. Many followers copied and enhanced those libraries but here are the original: complete with tools.
In it are functions like line, box, circle, fill figure, sprite, show text on graphics and so on

Pascal include libraries

Pascal articles

Programming in Turbo Pascal, after Basic and assembler, has been the preferred programming environment for many. Much faster in execution than Basic, much faster in development than assembler.
The magazines have paid attention to this environment with many articles, collected as far as available, here.