Welcome, Guest. Please login or register.

Author Topic: Pascal Users  (Read 7539 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline Nosferax

  • Newbie
  • *
  • Join Date: Aug 2005
  • Posts: 7
    • Show only replies by Nosferax
Re: Pascal Users
« Reply #14 on: May 01, 2015, 08:03:53 PM »
Quote from: Thomas Richter;786009
I used the PCQ compiler on the Amiga for quite some time and did some Pascal here and then (also see Gfx4PCQ, on Aminet, which is a nice graphic support library for PCQ).  Well, Pascal was designed as a teaching language, allowing a single-pass compiler, that grew larger and more successful than its inventor originally intended (Wirth). Interestingly, his languages that tried to connect to this success and tried to provide functions for more professional programming were much less successful (Modula, Oberon).  The good part is: It is a very clean, very strict, and very static language. In a sense, it is a very "German" language (sorry, Wirth is swiss, but I guess you get the idea), compared to the very pragmatic "American" language "C".  If something is against the Pascal design, you cannot do it in Pascal. If something is against the C design, there is always a way to do what you want, even though it looks dirty and becomes a mess. It's much easier to create a mess in C than it is in Pascal, but it's much easier to get something done in C "quick and dirty" compared to Pascal.  It is, in its design, a bit outdated for today's requirements, some of which were addressed by later language extensions. For example, the original Pascal had no "include" support (TurboPascal added this, and it is a very standard extension), had no String support (only static "Array of Character", though String is a very popular extension offered by many if not all implementations) and no modulo support, and no object orientation (Delphi added this).  It is a nice tool for learning structured programming, but probably run out of fashion as it lacks some important modern features. Object orientation is closer to state of the art today, and this is why today python or java is tought instead. Nevertheless, Pascal was a milestone in language design.


Turbo Pascal 7 added object, not Delphi. Delphi came later.
 

Offline kamelito

Re: Pascal Users
« Reply #15 on: May 01, 2015, 08:34:16 PM »
What would be nice if that Pascal programmers converts these tools to Amiga so porting Z80  source code to Amiga would be simpler.

Kamelito
http://files.programmersheaven.com/ASM/68000/z80conv/
 

Offline aGGreSSor

  • Newbie
  • *
  • Join Date: Nov 2009
  • Posts: 34
    • Show only replies by aGGreSSor
Re: Pascal Users
« Reply #16 on: May 01, 2015, 09:32:10 PM »
Here's the my slow flame/plasma on HiSpeed Pascal

Code: [Select]
{ Flame.pas ; HiSpeedPascal Amiga/TP 7.0 compatibly (c) aGGreSSor, 30-Jun-00 }

program Flame;
  uses Crt,Graph;
   var GrDriver,GrMode,x,y,n,m,i,r: integer;
         A: real;
         CTab: array [0..10,0..50] of integer;
         
procedure Clear_Tab;
  begin
   FOR x:=0 TO 50 DO
    FOR y:=0 TO 10 DO
     CTab [x,y]:=0;
    end;
   
procedure RND_Tab;
  begin
   y:=10; Randomize;
    FOR n:=0 TO 50 DO
     begin
      r:=Random(5);
      CTab[n,y]:=r;
     end;
  end;
 
procedure Calc_Tab;
  begin
   FOR y:=1 TO 9 DO
    begin
     FOR x:=1 TO 49 DO
      begin
       A:=Int((CTab[x+1,y+1]+CTab[x-1,y+1])/2);
       CTab[x,y]:=Trunc(A);
     end;
    end;
  end;
 
procedure Print_Tab;
  begin
   FOR y:=1 TO 9 DO
    FOR x:=1 TO 49 DO
      putpixel (x+135,y+160,CTab[x,y]);
  end;
 
  { flame/plasma process.. }
  begin
   GrDriver:=CGA; GrMode:=CGAc0;    {CGA, 320x200, 4 colors}
   InitGraph (GrDriver,GrMode,' '); {0-black, 1-blue, 2-red, 3-magenta}
    Clear_Tab; m:=0;
   REPEAT
    RND_Tab;
    Calc_Tab;
    Print_Tab;
   UNTIL m=250;
m:=0;
   REPEAT
  FOR x:=0 TO 50 DO
   begin
    CTab[x,10]:=0;
   end;
  Calc_Tab;
  Print_Tab;
m:=m+1;
  UNTIL m=30;
 
{ delay (1000); }

  CloseGraph
    end.

Hehe
A1230@50MHz/32M/80G, Mediator PCI (S3 ViRGE/DX 4M, RTL8139), GBS-8200, AOS 3.9;
A2000@7.14MHz without all :laugh1:
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #17 on: May 02, 2015, 01:34:03 AM »
Digging up bones.
Cool seeing this thread is still going.
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #18 on: September 07, 2016, 12:59:25 AM »
I would like to apologize to any and all here for any bad post that I have made.
Still looking looking to learn Pascal and Basic and maybe C,C++.
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline nyteschayde

  • VIP / Donor - Lifetime Member
  • Hero Member
  • *****
  • Join Date: Mar 2002
  • Posts: 643
    • Show only replies by nyteschayde
    • http://www.nyteshade.com
Re: Pascal Users
« Reply #19 on: September 07, 2016, 05:11:50 AM »
Quote from: trekiej;813574
I would like to apologize to any and all here for any bad post that I have made.
Still looking looking to learn Pascal and Basic and maybe C,C++.


Don't feel bad. I have an unhealthy obsession with writing Objective-C code on the Amiga. :) We all have things we like. I'm just trying to figure out a way to get the source off my NeXTStep machine to my Amiga and see if I can port the OpenStep version of Objective-C to the Amiga instead; it has some features above and beyond what is provided in 2.95.3
Senior MTS Software Engineer with PayPal
Amigas: A1200T 060/603e PPC • A1200T 060 • A4000D 040 • A3000 (x2) • A2000 Vamp/V2 • A1200 (x4) • A1000 (x3) • A600 Vamp/V1 • A500
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #20 on: September 07, 2016, 06:26:13 AM »
I see myself bouncing between languages. :(
It would be good to be able to write for more than one platform.
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline EugeneNine

  • Jr. Member
  • **
  • Join Date: Aug 2016
  • Posts: 88
    • Show only replies by EugeneNine
Re: Pascal Users
« Reply #21 on: September 08, 2016, 12:02:21 AM »
We learned on Borland Turbo Pascal my first trimerster in college.  I bought my SX-64 to class and was writing my programs in class on it.  

We later used Borland C in a later class.  By then I had an Amiga 500 and would run it under an IBM emulator and it was faster than the computers as school.

IIRC Pascal's purpose was to teach programming.

I dabble a little in others, once you get one they are all similar.

Pascal:

 
program Hello

begin   
      writeln 
('Hello, world.'
end.  
C:


#include<stdio.h> 
void main() 
{
     
printf("Hello World \n");
}
Fortran:

 
program hello
    
print *,'Hello World' 
end program hello  


I bounce between them too.
« Last Edit: September 08, 2016, 12:07:05 AM by EugeneNine »
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #22 on: September 08, 2016, 04:08:36 AM »
Fortran does not seem to be as mysterious as I had thought.
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline EugeneNine

  • Jr. Member
  • **
  • Join Date: Aug 2016
  • Posts: 88
    • Show only replies by EugeneNine
Re: Pascal Users
« Reply #23 on: September 08, 2016, 12:12:33 PM »
Then there is Forth, Lisp, Python, etc :)
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #24 on: September 08, 2016, 06:36:34 PM »
Does Lisp really do anything for AI?
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline EugeneNine

  • Jr. Member
  • **
  • Join Date: Aug 2016
  • Posts: 88
    • Show only replies by EugeneNine
Re: Pascal Users
« Reply #25 on: September 08, 2016, 07:06:08 PM »
Not sure anymore.  I learned Pascal and C and was starting with others when I was in Electronic Engineering college.  Sold my Amiga and went PC for a while and worked in IT supporting PC's then when XP was a dud I moved to Linux and moved away from Windows and into ITSecurity.  Not that I have kids and they are getting older and into electronics and computers I'm trying to get back into both a bit more.  One of my old projects was using a 68k for the main cpu of a robot with a Pic microcontroller based neural network around it.    At the time I was using Parallax's PIC programmer which used their pseduo 8051 like assembly.  Been messing with arduino a little,bit not and starting to get back into PIC using MPLAX C for C and Assembly.  I was using A64 on the Amiga at the time so I could port my assembly over to to the 68k but the longer term goal was to use a higher level language there.
I've been trying to revive some of those old projects now and picked up an Amiga 2000 a while back but have to fix it.  I've set up my environment under FS-UAE hoping I can just copy over to the Amiga when I get it working.

Back then doing complex stuff in assembly was tedious I was hoping to use soem match functions from a higher language to load lookup tables into the PIC's for the complex stuff.
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #26 on: September 08, 2016, 07:16:57 PM »
Busy, Busy. :)
Amiga 2000 Forever :)
Welcome to the Planar System.
 

Offline Rabbi

  • Sr. Member
  • ****
  • Join Date: Aug 2006
  • Posts: 269
    • Show only replies by Rabbi
Re: Pascal Users
« Reply #27 on: September 08, 2016, 09:36:13 PM »
Quote from: kamelito;788707
What would be nice if that Pascal programmers converts these tools to Amiga so porting Z80  source code to Amiga would be simpler.

Kamelito
http://files.programmersheaven.com/ASM/68000/z80conv/


Why would you need to port Z80 source code over to the Amiga when I've uploaded AmigaZ80 to AmiNet?  You can run TurboPascal ver 3.0 on it.
--------------------------------------------------------
In a world without walls and fences, who needs Windows and Gates?
===================================================================
Computer used:     Amiga A1200 (NTSC version) with 128 MB ...
 

Offline EugeneNine

  • Jr. Member
  • **
  • Join Date: Aug 2016
  • Posts: 88
    • Show only replies by EugeneNine
Re: Pascal Users
« Reply #28 on: September 09, 2016, 05:39:26 PM »
Quote from: trekiej;813637
Busy, Busy. :)
Yea, I get side tracked easy :)

What I was getting at is I'm not sure about LISP currently.  I got sidetracked after college and am just catching back up.

Anyway, it looks like FPC (Free Pascal) is available for classic Amiga (though a little older version) as well as AROS and Linux, etc.

Last time I messed with Pascal after college GNU pascal was the big project but it appears its not been maintained i a while with free pascal being the current popular.  They have their own IDE (Lazarus) as well if you like that style too.
 

Offline trekiejTopic starter

Re: Pascal Users
« Reply #29 from previous page: September 09, 2016, 05:46:03 PM »
I need to check out Lazarus. I keep hearing about it.
Amiga 2000 Forever :)
Welcome to the Planar System.