ASIC programming language

From Wikipedia, the free encyclopedia
ASIC
ASIC programming language.png
Version 5.0
Original author(s)Dave Visti
Developer(s)80/20 Software[1]
Initial releasebefore 1993[2]
Final release
5.00 / 1994; 27 years ago (1994)
Written inx86 assembly, Turbo C
Operating systemMS-DOS
TypeBASIC
LicenseShareware

ASIC is a compiler and integrated development environment for a subset of the BASIC programming language. It was released for MS-DOS and compatible systems as shareware. Written by Dave Visti of 80/20 Software, it was one of the few BASIC compilers legally available for download from BBSes. ASIC allows compiling to an EXE or COM file. A COM file for Hello world program is 360 bytes.[3]

ASIC has little or no support for logical operators, control structures,[4] and floating-point arithmetic. These shortcomings resulted in the tongue-in-cheek motto, "ASIC: It's almost BASIC!"[5][3]

Features[]

ASIC is strongly impoverished in comparison with its contemporary BASICs.

Expressions[]

ASIC does not have the exponentiation operator ^.

ASIC does not have boolean operators (AND, OR, NOT etc.).

Input and Output[]

PRINT's arguments must be a literal or variable. PRINT does not allow to use combined expressions as its arguments, nor does it allow to use strings concatenated with ; or +.

If a PRINT command ends with ; or ,, then the next PRINT command will resume in the position where this one left off, just as though its argument were appended to the argument of the current PRINT command.

LOCATE row,column
Moves the text cursor to the position (column, row), where 0 ≤ column and 0 ≤ row. The position (0, 0) is the upper left corner.

Graphics[]

PSET (row,column),color
Turns on the pixel of the color color at position (column, row), where 0 ≤column and 0 ≤ row. The position (0, 0) is the upper left corner.

Control Structures[]

Decisions[]

A boolean condition in IF may be only a comparison of numbers or strings, but not a comparison of combined expressions.

Looping[]

In FOR, after TO there may be only a number - literal or variable - but not a combined expression. The STEP clause does not exist in ASIC.

BAS2ASI[]

This utility, serving to convert GW-BASIC programs to ASIC syntax, in the version 5.0 does not support some GW-BASIC features. Examples:

STEP in the for loop is not converted. The program

10 FOR i=10 TO 1 STEP -1 
20 PRINT i
30 NEXT i

is converted into

	REM 10 FOR i=10 TO 1 STEP -1 
	FOR I@ = 10 TO 1 
		ASIC0@ = -1 -1 
		I@ = I@ + ASIC0@ 
		
		REM 20 PRINT i
		PRINT I@ 
		
		REM 30 NEXT i		REM 30 NEXT i		3:  Syntax error

The exponentiation operator ^ is not converted. The program

10 a=2
20 b=a^10
30 PRINT b

is converted into

	REM 10 a=2
L10: 
	A@ = 2 
	
	REM 20 b=a^10
	2:  Syntax error

	REM 30 PRINT b	REM 30 PRINT b	3:  Syntax error

References[]

  1. ^ IBRARY: Library for the ASIC compiler. Current Version: 3.1...David A. Visti, Catalog - Updated :February 1, 1996, Charon Software
  2. ^ ASIC 4.0 - Download
  3. ^ a b ASIC, Area code magic with AC Hunter (computer program) (On Disk) (evaluation), by George Campbell, COMPUTE! ISSUE 126 / FEBRUARY 1991 / PAGE 86
  4. ^ In ASIC 3.01 (1991), the manual lists FOR...NEXT, WHILE...WEND and IF...ENDIF, but no switch statements, and no functions or procedures with parameters or local variables, only GOSUB for subroutines. The example programs use Goto instead of WHILE.
  5. ^ ASIC is the work of David Visti and his compiler takes code that is "almost BASIC" and compiles it down to a very small executable. Archived November 4, 2015, at the Wayback Machine, Programmer's Corner: TIPI: A Small Programming Language for Small Comp, By Kent Peterson

External links[]

Retrieved from ""