C1 Pascal

Anything QL Software or Programming Related.
User avatar
dilwyn
Mr QL
Posts: 1322
Joined: Wed Dec 01, 2010 10:39 pm
Location: Wales
Contact:

C1 Pascal

Postby dilwyn » Fri Apr 13, 2018 4:42 pm

Has anyone managed to use the Computer One Pascal from my website successfully on QPC2?

It seems to unzip OK, but someone has indicated that it might not run OK, in particular a problem with the file called "pfile". The symptons are that the main menu appears incomplete and cursor won't move.

I don't know anything about Pascal so I have to ask for help on this one.


Dilwyn
All things QL: see www.dilwyn.me.uk
User avatar
tofro
QL Wafer Drive
Posts: 1377
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: C1 Pascal

Postby tofro » Fri Apr 13, 2018 5:48 pm

Dilwyn,

C1 Pascal wants a 100% identical memory layout as that of an original QL - Otherwise, it won't run.

It is also not compatible with the pointer interface - It asks for input in the menu window but doesn't display a cursor, so you can't <CTRL>-C into it.

I once tried to patch it but decided it's not worth the hassle, as we have much better Pascal compilers freely available (e.g. Prospero) for the QL now - Even if it has a nice menu environment, something you could call the beginning of an IDE.

In case someone wants to patch it: It's not exactly an easy task, as it loads a main module (as a basic extension) and then dynamically loads the editor and compiler modules afterwards.

Tobias


User avatar
Dave
SandySuperQDave
Posts: 2001
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: C1 Pascal

Postby Dave » Fri Apr 13, 2018 5:57 pm

Are C1 PASCAL and Metacomco Pascal (with the ROM dongle) comparable?


User avatar
tofro
QL Wafer Drive
Posts: 1377
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: C1 Pascal

Postby tofro » Fri Apr 13, 2018 6:30 pm

Dave wrote:Are C1 PASCAL and Metacomco Pascal (with the ROM dongle) comparable?


From a language view, yes - All tree implement a somewhat standard Pascal with similar language features, although the QL-specific implementations differ a bit.

The main difference is that C1 Pascal is not what I would call a true compiler - It compiles to intermediate code and uses a virtual machine implementation to run that intermediate code - Somewhat like what Java does nowadays. You can produce stand-alone programs, though, in this case, the compiler binds the runtime environment into your executable.

Another difference is that C1 Pascal comes with a menu-driven development environment. You can edit, compile and run Pascal programs from one single program, something you would first need to set up with the other compilers.

Opposed to that, both Metacomco and Prospero compilers produce real 68k machine code in Sinclair relocatable file format, so you can combine Pascal and assembler (or, whatever) code using the linkers. Even if both of the compilers came with a ROM originally, the main differences between Metacomco and Prospero is that M uses the ROM for copyright protection only (and has thus part of the compiler in there), while P has put the runtime library for both Pascal and Fortran into the ROM. P does, however, come with a distributable runtime library in a file - But the compiler wouldn't run with that.

Tobias


swensont
Forum Moderator
Posts: 120
Joined: Tue Dec 06, 2011 3:30 am
Location: SF Bay Area
Contact:

Re: C1 Pascal

Postby swensont » Fri Apr 13, 2018 6:51 pm

Dilwyn,

I've got C1 Pascal to run on Q-emulator. I don't think I've gotten it work on UQLX. C1 Pascal does have a nice front end for editing and compiling, but it is a bit limiting. For Pascal, I think I'd stick with Prospero ProPascal. IIRC I got it working with UQLX. I did some write ups on this in SMSQzine.

Tim


User avatar
tofro
QL Wafer Drive
Posts: 1377
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: C1 Pascal

Postby tofro » Fri Apr 13, 2018 7:08 pm

Here's another thread where I described how to create a Prospero Pascal programming environment for modern SMSQ/E computers using C68 make:

viewtopic.php?f=3&t=1838

Tobias



Return to “Software & Programming”

Who is online

Users browsing this forum: No registered users and 1 guest