HiSoft Pascal Primer cover: a square, a triangle and a circle drawn and filled by a HiSoft Pascal program on the Tatung Einstein
← Back to Courses
module
2

Setting Up

Introduction

You set up MAME and the Einstein ROM in the Turbo course, and they stay as they are. The only new piece is a disc. By the end of this section you will have the Einstein running from it, and you will have met the compiler and the editor - two separate programs, where Turbo had one.

If You Have A Real Einstein

Put the primer's disc image on whatever you use to give your Einstein disc images, start the machine with it in drive 0, and when you have the 0: prompt, pick this section up at What Is On The Disc. Lines beginning "In MAME" are not for you.

The Disc

Download the HiSoft Pascal Primer disc, hisoftpascal.mfi, from this site, and put it beside the Turbo course's disc - ~/einstein/ if you followed the Turbo course exactly.

It is an .mfi for the same reason the Turbo course's disc was: MAME will not write to a .dsk, and everything you type is going to be saved to this disc.

Starting The Machine

The same command as for the Turbo course, with the new disc's name:

On macOS, in Terminal:

mame -rompath ~/roms einstein -flop1 ~/einstein/hisoftpascal.mfi -window

On Windows, in a Command Prompt in MAME's folder:

mame.exe -rompath roms einstein -flop1 hisoftpascal.mfi -window

The Einstein boots from the disc:

           ***  EINSTEIN  ***

TATUNG/XtalDOS 1.31        (C) 1983 1984

No File
0:

The DOS line is not quite the Turbo disc's (DRC and 1985 there): this is the DOS the HiSoft disc came with. It behaves the same. No File is there every time, as it was on the Turbo disc, and means nothing.

What Is On The Disc

At the 0: prompt, type DIR and press ENTER:

0: HPEIN   .COM : XBAS    .COM
0: ASK     .ASC : BOX     .ASC
0: COUNT   .ASC : DICE    .ASC
0: FACE    .ASC : FIRST   .ASC
0: HANOI   .ASC : MOVER   .ASC
0: NAMES   .ASC : NOTES   .ASC
0: NUMBERS .ASC : PICTURE .ASC
0: SCALE   .ASC : SHELF   .ASC
0: SHOW    .ASC : STACK   .ASC
0: WORDS   .ASC
68k Size, 120k Free, 190k Total

HPEIN.COM is HiSoft Pascal. XBAS.COM is the Einstein's own BASIC, which you will use as the editor. The .ASC files are the programs from this primer's sections, ready typed - Appendix III lists them. Type them yourself as you go; they are there for when a listing will not work and you want to compare.

Wait for the 0: to come back before you type the next thing. While the disc is being read, the Einstein does not take in what you type: a command typed too soon arrives with its first letters missing.

The Compiler

Type:

HPEIN

After a moment:

Malformed Command Line
0:

That is HiSoft Pascal - and all it has to say without a program to compile. There is no menu and no editor waiting behind it. S4 gives it a program.

The Editor

Type:

XBAS

and the screen clears to:

TATUNG/Xtal BASIC 4.2     (C) 1983 1984
Size:  43324
Ready

This is the BASIC every Einstein came with. You will not write any BASIC in it: you will type your Pascal into it, because it is good at keeping numbered lines and saving them to a disc. S3 shows how.

To go back to the 0: prompt, type:

DOS

The Code

No Pascal yet. The whole of this section, as one session:

DIR
HPEIN
XBAS
DOS

Starting from

A fresh start of the machine with the primer's disc.

What you should see

The directory, Malformed Command Line, XBAS's sign-on, and the 0: prompt again.

When It Goes Wrong

SymptomCause
No File after a commandThe command was mistyped, or typed before the last one had finished and lost its first letters. Wait for 0:, then type it again.
The DOS line says DRC ... 1985That is the Turbo course's disc. Start MAME again with hisoftpascal.mfi.
Files you saved are gone after a restartThe disc was a .dsk. Use the .mfi.

Summary

The primer's disc boots into the DOS, with HPEIN (the compiler) and XBAS (the editor) on it. HPEIN alone only says Malformed Command Line; XBAS starts with Ready, and DOS leaves it. Wait for 0: before typing the next command.

Next

S3, Writing A Program In XBAS - Pascal as numbered lines, and saving it where the compiler can find it.

Get the Newsletter

New guides, disk images and community finds, roughly once a quarter. No spam, we promise, this isn't Tatung's marketing department.
Your subscription could not be saved. Please try again.
Your subscription has been successful.

Newsletter

Subscribe to our newsletter and stay updated.