Commodore-64 Comal 80 rev 2.01

From C64-Wiki
Jump to navigationJump to search
Comal 80 rev. 2.01
Comal80_Modul_Startup_message
Developers Jens Erik Jensen, Mogens Kjær, Helge Lassen, Lars Laursen
Publisher Unicomal , Commodore Data
Release 1984, 1985
platform(s) C64
Genre Development system for language Comal
Control Keyboard
Media Cartridge
Language English
Information ...


Description[edit | edit source]

COMAL Cartridge

COMAL 80 v2.01 on Commodore 64 is Unicomal's ApS implementation of the COMAL80 standard for Commodore Data A/S on Cartridge.


Shipment[edit | edit source]

The developement system contains one cartridge with COMAL 80 and 5,25" floppy disks with demos and a manual.


Hardware Specifications[edit | edit source]

Minimum:

also:

Documentation[edit | edit source]


Cartridge Structure[edit | edit source]

The C64 Comal80 cartridge size is 64 KB (4 banks x 16KB + 16KB possible EPROM + 16KB possible EPROM) and it's using bankswitching, so that only 16 KB is visible at a time in the C64 memory map at address $8000 to $BFFF. By write too address $DE00 or call comal system routine, you can control which comal80 module routines you can call in our own mashineprogram.


Difference between v2.0 and rev. 00.14[edit | edit source]

rev. 00.14 is a diskloading system where Comal 80 is loaded from Diskdrive, it gives only 12 KB programming space, compared to v2.0 where there is 30 KB programming space and some other features.


Comal programs saved must be loaded with same version, a solution to overcome this, is to LIST the program to Diskdrive.


  • The variable used in FOR is not local in rev. 00.14 where it is local in v2.0.
  • CLOSED procecures or functions names is global in rev. 00.14 where in v2.0 it is local a must use IMPORT to be used.
  • SPRITES IDENTIFY must follow a SHOWSPRITE in v2.0.
  • Tranfering arrays in function calls in rev. 00.14 it only needs the name, in v2.0 the name must be followed by a (,).
  • Function calls with parameters can be used without () in rev. 00.14 where in v2.0 you must use ().
  • Direct access can be done in rev. 00.14, it is forbidden in v2.0.
  • UNIT was used in rev. 00.14 to specify device, in v2.0 only needs to type "0:" for use device 8.
  • CLOSE FILE 255 is deleted in program in v2.0.
  • In rev. 00.14 Packages GRAPHICS and SPRITES is included in program where in v2.0 it must use USE Package.
  • CLEAR in rev. 00.14 is now CLEARSCREEN in v2.0.
  • SETTEXT in rev. 00.14 is now TEXTSCREEN in v2.0.
  • SETGRAPHICS in rev. 00.14 is now GRAPHICSSCREEN in v2.0.
  • HOME in rev. 00.14 is center of the screen where in v.2.0 it is (0,0).
  • FRAME in rev. 00.14 is changed to WINDOW in v2.0.


ONLY in v2.0[edit | edit source]

  • FULL Comal Kernal
  • Defineable functionkeys
  • Graphicsscreen dumps
  • Better error messages
  • Modem communication
  • ASCII conversion
  • Batch files
  • External procedures
  • User Packages
  • Empty EPROM socket



Programming[edit | edit source]

Editor commands[edit | edit source]

Disk commands[edit | edit source]

Input & Output commands[edit | edit source]

File commands[edit | edit source]

Real Number functions[edit | edit source]

Integer functions[edit | edit source]

String functions[edit | edit source]

Structure[edit | edit source]

Variables[edit | edit source]

Type Declare Min value Max value
Real numbers variablename := 3.14 1.70141183e-38 1.70141183e38
Integer variablename# := 255 -32768 32767
Hexadecimals variablename := $ffff 0 65535
Binary numbers variablename := %1111111111111111 0 65535

Function[edit | edit source]

Procedure[edit | edit source]

Loops[edit | edit source]

Branches[edit | edit source]

Logical operators[edit | edit source]

Error handling[edit | edit source]

Others[edit | edit source]

Packages[edit | edit source]

Command: USE package

Expand COMAL 80[edit | edit source]

USE - LINK - DISCARD


Machinecode

Example of a package to expand Comal 80 with a function using Comal kernal functions, to subtract 2 real numbers for return a real number. Best methode is to assemble it with Assembler 64 from Commodore Data or a assembler who can assamble to OBJ type file in SEQ fileformat.

;
.LIB   C64SYMB         ;FILE FROM COMAL DEMODISK
;
       *=$8009         ;BEGIN ADDRESS
;
       .BYTE DEFPAG    ;52KB RAM MEMORY MAP
       .WORD END       ;MODULE END LABEL
       .WORD DUMMY     ;NO SIGNAL-HANDLER
;
;  PACKAGETABEL:
;
       .BYTE 4,'TEST'  ;PACKAGES NAME IS TEST
       .WORD TESTP     ;PROCEDURE-TABEL
       .WORD DUMMY     ;INGEN INITIALISERING
       .BYTE 0         ;NO MORE PACKAGES
;
;  PROCEDURE-TABEL:
;
TESTP  .BYTE 3,'SUB'
       .WORD PSUB
       .BYTE 0         ;NO MORE PROCEDURES
;
;  FUNC SUB(A,B)
;
PSUB   .BYTE FUNC+REAL,<SUB,>SUB,2
       .BYTE VALUE+REAL
       .BYTE VALUE+REAL
       .BYTE ENDFNC
;
SUB    LDA #1
       JSR FNDPAR
       LDA COPY1
       LDY COPY1+1
       JSR LDAC2
       LDA #2
       JSR FNDPAR
       LDA COPY1
       LDY COPY1+1
       JSR LDAC1
       JSR FPSUB2
       JSR PUSHA1
       RTS
;
END    .END

Manual[edit | edit source]


Literature[edit | edit source]


Links[edit | edit source]