Crash


Full Screen Editor/Assembler

Publisher: Oxford Computer Publishing
Machine: Spectrum 16K/48K

 
Published in Crash #5

Full Screen Editor/Assembler

This is a machine code Editor/Assembler for the 48K and 16K Spectrum. The cassette is supplied in a cardboard presentation box and comes complete with comprehensive instruction/tutorial manual. Also on the tape is a demonstration file for practice purposes, and a character generator program, for designing your own UDGs! This makes for quite good value at £9.95. The editing functions can be quite complex so it is worth studying the instructions before attempting to write your own code. The demonstration file is provided so that you can practise the many editing functions and commands.

To load the assembler, simply type LOAD"". The program loads in two parts - the first part being a Basic loader, and when loading is complete the editor is automatically entered. A special printing routine is employed to give 42 columns on-screen. This aids text readability as most instructions can be printed all on one line instead of spread over two. Forty-two columns are also output to the printer for listings.

The Editor

The editor uses line numbers and these appear at the far left-hand side of the screen display. Moving right, next comes the label field - labels can be up to six characters long. Next comes the op-code field and after this the operand field. Comments can be written after the operand field, and these are indicated as usual by a semi-colon.

Full Screen Editor/Assembler

The line number can occur in any order and need not even be unique. The editing operations are carried out on a 'text buffer' which contains the source code. The editor provides commands to change, insert and delete individual characters within a line; to move, copy and delete single lines or blocks of lines as a whole; to locate change and delete specified strings of characters as well as commands to output text to the ZX printer and to cassette tape. Commands are also provided to Save, to Load, Verify or Append files from tape. An expression evaluator is included.

The Assembler

The assembler is really quite separate from the editor. After your source code is completed and checked, the assembler can be called. Its function is to convert your source code mnemonics and operands into the machine code form understood by the Z-80 mpu, and to output this code to tape, memory, screen and/or printer. The assembler is invoked from normal edit mode.

The assembler makes two passes through the source code in the text buffer. The first pass checks the syntax of the source code and creates a user symbol table. The second pass converts the source code mnemonics into their object code equivalents. This is all displayed on screen during the second pass.

The assembly listing is displayed in three sections. The right-hand part is a copy of the source code from the text buffer. The two columns on the left contain the location at which the object code will reside, followed by the object code itself; both in hexadecimal.

Error messages are comprehensive and a complete list of error and their causes, etc, is given in the manual. At the end of the assembly is given a count of the errors.

The assembler stores the code it produces in an object code buffer. This is usually not the place in memory that the code was designed to run - but when this is saved to tape the header is arranged to contain the correct information. Several assembler switches are available; these are for directing the object code, listing on/off, etc.

In Use

The package was very easy to use after a couple of hours practice. One slightly annoying thing is the speed of the repeat on the keyboard. This is much too fact and often results in a single key being read twice or more on the same depression. This is a small fault which spoils the program and increases wear on the keyboard as you have to jab at the keys. The expression evaluator is useful for automatically generating such things as table lengths string lengths, constants, address and other data. This take a lot of the tedium out of assembly level programming and is a useful programming aid.

Applications

To use an assembler, you obviously need some knowledge of machine code, and you probably have your own ideas as regards applications. For any serious (or indeed, if you're writing games - non-serious) use of machine code the opposite of the above is also true - that is, to use machine code, you need an assembler, and this one does its job very well.

The program can be recommended to beginners to machine code as it is quite easy to use. The more accomplished programmer, however, will probably reqire something a little more flexible. OCP's Editor/Assembler is quite adequate for general purposes machine code programming, offering powerful features at a reasonable price.