Page 2 of 8

Re: Pascal for ZX81

Posted: Mon Feb 08, 2021 9:12 pm
by jdfan1000
David Solly (who wrote about using Hi-Soft Pascal on his 2068 for some newsletters) has said he has a ZX81/1000 Pascal in storage, possibly with a manual. He's looking for it and will scan for me to upload to archive.org.

Re: Pascal for ZX81

Posted: Mon Feb 08, 2021 10:23 pm
by mrtinb
Wow that sounds great.

I’ve found out a little by try and error.

In Partial Pascal:
  • Select 1 for editor
  • The only three-letter token I could get to work was PPP
  • Then hit Newline, and you are in the editor
  • You can exit the editor with Shift-G
  • If you renter the editor, there is only the first line

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 5:39 pm
by siggi
I have a manual of partial PACSAL (a copy of copy of a horrible printout by a dot-matrix printer, nothing usable for OCR :( ).
I also have patched that PASCAL (long time ago!!) to use MEFISDOS instead of tape for program development.

The usual workflow is: edit PASCAL source (in ZX81 memory) and compile: output of compiler goes to tape (after patch: into a MEFISDOS file).
Load compiled code from tape and run it (save edited code before that!!!).

The 3 letter indicates, where standard-IO of PASCAL goes to: first param is input, second output, third printer.
Output usually goes to console or printer, input is usually coming from console or tape.

If necessary, I can dig out the paper manual ...

Siggi

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 5:47 pm
by mrtinb
Please do so. We have been searching for it. The program is useless without it.

Do you have possibility to scan it?

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 6:22 pm
by siggi
Ok, I will try ..

About standard IO:
N is (afaik) Nothing:
if you enter T for input of the editor, it reads existing input from tape (load source from tape)
if your enter C for editor, you can type in (from console) source text into editor
if you enter T for output of the editor, it saves source code to tape: If you select P, it prints out text

If you enter N as output of the compiler, it writes to nothing (syntax check only)
If you enter T as output, it saves compiled code on tape.
If you enter C (console) for input, you can enter source code directly into the compiler ;)

if you run a compiled program, the 3 letters define its own "input" (console, tape, nothing) or "output" (tape, console, printer, nothing) or "printer" (nothing, tape, real printer, console).

Siggi

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 6:38 pm
by siggi

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 8:42 pm
by siggi
Here it is: hard to read, but better than NIL ;)
Semper-Partial-Pascal-Manual.zip
(18.09 MiB) Downloaded 233 times
Have fun
Siggi

PS. Is any page missing?

Re: Pascal for ZX81

Posted: Tue Feb 09, 2021 8:43 pm
by mrtinb
Wow! Thank you so much!!!!

Re: Pascal for ZX81

Posted: Tue Feb 16, 2021 12:39 pm
by mrtinb
jdfan1000 wrote: Mon Feb 08, 2021 9:12 pm David Solly (who wrote about using Hi-Soft Pascal on his 2068 for some newsletters) has said he has a ZX81/1000 Pascal in storage, possibly with a manual. He's looking for it and will scan for me to upload to archive.org.
It is great that Siggi found a scan. However jdfan1000, if you can find a better scan, as Siggi's version is unreadable several places.

Siggi! It's great you found this. I've been coding Pascal all weekend in EightyOne. Thank you for your article about patching for MEFISDOS. I'm thinking about a patch where memory 32-64k could be storage, and then exit pascal to save it to p-files. I currently use EightyOne, as I don't have a taperecorder, or a device capable of MEFISDOS.

Re: Pascal for ZX81

Posted: Sat Feb 20, 2021 1:59 pm
by mrtinb
Since I got hold of the manual I've used the weekends to play with and investigate Partial Pascal. I wondered if the object code generated with Partial Pascal was machine code with calls to a Pascal library, or tokens that needed an interpreter.

The below listing contains 3 prints:
  • First is output from a program I've made in Partial Pascal. The program dumps the content of a file as hex output. Here it is run with the object code of a small example program shown just below. (Ignore the last byte, as it comes from a small bug in my program.)
  • Secondly there is the source for the little example program, when it was run through the compiler. It displays that the generated object code is 42 bytes. But if we count the bytes of the object file above, we have 66 bytes. So some of the bytes must be header information and not the program.
  • Thirdly I entered the object code bytes into a disassembler, to see if that made any sense when comparing it to the source.
When I look at the bytes in the disassembler, it doesn't make any sense as code. So my conclusion is, that Partial Pascal generates some token bytes, that runs through an interpreter. So unfortunately Partial Pascal does not compile to machine language but just creates a compact code for an interpreter.

Any thoughts?

Image