JUL Y- AUG '93 VOL 1 1 #4

TORONTO TIMEX-SINCLAIR USERS CLUB

JULY-AUG '93 VOL 11 #4

SINC-LINK IS A PUBLICATION OF THE TORONTO T I ME X -SINCLAIR USERS CLUB AND IS ISSUED 6 TIMES A YEAR. CLUB MEMBERS RECEIVE FREE COPIES AS PART OF THE $20.00 ANNUAL MEMBERSHIP FEE.

NEWSLETTERS ARE EXCHANGED, FREE OF CHARGE, WITH OTHER TIMEX-SINCLAIR USER GROUPS.

PLEASE CREDIT THIS PUBLICATION AND THE AUTHOR IF YOU COPY MATERIAL.

THE TS2068 & ZX-81 GROUP MEETS ON THE FIRST WEDNESDAY OF EACH MONTH AT 14 RICHOME COURT, SCARBOROUGH, ONT. 7PM START.

THE QL SIG MILL MEET THURSDAY, JULY 15TH AT 586 ONEIDA DRIVE, BURLINGTON, ONT. 7PM START. AUGUST DATE TBA.

SINC-LINK IS PRODUCED ENTIRELY ON SINCLAIR AND TIMEX-SINCLAIR COMPUTERS.

SEND CORRESPONDANCE TO:

SINC-LINK EDITOR, TORONTO TIMEX-SINCLAIR USERS CLUB, 14 RICHOME COURT, SCARBOROUGH, ONTARIO, CANADA M1K 2Y1.

EXECUTIVE OFFICERS

PRESIDENT; TREASURER; SECRETARY ; ACTIVITIES QL CONTACT; NEWSLETTER: LIAISON OFFICER: { Out-of-town members )

T

L

nmnm

mm 3L

TS2866

i

L

K

i

3 i.

8

t

I

I

N

I

I

3

I

/

F

/

jj

s

rtttftttf

fttfl

TORONTO TIHEX-SINCLfllR

USERS CLUB

( AREA CODE 416) RENE BRUNEAU (531-9749) BILL LAWSON ( 444-8772 ) GEORGE CHAMBERS ( 751-7559 ) LOU LAFERRIERE ( 820-3725 ) HUGH HOWIE ( 634-4929 ) JEFF TAYLOR ( 244-8583 ) GEORGE CHAMBERS. 14 RICHOME COURT. SCARBOROUGH. ONTARIO M1K 2Y1 ( 416-751-7559 )

TORONTO TIMEX-SINCLAIR USERS CLUB

SINC-LINK

HOT SUMMER 1993 INDEX VOLUME 11-4

page 2 - Club Stuff page 3 - Index & Editorial page 4 - Interbank Database page 5 - Newport Report page 8 - QLips page 9 - Tank Volume page 10 - Spectrum Restart page 13 - Mechanical Affinity Ad page 15 - Visionmixer-1 page 16 - QLips page 17 - Al Green Writes page 18 - Stepper Motor Driver page 19 - Lastest Index of QL Articles page 20 - More on "SLOWGOLD" page 21 - Auto Fade page 23 - Read 2068 JLO Disks With QL page 25 - PD Newsletter page 27 - PRISM PD Ad page 29 - Z-88 Parallel/Series Converter page 30 - Dayton Computerfest Info

EDITORIAL

Well, we got an interesting package in the mail this week. A U.K. public domain software company dedicated to the Spectrum has sent me a sampling of their utility programs on both tape and a +D format 3.5" disk.

You may recall that I ran a copy of PRISM PD's advertisement a couple of issues ago and after a long delay on my part, I decided to try them out. I was particularly interested to see if the Larken system would be able to read the +D disk. More on that next issue.

Also included in the package was another ad, this time aimed at North American users, and a well- assembled newsletter. If this newsletter is any indication of their commitment then it looks like PRISM PD will be around for a whi le .

See their new ad and the first couple of pages of the newsletter near the back of this issue. They certainly offer a lot of selection.

NEWS ON NEWPORT

In early June, Hugh Howie attended the QL Fest in Newport, Rhode Island. Hugh manned a table, handed out info on our club and met lots of fellow QLers. See his report this issue and pay particular attention to his request for comments. Who knows?

BYE BYE, YOUR SINCLAIR

Also included in the above- mentioned package from the U.K. is the sad news that YOUR SINCLAIR is preparing to fold. With it goes the last commercial publication in the U.K., so if you want to continue seeing products for your Timex and Sinclair computers you're going to have support the few remaining dealers, clubs and magazines still around on either side of the Atlantic .

That's all for now...

J.T

SINC-LINK

AN INTERBANK DATABASE FOR THE TS2068 Larken Library Disk #30 by G, Chambers

The Larken 2068 library has a disk #30 , called INTERBANK DATABASE. This disk has a suite of programs that make use of the bank-switching capability of the TS2068, when used in conjunction with the Larken RAMDISK, These programs were deve I oped by Larry Crawford , a longtime club member from London, Ont .

We think of the Larken RAMdisk as a sol id-state disk drive which has as 48 "tracks" on it, when eight 32K memory chips are instal I ed .

However, through a little-used capability of the TS2068, each of these memory chips can be sel ect ivel y interchanged with the upper 32K of computer memory, using OUT commands. Larry Crawford has written a program which makes use of this feature to provide us with a very useful database program. The most s ignif icant feature of this database is it's size. It's bank-sw itch ing capability means that a single database can expand to eight times the usual computer memory. Our disk #30 has an example of a database using 3 banks of RAMdisk, plus the computer memory.

Not too much use has been made of the suite of programs on this disk. When I look through the material in our news I etter I see very little written up about it. I must take some responsibility for this.

I always had some difficulty in comprehend i ng the make-up of Larry's disk. About a year ago I decided to rework it to make it more understandabl e. In the process I encountered problems (of my own making, I have to admit), and I had to ask Larry Crawford to help me out of them. He has done so recently and this article is to invite Larken RAMdisk owners to sample this disk.

Actually #30 consists of several disks, each with a different database application. The idea being to give you some idea of how you could make use of this program. One disk contains a database of the titles of 2200 movie films. Another has a music col I ect ion database. There's one that holds a database of the complete SINC-LINK index of articles. And still another that contains a record of a co 1 1 ect i on of Spectrum games programs, and an index of games tips from Spectrum magaz ines.

You may wonder how this program can make use of the RAMdisk, when your RAMdisk is already full of your programs. The answer is really quite simple. During the process of loading the database the program places a copy of the original RAMdisk contents onto the database disk. Then when you are finished it re-saves the database from the RAMdisk, and restores the original RAMdisk contents .

Now, it is not sufficient that a database program be able to store large amounts of data. It must have other capabilities as well. The IBDB program can SEARCH, SORT, ADD, EDIT, DELETE, LIST, and PRINT out to a 2040 or large printer. You can set up the database so that it stores files of up to a maximum 1 27-character length. It will SORT on any selected column, and can SEARCH for any desired character string.

Do give this very interesting library aisk a try I

4

SINC-LINK

NEWPORT

by Hugh

The Newport Miracle which was sponsored by IQLR is now part of QL history.

On Friday June 4th, at the Carlton Motel in Newport, we had a busy time meeting and getting to know each other and general gabbing. Many visitors from all over the country were staying there, with some at other motels nearby. Central point being the Carlton.

The UK contingent consisting of Stuart Honeyball, Tony Firshman, and Bill Richardson were all busy on this day just talking about things in general, and there was a fair amount of swapping of wares and information.

I was able to meet many members of our club, and to discuss our club with them. I was also able at this time to show them a program I have just completed called QUANDEX, which is an index/cross reference type of thing for the QUANTA Magazine from the time it first started. This program is being sent to QUANTA for inclusion in their library. (I hope) It already is in our own QL Library.

On Saturday, I had a table on behalf of our club at the Salvation Army Building where the convention was held, and again meeting many of our members, and also many who were not members . I met many who had heard of us, and many who had not heard of us . Now I can say that many more know who we are, where we are, and what we are at.

I had my trusty QL with me, and all the stuff that goes with it, and also a few demo programs to keep interest alive in my little corner of the area. But shortly into the demo my trusty QL decided it was a bit shy and embarrassed in that hoard of milling bodies, and decided that it did not like the "1" key. So I replaced the membrane hoping that my troubles were solved, but my trusty QL was still not up to appearing in the public eye, and decided the only way to get seclusion was to stop accepting power at the power input socket. Woe is me, a lot of demo stuff to run, and a table loaded with literature, and my trusty QL goes all bashful on me.

REPORT Page 1

Bowie

However all was not lost. I was able to borrow from Bill Cable a spare unit to help me out, but I was not out of the woods yet!

When I started to install my Gold Card in Bill's machine I bent the pins in the port. But I was fortunate that I had a pair of long nosed do-dads and was able to get deep into the port and straighten out the pins.

I was back in business, many thanks to Bill Cable, and the demos were running again.

Those demos were mainly run using a program called Vision Mixer, utilising many of my EYE-Q pictures, plus some I had made with PictureMaster . I tried to make the demos interesting as well as amusing.

Vision Mixer is a program that allows you to change screens in a nice easy automatic manner, and the screens are changed in many different ways, just like on the TV for example .

While I was getting all this sorted out other parties were going full steam ahead with their own interests giving demos and selling stuff. There did not appear to be a great lack of the green stuff as many were in a buying mood.

Stuart Honeyball from Miracle Systems was there pushing his latest addition to the QL world, the QXL card, and doing good business which was evidenced by the number of bodies gathered around his table. The QXL card is a card that turns the PC into a QL compatible. I don't have a PC and don't imagine I will be getting one, so I was not too involved with being one of the many gawkers at his stand. And don't ask me how much as I can t remember the price.

Bill Richardson representing his own company, W.N.Richardson, was having no problems with empty space around his table. Plenty* of goodies for all to buy. Bill was also selling subscriptions to QUANTA and seemed to be doing good business all around.

SINC-LINK

5

NEWPORT

bj Hugh

Tony Firshman of TF Services was there giving demos and passing stuff around. He was at the next table to our own, but I did not get much time to see what he was up to. All I knew was that when I wanted to leave my table to get a breath of air, I had to push my way past his adoring mob. He is very strong on HERMES which is the new processor to replace the 8049. HERMES is reputed to get rid of that key bounce, and also to operate at higher baud rates which is what is required for the modem operations, plus a whole lot of other improvements. I think I will get one myself. I believe Mechanical Affinity also have them.

Tim Swenson was in attendance with his QL Hackers Journal. (QHJ) . For those who don't know what this is, it is a journal put out by Tim for the advanced programmer, and it deals with many languages in depth. It is available in booklet form, and also on disk. He puts out a new issue about every couple of months. If you are interested I can let you have his address. I also have most of QHJ on disk in our library.

To my right was Mechanical Affinity with Paul Holmgren and Frank Davis in attendance, and every time I looked at Paul I got the impression of a bundle of $$$ in his fist. More like a bookie than a trader. Lucky Paul!

John Impellizzeri and his partner were there showing off their tower assembly where the QL and all its whatevers are enclosed in one neat little stack. Looks mighty impressive to me. I could not get a price out of him for the conversion etc., but it would appear to be quite a bit less than what I had heard rumour say initially. We will have to wait and see what the future produces, and just keep your fingers crossed - a one unit affair for the QL may not be too far away!

Then of course we had Bill Cable of Wood and Wind Computing, he it was who loaned me his spare QL. He was demonstrating his new program called QLerk, which he has been working on for a couple years or so - a program which is suitable to run a

REPORT Page 2

Bowie

small business, or even your household finances. I have been privileged in having the opportunity to have a ver close look at this program, and while admitting there is going to be a period of getting to know QLerk, it is also a very comprehensive book-keeping system.

QLerk will write your cheques for you and keep the bank account in balance, (have you managed to do that yourself yet?) Looks after deductions, wages, accounts payable and receivable, prints purchase orders, balances up to five bank accounts, your wifes (wives?) petty(?) cash outputs, and also to the main thing, which is what is left for yourself at the end of the day. Not much these days I have to admit. Just be thankful for small mercies, egad - how small!

Bob Dyl was pushing IQLR which was the sponsor of the whole show. Thanks Bob.

NESQLUG utilised the serving hatch to the kitchen and provided us with donuts and soft drinks, just help yourself, and it was all for FREE. A very grateful thank to NESQLUG, and thank you for a wonderfu idea. That was also a very popular section of the show.

Who else was there? A whole bunch of dedicated QL users from a young man not yet in his teens, to old fogies like myself .

I have probably missed someone out, and if so, please accept my apologies, and the wet noodle treatment would be appropriate !

After the show closed many of us attended a dinner at the Newport Beach Hotel, where we enjoyed an excellent meal, and many the tale was told at the many tables .

On Sunday, there were little meetings going on the rooms of the Carlton Motel. Lots of coming and going and interesting chatter about programs and what was in the future and all that jazz.

Tony Firshman was running a BBS on two QL's connected by the serial ports, I

SINC-LINK

NEWPORT REPORT

Page 3

by Hugh Bowie

could not get near it as there were so many crowded into a small bedroom, but from what I did see it was a most interesting couple of hours.

Miracle are still working on their graphics card which should be coming out fairly soon. Not too much was said about it or its price, but it is going give a very high resolution to the QL. A great deal of interest was evidenced by the questions being asked.

I came home on the Monday, but many stayed on to have a look around at Cape Cod and the surrounding country in general .

From what I gather the UK people are willing and keen to come back again next year, and since I have arrived home, I have been told that the German and some other continental suppliers of QL ware are interested in coming if there should be another convention over here, but I have heard that they would like to see it further inland the next time.

I have also heard the comment that there should have been more lead time to enable a more comprehensive advertising campaign, to generate a greater interest.

In discussion with an interested party, (trader) I asked what they thought of Toronto and was told that would be an ideal place for a convention. I said that I would like to see a Sinclair convention covering ALL the Sinclair computers, and this was thought to be possible .

My thinking, and let me say this right here and now, my thinking is not that of the other club officers, it is just my own solitary single idea off the top of my head. I am tossing this out for comment, and I hope to get plenty of comment .

Owing to the cost of accommodation and meeting places in Toronto, I feel that an ideal area would be in the Hamilton - Toronto corridor. In this area it is easier to move around than in Toronto itself. Accommodation is cheaper. And

for anyone wishing to visit Toronto, there is the Queen Elizabeth Way (QEW) for fast commuting right into the heart of the downtown entertainment and shopping of centres of Toronto. There is also a bus service and a train service. The distance by QEW from Burlington to Toronto downtown is 32 miles.

This Hamilton-Toronto corridor is of easy access to travellers from all over. Those from the Eastern States would travel on the QEW, and for those from the South, it is only a few miles from the 401 on easy access highways.

As I have said earlier, lots of lead time is required for organisation and advert- ising. So if you would like to see this thing, I would like to know by reply exactly what your thoughts are.

Only if a certain level of support was indicated, would it be possible to start the ball rolling. So if you want to see this come off, write to me today and give me your views and comments. I am adding my address at the end of this so that you may write right away.

Remember if you want to see a Sinclair convention in the Toronto area, please write .

And when you write, please let us know what traders you would like to see there. Not all asked would come or be able to come, but at least we could ask them.

Was the Newport Miracle a success? I would say so, and so also would many others. Apart from the traders who appeared to be happy, the general consensus would be that everyone was happy to have attended and to have met so many old friends, and made so many new ones. Is that not what a convention is all about?

Hugh H. Howie, QL Contact, 586 Oneida Dr. Burlington, Ont. Canada, L7T 3V3 (416) 634 - 4929

SINC-LINK

Q L I P S

by Hugh Bowie

Sometimes I sit down and have no idea in the world just exactly what I am going to see on the paper as it comes out of the printer. Today, you fortunate folks out there are going to get a sample of what comes out at one end after I have put nothing in at the other. So just sit back and relax, this is going to be one of those days you don't need, but that still seem to pop up at odd times, only too frequently.

Tother day I was trying to copy a Cartridge to Disk and that darn thing just would not go over - kept getting that old QL story "Bad or Changed Medium" which we have all had with various degress of teadiom (I told you it was going to be one of those days)

Anyway I got that message and do what I might I could not get that copied over, and I badly wanted the transfer made.

A thought came to my mind, at least what is left of it, mind that is, and I copied from Cart to RAM just to see if I could operate from RAM. After doing so for a while I decided to copy RAM to Disk just for kicks and to see what happened. An' by golly that stuff went from ram to disk just like that, (snap-o-da-thum)

So I again tried to get a copy from Cartridge to Disk - No Go. I then tried Cartridge to RAM and RAM to Disk and again by golly you should have seen that thing go over just like that. (Snap-o-da- thum)

Now why will it go from Cart to Ram to Disk, and yet will not go from Cart to Disk direct?

Network Prover.

Every time I say this is it - no more money to be spent on this QL, I see something that tickles my fancy, and recently I saw that there was a Network Prover. A gadget to indicate that the Network system was aworkin . So I spent a few bucks and got this thing from Dilwyn Jones, and by golly that thing really does work!

Often I have wondered if the Net was

working or just making look like, but this Network Prover really does send out a flashing light to show that data is being transferred. Cost? £3.50.

Now I can sit and watch the light flash as I wait for the transfer to be made. I never stop being amazed at the wonders of science!

I just looked at my little list of things to write about, and I see the word CARDS, now what the heck is that? It should remind me of something, but what? I just don't have a QLue.

Oh Yes! now I remember. In the past I have made up some "business" cards for members going to a convention or show or whatever. The cards could also be pinned to the lapel for identification purposes. If the owner got lost you always knew where to send him/her.

Anyway, to make those cards was not that easy, as the paper I used was a little bit glossy, the friction feed had no friction, and it did not have those little holes in the side of the paper t help it to run properly through th printer. But I got an idea * FLASH * and my problem was pretty well solved.

I use those 3 1/2 inch address labels in sheets with holes at the edges, (gee thanks - I know they are called perforations) so I saved the strip after the labels had been removed, and taped a piece of cardboard, cut to the required width, to the strip, fed it through the printer from the front, and I have no more of this slipping and sliding and and funny type as the paper goes through the printer.

This works fine with my Panasonic 1124 as it has front loading, but is no good with my Seikosha 1600 as the rollers make the cardboard bend too much.

Well that is how I did it, you do it your own way.

I started with nothing to write abou*- and I have ended up the same way. And have filled a page with nothing. So There! (Tip of tongue is shown)

SINC-LINK

TANK VOLUME

Bob Nil son

Here is a TS1000 program listing written by the depth of fluid in the tank. It is a good user.

llREM ** TANK UOLUME ** ** BOB UILSON ** 10 PRINT TRE li; "TANK UOLUME:: 15 PRINT 20 PRINT

30 PRINT ;

V

40 PRINT ;

V

50 PRINT .; 6S PRINT ;

70 PRINT

I

V

90 PRINT 100 PRINT " >B <> L

< >B < 11 110 PRINT

115 REM ** INPUT ** 120 PRINT " INPUT DIMENSIONS IN INCHES" 130 PRINT

14-0 PRINT "TANK DIAMETER " "D 150 INPUT D

150 PRINT AT 14- ,27 ;"=■*; D 170 PRINT "CYLINDRICAL PPRT LEN 6TH " "L 180 INPUT L

190 PRINT AT 15.27; "=";L

200 PRINT "BULBOUS PPRT ■•»B""!!

210 INPUT B

220 PRINT AT 15 .27 ; " =" ; B 230 PRINT HEIGHT OF LIQUID

one of our club leibers to calculate tne volute of a tank based on exaiple of the kind of programs that can simplify the vork of the

R. Bruneau

390 REM ** UOLUME CALCULATION *

4-00 LET X=PCS Cl-t2*H/D))

4-10 LET A5=D**2*X/4

4-20 LET AT=D/2*A55 (D/2-M;*SIN

"' 430 IF H<=D/2 THEN LET U=CAS-RT ) *L

^40 IF H>D/2 THEN LET U= £flS+flT3 ±L

450 LET U=P5N t CH-D/2J / (D/2'H 450 LET U=D**2*B/24* >4*C05 U*CO

S U*COS U*SIN Li + 6*(U*5IN (2*U) /2

) -!-3*PI)

470 LET UI=INT t (U+U) /£77*100+ . 5 3 /I 00

430 LET UU=INT [ CU+UJ /230 . 64959 *100* . 5) /130

490 LET UL=INT ( (V+U) /6 1.03*100 4.53 .-100

500 RETURN

240 INPUT H

250 PRINT PT 17.27: "=".H 25© GOSUE 400. 270 PRINT

280 PRINT "TANK UGL . IN IMP L . =" ; ui

290 PRINT U.S L. =".; vU

300 PRINT - ES=" ; UL

310 STOP

H

. GP, . GP LITP

TANK UOLUME

if

: B . > L

INPUT DIMENSIONS IN INCHES

B <

TANK D IP METER "D" =£4

CYLINDRICAL PART LENGTH "L!I=48

BULBOUS PART "B" =b

HEIGHT OF LIQUID "H" =12

TANK UGL. IN IMP. GAL . =44 . 1 U.S. GAL. =52.95 LITRES =200 . 14

SINC-LINK ADVERTISES FDR FREE PLACE YOUR AD HERE AND GET RESULTS!

SINC-LINK

Photocopied fro. tkt Harch 1986 issue of Practical Electronics, an english P""""* 1932. Thoujh the article taroets the Spectrui, it should uork on the 2068 and the ZX81/TS 1000.

Spectrum _

Hardware

RESTART

R.Macfarlane

THIS board is designed to plug into the Spectrum edge connector and will allow the user to escape from any running program without losing the memory contents. The action is similar to the BREAK key on the keyboard which jumps to a routine within the Spectrum ROM, prints BREAK and eventually returns to the <K) cursor. However, if the BREAK key has been disabled then the only recourse is to remove the bower plug and reset the system which, of course, clears the memory contents. It can also be extremely annoying if during the development of a machine code program the computer enters a loop from which there is no escape. With this circuit the Z80 processor can be forced to jump to any address within the Spectrum ROM or RAM.

When running BASIC programs the address of the Auto List routine in ROM was chosen as the restart address. Executing a hardware restart therefore produces an automatic listing of the first few lines of the program and then returns to the (K) cursor. Further Basic commands can now be entered and run, eg. Lib.. , SAVE, PRINT, etc.

When running machine code the address EOOOH was chosen. This is the start address of the ZEUS Assembler program wh.ch is used to develop machine code programs. Again, executing a hardware restart produces the ZEUS copyright symbol and by using 0 for OLD, the original source file can be recovered intact.

However, any restart address may be chosen to meet the needs of the individual user.

SYSTEM OUTLINE

When the Spectrum is first switched on the reset line to the £bu processor chip is held low for a few milliseconds by the action of Ra and Ca (Fig. 1). This ensures that the supply rails are given time to reach their operating voltage and that the CPU is properly initialized.

The initialisation includes:

1) Forcing the program counter to zero.

2) Disabling the interrupts.

3) Setting the interrupt register to OOH.

4) Setting the refresh register to OOH.

5) Setting interrupt MODE 0.

During reset time the address bus and the data bus go to a high impedance state and all control output signals go to the inactive state. No refresh of the dynamic memory occurs so that all memory contents are lost.

When the reset line eventually goes high the CPU executes the instruction found at address OOOOH which is the start of the initialisation procedure for the Sinclair Basic in ROM.

In order to restart the system at a different address two conditions must be met. The reset line must be held low for as short a period as possible so that the memory refresh cycles ; are maintained and memory contents are not lost. When the CPU addresses location OOOOH it must find a different set of instruc- tions to the ones held in the Sinclair BASIC ROM. To achieve these conditions, therefore, the external circuit operates in the following

A short 50uS pulse is applied to the reset line of the Z80 CPU. This is of sufficient duration to properly initialize the CPU but have no effect on the memory contents. Coincident mththis pulse he Spectrum BASIC ROM is deselected using the ROMCS line on the edge connector and an external ROM selected in its place

The CPU will then run the program within this new ROM which in fact holds a jump instruction to another address. When the jump is completed the external ROM must be deselected and replaced by the Spectrum BASIC ROM.

To understand how the ROMs are selected and deselected an explanation of the Z80 Ml output is required.

The Ml (Machine Cycle One) is an active low output which indicates that the CPU is currently executing an operating code fetch cycle. The OP Codes can be any one of the 1 58 different in- structions that the Z80 can execute, eg. LOAD. ROTATE. CALL. JUMP, HALT, etc.

Examination of the Jump instruction is shown in Table 1 .

This is a three byte instruction, the first byte containing the OP Code for JUMP, the following two bytes holding the address to be jumped to. However, only when fetching the OP Code from memory will the CPU issue an Ml cycle output signal. The CPU knows that the following two bytes must form an address and tne Ml output stays high.

OP CODE

C3

Low Order Address

A2

High Order Address

12

Table 1.

JUMP Instruction

Aner a reset puis>e un> ^< <-> "... , , .

zero. The address bus is, therefore, OOOOH and the CPU is looking for its first instruction. The Ml output goes low as the CPU executes an OP Code fetch cycle. The falling edge of the Ml output is used to switch from internal to external ROM and control can be handed back to the internal ROM at the next occurrence of an Ml cycle.

SPECTRUM KEYBOARD

As stated earlier, when the CPU is reset the interrupts are disabled end the MODE is set to 0. Without wishing to delve deeply into the interrupt structure of the Z80 CPU it is sufficient to say that the Spectrum Keyboard operating system requires the CPU to be in MODE I and that the interrupts are enabled. Before jumping to the new address, therefore, two extra commands must be executed. These are IM I and El.

RESTART PULSE

ICSb PIN S, 0

ICSo_ PIN 6, Q

lC6b PIN I. Q

ICSb PIN 9,0

i

L

PROMCS

gnus* i

Fig. 1. Timing diagram showing the Ml cyclas

SINC-LINK

COMPUTING

IO-ICS PI N 7 * ov

PINUx+SV

IC1o

7tlSU

mTo— ^^o-

IN4HI

w—

-OR0MCS

330 r 9 r i i-1— i

M *l >

e

*l

»*

01 0|

»t

IC7

01

IS 123

Bt

Dl

»0

n

tb

741SU

ice

7«05

Fig. 2. Complete circuit diagram of the Hardware Restart

IM I is a two byte OP Code and El a single byte OP Code. This brings the required number of OP Code fetch cycles to be executed in external ROM to four, ie, IM I, El. JP.

Four Ml cycles must, therefore, be counted before returning control to the Sinclair BASIC ROM. The timing diagram of Fig. 1 shows the relevant switching points.

CIRCUIT DESCRIPTION

IC1a buffers and inverts the Ml signal from the edge connector and the output is fed to the clock inputs of IC2a and IC5a. The re- set input to IC2a is held low by the output of IC1b the input of which is held high by R1, R2, CI. C1 serves to debounce the restart switch and R2 limits the discharge current of CI.

When the restart switch is pressed the reset on Pin 1 of IC2a is removed and the next negative going edge on an Ml cycle will clock IC2a causing the Q output to go high. Further incoming edges will cause no change since the D input is tied to the 5V rail and only when the restart switch is released will the Q output fall to zero.

The positive going edge at the Q output of IC2a triggers the one shot IC3 to produce a 50uS positive going pulse at the Q output Pin 6, which is in turn inverted by the parallel connected NOR gates of IC4. This parallel connection is required due to the internal combination of Ra and Ca enabling the power up reset for the Spectrum. Using IC4a, b, c, d in this way increases the sourcing and sinking currents and the above timing requirements can be met.

The second NOR input to IC4 is taken from the output of IC1c whose input is identical to IC1b. This provides a means of resetting the Spectrum without removing the power plug and also provides, due to the action of R5, C3, an external power up reset.

The output of IC 1 a is also fed to the input of IC5a Pin 3. which is connected as a divide by 4 counter The Q output of IC5b Pin 9 is connected to the clock input of a further divide by 2 stage IC6a. The reset inputs to the three stage counter are taken low during the 50uS Restart pulse by Q on IC3 pin 1 and the first negative go- ing edge of Ml to appear after the restart pulse will cause the Q output of IC6a Pin 6 to go low.

After four Ml cycles this Q output will go high again and is used as a clock input to IC6b.

During the 50uS restart pulse the set input of IC6b Pin 10 goes low causing the Q output at Pin 9 to go high. This deselects the

Spectrum ROM and simultaneously the 0 output at Pin 8 selects the external ROM. When the clock input of IC6b Pin 1 1 goes high this state is reversed. Further clock inputs to lC6b are ignored due to the D input being tied to the 0V rail and can only change state after the set input is once again taken low by another restart pulse.

IC6b, therefore, selects the external ROM on the negative edge of the restart pulse and selects the internal ROM four Ml cycles later. Diode, D 1 is included in the ROMCS line and this input is con- nected in a wired OR configuration within the Spectrum.

IC7 is a 32*8 tri-state fusible PROM. When the CS Pin 1 5 is high the data outputs are in a high impedance state and do not affect the operation of the internal data bus on the Spectrum.

Switch SW3 selects one of four 8-byte blocks giving a possible four selectable restart addresses. AO, A1, A2 are connected to the Spectrum address bus and select the program data held in one of these four blocks.

The contents of the PROM are shown in Table 2.

Addr

BLOCK

SW3

00H

ED

56

FB

C3

00

EO

*

*

1

3

08H

ED

56

FB

C3

A2

12

*

*

2

2

10H

*

*

*

3

1

18H

*

*

*

*

4

0

Table 2. Contents of the 32*8 ♦ri-state fusible PROM

POWER SUPPLY

The internal 5V supply from the Spectrum cannot supply the necessary current so an onboard 5V regulator is used. An unregulated 9V from the Spectrum power pack is available on the edge connector and this is used to drive the external restart circuit.

CONSTRUCTION

The printed circuit board is double sided and requires a number of through hole connections to be made using linking pins (Fig. 3).

The resistors and capacitors should be soldered in place first, remembering to solder on both sides of the board where required as some leads form necessary through connections.

The i.e. sockets, regulator and switches can then be added along with the edge connector, being careful to mount this on the

SINC-LINK

correct side of the board. The i.c.s can now be inserted and with switch SW3 in position 2, the board can be connected to the rear eage connector on the Spectrum.

TEST PROGRAMS

Test Program 1

40 PRINT "RESTART"; 50 GOTO 40

Test Program 2

10 POKE 23296.243: REM Disable Interrupts

20 POKE 23297,201: REM Return ' 30 RANDOMIZE USR 23296: REM Run m/c and return to Basic 40 PRINT "RESTART"; 50 GOTO 40

easily have been stopped using the break key itself.

Running the Test Program 2 will disable the keyboard interrupt and then print a continuous stream of RESTARTS. There will be no response to the break key and eniv by use of the RESTART button can the listing be retrievea.

It should be noted that breaking into commercial software is now quite possible but that the board should not be used for the purpose of copying tapes as this is forbidden by copyright.

If running the ZEUS assembler program, then pressing the RESTART button, with SW3 in position 3, will immediately return the user to this program start either from BASIC, without requiring the usual PRINT USR 57344 start up command, or from the currently executing machine code program.

rig. 3. The p.c.b. design and component layout

COMPONENTS

Resistors

R1.R4

R2, R5 R3

R6, R7

330 (2 off) 10K (2 off) 68K

47K (2 off)

r.

All resistors 5% 0*25 W carbon

Capacitors

C2.

C3 . ' C4, C5 . C6-C12 . ,

10u16VTant ,1n Ceramic 68m 6-3V Tant 680n Polyester (2 off) . 100n Ceramic (7 off)

Semiconductors

D1

ICl"

IC2, IC5, IC6

IC3

IC4

IC7

IC8 . .

IN4148 •74LS14

74LS74 (3 off) ^ 74121

74128

N82S123 PROM 7805

TESTING

Vith the unit connected, power can now be arjoiied. The Soectrum should come up with the familiar white screen and 3ASIC ROM message. Pressing the RESET button snould bring ;oout a similar result.

;f the small BASIC program (Test Program 1 ) is entered and run, rxecution can be immediately stopped by pressing tne RESTART mutton and an automatic listing of the program will aooear. The :rogram can at this point be re-run, listed or savea as oesired.

The significance of the restart will become apparent only when -ne break key is disabled, as the above program could just as

Miscellaneous

SW1,.SW2 v: Min. p.c.b. keyboard (R.S. 334-892) SW3 •*■ Horiz. decimal switch (R.S. 334-965)

14-pin d.i.l.skt (6 off) , , £f

' :1 6-pin d.i.l.sktjl off) ' ' ' ; ' . :7$&

28-way Double sided edge connector (Wire wrap tags) I