ASIC programming language

Last updated
ASIC
Original author(s) Dave Visti
Developer(s) 80/20 Software [1]
Initial releasebefore 1993 [2]
Final release
5.00 / 1994;30 years ago (1994)
Written in x86 assembly, Turbo C
Operating system MS-DOS
Type BASIC
License Shareware

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]

Contents

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. The features of ASIC are selected to make a program be easily and directly compiled into machine language. Thus, many language constructs of ASIC are equivalent to constructs of assembly language.

Program elements

Neither indetifiers, nor keywords are case-sensitive.

Any DIM statements, if specified, must precede all other statements except REM statements or blank lines.

All DATA statements must be placed at the beginning of the program, before all other statement types, except DIM, REM statements, or blank lines).

Expressions

ASIC does not have the exponentiation operator ^.

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

Arrays

The size of array specified in the DIM statement must be a literal constant. A single DIM allows to declare only one array.

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.

The PRINT statement prints integer values six characters wide. They are aligned to the right (no trailing spaces).

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

A boolean condition may be only a comparison of numbers or strings, but not a comparison of combined expressions. A literal cannot be the left operand of comparison (e.g. can be X = 2, not 2 = X).

Decisions

After THEN, there may be a sequence of statements delimited by ELSE or ENDIF. An example:

IFX<0THENPRINT"Negative"ELSEPRINT"Non-negative"ENDIF

Contrary to other BASICs, statements cannot be put between THEN and the end of the line.

An if-statement can realize the conditional jump. In this case, after THEN there may be a label.

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.

Branching

In a GOTO statement, the label must be followed by a colon.

Subroutines

In a GOSUB statement, the label must be followed by a colon.

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

10FORi=10TO1STEP-120PRINTi30NEXTi

is converted into

REM10FORi=10TO1STEP-1FORI@=10TO1ASIC0@=-1-1I@=I@+ASIC0@REM20PRINTiPRINTI@REM30NEXTiREM30NEXTi3:Syntaxerror

The exponentiation operator ^ is not converted. The program

10a=220b=a^1030PRINTb

is converted into

REM10a=2L10:A@=2REM20b=a^102:SyntaxerrorREM30PRINTbREM30PRINTb3:Syntaxerror

Related Research Articles

Applesoft BASIC is a dialect of Microsoft BASIC, developed by Marc McDonald and Ric Weiland, supplied with Apple II computers. It supersedes Integer BASIC and is the BASIC in ROM in all Apple II series computers after the original Apple II model. It is also referred to as FP BASIC because of the Apple DOS command FP used to invoke it, instead of INT for Integer BASIC.

<span class="mw-page-title-main">BASIC</span> Family of programming languages

BASIC is a family of general-purpose, high-level programming languages designed for ease of use. The original version was created by John G. Kemeny and Thomas E. Kurtz at Dartmouth College in 1963. They wanted to enable students in non-scientific fields to use computers. At the time, nearly all computers required writing custom software, which only scientists and mathematicians tended to learn.

<span class="mw-page-title-main">Atari BASIC</span> Dialect of the BASIC programming language

Atari BASIC is an interpreter for the BASIC programming language that shipped with Atari 8-bit computers. Unlike most American BASICs of the home computer era, Atari BASIC is not a derivative of Microsoft BASIC and differs in significant ways. It includes keywords for Atari-specific features and lacks support for string arrays.

<span class="mw-page-title-main">Visual Basic (.NET)</span> Object-oriented computer programming language

Visual Basic (VB), originally called Visual Basic .NET (VB.NET), is a multi-paradigm, object-oriented programming language, implemented on .NET, Mono, and the .NET Framework. Microsoft launched VB.NET in 2002 as the successor to its original Visual Basic language, the last version of which was Visual Basic 6.0. Although the ".NET" portion of the name was dropped in 2005, this article uses "Visual Basic [.NET]" to refer to all Visual Basic languages released since 2002, in order to distinguish between them and the classic Visual Basic. Along with C# and F#, it is one of the three main languages targeting the .NET ecosystem. Microsoft updated its VB language strategy on 6 February 2023, stating that VB is a stable language now and Microsoft will keep maintaining it.

The C preprocessor is the macro preprocessor for several computer programming languages, such as C, Objective-C, C++, and a variety of Fortran languages. The preprocessor provides inclusion of header files, macro expansions, conditional compilation, and line control.

Integer BASIC is a BASIC interpreter written by Steve Wozniak for the Apple I and Apple II computers. Originally available on cassette for the Apple I in 1976, then included in ROM on the Apple II from its release in 1977, it was the first version of BASIC used by many early home computer owners.

In computing, a line number is a method used to specify a particular sequence of characters in a text file. The most common method of assigning numbers to lines is to assign every line a unique number, starting at 1 for the first line, and incrementing by 1 for each successive line.

BASIC-PLUS is an extended dialect of the BASIC programming language that was developed by Digital Equipment Corporation (DEC) for use on its RSTS/E time-sharing operating system for the PDP-11 series of 16-bit minicomputers in the early 1970s through the 1980s.

<span class="mw-page-title-main">FreeBASIC</span> BASIC dialect

FreeBASIC is a free and open source multiplatform compiler and programming language based on BASIC licensed under the GNU GPL for Microsoft Windows, protected-mode MS-DOS, Linux, FreeBSD and Xbox. The Xbox version is no longer maintained.

HP Time-Shared BASIC is a BASIC programming language interpreter for Hewlett-Packard's HP 2000 line of minicomputer-based time-sharing computer systems. TSB is historically notable as the platform that released the first public versions of the game Star Trek.

Color BASIC is the implementation of Microsoft BASIC that is included in the ROM of the Tandy/Radio Shack TRS-80 Color Computers manufactured between 1980 and 1991. BASIC is a high level language with simple syntax that makes it easy to write simple programs. Color BASIC is interpreted, that is, decoded as it is run.

IBM System/3 BASIC was an interpreter for the BASIC programming language for the IBM System/34 midrange computer.

IBM System/36 BASIC was an interpreter for the IBM System/36 midrange computer.

<span class="mw-page-title-main">FutureBASIC</span>

FutureBasic is a free BASIC compiler for Apple Inc.'s Macintosh.

The syntax and semantics of PHP, a programming language, form a set of rules that define how a PHP program can be written and interpreted.

SCELBAL, short for SCientific ELementary BAsic Language, is a version of the BASIC programming language released in 1976 for the SCELBI and other early Intel 8008 and 8080-based microcomputers like the Mark-8. Later add-ons to the language included an extended math package and string handling. The original version required 8 kB of RAM, while the additions demanded at least 12 kB.

Data General Extended BASIC, also widely known as Nova Extended BASIC, was a BASIC programming language interpreter for the Data General Nova series minicomputers. It was based on the seminal Dartmouth BASIC, including the Fifth Edition's string variables and powerful MAT commands for matrix manipulation. In contrast to the compile-and-go Dartmouth BASIC, Extended BASIC was an interpreter.

SDS BASIC, also known as CP-V BASIC, Batch BASIC or Sigma BASIC depending on the version, is a BASIC programming language compiler for Scientific Data Systems's (SDS) Sigma series mainframe computers, originally released in 1967. Xerox purchased SDS in 1969 and began rebranding it as Xerox Data Systems, and finally just Xerox, at which time the language became known as Xerox BASIC.

Wang BASIC is a series of BASIC programming languages for computers from Wang Laboratories. The term can be used to refer to the BASIC on any Wang machine, but is mostly associated with the versions on the Wang 2200 minicomputer series of the early 1970s. When these machines were updated to the VP series in 1976, BASIC-2 was introduced and remained the pattern for future machines in the 2200 series. A planned BASIC-3 was never released.

Acorn System BASIC and Atom BASIC are two closely related dialects of the BASIC programming language developed by Acorn Computers for their early microcomputers like the Acorn System 3 and Acorn Atom. Developed in-house, they have a number of significant idiosyncrasies compared to most BASIC dialects of the home computer era.

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. 1 2 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