|★ APPLICATIONS ★ PROGRAMMATION ★ SIDEWAYS ROM: A ROM on the Side ★|
|Micropower - Sideways Rom (Amstrad Computer User)||Applications Programmation|
Cliff Lawson examines two new sideways roms from Super-Power.
For over a year now, there seems to have been very little movement towards using the Arnold's in-built ability to address banks of sideways ROMs, then, all of a sudden, the market seems to be awash with them. First there came the excellent Arnor assembler which has been closely followed by offerings from Honeysoft, KDS and Micropower. A lot of this may well be due to the cost of blank EPROMS (Arnold is very particular about them having an access time of 200nS or better), the cost of 16K EPROMS is still quite high, even when bought in quite large bulk quantities and this perhaps explains the rather high cost of some of the add-on ROMS that have now appeared (both the Arnor assembler and the Micropower ROMs retail at about 40 quid). A second stumbling block in producing sideways ROMs is ensuring that the user has somewhere to put them - all the companies mentioned above have produced some form of plug-in ROM card, offering from 1 up to 8 free slots. The eight slot card is being produced by Micropower (as mentioned in a previous issue), probably because they have at present the largest range of ROMs available. Their card comes pleasantly boxed in a case which matches the colour scheme of the 464 and internally the circuitry is well laid out, providing a very simple way of selecting ROM numbers for a particular socket. The actual circuit, however, is a little suspect and will cause problems if other ROM cards (such as MAX AM) are present as well (see letter in September issue for more details).
It should be emphasised that their card is aimed very much at the 464 and will not even fit onto a 664 or 6128. This is just as well, because the majority of their software is not compatible with V1.1 firmware anyway (making use of a host of un-documented addresses to provide features such as forcing CAPS LOCK on which would not be possible otherwise. This is particularly true in the programmer's toolkit but may not be such a problem in the other ROMs). Already available is a competent mailing list program within ROM (though I would have thought that it may be a rather specialist sort of program to produce in a ROMable form). There is some talk of that old arcade favourite of theirs, 'Ghouls'being available in a ROM, however, I was unable to see a copy of it - the two reviewed here both fit quite nicely into the category of utilities ROMs. Probably the most interesting of the Micropower ROMs is their Programmer's Toolkit. As the manual clearly states in its introduction, the ROM aims to do four jobs: Provide the 464 with most of the V1.1 BASIC additions; Add several very useful new commands to the BASIC; Give BASIC programmers a collection of debugging aids; Provide utilities (such as a UDG designer). Although I had only a draft copy of the manual, it did appear to be quite a comprehensive introduction (not just a few scribbles on the back of an envelope as has been the case in the past for several computer products I've seen). The syntax of each of the 35 new commands is given, followed by a description of its operation and use. Thankfully, a number of examples that will hopefully illustrate anything the text has failed to fully describe are also given.
One of the most useful commands is I COMMAND which will not only list the new commands, but can also give a reminder of the syntax of any individual one, especially useful when the manual isn't just to hand. That old toolkit faithful - a REM remover is available under the command |COMPACT. |CHARACTER allows user defined graphics to be easily edited on a full screen grid.
|EDITOR splits the screen into three windows and defines keys on the key-pad for some of the more popular BASIC commands - I'm not wholly sure how useful this one would really be, but with time, one might become trained in the habit of switching windows to run and edit one's programs. One of the commands that makes the whole thing worthwhile is the |FIND command which will also replace strings within a BASIC program. This acts globally but prompts at each occurrence for verification that it should be replaced. A very simple memory editor goes under the name |MEDIT, but is not a patch on that contained within MAXAM.
|XREF will indicate all the lines that GOTO or GOSUB to a particular line, this doesn't exactly promote a structured approach to programming, but we've all needed to do this sort of thing at some time in the past.
The ROM contains two types of screen dump which can be used with either the dreaded DMP1 or a decent EPSON compatible, the I PRINTER command selects which will be used and |DUMP or |CDUMP pick either a straight monochrome dump or a shaded dump that goes some way to allowing colour displays to be printed on a single ink printer, though the aspect ratio of the dump does not appear to be the same as that of the screen, producing a rather elongated print. All output to the screen can be echoed to the printer with the cunningly named |ECHO.ON (|ECHO.OFF cancels the effect). This would, for example, allow disc CATalogues to be printed.
The copious output of BASIC'S trace can be directed to the printer using |LTRON. |LTROFF stops it. One of the basic graphic commands that isn't present in Locomotive BASIC is |CIRCLE. This uses a particularly fast algorithm - though it isn't as smooth as some slower techniques.
The command that most people miss on the 464 which is available on later machines is now available using I FILL -unfortunately, this algorithm is not very fast, but benefits from the fact that areas are filled using the current line MASK, enabling easy stipple filling which can produce some powerful effects in only a couple of instructions. As on V1.1, CALL &BD19 has been given the prettier interface of I FRAME to synchronise animation effects. The setting of graphics paper and pen is simplified using |GRAPHICS.PAPER and |GRAPHICS.PEN. The powerful V1.1 MASK command has been implemented in the shape of |MASK and like its namesake allows a binary dot pattern to be set up for line drawing (and area filling as mentioned above).
LOGO freaks (and DRAGON owners) can spend many a happy hour driving an imaginary turtle about leaving a trail. The I TURTLE command takes a string parameter which contains direction instructions of the F,B,L and R variety (for Forward, Back, Left and Right for those who hadn't already guessed). Though I was rather suprised to find that it will only accept upper case letters as command. Picking characters up from the screen for collision detection purposes and the like can be achieved using |COPYCHAR.
The ESC control code that is usually ignored by Arnold's VDU can be used to switch on underline and/or double height characters, when followed by a second parameter. Any odd graphic effects instigated by the new commands can be nullified using |NORMAL which sets things to just that.
Because some of the ROMs commands can produce more than a screenful of output (e.g. |COMMAND) and the [ESC] key does not pause output but terminates it, paged output can be enabled with |PAGE.ON and disabled with |PAGE.OFF - this will stop screen output every 15 lines. The firmware allows either the memory at &C000 or &4000 to be used to hold screen info. - it is possible to switch between the two using I SCREEN -though this is unlikely to be very useful from BASIC as the latter of the two areas is where the middle of a BASIC program would usually reside. Micropower's roots in the world of Acorn machines show with some of the ROM commands such as IVDU which does the same as PRINT CHR$() and |GCOL to set the graphics mode and ink colour.
High speed tape
To supplement the 464 tape/disc filing system, |BAUD will allow 3000 and 4000 baud saving as well as the usual 1000 and 2000 - This will, however, be driving the hardware outside its design specification and cannot be guaranteed to be 100% successful - particularly when transfering tapes between more than one machine.
Like the |TURTLE command, |TUNE also takes a string parameter, but it obviously contains note data rather than direction information. Again, it is rather annoying that it will not accept lower case.
Safe to use?
Some of the commands in this ROM are a little suspect (especially, |UNPROTECT) and making use of undocumented features/addresses so as to make it incompatible with all models except the 464 is a little worrying. Please note all you people who complain about 464/664 incompatibilities, the incompatibilty is caused solely by the use of undocumented features and is in no way caused by differences in the documented firmware - as there are no major differences. However, as a programmer, I would have to say that this is a very worthwhile investment - especially as Amsoft have no plans to make the Vl.l ROM available. One or two of the commands do seem a little esoteric but are balanced by those that are an absolute must (e.g. I FIND). £39.95 isn't exactly cheap, but does seem to be the going rate for a 16K sideways ROM and this particular ROM probably provides the best value for money of all the Micropower ROMs. The matching ROM card at the same price will make it quite an expensive buy for both items, but the card can then take another seven ROMs (though some other manufacturers ROM card could be used equally well and would avoid any potential addressing problems that this card may contain).
The second of Micropower's ROMs that I had for review was their Disk (spelt incorrectly) User'Utilities. Unlike the other ROM, this is a foreground ROM, so that, rather than adding a number of commands to the on-board BASIC (or other foreground program) it takes over the machine completely having been started by the system extension |DP. One thing not made clear in the manual, though it may be in the ROM card instructions, was that on a 464 foreground, ROMs must be fitted contiguously from ROM address 1 - which means that in the eight slot card, the disc utilities ROM must occupy the first free slot counting up from ROM 1 (on the left).
You're perhaps wondering what use the ROM is anyway, well, anyone who has erased *.* when they really meant *.BAK is the sort of person who could find this ROM useful. Directory entries can be read in, modified and re-written to the disc so that erased files can be restored (they are not wiped from the disc by ERA, only the directory entry is changed). Formatting and disc copying without having to have a copy of your system utilities disc is another potential use for the ROM. Also, discs corrupted on only a couple of sectors that would be uncopiable could be restored by selective copying of the undamaged parts. Having typed |DP, a menu providing ten options (1-9 and 0) appears. Several of these will perform a function then enter a standard editor so that sector information can be updated by the user. Option 5 at any time allows direct access to the editor.
The OptionsOption 1 will read the directory sectors from a disc and place them in the editor's buffer. The bytes within an entry are briefly described in the manual - sufficiently for one to understand how the allocation unit numbers relate to physical tracks and sectors on a disc. By the way, if all this talk of tracks and sectors has already got you baffled, then don't worry too much -the manual is much better at explaining them than I am, besides which, anyone not familiar with such terms is unlikely to be buying a ROM to doctor their discs anyway.
Option 2 allows selective reading of sectors from a disc - the editor being entered once the sector is read. Option 3 again enters the sector editor once a file has been chosen from the directory. Cursor keys are used to step onto to the next sectors that contain the file (even though they may not be contiguous - the allocation units being read from the directory entry).
As well as allowing one to read sector information, the contents of any banked ROMs can also be read into the editor - though update would obviously be futile. Having edited some sector information that has been read into the buffer, its contents can be replaced on the disc using option 6. Used incorrectly, this could have disastrous effects on your discs - the manual does give a concise warning to this effect but this cannot be emphasised too strongly. Although all editing could in theory be reversed, one would have to keep an exact record of all changes made (or better still, a backup copy of the disc). A quite passable Z80 disassembler can be called up using option 7 and will not only disassemble the contents ol a sector held in the buffer but could also be used to pry into other sideways ROMs. A second, general, debugging tool is the search memory option 8.
Option 0 allows a choice of screen displays for the editor and also allows the colours used to be changed.
Second menuOption 9 is really just an entry to a second menu of utilities that consist of:-
That about wraps it up for this ROM, I have a feeling that the Programmer's Toolkit is more likely destined to become a best seller. Disc doctoring ROMs are OK in experienced hands, but your average lorry driver may be a little lost with it. Hopefully, semi-conductor developments will bring down the cost of this medium to a level where it makes more sense to use ROMs for things such as assemblers, word-processors and toolkit utilities than wasting space on discs. However, there would have to be a quite drastic cut in the price before they could be used as a mass media device.
Cliff Lawson, ACU #8510