80-Bus News


July–October 1982 · Volume 1 · Issue 3

Page 30 of 51

The Kiddies Guide To Z80 Assembler Programming

by D. R. Hunt

The Crossroads of personal computing (it goes on and on).

Part: The Seventh, the last

Putting it all to use.
Making programs do things.

It seems no time at all since I wrote the last episode of Kiddies Guide, although it’s now early July, so it must be at least six weeks. This episode I have determined will be the last. It’s taken some eighteen months and roughly 36,000 words to get this far (36,107 words, I haven’t counted them, but my trusty Spell Guard program has, that’s including this episode). I feel that it is perhaps time for a change, and to that end, my (Disk) Pen will be turned elsewhere in future. Thank you to all those people who wrote me encouraging letters, and thank you to those few who wrote letters highly critical of my literary style, finding it somewhat jarring on the nerves. To my critics, I can only reply that the style has been deliberately chatty with the hope that it might engender some interest in what is after all a very dry subject. Most people seemed to like it, but perhaps to get some practice at writing on more serious matters the style of this episode should be toned down somewhat, and the style made a little more turgid.

So, for this last episode, I have decided to look at the uses of a computer outside the pure enjoyment of writing software that works or the equally rewarding but considerably more frustrating task of debugging software that doesn’t. Firstly, it occurs to me that I haven’t published my philosphical view of what a computer is. How do I justify my statement that the computer is a remote mental extension of the mind of the man who programs it ?

Given that the computer is an intelligent machine, in that it may be preprogrammed (taught) to follow a logical course and make logical decisions based on the outside factors placed at it’s inputs, it should therefore be possible to adapt the machine to take command of the outside factors which affect it. Of course I’m not talking about computers of science fiction which for instance can adjust, say the weather to suit themselves, or are capable of taking intelligent decisions beyond the scope of a thinking person. Rather, I am considering the computer from the point of view that it has somewhat less intelligence than an embryo woodlouse, and is capable of nothing without being imbued with the intelligence of the person who programs it. In otherwords, the computer IS the remote extension of the programmer. It can perform tasks set it by the programmer without supervision. Once set running by some other person it may perform these tasks without the programmer even being aware that machine is acting upon his instructions written may be months or years previously. However, it’s intelligent progress through those tasks has already been predetermined from the stored image of the logical process of the programmer’s mind in writing the program. It is incapable of any choice outside the program, and most of all it is incapable of a single ‘original’ thought.

The machine is, on the other hand extremely fast, and given satisfactory environmental conditions, meaning freedom from mains glitches, internal faults, etc, it is infallible. Or, rather, only as fallible as the programmer when the original program was written. Something outside the scope of the original program can always occur, and the machine fail to perform satisfactorily. This is not the fault of the machine, but of the lack of foresight of the programmer in failing to predict the fault condition. Software failsafe, and automatic learning techniques already exist for this sort of occurrence, but again, these rely on the programmer to predict that the unforseen could happen, and for him to endow that machine with the necessary intelligence to cope with whatever problems might occur. Again the onus is on the programmer. The machine can not learn from it’s mistakes unless there is a program to allow it to learn from it’s mistakes, and so on. This type of argument is never ending, as the next level down is the program to allow the machine to correct the

Page 30 of 51