+ All Categories
Home > Documents > The Transactor V8 03 1987 Nov

The Transactor V8 03 1987 Nov

Date post: 08-Apr-2018
Category:
Upload: cubemanpdx
View: 226 times
Download: 0 times
Share this document with a friend
84
8/7/2019 The Transactor V8 03 1987 Nov http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 1/84
Transcript
Page 1: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 1/84

Page 2: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 2/84

T h eP o t p o u r r iD i s k

H e l p !

T h i sH E L P f u lu t i l i t yg i v e sy o ui n s t a n t

m e n u - d r i v e n a c c e s st o t e x tf i l e s

a t t h et o u c ho f a k e y- w h i l ea n yp r o g r a mi s r u n n i n g !

L o a nH e l p e r

H o wm u c hi s t h a tl o a nr e a l l yg o i n g

t o c o s ty o u ?W h i c hi n t e r e s tr a t e

c a ny o ua f f o r d ?W i t hL o a nH e l p e r ,

t h ea n s w e r sa r ea s c l o s ea s y o u r

f r i e n d l y6 4 !

K e y b o a r d

L e a r n i n gh o wt o p l a yt h ep i a n o ?

T h i sh a n d ye d u c a t i o n a lp r o g r a mm a k e si t e a s ya n df u nt o l e a r nt h e

n o t e so n t h ek e y b o a r d .

F i l e d u m p

E x a m i n ey o u rd i s kf i l e sF A S Tw i t h

t h i s m a c h i n el a n g u a g eu t i l i t y .

H a n d l e ss i xf o r m a t s ,i n c l u d i n g h e x ,

d e c i m a l ,C B Ma n d t r u e A S C I I ,

W o r d P r oa n dS p e e d S c r i p t .

A n a g r a m s

A n a g r a m sl e t s y o u u n s c r a m b l e

w o r d sf o r c r o s s w o r dp u z z l e sa n d

t h el i k e .T h ep r o g r a mu s e sa r e c u r

s i v eM Ls u b r o u t i n ef o r m a x i m u m

s p e e da n de f f i c i e n c y .

L i f e

A F A S Tm a c h i n el a n g u a g ev e r s i o n

o f m a t h e m a t i c i a nJ o h nH o r t o n

C o n w a y ' sc l a s s i c s i m u l a t i o n .S e t

u p y o u ro w n' c o l o n i e s 'a n dw a t c h

t h e mg r o w !

W a rB a l l o o n s

S h o o td o w nt h o s ee v i lN a z iW a r

B a l l o o n sw i t hy o u rh a n d yA c m eC a n n o n !D o n ' tl e tt h e mg e ta w a y !

V o nG o o g o l

A t l a s t ! T h e m a d p h i l o s o p h e r ,

H e l g av o nG o o g o l ,b r i n g sh e ro w nb r a n do f w i s d o mt o t h e s m a l l

s c r e e n !I f t h i si s ' A l ' ,t h e ni t j u s t a i n ' t

n a t u r a l !

N e w s

S a v et h e m o n e yy o u s p e n do n

t h o s es u p e r m a r k e tt a b l o i d s- t h i s

p r o g r a mw i l l g e n e r a t ee q u a l l y

c o n v i n c i n gh e a d l i n ec o p y- f o r

f r e e !

W r d

T h eu l t i m a t ei n e a s y - t o - u s ed a t a

b a s e p r o g r a m s .W R Dl e t s y o u

q u i c k l ya n ds i m p l yc r e a t e ,e x a m

i n ea n de d i tj u s ta b o u t a n yd a t a .

C o m e sw i t hs a m p l ef i l e .

Q u i z

T r i v i af a n a t i c sa n d s t u d e n t sa l i k e

w i l l h a v ef u n w i t ht h i s p r o g r a m ,

w h i c hg i v e sy o u m u l t i p l ec h o i c e

t e s t so n m a t e r i a ly o u h a v e e n

t e r e dw i t ht h eW R Dp r o g r a m .

A H A !L a n d e r

A H A I ' sg r e a tl u n a rl a n d e rp r o g r a m .

U s ee i t h e rj o y s t i c ko r k e y b o a r dt o

c o m p e t ea g a i n s ty o u r s e l fo r u p t o

8 o t h e rp l a y e r s ,W a t c ho u t f o r

s p a c em i n e s !

B a gt h eE l v e s

A c u t el i t t l ea r c a d e - s t y l eg a m e ;c a p t u r et h e e l v e si n t h e b a ga s

q u i c k l ya s y o uc a n- b u td o n ' tg e t

t h eg o o de l f !

B l a c k i a c k

T h e m o s tf l e x i b l eb l a c k j a c ks i m u l a

t i o ny o u ' l lf i n da n y w h e r e .S e t u p

y o u rf a v o u r i t er u l ev a r i a t i o n sf o r

d o u b l i n g , s u r r e n d e r i n ga n d s p l i t

t i n gt h e d e c k .

F i l pC o m n n r p

W h i c ho f t h o s et w of i l e sy o uj u s t

c r e a t e di s t h e m o s tr e c e n tv e r

s i o n ?W i t ht h i sg r e a tu t i l i t yy o u ' l l

n e v e rb e l e f tw o n d e r i n g .

G h o u lD o g s

A r c a d em a n i a c sl o o ko u t !Y o u ' l l

n e e da l l y o u rd e x t e r i t y t oh a n d l e

t h i sw i c k e dj o y s t i c k - b u s t e r !T h e s e

m a d d o g - m o n s t e r sf r o ms p a c e

a r en o tf o rn o v i c e s !

O c t a g o n s

J u s tt h et h i n gf o ry o uM e n s at y p e s .

O c t a g o n si s a c h a l l e n g i n gp u z z l e

o f t h e m i n d , F o u rl e v e l so f p l a y ,

a n d a t o u g h ' m e m o r y 'v a r i a t i o n

f o rr e a le x p e r t s !

B a c k s t r e e t s

A n i f t ya r c a d eg a m e ,1 O O %m ac h i n el a n g u a g e ,t h a t h e l p sy o u

l e a r nt h e t y p e w r i t e rk e y b o a r d

w h i l ey o up l a y ! U n l i k ea n yt y p i n g

p r o g r a my o u ' v es e e n !

A l lt h ea b o v ep r o g r a m s ,j u s t$ 1 7 . 9 5U S ,$ 1 9 . 9 5C a n a d i a n .N o ,n o tE A C Ho f t h e

a b o v ep r o g r a m s ,A L Lo f t h e a b o v ep r o g r a m s ,o n a s i n g l ed i s k ,a c c e s s e d

i n d e p e n d e n t l yo r f r o ma m e n u ,w i t hb u i l t - i nm e n u - d r i v e nh e l pa n df a s t - l o a d e r .

T h eE N T I R EP O T P O U R R IC O L L E C T I O N

J U S T$ 1 7 . 9 5U S ! !

S e eO r d e rC a r da t C e n t e r

Page 3: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 3/84

V o l u m e8

I s s u e0 3P a i dC i r c u l a t i o n

1 5 , 0 0 0

B i t sa n dP i e c e s. . 6R i b b o nR e j u v e n a t i o n

C A U T I O N !

D e f a u l t s

P e e k - a - P a g e

F i l eH i d e r

M o r e o nt h eV A LB u g

M u l t i p l yB u g

L I S TD u r i n ga P r o g r a m

I n s i d eV i e w

M o b i l eB A S I C

B y t e sF r e e

G e t t i n gT h eB o o t

B o o t i n gU pY o u rM o d e M e n uQ u i c kF i l eC o p i e r

F A S TG U L P

B u i l t - i nC r a s hP r o t e c t i o n

C o m m o nM e m o r y

C u s t o m i z i n gC L IW i n d o w s

T i t l e si n A m i g a B a s i c

E a s t e rE g g s

L e t t e r s 1 3G l o s s yp a p e rp r i c i n g

B l a z i n 'F o r t hd o c s

D r i v eh e a dn o i s ea b a t e m e n t

T h e6 8 0 1 0 a n dc o m m e r c i a ld i s k s

T a k i n gA m i g at o t a s k

M y s t e r i o u sq u o t em o d ee x p l a i n e d

G u r um a i ld e p a r t m e n tM o r eP l u s / 4T e c hI n f o

N e w sB R K 7 6N o - F a u l tP r o g r a mE n t r y I n s u r a n c e

S e n dT P U GS u b s c r i p t i o n st o T P U G !

T r a n s a c t o rR e n e w a l s

M u l t i p l eY e a rS u b s c r i p t i o n s

U s et h eN e wS u b s c r i p t i o n C a r d s !

N e wT r a n s a c t o rS p e c i a l O f f e r s

U . S .O r d e r sI n v o i c e dI n C a n a d i a nD o l l a r s

A d v e r t i s e r sW a n t e d

G r o u pS u b s c r i p t i o nR a t e s :T h e 2 0 / 2 0D e a l

M a i l - O r d e rP r o d u c t sN o L o n g e rO f f e r e d

T r a n s a c t o rM a i lO r d e r

A m i E X P Oi n N e wY o r kC i t y

S p e c i a lA m i g aS o f t w a r eO f f e r

B e n c h m a r kM o d u l a - 2f r o mO x x i ,I n c .

D e s i g n T e x t ,f r o mD e s i g n T e c h

J F o r t h ,f r o mD e l t aR e s e a r c hI n c .

L e x C h e c k , f r o mC . D . AI n c .

V i d e o S c a p e3 D , f r o mA e g i sD e v e l o p m e n tI n c .

T r a n s B l o o p s. . .T h eB l u n d e r f u lM r .E d

L o n g S y m a s sL a b e l s

S p a c eo r N u l l S t r i n g

A f e wT r a n s B a s i cb u g s

C a p a c i t a n c eM e t e rL i n eN u m b e r s

F i r s t — A i df o rP r o g r a m m e r ' sA i d

X r e f 6 4

D i v i s i o nR e v i s i o n

1 1

T r a n s a c t o rT h eP u n t e r N E T B B Sn e t w o r k 1 8

A S w i t c h a b l eR S - 2 3 2I n t e r f a c eA ne a s yd o - i t - y o u r s e i f R s - 2 3 2a d a p t e r. . 1 9

B u l l e tP r O O fC O m p U t e r SS i m p l e s u r g ep r o t e c t i o na n do t h e rt i p s 2 2

T h e1 5 8 1 D i s kD r i v ea t e c h n i c a l e v a l u a t i o n 2 6

C P / Ma n dt h e1 5 8 1D i s kD r i v ew h yb u yu p g r a d e s ? 3 3

P r o g r a m m i n gt h e1 5 4 1K n o t *h u d » y o ut h i n u 3 5

A u t oT r a n s m i s s i o nf o rt h eC 6 4a na u t ou n - r u nu t i l i t y 4 0

L O n H T l O nv ^ O Q ea n o t h e ra p p r o a c ht oc o d ec o m p r e s s i o n 4 1

G O U OD a n C e rt h e u l t i m a t e l a b e l l e dg o t ou t i l i t y 4 6

N O WY O US e eI t , N O WY O UD o n ' tC 6 4t r a n s p a r e n tc a r t r i d g e s 4 9

F i d d l i n gA b O U th i g hr e s o l u t i o n8 0c o l u m nc o l o u ro nt h eC l 2 8 5 1

T w i n8 0 S c r e e nf o rt h eC 1 2 8t w o ,t w o ,t w om o n i t o r si no n e ! 5 6

M e m o r yL a n eE x p l o r i n gt h ed a r ka l l e yo f fZ e r o - P a g eS t r e e t 6 0

A m i g aS e c t i o n

t iV e n tI V l a K e rN o b o d yd o e si t b e t t e r .. . f a s t e ra n dm o r ea c c u r a t e l yt o o ! v Z

A N e WE C H OI m p r o v i n g o nA m i g a D O S 6 6

A m i g a P r o g r a m m e dC W S O r ?J i mB . o f f e r ss o m ec o n s o l e - a t i o n 7 0

O u rs w i t c h e d - o ns c r i b e b r i n g sy o ut h el a t e s tn e w s I D

N o t e :b e f o r ee n t e r i n gp r o g r a m s ,s e e" V e r i f i z e r "o n p a g e4

T r a n s a c t o rA B O U TT H EC O V E R :T o r o n t o ' sC NT o w e ri s t h et a l l e s tf r e e - s l a n d i n g s t r u c t u r ei n t h e

w o r l d .I t t o o kj u s to v e r3 y e a r sf o ra c r e wo f 1 5 3 7t o c o m p l e t et h e t o w e r ,a t a c o s t o f$ 5 7

m i l l i o n .I t w a sb u i l lb y C NT e l e c o m m u n i c a t i o n st o o v e r c o m et h ep r o b l e m sf a c e db y f i r m s

w i s h i n gt o t r a n s m i tt h e i rs i g n a l sn o r t h w a r dp a s tt h eg r o w i n gT o r o n t od o w n t o w nc o r e .T h e

t i p r e a c h e s1 8 1 5f e e t5 i n c h e s( 5 5 3 . 3 3 m )i n t ot h es k y- a b o u t5 ' / sf o o t b a l lf i e l d s .T h e

" d o u g h n u t " s h a p e dp o r t i o nh o u s e s m o s to f t h ec o m m u n i c a t i o n se q u i p m e n t .T h ea n g l e d

p e r i m e t e rj u s ta b o v ei s t h eo u t d o o r o b s e r v a t i o nd e c k( h e i g h t :1 1 3 6f e e to r 3 4 6 m ) .O n e

f l o o ra b o v et h a ti s t h e i n d o o r o b s e r v a t i o n d e c k .O n ( h es a m el e v e li s " S p a r k l e s " , a

d i s c o t h e q u ew i t ha s p e c t a c u l a rv i e wo f t h eT o r o n t os k y l i n e ,s a i dt o b e o n eo f t h em o s t

h a n d s o m ep r o f i l e si n t h e w o r l d .A b o v et h a ti s t h e " T o po f T o r o n t o "r e s t a u r a n t , a p t l y

n a m e d ,w h i c hm a k e so n ec o m p l e t er e v o l u t i o ne v e r y7 2 m i n u t e s .T h es m a l l e rp o da t t h e

b a s eo f t h ea n t e n n ai s k n o w na s t h es p a c e d e c k .I t ' st h e h i g h e s to b s e r v a t i o n d e c ki n t h e

w o r l da t 1 4 6 5f e e t( 4 4 7 m ) ,b u to n l y1 1 f e e th i g h e r t h a nt h e r o o fo f t h eS e a r sT o w e ri n

C h i c a g o .A l ld e c k sc o m b i n e d h a v ea c a p a c i t yo f a b o u t4 0 0p e o p l e ,a n da b o u t1 . 7m i l l i o n

v i s i te a c hy e a r .A s c e n d i n go r d e s c e n d i n g ,t h e e l e v a t o r st r a v e la t a b o u t1 5 k m h ,m a k i n g

S t h e mt h ef a s t e s tc o m m e r c i a le l e v a t o r si n t h ew o r l d - d e s c e n d i n gi s e q u i v a l e n tt o f a l l i n gi n

a n o p e np a r a c h u t e .T i pt o b a s e ,t h et o w e ri s w i t h i np l u m bb y 1 . 1 i n c h .O nw i n d yd a y st h et i pc a ns w a y3 f e e t i ne i t h e r d i r e c t i o n

( l i m i t e db yt w o1 0t o ns w i n g i n gc o u n t e r w e i g h t sm o u n t e do n t h ea n t e n n a ) ,a n dw a sd e s i g n e dt o w i t h s t a n dw i n d s u pt o 2 6 0m p h .

A l lw i n d o w sh a v e a no u t e r p a n e ,3 / si n c ht h i c k ,a n i n n e r p a n e ,' A i n c ht h i c k ,a r ea r m o u r - p l a t e d ,a n dc a nw i t h s t a n dp r e s s u r e si n

e x c e s so f 1 2 0p s i .A l lc o n s t r u c t i o n m a t e r i a l sw e r e c h o s e nf o rt h e i rf i r e - p r o o fo r f i r e - r e s i s t a n t q u a l i t i e s .S m o k i n gi s a l l o w e di n t h e

r e s t a u r a n t so n l y .I n t h e u n l i k e l ye v e n to f f i r e ,s e v e r a lp u m p sa t t h eb a s e c a n s e n du p 5 0 0g a l l o n so f w a t e r p e rm i n u t e .T h e r ei s

a l s oa r e s e r v o i ro f w a t e rj u s ta b o v et h em a i np o d . L i g h t n i n gs t r i k e st h et o w e ra b o u t6 0 t i m e s p e ry e a rb u tt h e r e ' sp r o b a b l yn o

s a f e r p l a c ed u r i n ga s t o r m .E v e r ys u r f a c ew h i c hc o u l dp o s s i b l ya t t r a c tl i g h t n i n gi s a t t a c h e dt o t h r e ec o p p e rs t r i p sr u n n i n gd o w n

t h e t o w e r ,c o n n e c t e dt o f o r t y - t w o2 2 f o o tg r o u n d i n gr o d sb u r i e d2 0 f e e tb e l o wt h e s u r f a c e .S i n c et h et o w e ro p e n e di n 7 8 ,P r o f .

W a s y lJ a n i s c h e w s k y jo f t h e U n i v e r s i t yo f T o r o n t o h a sb e e ni n c h a r g eo f a l i g h t n i n gs t u d ya t t h eC NT o w e r .T h e y ' v ef o u n dt h a t

l i g h t n i n gs t a r t sI r o mt h e s m a l l e rs u r f a c e .S o i f i t h i t sa l a k e o ra f i e l d ,t h e l i g h t n i n gi n d e e dc o m e sd o w nf r o mt h ec l o u d s .I f t h e

l o w e re n do f t h ep a t hi s t h et i po fa t a l lb u i l d i n g ,t h e c l o u d sa r et h e nt h el a r g e rs u r f a c ea n dt h el i g h t n i n gg o e su p .S i n c el i g h t n i n gi s

t h er e s u l t o fo p p o s i t es t a t i cc h a r g e sb e t w e e nt h e c l o u d sa n dg r o u n d ,a n yt o w e r r e d u c e st h e d i s t a n c e t h es p a r ki s r e q u i r e dt o

j u m p ,w h i c hm e a n st h e d i s c h a r g e o c c u r sa t l o w e rv o l t a g e s .P r o f .J a n i s c h e w s k y j ' st e a mf e l tt h i sm i g h td o l e s sd a m a g e ,b u tt h e n

d i s c o v e r e dt h a tw h a ta p p e a r st o b e a s i n g l eb o l ti s o f t e n a c t u a l l y s e v e r a l r a p i d f l a s h e sw h e nt h el o w e re n di s t h et i po f a t a l l

s t r u c t u r e .I n f o r m a t i o n f r o mt h es t u d yw i l lu n d o u b t e d l ya s s i s tp o w e rc o m p a n i e sd e s i g ni n s u l a t o r so n h y d r ot o w e r st h a ta r el e s s

l i k e l yt o s h o r t - c i r c u i t .S p e c i a lt h a n k st o J o a n C o r m i e r a n dP e n n yW r i g h to f t h eC NT o w e rf o rs u p p l y i n gt h ep h o t oa n dt h e s e

i n t e r e s t i n gf a c t s .E x t r as p e c i a lt h a n k st o P a t r i c i aK e l l y ,a n dt o A l l a nS t o k e l lo f P o s i t i v eI m a g e s ,f o rh e l p i n g u sf i n dt h es u p p l i e r .

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 4: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 4/84

I t a n s a d o rT h «M o g a z l i Mf o rC o m m o d o r eP r o g r a m m e r !

E d i t o r - i n - C h i e f

K a r l J .H . H i l d o n

P u b l i s h e r

R i c h a r d E v e r s

T e c h n i c a lE d i t o r

C h r i sZ a m a r a

S u b m i s s i o n sE d i t o rN i c kS u l l i v a n

C u s t o m e rS e r v i c e

J e n n i f e rR e d d y

C o n t r i b u t i n gW r i t e r s

I a nA d a m

D a v i dA r c h i b a l d

J i mB a r b a r e l l o

A n t h o n yB e r t r a m

T i mB o l b a c h

D o n a l d B r a n s o n

N e a lB r i d g e s

A n t h o n yB r y a n t

J i mB u t t e r f i e l d

D a l eA . C a s t e l l o

B e t t y C l a yJ o s e p hC a f f r e y

T o mK . C o l l o p y

R o b e r tV . D a v i s

E l i z a b e t hD e a l

F r a n kE . D i G i o i a

C h r i sD u n n

M i c h a e lJ . E r s k i n e

J a c kF a r r a h

M a r kF a r r i s

J i mF r o s t

M i k l o sG a r a m s z e g h y

E r i cG e r m a i n

M i c h a e lT . G r a h a m

E r i cG u i g u e r e

T h o m a sG u r l e y

R . J a m e sd e G r a f fT i mG r a n t h a m

A d a mH e r s t

T h o m a sH e n r y

J o h nH o l t t u m

J o h nH o u g h t o n

R o b e r tH u e h n

D a v i d J a n k o w s k i

C l i f t o nK a r n e s

L o m eK l a s s e n

J e s s eK n i g h t

G r e g o r yK n o x

D a v i d L a t h r o p

J a m e sA . L i s o w s k i

R i c h a r dL u c a s

S c o t tM a c l e a n

S t e v eM c C r y s t a l

S t a c yM c l n n i s

C h r i sM i l l e r

T e r r yM o n t g o m e r y

R a l p hM o r r i l lD . J .M o r r i s

M i c h a e lM o s s m a n

B r y c eN e s b i t t

G e r a l d N e u f e l d

N o e lN y m a n

M a t t h e wP a l c i c

R i c h a r dP e r r i t

L a r r yP h i l l i p s

T e r r yP r i d h a m

R a y m o n dQ u i r l i n g

D o u gR e s e n b e c k

R i c h a r dR i c h m o n d

J o h nW . R o s s

D a nS c h e i n

E . J .S c h m a h l

D a v i dS h i l o hD a r r e nJ . S p r u y t

A u b r e yS t a n l e y

D a v i dS t i d o l p h

R i c h a r dS t r i n g e r

A n t o nT r e u e n f e l s

A u d r y sV i l k a s

J a c kW e a v e r

G e o f f r e yW e l c h

E v a nW i l l i a m s

P r o g r a mL i s t i n g sI n T r a n s a c t o r

A l lp r o g r a m sl i s t e di n T r a n s a c t o rw i l la p p e a ra s t h e yw o u l d o ny o u rs c r e e ni n U p p e r / L o w e rc a s e

m o d e .T oc l a r i f yt w op o t e n t i a lc h a r a c t e rm i x - u p s ,z e r o e sw i l la p p e a ra s ' 0 ' a n dt h el e t t e r" o "w i l lo f

c o u r s eb e i n l o w e rc a s e .S e c o n d l y ,t h el o w e r c a s eL ( T )i s a s t r a i g h t l i n ea s o p p o s e dt o t h en u m b e r1

w h i c hh a sa n a n g l e dt o p .

M a n yp r o g r a m sw i l lc o n t a i nr e v e r s ev i d e oc h a r a c t e r st h a tr e p r e s e n tc u r s o rm o v e m e n t s ,c o l o u r s , o r

f u n c t i o nk e y s .T h e s ew i l la l s ob e s h o w ne x a c t l y a st h e yw o u l da p p e a ro n y o u rs c r e e n , b u tt h e y ' r e

l i s t e dh e r ef o rr e f e r e n c e .A l s or e m e m b e r :C T R L - qw i t h i nq u o t e si s i d e n t i c a l t oa C u r s o rD o w n ,e t a l .

O c c a s i o n a l l yp r o g r a m sw i l lc o n t a i nl i n e st h a ts h o wc o n s e c u t i v es p a c e s .O f t e nt h en u m b e ro f s p a c e s

y o ui n s e r t w i l ln o tb e c r i t i c a lt o c o r r e c to p e r a t i o no f t h ep r o g r a m .W h e ni t i s ,t h er e q u i r e dn u m b e ro f

s p a c e sw i l lb e s h o w n .F o re x a m p l e :

p r i n t ' f l u s h r i g h t '- w o u l db e s h o w na s - p r i n t' [ 1 0s p a c e s ] f l u s hr i g h t '

C u r s o rC h a r a c t e r s F o rP E T/ C B M/ V I C/ 6 4

D o w n- Qu p - BR i g h t - DL e f t - [ l i t ]

R V S - QR V SO f f- D

I n s e r t - g j

D e l e t e -QC l e a rS c r n- QH o m e - QS T O P - H

C o l o u r C h a r a c t e r s F o rV I C/ 6 4

B l a c k- QW h i t e- QR e d - QC y a n - [ C y n ]

P u r p l e -[ P u r ]

G r e e n- Q

B l u e - B

O r a n g e-

B r o w n

L t .R e d -

G r e y1 -

G r e y2 -

L t .G r e e n-

L t .B l u e -

E lII1aii

Y e l l o w -[ Y e l ] G r e y3 - [ G r 3 ]

F u n c t i o nK e y sF o rV I C/ 6 4

F l -

F 2 -

F 3 -

F 4 -

F 5 - HF 6 -

F 7 - 0F 8 -

P r o d u c t i o n

A t t i cT y p e s e t t i n gL t d .

P r i n t i n g

P r i n t e di n C a n a d ab y

M a c L e a nH u n t e rP r i n t i n g

T r a n s a c t o ri s p u b l i s h e d b i - m o n t h l y b y T r a n s a c t o rP u b l i s h i n gI n c . ,8 5 W e s t W i l m o tS l r e e l ,U n i l1 0 ,

R i c h m o n dH i l l ,O n l a r i o ,L 4 B1 K 7 .C a n a d i a n S e c o n dC l a s s m a i lr e g i s l r a t i o nn u m b e r6 3 4 2 .U S P S7 2 5 -

0 5 0 ,S e c o n dC l a s sp o s t a g ep a i da t B u f f a l o ,N Y ,f o r U . S . s u b s c r i b e r s . U . S .P o s t m a s t e r s :s e n da d d r e s s

c h a n g e st o T r a n s a c t o r . P . O .B o x3 3 8 ,S t a t i o n C , B u f f a l o ,N Y .1 4 2 0 9I S S N '0 8 2 7 - 2 5 3 0 .

T r a n s a c t o ri s i n n o w a yc o n n e c t e dw i t hC o m m o d o r eB u s i n e s sM a c h i n e sL t d .o r C o m m o d o r eI n c o r p o r a t e d .

C o m m o d o r ea n dC o m m o d o r ep r o d u c tn a m e s( P E T .C B M ,V I C ,6 4 , 1 2 8 , A m i g a )a r er e g i s t e r e dt r a d e m a r k so f

C o m m o d o r eI n c .

S u b s c r i p t i o n s :

C a n a d a$ 1 9C d n . U . S . A .$ 1 5U S . A l lo t h e r $ 2 1U S .

A i r M a i l( O v e r s e a so n l y )$ 4 0U S . ( $ 4 . 1 5p o s t a g e / i s s u e )

S e n da l l s u b s c r i p t i o n st o : T r a n s a c t o r ,S u b s c r i p t i o n sD e p a r t m e n t , 8 5W e s t W i l m o tS t r e e t ,U n i t1 0 ,

R i c h m o n dH i l l ,O n t a r i o ,C a n a d a ,L 4 B1 K 7 ,4 1 6 7 6 45 2 7 3 .N o t e :S u b s c r i p t i o n s a r eh a n d l e da t t h i sa d d r e s s

O N L Y .S u b s c r i p t i o n s s e n tt o o u rB u f f a l oa d d r e s s( a b o v e )w i l lb e f o r w a r d e dt o o u rR i c h m o n dH i l lH Q .F o r

b e s tr e s u l t s ,u s e p o s t a g e p a i d c a r da t c e n t e ro f m a g a z i n e .

P l e a s eN o t e : T r a n s a c t o r ' s

p h o n en u m b e ri s :( 4 1 6 )7 6 4 - 5 2 7 3

Q u a n t i t y O r d e r s :

N o r l a n dC o m m u n i c a t i o n s2 5 1N i p i s s i n gR o a d ,U n i t 3

M i l t o n ,O n t a r i o

L 9 T4 Z 5

4 1 6 8 7 64 7 7 4

C o m p u S e r v eA c c o u n t s

C o n t a c tu s a n y t i m eo n G OC B M P R G ,

G OC B M C O M ,o r

K a r lJ . H .H i l d o n

C h r i sZ a m a r a

N i c kS u l l i v a n

E a s y P l e xa t :

7 6 7 0 3 , 4 2 4 2

7 6 7 0 3 , 4 2 4 5

7 6 7 0 3 , 4 3 5 3

S O L DO U T :T h eB e s to fT h eT r a n s a c t o rV o l u m e s1 & 2 & 3 ; V o l 4I s s u e s0 3 . 0 4 . 0 5 , 0 6 , a n dV o l 5I s s u e s 0 2 ,

0 3 ,0 4 a r ea v a i l a b l eo n m i c r o f i c h e o n l y

S t i l lA v a i l a b l e :V o l .4 : 0 1 , 0 2 . V o l .5 : 0 1 , 0 4 , 0 5 , 0 6 . V o l .6 : 0 1 , 0 2 , 0 3 , 0 4 , 0 5 , 0 6 .

V o l .7 : 0 1 , 0 2 , 0 3 , 0 4 , 0 5 , 0 6 . V o l .8 : 0 1 , 0 2 ,0 3

B a c kI s s u e s :$ 4 . 5 0 e a c h .O r d e ra i lb a c ki s s u e sf r o mR i c h m o n dH i l lH Q .

E d i t o r i a lc o n t r i b u t i o n s a r ea l w a y sw e l c o m e .M i n i m u mr e m u n e r a t i o ni s $ 4 0p e rp r i n t e d p a g e . P r e f e r r e d

m e d i aa r e 1 5 4 1 , 2 0 3 1 , 4 0 4 0 . 8 0 5 0 , o r8 2 5 0d i s k e t t e sw i t hW o r d P r o ,W o r d C r a f t ,S u p e r s c r i p t ,o r S E Qt e x t

f i l e s ,o r A m i g af o r m a t3 ' / 2 d i s k e t t e sw i t hA S C I It e x tf i l e s .P r o g r a ml i s t i n g so f m o r et h a n af e wl i n e ss h o u l db e

p r o v i d e do n d i s kM a n u s c r i p t ss h o u l db e t y p e w r i t t e n ,d o u b l es p a c e d , w i t hs p e c i a lc h a r a c t e r so r f o r m a t sc l e a r l ym a r k e d .P h o t o s s h o u l db e g l o s s y b l a c ka n dw h i t ep r i n t s .I l l u s t r a t i o n ss h o u l db e o n w h i t ep a p e rw i t h

b l a c k i n ko n l y .

A l l m a t e r i a la c c e p t e db e c o m e st h e p r o p e r t yo f T r a n s a c t o r . A l l m a t e r i a li s c o p y r i g h tb y T r a n s a c t o

P u b l i c a t i o n sI n c .R e p r o d u c t i o ni n a n yf o r mw i t h o u t p e r m i s s i o ni s i n v i o l a t i o no f a p p l i c a b l e l a w s . S o

m a t e r i a li s a c c e p t e do n a n a l l r i g h t s b a s i s o n l y .W r i t et o t h eR i c h m o n dH i l la d d r e s sf o ra w r i t e r ' sp a c k a g e .

T h eo p i n i o n se x p r e s s e di n c o n t r i b u t e da r t i c l e sa r en o t n e c e s s a r i l yt h o s eo fT r a n s a c t o r .A l t h o u g ha c c u r a c yi s

a m a j o ro b j e c t i v e ,T r a n s a c t o rc a n n o ta s s u m el i a b i l i t yf o re r r o r si n a r t i c l e so r p r o g r a m s .P r o g r a m sl i s t e d i n

T r a n s a c t o r ,a n d / o ra p p e a r i n go n T r a n s a c t o rd i s k s ,a r e c o p y r i g h tb yT r a n s a c t o r P u b l i s h i n gI n c .a n dm a yn o t

b e d u p l i c a t e do r d i s t r i b u t e dw i t h o u t p e r m i s s i o n .

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 5: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 5/84

C o p y C o p yR e v i s i t e d

H e r ea r es o m ee x c e r p t sf r o m p a g e3 e x a c t l yo n ey e a ra g o :

W e' u eb e e nr e c e i v i n ga n u m b e ro fl e t t e r sr e g a r d i n gl o c a ld u p l i c a t i o n

o f T r a n s a c t o rD i s k s .

O n c ea g a i n t h e q u e s t i o no f d u p l i c a t i n gT r a n s a c t o rd i s k sh a sb e e nt h et o p i c

f o rd i s c u s s i o na r o u n dt h eo f f i c e .I t ' sa m a z i n gh o wa p r o b l e mh i t sh a r d e ra t

h o m e .S o f t w a r ep i r a c yh a sb e e na l la r o u n du s f o ry e a r sa n da l t h o u g hy o u

k n o wi t ' sa f f e c t i n gt h e i n d u s t r y ,y o uc a n ' ti m a g i n et h e i m p a c tu n t i ly o u

b e c o m ea v i c t i m .R e c e n t l yw e ' v el e a r n e dt h a tm a n yu s e rg r o u p sa n do t h e r

" v e n d o r s "h a v eb e e no f f e r i n gT r a n s a c t o rd i s k so n a r e g u l a r b a s i sa t

s u b s t a n t i a l l yl e s st h a n o u rr e t a i lp r i c e .

W e ' r en o tt o t r y i n gt o f i n df a u l to r p l a c eb l a m e .I n f a c t ,w ep r o b a b l yh a v e n o

o n et o b l a m eb u to u r s e l v e s .A l t h o u g h o u rd i s kl a b e l ss h o wa c o p y r i g h t

n o t i c e ,u p u n t i l t h i si s s u ew es t a t e dr i g h to n o u rp o l i c i e sp a g e( p a g e2 ) t h a t

o u rp r o g r a m sa r e" p u b l i cd o m a i n ;f r e et o c o p y , n o tt o s e l l " .T h i sn o t i c eg o e s

b a c ka b o u t 4y e a r s- a p o p u l a rp h r a s eo r i g i n a l l yd e s i g n e dt o p r e v e n to n e ' s

p r o g r a mf r o mb e i n g" a c q u i r e d "b y s o m e o n ei n t h e s o f t w a r eb u s i n e s s .

H o w e v e r ,t h ef e ea t r e g u l a rc l u bm e e t i n g st o o b t a i na c o p yo f a n yd i s kb e i n g

o f f e r e dt h a tn i g h ti s c a r e f u l l yt e r m e da " c o p y i n gf e e " .U s u a l l yi t ' sa b o u t

$ 5 . 0 0 .A n d5 b u c k si s n ' ta l o t- t h e r e ' se q u i p m e n tw e a r a n dt e a r ,t i m e ,

t r o u b l ea n dt r a n s p o r t a t i o n ,s i t er e n t a lp e r h a p s ,p l u sa n yn u m b e ro f e x

p e n s e sa c l u bm i g h th a v et o d o l e o u t b e f o r em a k i n gt h ef i r s tc o p yo f t h e

e v e n i n g .C l u b sc a nc l a i mt h e y ' r en o t" s e l l i n g "T r a n s a c t o rd i s k s ,b u tt h a t ' s

o n l yb e n d i n gt h eo r i g i n a li n t e n t o fo u rp o l i c y ,w h i c h w a st o a v o i dt h ei d e a

t h a tw ew a n t e dt o e x e r tt o t a l i t a r i a na u t h o r i t yo v e rt h ep e r s o n a l p o s s e s s i o n

o f a n ym a c h i n e - r e a d a b l ep r o g r a mf r o mT r a n s a c t o rm a g a z i n e .

. . . w h a tl i t t l ep r o f i tw e t a k ed o e s n ' te v e np u ta d i n ti n o u rt o t a l

e x p e n s e s .

S o i f o u rp r o g r a m sa r ep u b l i cd o m a i n ,w h a t ' st h ed i f f e r e n c eb e t w e e no u r

d i s k sa n da n yo t h e rc l u bd i s k ?W e l l ,i t w a sa n e r r o rf o ru s t o u s et h et e r m

" p u b l i cd o m a i n "a t a l l - o u rp r o g r a m sa r e c o p y r i g h t , a ss t a t e do n e v e r y

l a b e lo f e v e r yd i s kw es e l l .T h ep r o g r a m sw ep u b l i s ha r e n ' tj u s td o n a t e d-

w ep a yf o rt h er i g h tt o p r i n ta n a u t h o r ' sw o r k .. . a t o t a lo f a l m o s t$ 3 0 0 0

e v e r yi s s u e .B e y o n dt h a t ,w ei n v e s th u n d r e d so f h o u r si n p r o d u c i n ge v e r y

T . d i s k m a s t e r .W ej u s tc a n ' ta f f o r dt o r e l e a s e t h e d i s k st o t h ep u b l i cd o m a i n .

A l lw e a s k i s t h a ty o u " d e - u n i f y " t h e d i s k si n t ot h e i rr e s p e c t i v e

c a t e g o r i e s .. . t h e u n i f i e dc o l l e c t i o n w i l lc o s tl e s s .

W h i c hi s w h a tw e s e l l .U n f o r t u n a t e l y ,i t a p p e a r st h a tt h i sp o l i c yt o oh a s

b e e ns o m e w h a tm o r eb r o a d l yi n t e r p r e t e dt h a nw e i n t e n d e d .A sy o um a y

k n o w ,t h e p r o g r a m si n t h e l a s t2 0 i s s u e sh a v eb e e nc h o s e n f r o mo u r

s u b m i s s i o n st o f i t a p r e d e t e r m i n e dt h e m e .E f f e c t i v e l y ,t h e n , t h em a i n

p r o g r a m s f r o ma n yi s s u ew e r ea l r e a d yi n a " r e s p e c t i v e c a t e g o r y " .T h ed i s k s

f o rt h e s em a g a z i n e sa l w a y ss t a r tw i t h af e wu t i l i t yp r o g r a m s ,f o l l o w e db y

o u rs h o r tB i t s ,a n dt h e no u rm a i np r o g r a ml i s t i n g s .S e p a r a t i n gj u s tt h em a i n

p r o g r a m so n t o a n o t h e rd i s k ,w i t hp e r h a p ss o m eo t h e rp r o g r a m so f t h e

s a m en a t u r e ,w a se s s e n t i a l l yr e s p e c t i n go u rr e q u e s t .I t ' sd i f f i c u l tt o s a y

w h e t h e rt h er e s u l tw a sa s i g n i f i c a n tl o s s i n s a l e s ,b u ti f s o i t w a so n c ea g a i n

o u ro w nf a u l t .

. . . m a n u f a c t u r e r sn e e dt o o f f e rm o r ei n a p a c k a g et h a nj u s ta

p r o g r a mt o a c c r u es a l e s .

U n l i k e a s o f t w a r ef i r mt h a tc a np r o t e c t a g a i n s t p i r a c yb yo f f e r i n gd o c u m e n

t a t i o na n do t h e rs e r v i c e st o r e g i s t e r e du s e r so n l y ,s u p p o r tf o ro u rp r o g r a m s

i s e a s i l yo b t a i n e dj u s tb yd r o p p i n gt h e s u b s c r i p t i o nc a r di n t h em a i l b o x .Y o u

e v e ng e tu p d a t e s !S o ,m a y b eo u rn e wd i s kl a b e l sw i l lh e l p .T h a t ' sr i g h t ,

w e ' v ed e c i d e dt o t a k es o m eo f o u ro w na d v i c e .I n a n a t t e m p tt o p r o t e c t

a g a i n s tp i r a c y ( w i t h o u t p r o t e c t i n g t h ed i s k s )w e ' r e g o i n gt o o f f e rs o m e t h i n

t h a tc a no n l yb e o b t a i n e df r o mt h em a n u f a c t u r e r .S t a r t i n gw i t ht h e d i s kf o r

t h i s i s s u e ,a l lT r a n s a c t o rd i s k sw i l lb e s h i p p e d w i t ht w o - c o l o u rl a b e l s t h a t

s h o u l dd i s t i n g u i s ht h e mf r o ma n yo t h e rd i s ki n y o u rc o l l e c t i o n .T h e y ' l lb e

c o l o u r - c o d e dt o t h ec o v e ro f t h ec o r r e s p o n d i n g m a g a z i n e , s oi f t h e l o g oi s

g r e e n , a so n t h i s i s s u e ,t h e d i s kl a b e lw i l la l s ob e g r e e n .Y o um i g h ts a y ," s o

w h a t " .W e l l ,a n o t h e rf e a t u r et h a tI ' mr e a l l yl o o k i n g f o r w a r dt o i s h a v i n gt h e

e n t i r ed i r e c t o r y p r i n t e dr i g h to n t h el a b e l !W e ' v es e l e c t e d al a b e l s i z e t h

w i l la c c o m m o d a t et h ew h o l ed i r e c t o r yl i s t i n g ,a n da l t h o u g ht h ef i l en a m e sw i l lb e s m a l l ,I i n t e n dt o p u s ht h i st y p e s e t t i n ge q u i p m e n tt o t h el i m i t t o

e n s u r et h e i rl e g i b i l i t y .

B a c ko n t h ed u p l i c a t i o ni s s u e ,w e ' v ec o m p o s e da S i t eL i c e n s i n ga g r e e m e n

f o ra n y o n ew i s h i n gt o m a k em u l t i p l ed u p l i c a t e so f T r a n s a c t o rd i s k s .S i m p l y

s e n du s $ 3 . 0 0f o r e v e r yc o p y m a d e .I n c l u d i n gt h i ss u r c h a r g e , c l

m e m b e r sw i l ls t i l lp a yl e s st h a n o u rr e t a i lp r i c e ,c l u bt r e a s u r i e sw i l ls t i l l

c o n t i n u et o b e n e f i tf r o mt h es a l e s ,a n dt h e c l u b sw i l ls t i l lb e a b l et o o f f e rt h e

s e r v i c ev a l u eo f o n - t h e - s p o ta v a i l a b i l i t y .

W i l l t h em e m b e rn e e dt o p r o d u c eh i so r h e rc o p yo f t h em a g a z i n eb e f o r e

t h e y ' r ea l l o w e dt h e i rc o p y ?N o .B u t ,t h e y s h o u l db e a w a r et h a tu n l i k e

g a m e so r a m e n ud r i v e na p p l i c a t i o n ,m o s to f t h ep r o g r a m sw ep u b l i s h a r

o f l i m i t e dv a l u e w i t h o u tt h ed o c u m e n t a t i o ni n t h em a g a z i n e .

R e m e m b e r ,w ew o u l d n' t b e t h ef i r s tc o m p u t e rp u b l i c a t i o nt o b e c o m e

a n o t h e rp a g ei n C h a p t e r1 1 .. .

W h a tw i l lw e d o i f t h e c l u b sa n do t h e ro f f e n d i n gp a r t i e sd o n ' tc o m p l y ?

P r o b a b l yn o t h i n g .B u tr e m e m b e r ,i f y o u rc l u bo r a n y o n ee l s es e l l so r a l l o w s

c o p y i n go f T r a n s a c t o rd i s k s ,t h e ya r ec o m p e t i n ga g a i n s tu s w i t ho u ro w n

p r o d u c t !A l t h o u g hw e ' dr a t h e rb e t h eo n l ys o u r c e ,w e ' dm u c hr a t h e r s t a yi n

b u s i n e s s .O u rS i t eL i c e n s i n ga g r e e m e n ti s a f a i rc o m p r o m i s et h a tw e h o p e

w i l lb e a d o p t e da n du p h e l d b yi n t e r e s t e dp a r t i e s .

A p a c k a g ei s g o i n go u t w i t h i n t h en e x tw e e kt o o v e r4 0 0c l u b sa r o u n dt h e

w o r l d .T h ec l u ba d d r e s s e sw e r eo b t a i n e df r o mt h el i s tp u b l i s h e dr e g u l a r l y

i n C o m m o d o r em a g a z i n e , s oi f y o u rc l u bi s n ' to n t h i sl i s t ,p l e a s e c o n t a c tu s .

T h ep a c k a g ec o n t a i n sm o s to f t h ea b o v ei n f o r m a t i o n , p l u sd e t a i l so fo u r 2 0 /

2 0 d e a l .A sd e s c r i b e di n N e w sB R K ,t h e2 0 / 2 0d e a lm e a n s2 0% o f f f o ra n y

o r d e ro f 2 0 s u b s c r i p t i o n s ,d i s k s ,o r a n yo t h e rT r a n s a c t o rp r o d u c t .T h i si s an a t u r a lf o r C o m m o d o r eu s e rg r o u p s , b u ty o ud o n ' tn e e dt o b e a c l u b

m e m b e rt o t a k ea d v a n t a g eo f i t . S op o s t t h en o t i c eo ny o u rl o c a lB B S- i f 1 9

o t h e r sr e s p o n d ,t h et o t a ls a v i n g sa r e p r e t t y r e s p e c t a b l e !T h ea r e a s c h o o

b o a r do f f i c ei s a n o t h e rg o o dp l a c et o s p r e a dt h i sa n n o u n c e m e n t .

O n a l i g h t e rn o t e ,w h a td o y o ut h i n ko f o u rn e wc o v e rd e s i g n ? ( D u k e 'i n

t h eS k y p o d ) .I t i s n ' tn e c e s s a r i l yp e r m a n e n t- w e ' r ej u s te x p e r i m e n t i n gw i t h

i t w h i l e w e ' r eo f ft h en e w s s t a n d .C o m m e n t so r s u g g e s t i o n s ,a n y o n e ? N o w

t h et i m et o p u ti n y o u rt w oc e n t s 'w o r t h .O hy e s ,o n em o r et h i n g :o n ef r e e

B i t sb o o kg o e st o t h ef i r s tl o n gd i s t a n c ec a l l e r t os a yt h ew o r d" s h a z a m "

a n da n o t h e rt o t h e 1 0 t hl o c a lc a l l e r .

K a r lJ . H .H i l d o n , E d i t o ri n C h i e f

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 6: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 6/84

U s i n g" V E R I F I Z E R "

T h eT r a n s a c t o r ' sF o o l p r o o fP r o g r a mE n t r yM e t h o d

V E R I F I Z E Rs h o u l db e r u nb e f o r e t y p i n gi n a n yl o n gp r o g r a mf r o mt h e

p a g e so f T h eT r a n s a c t o r .I t w i l ll e ty o u c h e c ky o u rw o r kl i n eb y l i n ea sy o ue n t e r t h ep r o g r a m ,a n dc a t c hf r u s t r a t i n gt y p i n ge r r o r s .T h eV E R I F I

Z E Rc o n c e p tw o r k s b yd i s p l a y i n g a t w o - l e t t e rc o d ef o re a c h p r o g r a m

l i n ew h i c h y o uc a n c h e c ka g a i n s t t h ec o r r e s p o n d i n gc o d ei n t h e

p r o g r a ml i s t i n g .

T h e r ea r ef i v ev e r s i o n so f V E R I F I Z E Rh e r e ;o n ef o rP E T / C B M s ,V I Co r

C 6 4 ,P l u s4 , C 1 2 8 ,a n dB 1 2 8 .E n t e rt h e a p p l i c a b l ep r o g r a ma n dR U Ni t .

I f y o ug e ta d a t ao r c h e c k s u me r r o r ,r e - c h e c kt h ep r o g r a m a n dk e e p

t r y i n gu n t i la l l g o e sw e l l .Y o us h o u l dS A V Et h ep r o g r a m ,s i n c ey o u ' l l

w a n tt o u s ei t e v e r yt i m ey o ue n t e ro n eo f o u r p r o g r a m s .O n c ey o u ' v e

R U Nt h el o a d e r ,r e m e m b e rt o e n t e rN E Wt o p u r g eB A S I Ct e x ts p a c e .

T h e nt u r nV E R I F I Z E R o nw i t h :

S Y S6 3 4t o e n a b l et h eP E T / C B Mv e r s i o n( o f f :S Y S6 3 7 )

S Y S8 2 8t o e n a b l et h eC 6 4 / V I Cv e r s i o n( o f f :S Y S8 3 1 )

S Y S4 0 9 6t o e n a b l et h e P l u s4 v e r s i o n ( o f f :S Y S4 0 9 9 )

S Y S3 0 7 2 , 1t o e n a b l et h eC 1 2 8v e r s i o n( o f f :S Y S3 0 7 2 , 0 )

B A N K1 5 :S Y S1 0 2 4f o rB 1 2 8( o f f :B A N K1 5 :S Y S1 0 2 7 )

O n c eV E R I F I Z E Ri s o n ,e v e r yt i m ey o up r e s sR E T U R No n a p r o g r a m

l i n ea t w o - l e t t e rr e p o r tc o d ew i l la p p e a ro n t h e t o pl e f to f t h es c r e e ni n

r e v e r s ef i e l d .N o t et h a tt h e s el e t t e r sa r ei n u p p e r c a s ea n dw i l la p p e a ra s

g r a p h i c s c h a r a c t e r s u n l e s sy o ua r e i n u p p e r / l o w e r c a s em o d e( p r e s s

s h i f t / C o m m o d o r eo n C 6 4 / V I C ) .

N o t e :I f a r e p o r tc o d ei s m i s s i n g( o r" — " )i t m e a n sw e ' v ee d i t e dt h a t

l i n e a tt h e l a s tm i n u t ew h i c hc h a n g e st h e r e p o r tc o d e .H o w e v e r ,t h i s

w i l lo n l yh a p p e no c c a s i o n a l l ya n du s u a l l yo n l yo n R E Ms t a t e m e n t s .

W i t hV E R I F I Z E Ro n , j u s te n t e r t h ep r o g r a mf r o mt h e m a g a z i n en o r

m a l l y ,c h e c k i n ge a c hr e p o r tc o d ea f t e ry o up r e s sR E T U R No n a l i n e .I f

t h ec o d ed o e s n ' tm a t c hu p w i t ht h el e t t e r sp r i n t e di n t h eb o xb e s i d et h e

l i s t i n g ,y o uc a nr e - c h e c ka n dc o r r e c tt h e l i n e ,t h e nt r y a g a i n .I f y o u

w i s h ,y o u c a nL I S Ta r a n g eo f l i n e s ,t h e nt y p eR E T U R No v e re a c hi n

s u c c e s s i o nw h i l ec h e c k i n gt h er e p o r tc o d e sa s t h e y a p p e a r .O n c et h e

p r o g r a mh a sb e e np r o p e r l y e n t e r e d ,b e s u r et o t u r nV E R I F I Z E Ro f fw i t h

t h eS Y Si n d i c a t e da b o v eb e f o r ey o u d oa n y t h i n ge l s e .

V E R I F I Z E Rw i l lc a t c ht r a n s p o s i t i o n e r r o r sl i k eP O K E5 2 3 8 1 , 0i n s t e a d

o f P O K E5 3 2 8 1 , 0 .H o w e v e r ,V E R I F I Z E Ru s e sa " w e i g h t e dc h e c k s u m

t e c h n i q u e "t h a tc a n b ef o o l e di f y o ut r yh a r de n o u g h ;t r a n s p o s i n gt w o

s e t so f 4 c h a r a c t e r sw i l lp r o d u c et h es a m er e p o r tc o d eb u tt h i ss h o u l d

n e v e rh a p p e ns h o r to f d e l i b e r a t e l y( v e r i f i z e rc o u l dh a v e b e e nd e s i g n e dt o b e m o r ec o m p l e x ,b u t t h e r e p o r tc o d e sw o u l d n e e dt o b e l o n g e r ,a n d

u s i n gi t w o u l db e m o r et r o u b l et h a n c h e c k i n gc o d em a n u a l l y ) .V E R I F I

Z E Ri g n o r e ss p a c e s ,s o y o um a ya d do r o m i ts p a c e sf r o mt h e l i s t e d

p r o g r a ma t w i l l( p r o v i d i n gy o ud o n ' ts p l i tu p k e y w o r d s ! ) .S t a n d a r d

k e y w o r da b b r e v i a t i o n s( l i k en E i n s t e a do f n e x t )w i l ln o t a f f e c tt h e

V E R I F I Z E Rr e p o r tc o d e .

T e c h n i c a li n f o :V I C / C 6 4V E R I F I Z E Rr e s i d e s i nt h ec a s s e t t eb u f f e r ,s o

i f y o u ' r eu s i n ga d a t a s e t t eb e a w a r et h a tt a p e o p e r a t i o n sc a n b e

d a n g e r o u st o i t s h e a l t h .A s f a ra s c o m p a t i b i l i t yw i t ho t h e ru t i l i t i e sg o e s ,

V E R I F I Z E Rs h o u l d n ' tc a u s ea n yp r o b l e m ss i n c ei t w o r k st h r o u g ht h e

B A S I Cw a r m - s t a r tl i n ka n dj u m p st o t h eo r i g i n a ld e s t i n a t i o no f t h el i n k

a f t e ri t ' s f i n i s h e d .W h e nd i s a b l e d ,i t r e s t o r e st h e l i n kt o i t s o r i g i n a l

c o n t e n t s .

C l

C F

L I

H CD H

G K

O GJ O

A F

I N

O N

I B

C KE B

H E0 1

J B

P A

H E

E L

L A

K l

E B

D M

K E

J F

L I

B E

D H

G KF H

K P

A F

I N

E CE P

O CM NM GD M

C AN GO K

A N

G HJ C

E P

M HB H

P E T / C B MV E R I F I Z E R( B A S I C2 . 0 o r4 . 0 )

1 0 r e m *d a t al o a d e rf o r '' v e r i f i z e r4 . 0 ' '*

1 5 r e mp e t v e r s i o n

2 0 c s = 0

3 0 f o ri = 6 3 4t o 7 5 4 : r e a da : p o k ei , a

4 0 c s= c s + a : n e x ti

5 0 :

6 0 i f c s < > 1 5 5 8 0t h e np r i n t '' * * * * *d a t ae r r o r* * * * * '' : e n d

7 0 r e ms y s6 3 4

8 0 e n d

1 0 0 :

1 0 0 0 d a t a7 6 , 1 3 8 ,2 , 1 2 0 , 1 7 3 , 1 6 3 ,2 , 1 3 3 , 1 4 4

1 0 1 0d a t a1 7 3 ,1 6 4 , 2 , 1 3 3 , 1 4 5 ,8 8 , 9 6 , 1 2 0 , 1 6 5

1 0 2 0d a t a1 4 5 ,2 0 1 , 2 , 2 4 0 ,1 6 , 1 4 1 , 1 6 4 ,2 , 1 6 5

1 0 3 0d a t a1 4 4 ,1 4 1 ,1 6 3 , 2 , 1 6 9 ,1 6 5 ,1 3 3 ,1 4 4 ,1 6 9

1 0 4 0d a t a 2 , 1 3 3 , 1 4 5 ,8 8 , 9 6 ,8 5 , 2 2 8 , 1 6 5 , 2 1 1 0 5 0d a t a2 0 1 , 1 3 , 2 0 8 ,6 2 , 1 6 5 , 1 6 7 , 2 0 8 , 5 8

1 0 6 0d a t a 2 5 4 ,1 , 1 3 3 , 2 5 1 , 1 6 2 ,0 , 1 3 4 , 2 5 3 , 1 8 9

1 0 7 0d a t a 0 , 2 , 1 6 8 , 2 0 1 ,3 2 , 2 4 0 ,1 5 , 2 3 0 , 2 5 3

1 0 8 0d a t a1 6 5 ,2 5 3 , 4 1 , 3 , 1 3 3 , 2 5 4 ,3 2 , 2 3 6 ,2

1 0 9 0d a t a1 9 8 , 2 5 4 ,1 6 ,2 4 9 , 2 3 2 ,1 5 2 ,2 0 8 , 2 2 9 ,1 6 5

1 1 0 0d a t a 2 5 1 ,4 1 , 1 5 ,2 4 , 1 0 5 , 1 9 3 , 1 4 1 ,0 , 1 2 8

1 1 1 0d a t a1 6 5 ,2 5 1 , 7 4 , 7 4 , 7 4 , 7 4 ,2 4 , 1 0 5 , 1 9 3

1 1 2 0 d a t a 1 4 1 ,1 , 1 2 8 , 1 0 8 , 1 6 3 ,2 , 1 5 2 ,2 4 , 1 0 1

1 1 3 0d a t a2 5 1 ,1 3 3 ,2 5 1 , 9 6

V I C / C 6 4V E R I F I Z E R

1 0 r e m *d a t al o a d e rf o r '' v e r i f i z e r ' '*

1 5 r e mv i c / 6 4 v e r s i o n

2 0 c s= 0

3 0 f o ri = 8 2 8t o 9 5 8 : r e a d a : p o k ei , a

4 0 c s = c s + a : n e x ti

5 0 :

6 0 i fc s < > 1 4 7 5 5t h e np r i n t '' * * * * *d a t ae r r o r* * * * * '' : e n d

7 0 r e ms y s8 2 8

8 0 e n d

1 0 0 :

1 0 0 0d a t a 7 6 , 7 4 , 3 , 1 6 5 , 2 5 1 , 1 4 1 ,

1 0 1 0d a t a 2 5 2 ,1 4 1 , 3 , 3 , 9 6 , 1 7 3 ,

1 0 2 0d a t a 3 , 2 4 0 ,1 7 , 1 3 3 , 2 5 2 , 1 7 3 ,

9 9 , 1 4 1 ,2 ,

9 6 , 1 7 3 , 2 5 4 ,

0 , 1 8 9 ,

1 5 , 1 3 3 ,3 2 , 1 8 3 ,

1 0 3 0d a t a 2 5 1 ,1 6 9 ,

1 0 4 0d a t a 3 , 3 ,

1 0 5 0d a t a 0 , 1 6 0 ,

1 0 6 0d a t a 3 2 , 2 4 0 ,1 0 7 0d a t a1 3 3 , 9 0 ,

1 0 8 0d a t a 2 3 2 ,2 0 8 ,2 2 9 , 5 6 ,

1 0 9 0d a t a 3 2 , 2 1 0 , 2 5 5 ,1 6 9 ,

1 1 0 0d a t a 8 9 , 4 1 ,1 5 , 2 4 , 1 0 5 ,

1 1 1 0d a t a1 6 5 , 8 9 , 7 4 , 7 4 , 7 4 ,

1 1 2 0d a t a 3 2 , 2 1 0 , 2 5 5 , 1 6 9 , 1 4 6 ,

1 1 3 0d a t a 3 2 , 2 4 0 , 2 5 5 , 1 0 8 , 2 5 1 ,

1 1 4 0d a t a1 0 1 , 8 9 , 1 3 3 ,8 9 , 9 6

2 ,

3 ,

2 ,

3 , 1 6 9 ,

1 , 1 3 3 ,

0 , 2 , 2 4 0 ,

9 1 , 2 0 0 ,1 5 2 ,3 , 1 9 8 ,9 0 ,

3 2 ,2 4 0 , 2 5 5 ,

1 8 , 3 2 , 2 1 0 ,

9 7 , 3 2 ,

7 4 , 2 4 ,

3 2 , 2 1 0 ,

0 , 1 6 5 ,

3 , 1 6 5

3 , 2 0 1

3 , 1 3 3

3 , 1 4 1

8 9 ,1 6 2

2 2 ,2 0 1

4 1 , 31 6 , 2 4 9

1 6 9 , 1 9

2 5 5 ,1 6 5

2 1 0 , 2 5 5

1 0 5 , 9 7

2 5 5 , 2 4

9 1 , 2 4

V I C / 6 4D o u b l eV e r i f i z e r S t e v e n W a l l e y ,S u n n y m e a d ,C A

W h e nu s i n g' V E R I F I Z E R 'w i t hs o m eT V s ,t h eu p p e rl e f tc o r n e ro f t h e

s c r e e ni s c u to f f ,h i d i n g t h e v e r i f i z e r - d i s p l a y e d c o d e s .D O U B L EV E R I

F I Z E Rs o l v e st h a tp r o b l e mb y s h o w i n gt h e t w o - l e t t e rv e r i f i z e rc o d eo nb o t ht h e f i r s ta n ds e c o n dr o wo f t h eT Vs c r e e n .J u s tr u nt h e b e l o w

p r o g r a mo n c et h er e g u l a rV e r i f i z e ri s a c t i v a t e d .

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 7: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 7/84

K M

B C

D l

G DI N

E N

K GK O

F ML P

1 0 0f o ra d = 6 7 9t o 7 2 0 : r e a dd a : p o k ea d , d a : n e x ta d

1 1 0 s y s 6 7 9 :p r i n t :p r i n t

1 2 0p r i n t '' d o u b l ev e r i f i z e ra c t i v a t e d '' : n e w

1 3 0d a t a1 2 0 ,

1 4 0d a t a1 6 9 ,

1 5 0d a t a9 6 ,

1 6 0d a t a1 5 7 ,

1 7 0d a t a 2 0 8 ,

1 8 0d a t a 4 ,

1 6 9

2

1 6 2

4 0

2 4 5

1 5 7

1 8 0 , 1 4 1 ,

1 4 1 , 2 1 ,

0 , 1 8 9 ,

1 9 0d a t a 2 , 2 0 8

2 0 ,

3 ,

0 ,

2 1 6 , 2 3 2 , 2 2 4 ,

1 6 2 , 0 , 1 8 9 ,

4 , 2 3 2 ,

7 6 , 4 9 ,

4 0 ,

2 4 5 ,

3

8 8

2 1 6

2

0

2 2 4

2 3 4

V E R I F I Z E RF o rT a p eU s e r s T o mP o t t s ,R o w l e y ,M A

T h ef o l l o w i n g m o d i f i c a t i o n st o t h eV e r i f i z e rl o a d e rw i l la l l o wV I C a n d6 4

o w n e r sw i t hD a t a s e t t e st o u s et h eV e r i f i z e r d i r e c t l y( w i t h o u t t h el o a d e r ) .

A f t e rr u n n i n gt h en e wl o a d e r ,y o u ' l lh a v ea s p e c i a lc o p yo f t h eV e r i f i z e r

p r o g r a m w h i c hc a n b el o a d e df r o mt a p ew i t h o u td i s r u p t i n g t h ep r o

g r a mi n m e m o r y .M a k et h e f o l l o w i n g a d d i t i o n sa n d c h a n g e st o t h eV I C /

6 4 V E R I F I Z E Rl o a d e r :

N B 3 0 f o ri = 8 5 0t o 9 8 0 :r e a da : p o k ei , a

A L 6 0 i f c s < > 1 4 8 2 1t h e np r i n t ' ' * * * * * d a t ae r r o r * * * * * ' ' :e n d

I B 7 0 r e m s y s 8 5 0o n ,s y s 8 5 3o f f

— 8 0 d e l e t el i n e

— 1 0 0 d e l e t el i n e

O C 1 0 0 0d a t a 7 6 , 9 6 , 3 , 1 6 5 , 2 5 1 , 1 4 1 ,2 , 3 , 1 6 5

M O 1 0 3 0d a t a2 5 1 ,1 6 9 ,1 2 1 , 1 4 1 ,2 , 3 , 1 6 9 , 3 , 1 4 1

E G 1 0 7 0d a t a1 3 3 , 9 0 , 3 2 , 2 0 5 ,3 , 1 9 8 ,9 0 , 1 6 , 2 4 9

B D2 0 0 0a $= ' ' v e r i f i z e r . s y s 8 5 0 [ s p a c e j ' 'K H 2 0 1 0f o ri = 8 5 0t o 9 8 0

G L 2 0 2 0a $ = a $+ c h r $ ( p e e k ( i ) ) :n e x t

D C 2 0 3 0 o p e n1 , 1 , 1, a $ :c l o s e1

I P 2 0 4 0e n d

N o wR U N ,p r e s s i n gP L A Ya n dR E C O R Dw h e np r o m p t e dt o d o s o ( u s e a

r e w o u n dt a p ef o re a s yf u t u r e a c c e s s ) .T o u s et h es p e c i a l V e r i f i z e r t h a t

h a sj u s tb e e nc r e a t e d ,f i r s tl o a d t h ep r o g r a m y o uw i s ht o v e r i f y o r

r e v i e wi n t oy o u r c o m p u t e r f r o me i t h e rt a p eo r d i s k .N e x ti n s e r tt h e t a p e

c r e a t e da b o v ea n db e s u r et h a ti t i s r e w o u n d .T h e ne n t e ri n d i r e c t

m o d e :O P E N 1: C L O S E 1 .P r e s sP L A Yw h e np r o m p t e db y t h ec o m p u t e r ,

a n dw a i t w h i l e t h es p e c i a l V e r i f i z e rl o a d si n t ot h e t a p eb u f f e r .O n c e

l o a d e d , t h es c r e e nw i l ls h o wF O U N DV E R 1 F I Z E R . S Y S 8 5 0 . T oa c t i v a t e ,

e n t e rS Y S8 5 0( n o tt h e8 2 8a s i n t h eo r i g i n a lp r o g r a m ) .T o d e - a c t i v a t e ,

u s eS Y S8 5 3 .

I f y o ua r eg o i n gt o u s et a p et o S A V Ea p r o g r a m ,y o u m u s td e - a c t i v a t e

( S Y S 8 5 3 )s i n c eV E R I F I Z E Rm o v e ss o m eo f t h ei n t e r n a lp o i n t e r su s e d

d u r i n ga S A V Eo p e r a t i o n .A t t e m p t i n ga S A V Ew i t h o u t t u r n i n go f f

V E R I F I Z E Rf i r s tw i l lu s u a l l yr e s u l ti n a c r a s h .I f y o uw i s ht o u s e

V E R I F I Z E Ra g a i na f t e ru s i n g t h et a p e ,y o u ' l lh a v et o r e l o a di t w i t h t h e

O P E N 1 : C L O S E 1c o m m a n d s .

P l u s 4V E R I F I Z E R

N l

P M

E E

N H

J l

A P

N P

J C

I D

P L

C AO DL P

E K

1 0 0 0 r e m* d a t al o a d e rf o r ' ' v e r i f i z e r+ 4 ' '

1 0 1 0r e m* c o m m o d o r ep l u s / 4v e r s i o n

1 0 2 0g r a p h i c1 : s c n c l r :g r a p h i c O :r e mm a k er o o mf o rc o d e

1 0 3 0c s = 0

1 0 4 0f o rj = 4 0 9 6t o 4 2 1 6 :r e a dx : p o k e j . x :c h = c h + x : n e x t

1 0 5 0i f c h < > 1 3 1 4 6t h e np r i n t '' c h e c k s u me r r o r ' ' :s t o p

1 0 6 0p r i n t '' s y s4 0 9 6 :r e mt o e n a b l e ' '

1 0 7 0p r i n t '' s y s4 0 9 9 :r e mt o d i s a b l e ''

1 0 8 0e n d

1 0 9 0d a t a 7 6 , 1 4 , 1 6 , 1 6 5 , 2 1 1 , 1 4 1 ,2 ,

1 1 0 0d a t a1 6 5 ,2 1 2 ,1 4 1 , 3 , 3 , 9 6 , 1 7 3 ,

1 1 1 0d a t a 3 , 2 0 1 , 1 6 , 2 4 0 , 1 7 , 1 3 3 , 2 1 2 ,

1 1 2 0 d a t a2 , 3 , 1 3 3 , 2 1 1 , 1 6 9 ,3 9 , 1 4 1 ,

1 1 3 0d a t a 3 , 1 6 9 ,1 6 , 1 4 1 ,3 , 3 , 9 6 ,

3

3

1 7 3

2

1 6 5

D l

L K

G J

D NG J

C BC B

P E

D OB A

B G

1 1 4 0

1 1 5 0

1 1 6 0

1 1 7 0

1 1 8 0

1 1 9 0

1 2 0 0

1 2 1 0

1 2 2 0

1 2 3 0

1 2 4 0

d a t a 2 0 ,

d a t a 0 ,

d a t a1 7 6 ,

d a t a2 4 0 ,

d a t a2 0 0 ,

d a t a 1 6 ,

d a t a1 6 5 ,

d a t a 0 ,

d a t a 2 4 ,

d a t a 0 ,

d a t a 9 6

1 3 3 , 2 0 8 ,1 6 2 ,

2 , 2 0 1 ,4 8 ,

3 , 2 3 2 , 2 0 8 ,

2 2 ,2 0 1

1 5 2 , 4 1

1 9 8 , 2 0 9

2 0 8 , 4 1

1 2 , 1 6 5 , 2 0 8 ,

1 0 5 ,1 9 3 , 1 4 1 ,

1 6 5 , 2 1 0 ,2 4 ,

3 2 ,

3 ,

1 6 ,

1 5 ,

0 , 1 6 0 ,

1 4 4 , 7 ,

2 4 2 ,1 8 9 ,

2 4 0 , 1 5 ,

1 3 3 , 2 0 9 ,

2 4 9 ,2 3 2 ,

2 4 , 1 0 5 ,

7 4 , 7 4 ,

1 , 1 2 ,

1 0 1 , 2 0 8 ,

0 , 1 8 9

2 0 1 , 5 8

0 , 2

1 3 3 , 2 1 0

3 2 , 1 1 3

2 0 8 ,2 2 9

1 9 3 ,1 4 1

7 4 , 7 4

1 0 8 , 2 1 1

1 3 3 , 2 0 8

P K

A K

J K

N H

O GJ P

M PA G

I D

G F

M GH E

L M

J A

E l

K J

D H

J M

K GE F

C GE C

A CJ A

C CB OP D

C 1 2 8V E R I F I Z E R( 4 0c o l u m nm o d e )

1 0 0 0 r e m* d a t al o a d e rf o r '' v e r i f i z e rd 2 8 ' '

1 0 1 0 r e m* c o m m o d o r ed 2 8 v e r s i o n

1 0 2 0 r e m* u s ei n 4 0 c o l u m nm o d eo n l y !

1 0 3 0c s = 0

1 0 4 0f o rj = 3 0 7 2t o 3 2 1 4 :r e a dx : p o k e j . x :c h = c h + x : n e x t

1 0 5 0i f c h < > 1 7 8 6 0t h e np r i n t '' c h e c k s u me r r o r '' : s t o p

1 0 6 0p r i n t '' s y s3 0 7 2 , 1 :r e mt o e n a b l e ' '

1 0 7 0p r i n t '' s y s3 0 7 2 , 0 :r e mt o d i s a b l e ''

1 0 8 0 e n d

1 6 5 , 2 5 3 ,1 4 1 ,

3 , 9 6 ,

1 7 ,1 3 3 ,

2 5 3 ,1 6 9 , 3 8 ,

1 4 1 , 3 , 3 ,

1 6 2 , 0 ,

4 8 ,1 4 4 ,

2 3 2 , 2 0 8 , 2 4 2 ,

2 0 1 ,

4 1 ,

2 5 1 ,

2 4 0 ,

1 8 ,

2 4 ,

7 4 ,

2 1 0 ,

3 2 , 2 4 0 , 2 5 5 , 1 0 8 , 2 5 3 ,

2 4 , 1 0 1 , 2 5 0 , 1 3 3 , 2 5 0 ,

1 0 9 0d a t a2 0 8 ,

1 1 0 0d a t a 2 5 4 ,

1 1 1 0d a t a 2 0 1 ,

1 1 2 0d a t a 3 ,

1 1 3 0d a t a1 6 9 ,

1 1 4 0d a t a1 3 3 ,

1 1 5 0d a t a 2 ,

1 1 6 0d a t a 3 ,

1 1 7 0d a t a 2 2 ,

1 1 8 0d a t a1 5 2 ,

1 1 9 0d a t a1 9 8 ,

1 2 0 0d a t a 3 2 ,

1 2 1 0d a t a1 6 9 ,

1 2 2 0d a t a 1 5 ,

1 2 3 0d a t a2 5 0 ,

1 2 4 0d a t a 3 2 ,

1 2 5 0d a t a 2 4 ,

1 2 6 0d a t a 2 5 2 ,

1 1 ,

1 4 1 , 3 ,

1 2 , 2 4 0 ,

1 3 3 ,

1 2 ,

2 5 0 ,

2 0 1 ,

1 6 0 ,

7 ,

2 ,

1 7 3 ,

2 5 4 ,

1 4 1 ,

9 6 ,

0 ,

2 0 1 ,

0 ,

3 ,

3 ,

1 7 3 ,

2 ,

1 6 5 ,

1 8 9 ,

5 8 ,

2 ,

1 6 5

3

2

3

2 2

0

1 7 6

2 4 01 8 9 ,

3 2 , 2 4 0 ,1 5 , 1 3 3 , 2 5 2 , 2 0 0

3 , 1 3 3 , 2 5 1 ,3 2 , 1 3 5 ,1 2

1 6 , 2 4 9 , 2 3 2 , 2 0 8 , 2 2 9 , 5

2 5 5 , 1 6 9 ,1 9 , 3 2 , 2 1 0 , 2 5 5

2 1 0 , 2 5 5 , 1 6 5 , 2 5 0 ,4 1

1 9 3 , 3 2 , 2 1 0 , 2 5 5 , 1 6 5

7 4 , 7 4 , 2 4 , 1 0 5 , 1 9 3

1 6 9 , 1 4 6 ,3 2 , 2 1 0 , 2 5 5

0 , 1 6 5

9 6

3 2

1 0 5

7 4

2 5 5

B 1 2 8 V E R I F I Z E R E l i z a b e t h D e a l ,M a l v e r n ,P A

1 r e ms a v e ' ' @ 0 : v e r i f i z e r b 1 2 8 '' , 8

1 0 r e m *d a t al o a d e rf o r '' v e r i f i z e rb 1 2 8 ' '*

2 0 c s= 0

3 0 b a n k1 5 : f o r i= 1 0 2 4t o 1 1 6 3 : r e a d a : p o k ei ,

4 0 c s= c s + a : n e x ti

5 0 i f c s < > 1 6 8 2 8t h e np r i n t '' * * d a t ae r r o r* * '

6 0 r e m b a n k1 5 :s y s1 0 2 4

7 0 e n d1 0 0 0d a t a 7 6 , 1 4 , 4 , 1 6 5 , 2 5 1 , 1 4 1 , 1 3 0 ,

1 0 1 0d a t a1 4 1 , 1 3 1 ,2 ,

1 0 2 0d a t a 1 7 , 1 3 3 , 2 5 1 ,

1 0 3 0d a t a1 4 1 , 1 3 0 ,2 ,

1 0 4 0d a t a 1 ,

1 0 5 0d a t a 2 3 3 ,

9 6 , 1 7 3 , 1 3 0 ,2 .

1 7 3 , 1 3 1 ,2 , 1 3 3 .

1 6 9 , 4 , 1 4 1 , 1 3 1 ,

1 , 1 3 4 , 1 , 2 0 2 ,7 2 , 1 6 2

3 2 , 1 1 8 ,4 , 2 3 4 , 1 7 7 , 1 3 6 ,

1 0 6 0d a t a 3 2 , 2 4 0 ,1 5 , 1 3 3 , 2 3 5 , 2 3 2 , 1 3 8 ,

1 0 7 0d a t a2 3 4 , 3 2 , 1 1 0 ,4 , 1 9 8 , 2 3 4 ,1 6 ,

1 0 8 0d a t a 2 3 0 ,1 6 5 , 2 3 3 , 4 1 ,1 5 , 2 4 , 1 0 5 ,

1 0 9 0d a t a2 0 8 ,1 6 5 ,2 3 3 , 7 4 , 7 4 , 7 4 , 7 4 ,

1 1 0 0d a t a1 4 1 , 1 , 2 0 8 ,2 4 , 1 0 4 , 1 3 3 ,1 ,

1 1 1 0d a t a1 6 5 ,2 3 5 , 2 4 ,1 0 1 , 2 3 3 , 1 3 3 , 2 3 3 ,

1 1 2 0d a t a1 6 4 ,1 3 7 ,1 3 3 ,1 3 3 , 1 3 2 ,1 3 4 , 3 2 ,

1 1 3 0d a t a 3 2 , 7 8 , 1 4 1 , 1 6 5 , 1 3 3 ,5 6 , 2 2 9 ,

1 1 4 0d a t a1 7 0 ,1 7 0 , 1 7 0 , 1 7 0

: e n d

2 , 1 6 5 , 2 5 2

2 0 1 , 3 9 , 2 4 0

2 5 2 , 1 6 9 ,3 9

2 , 9 6 ,1 6 5

1 6 5 , 2 7 , 1 3 3

2 4 0 , 2 2 , 2 0 1

4 1 , 3 , 1 3 3

2 4 9 ,2 0 0 ,2 0 8

1 9 3 , 1 4 1 ,0

2 4 , 1 0 5 , 1 9 3

1 0 8 , 2 5 1 ,0

9 6 ,1 6 5 ,1 3 6

3 8 , 1 8 6 ,2 4

1 3 6 , 1 6 8 ,9 6

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 8: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 8/84

G o ta n i n t e r e s t i n gp r o g r a m m i n gt i p ,s h o r tr o u t i n e ,o r a n u n k n o w nb i to f

C o m m o d o r et r i v i a ?S e n di t i n - i f w eu s ei t i n t h eB i t sc o l u m n ,w e' I Ic r e d i ty o ui n

t h ec o l u m na n ds e n dy o u af r e eo n e - y e a r ' ss u b s c r i p t i o nt o T h eT r a n s a c t o r

R i b b o nR e j u v e n a t i o n M u r r a yK a l i s h e r

S a n t aB a r b a r a ,C A

M o s to f t o d a y ' sp o p u l a rd o t m a t r i xp r i n t e r su s e e a s i l y -

r e p l a c e a b l er i b b o nc a r t r i d g e s .T h e s eu s u a l l yc o n t a i n al o n g

c o n t i n u o u sl o o po f n y l o nr i b b o nf o l d e da n d" c r u n c h e d "i n s i d ea

p l a s t i cc a r t r i d g e .O n es h o r t s e c t i o no f t h er i b b o ni s e x p o s e dt o

t h e d o t m a t r i xp r i n th e a da n d t h e r i b b o ni s m o v e di n o n e

d i r e c t i o nc o n t i n u o u s l ya s p r i n t i n go c c u r s .I f y o u r e m o v ea w o r n

c a r t r i d g ey o um a yn o t i c et h a tu s u a l l yo n l yt h eu p p e rh a l fo f t h e

r i b b o nh a s b e e nu s e d .C e r t a i nt y p e so f c a r t r i d g e sa l l o wi n

c r e a s e dr i b b o nl i f eb y " f l i p p i n g "t h e r i b b o ni n t e r n a l l ys o t h a t

b o t ht o pa n db o t t o mh a l v e sa r e u s e d . F o rc a r t r i d g e sw h e r et h i s

i s n o t t h ec a s e ,y o uc a n d oi t y o u r s e l fw i t h o u tt o om u c ht r o u b l e ,

a n dd o u b l e y o u rr i b b o nl i f e .

F i r s tn o t i c et h ed i r e c t i o ni n w h i c ht h er i b b o nt r a v e l sb y t u r n i n g

t h ew i n d i n gk n o bl o c a t e da t t h e t o po f t h ep l a s t i cc a s e .L o o s e n

t h er i b b o na b i tb y p u l l i n go n i t a n dg i v ei t a h a l f t w i s tt o r e v e r s e

t h e t o pa n db o t t o me d g e s . P l a c e t h e t w i s t e d s e c t i o no f r i b b o n

o v e rt h e p l a s t i cg u i d ec l o s e s tt o w h e r et h e r i b b o ne n t e r st h e

c a r t r i d g ea n dt u r n t h ek n o bt o r e m o v et h e s l a c ki n t h e r i b b o n .

N o wk e e pt u r n i n gt h ek n o bt o p u l lh a l f o ft h e" t w i s t "i n t ot h e

c a r t r i d g e .O n c ei t ' s i n s i d ey o uj u s tk e e pt u r n i n gt h e k n o bf o r

p e r h a p s1 0o r 1 5m i n u t e su n t i lt h et w i s tc o m e so u t t h eo t h e re n d

o f t h e c a r t r i d g ea n dt h e r i b b o ni s c o m p l e t e l yu n t w i s t e da g a i n .

N o wn o t i c et h a tt h eu n u s e dh a l fo f t h er i b b o ni s a t t h e t o pe d g e .

Y o un o wh a v ee s s e n t i a l l ya " n e w "r i b b o n !

T h i st r i c k w i l ln o tw o r kw i t hc a r b o nf i l mt y p e r i b b o n sb e c a u s e

t h ec a r b o nw i l lb e o n t h ew r o n gs i d eo f t h ef i l mi f y o ut w i s ti t . I

t r i e d t h i st r i c kw i t ht h er i b b o nf o rm yC i t i z e np r i n t e r ,w h i c hi s a

s t a n d a r dE p s o nM X - 8 0r i b b o n ,a n di t w o r k sg r e a t !

C A U T I O N ! D e a nR o u n c v i l l

A t h a b a s c a , A l b

T h e r ei s a n e a s yw a yt o d e s t r o ya B A S I C p r o g r a mi n m e m o r y ,

o n e t h a t I f o u n do u t i n a m o s tu n p l e a s a n tm a n n e r .W h e n

e n t e r i n ga l i n ei n a l o n gp r o g r a m ,t h e r ei s a s h o r t d e l a y b e f

t h e c u r s o rc o m e sb a c k ,w h i l et h e i n t e r p r e t e rr e - c h a i n st h e

p r o g r a ml i n e l i n k s .O n v e r yl o n gp r o g r a m s ,t h i sd e l a yc a r ib e

s e v e r a ls e c o n d sl o n g .I f y o ui n t e r r u p tt h i sp r o c e s sb y h i t t i n g

R U N S T O P / R E S T O R Eb e f o r e t h ec u r s o rc o m e sb a c k ,y o u rp r o

g r a mw i l lb e i n q u i t ea m e s s ,a s t h er e c h a i n i n gp r o c e s sw a sn o t

c o m p l e t e d . T r y L I S T i n ga p r o g r a ma f t e ra R E S T O R Ei n s u c ha

c i r c u m s t a n c ea n dy o u ' l ls e e .S o m e t i m e s y o uc a ng e to u to f t h e

m e s sj u s tb y r e - t y p i n gt h e l i n ey o uj u s te n t e r e d ;o t h e rt i m e s ,

r e p a i r i n g t h ed a m a g ec o u l db e c o n s i d e r a b l ym o r ed i f f i c u l tt h a n

t h a t .

I h o p et h i sw a r n i n gw i l ls a v es o m e o n et h ea g o n yo f l o s i n gt w o

h o u r so f p r o g r a m m i n gt i m e ,a s I d i d .

D e f a u l t s A m i rM i c h a i l

W i l l o w d a l e ,O n t a r i o

U s e d1 / 2

U n u s e dV 2

T h en e e dt o s a v ed e f a u l td a t af o ra p r o g r a ma r i s e sm a n yt i m e s .

T o d oi t , o n en e e dn o ts e tu p a s e q u e n t i a lf i l et o s t o r et h ed e f a u l t

d a t a .H e r ei s a n e l e g a n ts o l u t i o nw h i c hp r o v i d e s2 5 5b y t e so f

d a t as t o r a g e( e n o u g hf o r5 0 t o p s c o r e si n a g a m e ! ) .A s a b o n u s ,

p r o g r a m sm a yb e l o a d e da n dt h e ns a v e do n a n o t h e rd i s k- t h e

d e f a u l t sw i l la u t o m a t i c a l l yb e s a v e dw i t ht h ep r o g r a m !

F i r s ta l i t t l et h e o r y .W h e ny o ul o a da p r o g r a m ,t h el a s tt r a c ka n d

s e c t o ru s e di s s t o r e da t 2 4 - 2 5( $1 8 - $1 9 )i n t h e1 5 4 1 .T h ei d e ai s

t o r e t r i e v et h i si n f o r m a t i o nf r o mt h ed r i v ef o rl a t e ru s e ,a n dl o a d

i n t h ed e f a u l td a t af r o mt h a ts e c t o r .

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 9: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 9/84

S i n c et h a tl a s ts e c t o rh a sj u s tb e e nl o a d e d ,t h e no n en e e dn o tt e l l

t h e d r i v et o r e a di t a g a i n- a l l t h e i n f o r m a t i o ni s t h e r ei n t h e

d r i v e ' s b u f f e r t h a tw a sj u s tu s e d !H o w e v e r ,t h e t r a c ka n ds e c t o r

s h o u l db e r e a df r o md r i v em e m o r ys i n c e t h eu s e rm a yw i s ht o

c h a n g et h ed e f a u l td a t al a t e ro n .

A d e m o n s t r a t i o np r o g r a mf o l l o w st h a t c l e a r l ys h o w sh o wt h i s

t e c h n i q u ec a n b eu s e d .H o w e v e r ,b e f o r ey o ur u ni t y o um u s t a d d

a d a t ab l o c k .F i r s tt y p ei n t h ep r o g r a ma n ds a v ei t a s " d e m o " .

N e x tt y p ei n t h e f o l l o w i n gi n d i r e c tm o d e :

o p e n 5 , 8 , 5 , " d e m o , p , a " : f o r j= 1 t o 2 5 4

: p r i n t # 5 , c h r $ ( j ) ; : n e x t : c l o s e 5

5 0 p r i n ti ; a s c ( b $+ c h r $ ( O ) )

6 0 n e x ti

T h ef i r s tt w op a r a m e t e r so f t h em e m o r y - r e a dc o m m a n ds p e c i f y

t h es t a r t i n ga d d r e s si n d r i v em e m o r y ,a n dt h et h i r dp a r a m e t e ri s

t h en u m b e ro f b y t e st o r e a d .A l t h o u g hz e r os e e m sl i k ea c u r i o u s

v a l u et o u s e ,i t a c t u a l l yc a u s e st h e d r i v et o s u p p l y2 5 6b y t e sd u e

t o t h ec o u n t i n g a l g o r i t h mu s e d b yD O S .

S i n c et h e" m - r "c o m m a n dp r e c e d e st h el o o p ,t h e r e a r e2 5 5f e w e r

c o m m a n d st o s e n da c r o s s t h es e r i a lb u sa n dh a v et h e d r i v e

e x e c u t e .

N o wl o a d t h ep r o g r a m a n dr u ni t ! W a r n i n g :i f y o u w a n tt o e d i t F i l eH i d e r

t h ep r o g r a m ,r e m e m b e rt o c r e a t ea n o t h e rd a t ab l o c k .

M i c h a e lB o n e

S t r a t h a l b y n ,S o u t hA u s t r a l i a

L P

G E

C A

E O

G K

P I

G J

F E

G A

H J

D M

F K

G J

C C

M D

D OM G

E E

K B

P A

L D

G P

L O

E D

F J

A L

K E

1 0 r e m *d e f a u l td e m o— J u l y1 9 8 7

2 0 r e m *b y a m i rm i c h a i l

3 0 r e m *s a v e sa n dr e a d sd e f a u l tv a l u e s

4 0 r e m *f r o ml a s tb l o c ko f p r o g r a m

5 0 :

1 0 0z $ = c h r $ ( O ) :o p e n1 5 , 8 , 1 5

1 1 0 o p e n 2 , 8 , 2 , " # "

1 2 0 r e mr e a dv a l u e sf r o md i s kb u f f e r

1 3 0 p r i n t # 1 5 , " m - r " c h r $ ( 2 4 ) c h r $ ( 0 ) c h r $ ( 2 )

1 4 0g e t # 1 5 , t $ , s $ : t= a s c ( t $+ z $ ) : s= a s c ( s $+ z $ )

1 5 0p r i n t # 1 5 , " b - p " ; 2 ; 2

1 7 0 g e t # 2 , c 1 $ , c 2 $ , c 3 $

1 8 0p o k e 5 3 2 8 1, a s c ( d $+ z $ ) : p o k e 5 3 2 8 0 ,

a s c ( c 2 $+ z $ ) :p o k e 6 4 6 , a s c ( c 3 $+ z $ )

1 9 5 c l o s e 2 : c l o s e 1 5

2 1 0p r i n t , ' c h a n g ec o l o rd e f a u l t s " ;

2 2 0i n p u tk $ : i fk $ = " n "t h e n3 2 0

2 3 0i n p u t" b a c k g r o u n d ,b o r d e r ,t e x t c o l o r s : " ;

d , c 2 , c 3

2 4 0 p o k e 5 3 2 8 1 , d :p o k e 5 3 2 8 0 , c 2 :p o k e 6 4 6 , c 3

2 5 0 o p e n1 5 , 8 , 1 5 :o p e n 2 , 8 , 2 , " # "

2 6 0r e mw r i t ev a l u e st o l a s ts e c t o r

2 7 0 p r i n t # 1 5 / b - p n ; 2 ; 2

2 8 0p r i n t # 2 , c h r $ ( d) c h r $ ( c 2 ) c h r $ ( c 3 ) ;

2 9 0 p r i n t # 1 5 , " u 2 " ; 2 ; 0 ; t ; s

3 0 0p r i n t" d o n e ! "

3 1 0 c l o s e 2 : c l o s e 1 5

3 2 0p r i n t" p r o g r a mc a ns t a r tf r o mt h i s p o i n t . "

3 3 0 e n d

P e e k - a - P a g e H a r d yM o o r e

B r i d g e w a t e r ,M A

O n e w a yt o r e a da p a g e f r o md i s km e m o r yi s t o e n c l o s ea

m e m o r yr e a da n da g e t * w i t h i n a l o o pa n de x e c u t ei t 2 5 6t i m e s .

H e r ei s a q u i c k e ra p p r o a c h :

1 0 o p e n1 5 , 8 , 1 5

2 0 p r i n t # 1 5 , " m - r " c h r $ ( l o ) c h r $ ( h i ) c h r $ ( 0 )

3 0 f o ri = 0 t o 2 5 54 0 g e t # 1 5 , b $

H e r e ' sa n e a s yw a yt o h i d ef i l e ss o t h a tt h e yw o n ' ts h o wu p i n a

d i r e c t o r y .T h i ss h o r tp r o g r a mw i l lh i d ee v e r yf i l ei n t h e d i r e c t o r

s t a r t i n gf r o mt h eo n ey o us p e c i f y .Y o uc a ns t i l ll o a d t h e" i n v i s i

b l e "f i l e s ,a n d y o uc a n l o a d t h ef i r s th i d d e nf i l e u s i n gt h e

f i l e n a m e" ? ? b l o c k sf r e e * " .

1 0 i n p u t" h i d ef i l e sf r o m " ; a $

2 0 o p e n1 , 8 , 1 5

3 0 p r i n t # 1, " r 0 : "+ c h r $ ( 2 0 )+ c h r $ ( 2 0 )+ " b l o c k sf r e e "

+ c h r $ ( O )+ c h r $ ( O )+ c h r $ ( O )+ " = " + a $

4 0 c l o s e1

T o g e tt h e d i r e c t o r yb a c kt o n o r m a l ,j u s tr e n a m et h e f i l eb a c k

a g a i n ,l i k et h i s :

p r i n t # 1 ,h r 0 : o l d n a m e= "+ c h r $ ( 2 0 )+ c h r $ ( 2 0 )

+ " b l o c k sf r e e "+ c h r $ ( O )+ c h r $ ( O )+ c h r $ ( O )

B a s i cB u g s

M o r eo n t h eV A LB u g

I n V o l u m e8 I s s u e1 , w e r e p o r t e do n a n " O b s c u r eC - 6 4V A L

b u g "a n dt h e p r o b l e m si t c o u l dc a u s ew i t hi n t e r r u p t - d r i v

p r o g r a m s .I n a n u t s h e l l ,i t h a p p e n e dl i k et h i s :t h eV A Lf u n c t i o n

w o u l dp u t az e r oa t t h ee n do f t h es t r i n gb e i n ge v a l u a t e d ,c a l la

s u b r o u t i n et o e v a l u a t et h en u l l - t e r m i n a t e ds t r i n g ,t h e nr e p l a c e

t h e z e r ow i t hw h a tw a st h e r eo r i g i n a l l y .T h eb u gw a st h a ta n

i n t e r r u p tr o u t i n es t a r t i n gr i g h ta b o v es t r i n gs t o r a g ew o u l dg e t

s t e p p e do n i f a V A Lw a sp e r f o r m e do n t h ef i r s ts t r i n gc r e a t e di n a

B A S I Cp r o g r a m ,a n db o m bo u ti f i tw a se x e c u t e dw h i l et h eV A L

w a sb e i n gp e r f o r m e d .

R e c e n t l y ,L a r r yP h i l l i p s o fV a n c o u v e r , B C , b r o u g h ta n o t h e r

m a n i f e s t a t i o no f t h i sb u gt o o u ra t t e n t i o n ,o n et h a ti s e a s i e rt o

r e p r o d u c e .F o r a d r a m a t i c d e m o n s t r a t i o n ,t r y e n t e r i n gt h i s

p r o g r a m :

1 0 a $ = " 4 e 9 9 " :p r i n tv a l ( a $ ) :r e mt h i sw i l ld i s a p p e a r

2 0 r e mb u tt h i sw o n ' t

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 10: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 10/84

R U Nt h e p r o g r a m( y o u ' l lg e t t h e m e s s a g e" o v e r f l o we r r o ri n

1 0 " ) ,t h e nL I S Ti t . Y o uw i l ln o t i c et h a tB A S I Ct o o kt h el i b e r t yo f

m u n c h i n gp a r to f l i n e1 0 ,a s p r e d i c t e db y t h eR E Ms t a t e m e n t .

E v e r y t h i n ga f t e rt h e " 4 e 9 9 " ,i n c l u d i n g t h ec l o s i n gq u o t e ,i s

w i p e do u t .

T h er e a s o nl i e si n a n o t h e r ,r e l a t e d ,b u gi n V A L .I f a n e r r o ro c c u r s

i n t h e e v a l u a t i o no f t h e s t r i n g , l i k et h e o v e r f l o we r r o ri n t h i s

c a s e ,t h ez e r ot h a tw a ss t o r e da t t h ee n do f t h es t r i n gi s n e v e r

r e p l a c e db y t h eo r i g i n a lc o n t e n t so f t h a tl o c a t i o n .S i n c ea s t r i n g

d e f i n e di n a B A S I C p r o g r a me x i s t sa s a p o i n t e rt o t h ep r o g r a m

t e x ti t s e l f ,V A Li s a c t u a l l yp u t t i n gt h a tz e r or i g h ts m a c ki n t oy o u r

B A S I Cc o d e !I f V A Lb o m b s ,y o u ' v eg o ta l i n e - t e r m i n a t i n gz e r o

s i t t i n g i ny o u rp r o g r a mt o m a k et h i n g sm y s t e r i o u s l yd i s a p p e a r .

T h i sb u gw o n ' to f t e nb e a p r o b l e m ,b u ti t i s i n t e r e s t i n gt o n o t e

t h a ta s e e m i n g l yi n n o c e n t - l o o k i n gb i t o f c o d ec a n b es e l f -

d e s t r u c t i v e .T h e s a m ep r o b l e mw i l l n o t o c c u ro n a C 1 2 8 ,

b e c a u s et h es t r i n gd o e sn o te x i s ta s ap o i n t e rt o B A S I Cc o d e , b u t

i s c o p i e di n t os t r i n gs t o r a g ei n h i g hm e m o r ya l o n g w i t ht h e

d y n a m i c a l l y - d e f i n e ds t r i n g s .

M u l t i p l yB u g D a v eD i x o n

V a n c o u v e r ,B C

H e r e ' sa n o t h e rB A S I Cb u gt h a ts h o w s u p o nt h e6 4 ,b u ti s f i x e d

o n t h e 1 2 8 .T h i so n ei s i n t h e m u l t i p l yr o u t i n e .T r yt h i s :

p r i n t8 3 8 8 6 0 8 . 8 8 *1

p r i n t1 * 8 3 8 8 6 0 8 . 8 8

A n ds e ew h a ty o ug e t .

L I S TD u r i n ga P r o g r a m J a s o nD o r i e

F t .M c M u r r a y ,A l b e r t a

A s y o um a yk n o w ,a L I S Tc o m m a n di n a p r o g r a mw i l le n di t

r i g h t a f t e rt h eL I S Ti s f i n i s h e d .T h i sl i n et a k e s c a r eo f t h a t :

1 0 p o k e7 6 8 , 1 7 4 :p o k e7 6 9 , 1 6 7 :l i s t

: p o k e7 6 8 , 1 3 9 :p o k e 7 6 9 , 2 2 7

L i n e r a n g e sm a yb e s p e c i f i e dw i t ht h eL I S Tc o m m a n da s u s u a l .

I n s i d eV i e w S c o t tG r a y

N e wB l o o m f i e l d ,M O

H a v ey o ue v e rw o n d e r e dw h a ty o u rc o m p u t e rm i g h ts e ef r o m

t h eo t h e rs i d eo f t h es c r e e n ?W e l l ,t h i sp r o g r a mw i l ls h o wy o u

j u s tt h a t- i t d i s p l a y s t h es c r e e nj u s ta s i f y o u w e r el o o k i n ga t i t

f r o mb e h i n d .W h a t ' sm o r e ,y o uc a n p r o g r a m a n do t h e r w i s e

o p e r a t ey o u r 6 4w h i l e e n j o y i n gt h i sv i e w ;a n yB A S I Cp r o g r a m

t h a td o e sn o tu s em a c h i n el a n g u a g es u b r o u t i n e so r a n a l t e r n a t e

c h a r a c t e rs e t w i l lw o r kf i n ew i t hI n s i d eV i e w ,t h o u g hi t w i l lb e

s l o w e dd o w na b i t .

T h i sp r o g r a mr e a l l yh a s n o p r a c t i c a lv a l u e ;i t j u s ts e r v e st o

d e m o n s t r a t ew h a tw e i r da n dw o n d e r f u lt h i n g s t h eC 6 4i s c a p a

b l eo f .

I t ' se a s yt o t o g g l eb e t w e e nt h en o r m a ls c r e e na n dt h er e v e r s e

s c r e e n :

n o r m a l: P O K E5 3 2 7 2 , 2 1 :P O K E5 6 5 7 6 , 1 5 1

r e v e r s e: P O K E5 3 2 7 2 , 3 7 :P O K E5 6 5 7 6 , 1 4 8

H a v ef u n !

L O

G E

N B

I E

J M

0 1

H N

M E

D P

G B

E A

H F

N H

J P

N B

O C

K A

L M

J A

H A

I B

P A

F P

O P

H F

O D

M B

M CK P

H B

H A

I C

L D

H CP C

C B

F D

C A

F E

K A

A B

C D

H B

D C

F G

M BJ B

1 r e m* * * * * * * * * * * * * * * * * * * * * * * *

2 r e m*

3 r e m*

4 r e m*

5 r e m*

6 r e m*

7 r e m*

8 r e m*

* *

*

i n s i d ev i e wb y s c o t tg r a y

t h ev i e wt h a ty o u rc o m p u t e r

s e e sf r o mt h e o t h e rs i d eo f

t h es c r e e n *

*

9 r e m* * * * * * * * * * * * * * * * * * * * * * * *

1 0 f o rx = 4 9 1 5 2t o 4 9 4 6 6

2 0 p o k ex , a : c= c + a : n e x t

3 0 i f c O 4 3 1 3 5t h e np r i n t

4 0 s y s 4 9 1 5 2 : e n d

1 0 0 0d a t a1 6 9 ,0 0 0 ,1 4 1 ,

1 0 0 1d a t a1 3 3 ,2 5 3 ,1 6 8 ,

1 0 0 2d a t a1 6 9 ,0 4 8 ,1 3 3 ,

1 0 0 3d a t a2 5 4 ,1 7 7 , 2 5 3 ,

1 0 0 4d a t a1 6 0 ,0 0 7 , 0 0 6 ,

1 0 0 5d a t a0 1 6 , 2 4 9 ,1 6 5 ,

1 0 0 6d a t a2 5 1 , 2 0 0 , 2 0 8 ,

1 0 0 7d a t a2 5 4 ,1 6 5 , 2 5 4 ,

1 0 0 8d a t a1 6 9 ,0 5 5 ,1 3 3 ,

1 0 0 9d a t a0 1 4 ,2 2 0 ,1 2 0 ,

1 0 1 0d a t a1 3 3 ,0 0 1 ,1 6 9 ,

1 0 1 1 d a t a2 5 3 , 1 6 8 ,1 6 9 ,

1 0 1 2d a t a2 0 8 ,1 3 3 , 2 5 4 ,

1 0 1 3d a t a2 0 0 ,2 0 8 ,2 4 9 ,

1 0 1 4d a t a1 6 5 ,2 5 4 , 2 0 1 ,

1 0 1 5d a t a0 0 1 , 0 0 9 , 0 0 4 ,

1 0 1 6d a t a1 4 8 ,1 4 1 , 0 0 0 ,

1 0 1 7d a t a0 2 4 ,2 0 8 ,1 2 0 ,

1 0 1 8d a t a0 0 3 , 1 6 9 ,1 9 2 ,

1 0 1 9d a t a0 9 6 ,1 6 9 , 0 0 4 ,

1 0 2 0d a t a1 3 3 ,2 5 4 ,1 6 9 ,

1 0 2 1d a t a2 5 1 , 1 6 8 ,1 6 2 ,

1 0 2 2d a t a1 5 7 ,0 0 0 , 2 0 0 ,

1 0 2 3d a t a0 4 0 ,2 0 0 ,1 8 5 ,

1 0 2 4d a t a2 0 0 ,1 8 5 ,1 2 0 ,

1 0 2 5d a t a1 8 5 ,1 6 0 , 0 0 4 ,

1 0 2 6d a t a2 0 0 ,0 0 4 ,1 5 7 ,

1 0 2 7d a t a0 0 4 ,1 5 7 , 2 4 0 ,

1 0 2 8d a t a1 5 7 ,0 2 4 , 2 0 1 ,

1 0 2 9d a t a0 6 4 ,2 0 1 ,1 8 5 ,

1 0 3 0d a t a2 0 1 ,1 8 5 , 1 4 4 ,

1 0 3 1 d a t a1 8 5 ,1 8 4 , 0 0 5 ,

1 0 3 2d a t a2 2 4 ,0 0 5 ,1 5 7 ,

1 0 3 3d a t a0 0 6 ,1 5 7 , 0 0 8 ,

: r e a da

" e r r o r !" : s t o p

0 1 4 , 2 2 0 , 1 3 3

1 6 9 , 0 5 1 , 1 3 3

2 5 2 ,1 6 9 , 2 0 8

1 3 2 , 0 0 2 , 1 3 3

0 0 3 ,1 0 2 , 0 0 4

0 0 4 ,1 6 4 , 0 0 2

2 3 2 , 2 3 0 ,2 5 2

2 0 1 , 2 2 4 , 2 0 8

0 0 1 ,1 6 9 , 0 0 1

1 6 5 , 0 0 1 , 0 4 1

0 0 0 ,1 3 3 , 2 5 1

0 4 8 ,1 3 3 , 2 5 2

1 7 7 . 2 5 1 ,1 4 5

2 3 0 . 2 5 2 ,2 3 0

2 2 4 , 2 0 8 ,2 3 9

1 3 3 , 0 0 1 , 0 8 8

2 2 1 ,1 6 9 , 0 3 7

1 6 9 ,1 3 4 , 1 4 1

1 4 1 , 0 2 1 , 0 0 3

1 3 3 , 2 5 2 , 1 6 9

0 0 0 ,1 3 3 , 2 5 3

0 3 9 ,1 8 5 , 0 0 0

1 8 5 , 0 4 0 , 0 0 4

0 8 0 , 0 0 4 , 1 5 7

0 0 4 ,1 5 7 , 1 2 0

1 5 7 ,1 6 0 , 2 0 0

2 0 0 , 2 0 0 , 1 8 5

2 0 0 ,1 8 5 , 0 2 4

1 8 5 , 0 6 4 , 0 0 5

1 0 4 , 0 0 5 ,1 5 7

0 0 5 ,1 5 7 ,1 4 4

1 5 7 , 1 8 4 , 2 0 1

2 2 4 , 2 0 1 , 1 8 52 0 2 ,1 8 5 , 0 4 8

, 2 5 1

, 0 0 1

, 1 3 3

, 0 0 3

, 1 3 6

, 1 4 5

, 2 3 0

, 2 2 2

, 1 4 1

, 2 5 1

, 1 3 3

, 1 6 9

, 2 5 3

, 2 5 4

, 1 6 5

, 1 6 9

, 1 4 1

, 0 2 0

, 0 8 8

, 2 0 0

, 1 3 3

, 0 0 4

, 1 5 7

, 0 8 0

, 2 0 0

, 1 8 5

, 2 4 0

, 0 0 5

, 1 5 7

, 1 0 4

, 2 0 1

, 1 8 5

, 0 0 8

, 0 0 6

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 11: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 11/84

C F

D E

E E

L D

C E

O C

B E

I D

J F

L C

A G

1 0 3 4

1 0 3 5

1 0 3 6

1 0 3 7

1 0 3 8

1 0 3 9

1 0 4 0

1 0 4 1

1 0 4 2

1 0 4 3

1 0 4 4

d a t a1 5 7 ,

d a t a0 8 8 ,

d a t a2 0 2 ,

d a t a1 8 5 ,

d a t a2 4 8 ,

d a t a0 0 7 ,

d a t a1 5 7 ,

d a t a1 1 2 ,

d a t a2 0 3 ,

d a t a2 0 0 ,

d a t a1 5 1 ,

0 4 8 . 2 0 2 ,1 8 5 ,

2 0 2 ,1 8 5 , 1 2 8 ,

1 8 5 ,1 6 8 , 0 0 6 ,

2 0 8 , 0 0 6 ,1 5 7 ,

0 0 6 ,1 5 7 , 2 4 8 ,

1 5 7 , 0 3 2 , 2 0 3 ,

0 7 2 . 2 0 3 ,1 8 5 ,

2 0 3 ,1 8 5 , 1 5 2 ,

1 8 5 ,1 9 2 , 0 0 7 ,

2 0 2 ,1 9 2 , 0 4 0 ,

1 9 2 , 0 7 6 , 0 4 9 ,

0 8 8 . 0 0 6 , 1 5 7

0 0 6 ,1 5 7 ,1 2 8

1 5 7 ,1 6 8 , 2 0 2

2 0 8 , 2 0 2 ,1 8 5

2 0 2 ,1 8 5 , 0 3 2

1 8 5 , 0 7 2 , 0 0 7

1 1 2 . 0 0 7 ,1 5 7

0 0 7 ,1 5 7 ,1 5 2

1 5 7 ,1 9 2 , 2 0 3

2 4 0 , 0 0 3 ,0 7 6

2 3 4 ,0 7 8 ,0 0 0

M o b U eB A S I C M a r kS c h r e i n e r

O v e r l a n dP a r k ,K S

T h es h o r tp r o g r a mb e l o we n a b l e sy o ut o m o v et h eB A S I Ca r e a

a n y w h e r ei n t h eC o m m o d o r e6 4 ' sm e m o r y . A n s w e rt h ep r o m p t s

w i t ht h es t a r t i n ga n de n d i n ga d d r e s s e so f B A S I C ' Sn e wl o c a t i o n

a n dt h em a c h i n ew i l la p p e a rt o b e r e s e tb u tt h e" B Y T E S F R E E "

m e s s a g ew i l lr e v e a lt h a ty o ua r ei n y o u rn e wz o n e .

M o v i n gB A S I Co p e n su p s o m ei n t e r e s t i n gp o s s i b i l i t i e s .T r y8 2 8 -

1 0 2 3( t h ec a s s e t t eb u f f e r )a n d4 9 1 5 2 - 5 3 2 4 7( t h e f r e em e m o r y

n o tc o n t i g u o u s w i t ht h en o r m a lB A S I Cw o r k s p a c e ) .Y o uc a nn o w

l o a di n m a c h i n el a n g u a g ep r o g r a m s a n do t h e rf i l e s( u s i n g t h e

" , 8 , 1 "n o n - r e l o c a t i n gl o a d o p t i o n )t h a tl o a di n t ot h e n o r m a l

B A S I Ca r e a .W i t hB A S I Cm o v e d , y o um a yu s e aB A S I C p r o g r a m

t o e x a m i n et h e c o n t e n t so f t h en o r m a lB A S I Ca r e a .

M a k es u r ey o us a v et h i sp r o g r a mb e f o r er u n n i n gi t - w h e ny o u

m o v eB A S I C ,t h ep r o g r a mw o n ' te x i s ti n t h en e wa r e aa n dy o u ' l l

l o s ei t . J u s tr e - l o a dt h ep r o g r a mi n t h en e wa r e ai f y o uw a n tt o

r e - l o c a t e a g a i n .

M A

N l

O H

D D

O F

C E

D E

G K

1 0 f o ri = 0 t o 1 8 :r e a da : p o k e8 2 8+ i , a :n e x t

2 0 i n p u t " s t a r t " ; b s :p o k e8 3 1, i n t ( b s / 2 5 6 )

3 0 p o k e8 2 9 , b s - ( i n t ( b s / 2 5 6 ) * 2 5 6 )

4 0 i n p u t " e n d " ; b e :p o k e8 3 9 , i n t ( b e / 2 5 6 )

5 0 p o k e8 3 7 , b e - ( i n t ( b e / 2 5 6 ) * 2 5 6 ) : s y s 8 2 8

6 0 d a t a1 6 2 ,0 , 1 6 0 ,0 , 2 4 , 3 2 , 1 5 6 ,2 5 5

7 0 d a t a1 6 2 ,0 , 1 6 0 ,0 , 2 4 , 3 2 ,1 5 3 ,2 5 5

8 0 d a t a 1 0 8 , 0 ,1 6 0

B y t e sF r e e G e o r g eB o r s u k

B r a n t f o r d ,O n t a r i o

H e r e ' sa s h o r t , r e l o c a t a b l em a c h i n el a n g u a g er o u t i n et o d i s p l a y

t h en u m b e ro f B A S I Cb y t e sf r e e .U n l i k e B A S I C ' SF R Ef u n c t i o n ,

t h i sr o u t i n ea l w a y sp r i n t st h en u m b e ro f b y t e sf r e ep r o p e r l y ,a s a

p o s i t i v en u m b e r .I t i s b a s e do n a R O Mr o u t i n et h a ti s e x e c u t e da s

p a r to f t h ep o w e r - u ps e q u e n c e .

I t s u b t r a c t s t h eb o t t o m - o f - m e m o r yp o i n t e ra t $ 2 D( t o po f y o u r

p r o g r a m ) f r o mt h et o p - o f - m e m o r yp o i n t e ra t $ 3 7 ,t h e n u s e st h e

R O Mr o u t i n ea t $ B D C Dt o p r i n tt h er e s u l t i n gv a l u e .F i n a l l y ,t h e

" B A S I CB Y T E S F R E E "m e s s a g es t o r e da t $ E 4 6 0i s p r i n t e db y t h e

p r i n t s t r i n gr o u t i n ea t $ A B 1 E .

Y o uc a nu s et h i sp r o g r a ma s - i sb y j u s tS Y S i n gt o i t f r o mB A S I C ,

o r i n c l u d e t h ec o d ei n y o u ro w nM Lp r o g r a m s .B o t hB A S I C

l o a d e ra n da s s e m b l e r c o d ea r el i s t e db e l o w :

1 r e m *b y t e sf r e ep r o g r a m*

2 r e m * b yg e o r g eb o r s u k*

1 0 f o ri = 4 9 1 5 2t o 4 9 1 7 2

2 0 r e a da : p o k ei , a :c h = c h + a

3 0 n e x ti

4 0 i f c h < > 2 6 2 4t h e np r i n f d a t ae r r o r ! ! ! " :s t o p

5 0 p r i n t " ** s y s4 9 1 5 2w i l lg i v eb y t e sf r e e "

6 0 d a t a1 6 5 , 5 5 , 5 6 , 2 2 9 ,4 5 , 1 7 0 , 1 6 5

7 0 d a t a 5 6 , 2 2 9 ,4 6 , 3 2 , 2 0 5 , 1 8 9 , 1 6 9

8 0 d a t a 9 6 , 1 6 0 , 2 2 8 ,3 2 , 3 0 , 1 7 1 ,9 6

T h em a c h i n ec o d e :

I d a $ 3 7

s e c

s b c$ 2 d

t a x

I d a $ 3 8

s b c$ 2 e

j s r $ b d c d

I d a # $ 6 0

I d y # $ e 4

j s r $ a b 1 e

r t s

G e t t i n gT h eB o o t

; t o p o fm e m o r y ,l o w

; s u b t r a c tb o t t o m ,l o w

; m e m t o ph i g h

; s u b t r a c tb o t t o mh i g h

; p r i n tn u m b e ri n a , x

; p o i n t t os t r i n g

; a t $ e 4 6 0

; p r i n tm e s s a g e

; r e t u r nt o B A S I Co r c a l l e r

C h r i sM i l l e r

K i t c h e n e r ,O n t a r i o

E v e r w i s hy o uc o u l dl o a di n m a c h i n el a n g u a g eo r d a t af i l e si n t o

y o u rC 6 4w i t h o u tt h ed a n g e ro f c r a s h i n go u to f B A S I Cw i t ha

F I L EN O T F O U N De r r o r ,o r h a v i n g y o u rp r o g r a mr e - r u n f r o m

t h e t o pa f t e rt h e l o a d ?A l li t t a k e si s a c o u p l eo f S Y Sc a l l sa n da

p o k e !

1 0 r e m b o o tt o l o a d3 p r o g r a m sf r o mb a s i c

2 0 s n = 5 7 8 1 2 :r e ms e tn a m e

3 0 I d = 6 5 4 9 3 :r e mk e r n a ll o a d

4 0 a = 7 8 0 : r e m. a r e g i s t e rp a r a m s

5 0 s y ss n ' p r o g i" , 8 , 1 :p o k ea , 0 :s y sI d

6 0 s y ss n " p r o g 2 " , 8 , 1 :p o k ea , 0 :s y sI d

7 0 s y ss n " p r o g 3 " , 8 , 1 :p o k ea , 0 :s y sI d

8 0 r e mc o n t i n u ew i t hb a s i c

T h ef l o wo f B A S I Ci s n o td i s t u r b e db y t h e s el o a d sa n di f a n e r r o r

o c c u r s ,y o uc a n h a n d l ei t y o u r s e l fw i t h o u tt h ep r o g r a mb o m b

i n g .J u s tc h e c kt h e d i s k e r r o ra f t e re a c hl o a dw i t hs o m e t h i n g

l i k e :

o p e n1 5 , 8 , 1 5 : i n p u t # 1 5 , a , b $ , c , d :c l o s e1 5

: i f a t h e np r i n tb $ ( e r r o r )

U s et h i st e c h n i q u ef o r " .. . , 8 , 1 "l o a d so n l y .

Y o uc a na l s ou s et h i si n d i r e c tm o d et o l o a dc o d eo r d a t aw i t h o u t

d i s t u r b i n gB A S I C ' Ss t a r t - o f - v a r i a b l e sp o i n t e r .

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 12: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 12/84

1 2 8B i t sQ u i c kF i l eC o p i e r T . A .S w e e n e

R i d g e f i e l d ,C T

B o o t i n gU p

Y o u rM o d eM e n u

J o h n C h i s m

K n o x v i l l e ,T N

P u t t e r i n ga r o u n dt h e C 1 2 8P r o g r a m m e r ' sR e f e r e n c e G u i d e ,I

f o u n ds o m ed a t ao n p a g e4 4 7t h a t ,w h e ne n t e r e di n t ot h eb o o t

s e c t o r ( T r a c k1 s e c t o r0 ) o f a d i s k ,p u r p o r t e dt o p r o v i d et h eu s e r ,

u p o nb o o t i n g ,w i t h am o d e m e n uf o r :

1 ) C 6 4 B A S I C

2 ) C l 2 8B A S I C

3 ) C 1 2 8M O N I T O R

T h i si s n o tq u i t es o . T h eM Lr o u t i n es h o u l d b e g i no n t h e9 t h

b y t e ,n o t t h e1 2 t h ,a n dt h el o o p w a i t i n gf o ri n p u ti s n o tp r o p e r l y

e x e c u t e d .

T h ef o l l o w i n gp r o g r a mi s a p r o p e r l yw o r k i n gv e r s i o n ,a n dw r i t e s

t h ec o d et o t h eb o o ts e c t o ro f a d i s k .B u tb e f o r e w a r n e dt h a ti t

s h o u l db e i n s t a l l e do n a f r e s h d i s k ,o r o n o n et h a ty o uk n o w

d o e s n ' th a v et r a c k0 1 ,s e c t o r0 0 a l l o c a t e d .

J u s tr u nt h i sp r o g r a mo n t h ef r e s hd i s kt o i n s t a l lt h eb o o tm e n u .

I n t h ef u t u r e ,w h e n e v e ry o ub o o tw i t ht h a td i s ki n t h ed r i v e ,t h e

a b o v em e n uw i l lc o m eu p a n da l l o wy o ut o m a k ea s e l e c t i o n .

B N

D O

H E

N C

O GE K

A P

I M

K A

J A

J P

L C

L G

D H

B P

N l

C L

F H

G H

L H

P I

C H

G N

C F

C P

M M

L F

1 0 0

1 1 0

1 2 0

1 4 0

1 5 0

1 6 0

1 7 0

1 8 0

1 9 0

2 0 0

2 1 0

2 2 0

2 3 0

2 4 0

r e m *

r e m *

r e m *

f o ri =

r e a d

n e x t

s e l e c to n

f i xf o rp g

b o o t

4 4 7

t r a c k1 s e c t o r

= 1 t c

b y t :

) 1 0 0

o f c 1 2 8p r g .g u i d e

0 m u s tn o tb e a l l o c a t e d

c s = c s + b y t :w $= w $+ c h r $ ( b y t )

i f c s < > 6 9 6 5t h e np r i n t" d a t ae r r o r " :

o p e r

o p e r

1 5 ,

8 , 8

p r i n t # 1 5 ,

3 , 1 5 ,

8 , " # "

■ b - p '

p r i n t # 8 , w $

p r i n t # 1 5 ,

p r i n t # 1 5 ,

p r i n t

2 5 0d a t a

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 0

3 6 0

3 7 0

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d s $

6 7

0

6 9

5 8

5 4

6 7

5 0

1 3

5 6

8 2

4 9

2 0 8

2 3 5

" u 2 " ; 8

' b - a "

i O "

8 ; 0

; 0 ; 1 ; (

0 ; 1 ; 0

D

c l o s e8 : c l o s e1 5

6 6 ,

3 2 ,

6 7 ,

1 3 ,

5 2 ,

1 3 ,

5 6 ,

3 2 ,

3 2 ,

1 3 ,

2 0 8 ,

3 ,

7 6 ,

7 7 ,

1 2 5 ,

8 4 ,

1 3 ,

3 2 ,

3 2 ,

3 2 ,

5 1 ,

7 7 ,

1 3 ,

3 ,

7 6 ,

0 ,

0 ,

2 5 5 ,

3 2 ,

3 2 ,

3 2 ,

5 0 ,

6 6 ,

4 6 ,

7 9 ,

0 ,

7 6 ,

3 ,

1 7 6

0 ,

1 3 ,

7 7 ,

4 9 ,

6 6 ,

4 6 ,

6 5 ,

3 2 ,

7 8 ,

3 2 ,

7 7 ,

6 4 ,

0 ,

8 3 ,

7 9 ,

4 6 ,

6 5 ,

3 2 ,

8 3 ,

6 7 ,

7 3 ,

2 2 8

2 5 5

2 0 1

e n d

0 ,

6 9 ,

6 8 ,

3 2 ,

8 3 ,

6 7 ,

7 3 ,

4 9 ,

8 4 ,

2 5 5 ,

2 0 1 ,

5 1 ,

0

7 6

6 9

6 7

7 3

4 9

6 7

5 0

7 9

2 0 1

5 0

2 0 8

H e r e ' s as h o r tp r o g r a mt o c o p y p r o g r a mf i l e sf r o mo n ed i s kt o

a n o t h e r .I t s i m p l ya u t o m a t e sa B L O A D / B S A V Ep r o c e s s ,a l l o w i n

p r o g r a mf i l e st o b e c o p i e da t a h i g hs p e e dw h i l em a i n t a i n i

t h e i r o r i g i n a ll o a d a d d r e s s .I t w a sw r i t t e ni n r e s p o n s et o p r o b

l e m sI h a dw i t ht h ef i l ec o p yf e a t u r eo f t h eD O Ss h e l l .

M N

C H

A L

G C

F M

I O

A K

P H

K P

I F

F D

N C

D G

1 0 0r e m p r o g r a mf i l ec o p i e r1 2 8t i ms w e e n e y

1 1 0p o k e5 8 , 5 : r e m r e s e r v es p a c ei n b a n k1

1 2 0c l r

1 3 0p r i n t ' p r gf i l ec o p i e r "

1 4 0p r i n f ' i n s e r tm a s t e rd i s k ,p r e s sk e y " :g e t k e ya $

1 5 0i n p u t ' f i l en a m e " ; f l $ :d c l e a r

1 6 0b l o a d( f l $ ) , b 1

1 7 0s a = p e e k ( 1 7 2 )+ p e e k ( 1 7 3 ) * 2 5 6: r e mg e t

s t a r t i n ga d d r e s s

1 8 0 e a= p e e k ( 1 7 4 )+ p e e k ( 1 7 5 ) * 2 5 6: r e m g e t

e n d i n ga d d r e s s

1 9 0p r i n f i n s e r t t a r g e td i s k ,p r e s sk e y " :g e t k e ya $

2 0 0d c l e a r :b s a v e( f l $ ) , b 1, p ( s a ) t op ( e a )

2 1 0p r i n f ' c o p yc o m p l e t e d ,a n o t h e r ?y " ;

: i n p u t " [ 3 l e f t ] " ; a $

2 2 0i f a $ = " y "t h e n1 2 0

2 3 0 p o k e5 8 , 2 5 5 :c l r : r e mr e s t o r eb a n k1

F A S TG U L P M .G a r a m s z e g

T o r o n t o ,O n t a r i o

W i t ha f e ws i m p l em o d i f i c a t i o n s ,t h e G U L P . C O P Yp r o g r a m

p r e s e n t e di n T r a n s a c t o rV o l .7 , I s s u e0 6 ( p a g e5 2 )f o rt h e 1 5 7 1

a n dC - 1 2 8( 1 5 7 1R A Md i s kc o p i e r ) ,c a n b ed o u b l e di n s p e e d .

T h em o d i f i c a t i o n sd e s c r i b e db e l o wa l l o wt h ep r o g r a mt o c o p ya

s i n g l es i d e d d i s ki n j u s to v e rf o u rm i n u t e sa n da d o u b l es i d e di n

a b o u ts e v e na n da h a l f .T h em o d i f i c a t i o n st o t h em a i n B A S

l i s t i n go n p a g e5 3 a r ea s f o l l o w s :

1 1 2 1s l o w :o p e n9 , 8 , 9 , " # 3 "

1 1 8 1p r i n t # 1 5 , " u O " c h r $ ( 8 ) c h r $ ( 4 )

1 2 6 1p r i n t # 1 5 , " u O " c h r $ ( 8 ) c h r $ ( 4 )

1 2 6 2r e s t o r e2 0 0 0

1 2 6 3o f $= " " :f o rf x = 1 t o 2 9 :r e a do f :o f $= o f $+ c h r $ ( o f )

: n e x t

1 2 6 4 p r i n t # 1 5 , " m - w " c h r $ ( 0 ) c h r $ ( 6 ) c h r

1 2 6 5 p r i n t # 1 5 , " m - e " c h r $ ( 0 ) c h r $ ( 6 )

1 3 3 0p r i n t c h r $ ( 1 4 7 ) :p r i n t" * * d o n e * * " :p r i n t # 1 5 , " u j " :d c l o s e

2 0 0 0d a t a1 2 0 ,1 6 9 , 1 3 , 1 4 1 , 1 6 9 ,

2 0 1 0d a t a1 4 1 , 1 7 0 ,2 , 8 8 , 9 6 ,

2 0 2 0d a t a 2 0 1 ,1 6 0 ,2 0 8 , 4 , 6 9 ,

2 0 3 0d a t a1 0 4 , 7 6 , 2 2 2 , 1 5 7 ,0 ,

2 ,

7 2 ,

0 ,

0

1 6 9 ,

1 6 5 ,

1 3 3 ,

6

0

0

T h eT r a n s a c t o r I O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 13: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 13/84

T h er e a s o n sf o rt h ec h a n g e sa r e a sf o l l o w s :

( 1 )l i n e1 1 2 1f o r c e st h eC - 1 2 8i n t os l o wm o d e( b e c a u s ed i r e c t

m e m o r ya c c e s sw i l ln o t w o r kp r o p e r l yi f t h e C - 1 2 8i s i n

F A S Tm o d e )a n dr e s e r v e sd i r e c ta c c e s s d i s kb u f f e r# 3 .

( 2 )l i n e s1 1 8 1a n d1 2 6 1 u s et h e b u r s tm o d e" s e ts e c t o ri n t e r

l e a v e "c o m m a n dt o a n o p t i m u mi n t e r l e a v eo f 4 . T h i ss p e e d s

u p b o t hd i s kr e a d sa n dw r i t e s .

( 3 )l i n e s1 2 6 2t o 1 2 6 5s e tu p a n de x e c u t ea s h o r tp r o g r a mi n t h e

1 5 7 1 ' sb u f f e r # 3 .T h i sp r o g r a mt u r n so f ft h ev e r i f ya f t e rw r i t e

f e a t u r eb y p a t c h i n gi n t ot h e1 5 7 1' s i n t e r r u p tr o u t i n ea l l o w i n g

m u c hg r e a t e r w r i t es p e e d s .( E a c ht i m et h e 1 5 7 1w r i t e sa

s e c t o r ,i t i m m e d i a t e l yr e a d si t b a c ki n a g a i nt o v e r i f yi t . T h i s

c a u s e sa t i m ed e l a yo f o n ed i s kr e v o l u t i o no r a b o u t0 . 3

s e c o n d so f w a s t e dt i m ef o re a c hs e c t o rw r i t t e n ) .

( 4 )T h ep r i n t # 1 5 , " u j "i n l i n e1 3 3 0r e p l a c e sa n " i O "i n t h e o l d e r

v e r s i o n .T h e" u j "w i l lr e s e tt h ed e f a u l t i n t e r r u p tv e c t o r si n t h e

1 5 7 1a f t e rt h ec o p y i n g h a sf i n i s h e d .

( 5 )l i n e s2 0 0 0t o 2 0 3 0c o n t a i n t h eo b j e c tc o d ef o r t h e 1 5 7 1

p r o g r a m .T h es o u r c ec o d ei s a s f o l l o w s :

; d i s a b l ei n t e r r u p t s

; l o wb y t eo f n e wi n t e r r u p tr o u t i n e

; s a v ei n i n t e r r u p tv e c t o rl o b y t e

; n e wh i b y t e

; a n ds a v ea l s o

; r e s t o r e i n t e r r u p t s

; n e wi n t e r r u p th a n d l e r

; s a v ea c c u m u l a t o r

; g e tj o bc o d ef o rb u f f e r # O

; c h e c kf o r" v e r i f ys e c t o r "

; n o ,t h e ng o b a c kt o n o r m a l

; y e s ,t h e nc a n c e li t

; a n ds a v ea g a i n

; r e t r i e v ea c c u m u l a t o r ,a n d

; g ot o n o r m a li n t e r r u p th a n d l e r

T h i ss h o r tm a c h i n ec o d ep r o g r a mc a nb e p l a c e di n a n yo f t h e

1 5 7 1' s b u f f e r sw h i c ha r e n o t c u r r e n t l yu s e db y D O S .B e c a r e f u l

w h e nu s i n gi t o n y o u ro w nb e c a u s ef a i l u r e t or e s e tt h ei n t e r r u p t

p o i n t e rt o i t sd e f a u l tv a l u ea f t e ru s ew i l lc a u s et h e1 5 7 1t o l o c k

u p o r g o h a yw i r ei f t h en e wi n t e r r u p tr o u t i n ew e r et o b e c o m e

c o r r u p t e db y b e i n go v e r w r i t t e nb y D O S .

s e i

I d a

s t a

I d a

s t a

c l i

r t s

w r i t e o f f= *

p h a

I d a

c m p

b n e

e o r

s t a

c o n t i n u e= *

p l a

j m p

# < w r i t e o f f

$ 0 2 a 9

# > w r i t e o f 1

$ 0 2 a a

$ 0 0

# $ a 0

c o n t i n u e

$ 0 0

$ 0 0

$ 9 d d e

B u i l t - i nC r a s h

P r o t e c t i o n

M i k eH a r t i g a n

L o c k p o r t ,N Y

A l i t t l e - k n o w na n de v e nl e s sd o c u m e n t e df e a t u r eo f t h eC 1 2 8i s

a b u i l t - i nw a yt o r e c o v e rf r o mc r a s h e s w i t h o u tl o s i n gy o u rB A S I C

p r o g r a m !I f a p r o g r a ml o c k su p , i t c a ng e n e r a l l yb e s a v e db y

h o l d i n gd o w nt h eR U N / S T O Pk e yw h i l es i m u l t a n e o u s l yp r e s s

i n g t h e r e s e tb u t t o n .T h i sw i l lc a u s et h e C 1 2 8t o r e s e t ,b u t

i n s t e a do f i n i t i a l i z i n gB A S I C ,i t w i l le n t e r t h eb u i l t - i nm o n i t o r .

T h ei n t e r e s t i n g p a r ti s t h a tz e r op a g eh a sb e e nl e f tv i r t u a l l y

u n t o u c h e d ,i n c l u d i n g t h e p o i n t e r st o y o u rB A S I Cp r o g r a m !N o w

e n t e rX < R E T U R N >t o e x i tt h e m o n i t o r ,a n dV o i l a !Y o u rB A S I C

p r o g r a mi s t h e r e ,r i g h tw h e r e y o ul e f ti t ! T h i st r i c kw i l ln o tw o r k

i f y o ul o s ty o u rp r o g r a mt o a N E Wc o m m a n d ,s i n c et h e p o i n t e r s

h a v ea l r e a d yb e e nr e s e t .I n t h i sc a s e ,a m o r et r a d i t i o n a lu n - n e w

t e c h n i q u em u s tb e e m p l o y e d .

C o m m o nM e m o r y T i mF l e e h a r t

T u m w a t e r ,W A

T h eC 1 2 8 ' sM M U( M e m o r y M a n a g e m e n tU n i t )h a sa r e g i s t e r

t h a t c o n t r o l s t h ea m o u n to f " s h a r e d "o r c o m m o nm e m o r y

p r e s e n ti n b o t ht h e1 2 8a n dZ 8 0m o d e s .T h ec o m m o nm e m o r y

i s a l w a y sb a n k0 . T h i sr e g i s t e ri s l o c a t e da t $ F D 5 0 6a n di t w o r k s

l i k et h i s :

B i n a r yv a l u e

o f l o wn y b b l e

O O x x

O l x x

l O x x

l l x x

x x O O

x x O l

x x l O

x x l l

S h a r e dm e m o r yc o n f i g u r a t i o n

N os h a r e dm e m o r y

S h a r e l o wm e m o r yo n l y

S h a r eh i g hm e m o r yo n l y

S h a r ei n b o t hh i g ha n dl o wm e m o r y

S h a r e1 k b y t e si n e a c hs e c t i o n

S h a r e4 k b y t e si n e a c hs e c t i o n

S h a r e8 k b y t e si n e a c hs e c t i o n

S h a r e 1 6 kb y t e si n e a c hs e c t i o n

E x a m p l e :s t o r i n g$ 0 F( % 0 0 0 0 1 1 1 1 )i n $ F D 5 0 6r e s u l t si n 3 2 ko f

s h a r e dm e m o r y ;1 6 k f r o m$ 0 0 0 0t o $ 3 F F F ,a n d1 6 k f r o m$ C 0 0 0

t o $ F F F F( e x c e p t i n g ,o f c o u r s e , t h e c o n f i g u r a t i o nm e m o r ya t

$ F F 0 0 - $ F F 0 4 ) .

T h ep u r p o s eo f t h i sc o m m o nm e m o r yi s t o f a c i l i t a t et h e s t a c k

a n d t h e c o m m o ns t o r a g en e c e s s a r yf o r p r o g r a m' h o u s e

k e e p i n g ' .T h e8 5 0 2r e q u i r e sc o m m o nl o wm e m o r yf o ra s t a c k

a n dz e r o

A m i g aB i t s

C u s t o m i z i n g

C L IW i n d o w s

B r y c eN e s b i t t

B e r k e l y ,C A

W h e na n e wC L Ii s s t a r t e df r o mt h eW o r k b e n c h ,t h ew i n d o w

a l w a y sc o m e su p i n t h es a m e ,f i x e dl o c a t i o n .I f y o u d on o tl i k e

t h e p o s i t i o n o rs i z ey o ua r e o u to f l u c k .F r o mt h eC L Ia b i tm o r e

c o n t r o li s p o s s i b l e :a w i n d o ws p e c i f i c a t i o ns u c ha s " C O N : 0 / 1 /

6 4 0 / 2 0 0 / O l dC L I "c a nb e t y p e da f t e rt h eN E W C L Ic o m m a n d .

B u tt h a t ' sa l o t o f t y p i n ga n di s u s e l e s sf o rW o r k b e n c hu s e r s .

C h a n g i n gt h ed e f a u l t sa l l o w sb o t hC L Ia n dW o r k b e n c hu s e r st o

g e t t h a tc u s t o ml o o kw i t h o u ta l lt h eh a s s l e .

T h em o d i f i c a t i o ni s e a s y ,w i t ho n ee x c e p t i o n :a b i n a r yf i l ee d i t o r

i s n o tp a r to f t h es o f t w a r ep r o v i d e dt o u s e r sw i t ht h e i rA m i g a .

T h er e s to f t h i sd i s c u s s i o nw i l la s s u m et h a ty o uh a v ea l r e a d y

T h eT r a n s a c t o r N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 14: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 14/84

d o w n l o a d e d ,o r o t h e r w i s e o b t a i n e dt h ep r o g r a m" f i l e z a p " .T h e

t e c h n i q u e sd e s c r i b e dc a na l s ob e a p p l i e dt o o t h e re d i t o r s .( T h e

t e x te d i t o r" A e d i t "b y J o eB o s t i c ,f o re x a m p l e ,a l l o w se d i t i n go f

b i n a r yf i l e s . )

D e p e n d i n go n w h i c hC L Is t a r t u pf i l ey o uw i s ht o m o d i f y ,u s eo n e

o f t h e s ec o m m a n d st o s t a r t f i l e z a p :

C L I > r u nf i l e z a pc i n e w c l i

W o r k b e n c h> r u nf i l e z a ps y s : s y s t e m / c l i

N o wp a g ef o r w a r d w i t ht h e < F >c o m m a n d ,k e e p i n ga s h a r p

l o o k o u tf o ra s t r i n g t h a tl o o k ss o m e t h i n gl i k e" C O N : 0 / 5 0 / 6 4 0 /

8 0 / N e wC L I " .T h i sd e f i n e s t h ec h a r a c t e r i s t i c so f t h e n e wC L I

w i n d o w :

" C O N : "m e a n so p e na c o n s o l ew i n d o w- l e a v et h i sp a r ta l o n e .

T h ef i r s tn u m b e ri s h o w m a n yp i x e l sf r o mt h e l e f te d g et h e

w i n d o ws h o u l ds t a r t .T h es e c o n d sn u m b e ri s h o w m a n yp i x e l s

f r o mt h et o p .T h et h i r di s t h ew i d t hi n p i x e l s ,a n dt h ef i n a lo n ei s

t h e h e i g h t .T h e" N e wC L I "w i l lb e u s e da s t h et i t l eo f t h e

w i n d o w .

U s ef i l e z a p ' s< * >c o m m a n dt o c h a n g et h e d e f a u l t s .K e e pi n

m i n dt h a tt h ew i n d o wm u s tf i to n t h e s c r e e n ,a n dt h a ty o uc a n ' t

c h a n g et h et o t a ll e n g t ho f t h es t r i n g !I f y o um a k ea m i s t a k e ,u s e

t h e < R >c o m m a n dt o r e c o v e r .W h e nr e a d y ,u s e t h e < U >

c o m m a n dt o u p d a t et h ef i l e ,a n dp r e s s< C T R L X C >t o e x i t .

N o wy o u rC L Iw i n d o ww i l lc o m eu p w h e r e a n dh o wy o ul i k ei t !

T i t l e s

i n A m i g a B a s i c

J o h nC h e n

C U ft o n ,N J

I t ' sd i f f i c u l t t oc h a n g et h et i t l eo f a w i n d o wi n A m i g a B A S I Ca f t e r

t h e w i n d o wh a s b e e no p e n e d ,a n d i m p o s s i b l et o n a m et h e

s c r e e nt i t l e .T h i sp r o g r a mu s e sa s y s t e ml i b r a r yr o u t i n et o

c i r c u m v e n tt h i sB A S I Cw e a k n e s s .F o rt h ep r o g r a mt o w o r k ,t h e

" i n t u i t i o n . b m a p "f i l e h a s t o b e i n t h e " l i b s : "d i r e c t o r yo n t h e

W o r k b e n c hd i s k o ri n t h es a m ed i r e c t o r y t h ep r o g r a mi s s t o r e d

i n .Y o uc a ng e tt h e" . b m a p "f i l ef r o mt h e p u b l i cd o m a i no r , i f y o u

h a v et h e " A m i g a E n h a n c e rk i t "( t h e 1 . 2s y s t e ms o f t w a r eu p

g r a d e ) ,y o u c a nu s et h e" C o n v e r t F D "p r o g r a m o nt h eE x t r a sd i s k

( i nt h e" B a s i c D e m o s "d i r e c t o r y )t o r o l ly o u ro w n. b m a p sf r o mt h e

f i l e si n t h e" F D 1 . 2 "d i r e c t o r y .

L I B R A R Y" i n t u i t i o n . l i b r a r y "

w s &= W I N D 0 W ( 7 )' p o i n t e rt o a W i n d o ws t r u c t u r e

I N P U T ' W i n d o w T i t l e " ; w t $

I N P U T " S c r e e n T i t l e " ; s t $

w t $= w t $+ C H R $ ( 0 )' f o rn o t i t l es e t

s t $= s t $+ C H R $ ( 0 )' s t r i n g t oc h r $ ( O )

C A L L S e t W i n d o w T i t l e s ( w s & , S A D D ( w t $ ) , S A D D ( s t $ ) )

' S A D Dr e t u r n st h ea d d r e s sw h e r et h es t r i n gi s s t o r e d

L I B R A R YC L O S E

E N D

E a s t e rE g g s

W e ' v es e e nc o m p u t e r sb e f o r ew i t hs e c r e tm e s s a g e sh i d d e n

w i t h i nt h e i ro p e r a t i n gs y s t e m sl i k eE a s t e re g g s :t h eo r i g i n a lP E T

h a dM i c r o s o f t ' s" W A I T6 5 0 2 , x "j o k e ;t h e C - 1 2 8h a s i t s " S Y S

3 2 8 0 0 , 1 2 3 , 4 5 , 6 "i n c a n t a t i o nt h a tp u t su p c r e d i t sa n da p e a c e n i

m e s s a g e .T h eA m i g at a k e st h i st r e n do n es t e pf u r t h e r .

F i r s ts t e p :M o v ea n yw i n d o w so u to f t h ew a yt h a ta r ec o v e r i n gu p

t h eW o r k b e n c hs c r e e n ' st i t l eb a r ,a n dc l i c ks o m e w h e r eo n t h e

W o r k b e n c hw i n d o wt o a c t i v a t ei t . Y o us h o u l d s e et h e f a m i l i a

" W o r k b e n c hr e l e a s e .. . " m e s s a g ew i t ht h e a m o u n to f f r e e

m e m o r yd i s p l a y e di n t h et i t l eb a r .I t i s i n t h et i t l eb a rt h a tt h e

s e c r e tm e s s a g e sw i l lb e d i s p l a y e d .

N o w ,y o u ' l lh a v et o h o l dd o w ns e v e r a lk e y sa t o n c ef o rt h i s :w i t h

t h et h u m bo f y o u rl e f th a n d ,h o l dd o w nt h el e f tS H I F Ta n dA L T

k e y ss i m u l t a n e o u s l y ,a n dw i t ht h et h u m bo f y o u rr i g h th a n d ,

h o l dd o w nt h er i g h tS H I F Ta n dA L Tk e y s .N o w ,w i t ht h em i d d l e

f i n g e ro f y o u rl e f th a n d ,h o l dd o w nt h eF l k e y -a l l f i v ek e y s

s h o u l db e d o w na t t h i sp o i n t .P o o f !W i t ht h ef l a s h o fa " d i s p l a

b e e p " ,u p c o m e sa s e c r e tm e s s a g ei n t h et i t l eb a r !N o wr e l e a s e

F l a n dh o l dd o w nF 2 i n s t e a d .Y o ug e ta n e wm e s s a g ef o re a c ho f

t h et e n f u n c t i o n k e y s .

I f y o ut h o u g h tg e t t i n gt h o s em e s s a g e sw a sa b i tt r i c k y ,y o u ' l l f i n

t h a t g e t t i n gt o t h en e x ts t a g eo f m e s s a g e si s l i k ep l a y i n gs o l i t a i r

t w i s t e r . F i r s t o fa l l ,m a k es u r et h eW o r k b e n c hw i n d o wi s a c t i

v a t e d , t h et i t l eb a ri s v i s i b l e ,a n dt h eW o r k b e n c hd i s ki s i n t h e

i n t e r n a ld i s kd r i v e .Y o u rm o u s es h o u l db e p l a c e du p a g a i n s t t h

r i g h ts i d eo f t h ek e y b o a r d ,c l o s et o t h eA m i g a .A l s o ,t h em o u s e

p o i n t e ro n t h es c r e e nm u s t b er e s t i n go v e rt h es c r e e n - t o - b

r e - o r d e r i n gg a d g e ti n t h e W o r k b e n c hs c r e e nt i t l eb a r ( t h e

s e c o n dg a d g e tf r o mt h er i g h t ) .T o g e tt h em o u s ea n dp o i n t e ri n

t h e s ep o s i t i o n s ,y o um a yh a v et o l i f tt h e m o u s eu p a n dp u t i t

d o w nw h e r ey o u w a n ti t . N o wy o ua r er e a d yf o rs t a g et w o :f i r s t

g e tt h e F ls e c r e tm e s s a g ed i s p l a y e d a se x p l a i n e d a b o v e .N o w ,

w i t ha l lf i v ek e y ss t i l lh e l dd o w n ,r e a c ho u tw i t ht h er i n gf i n g e ro f

y o u rr i g h th a n da n de j e c tt h eW o r k b e n c hd i s kf r o mt h ed r i v e .

P o o f !y o uw i l ls e ea n o t h e rs e c r e tm e s s a g ea p p e a ri n t h et i t l eb a r .

N o wd o n ' tm o v e !Y o ua r er e a d yf o rs t a g et h r e e .

S t a g et h r e es h o u l d o n l yb e a t t e m p t e di f t h e r e a r en o c h i l d r e n

p r e s e n t ,a n d y o ua r e n o to f f e n d e db y n a u g h t yw o r d s .W h i l ei n

t h ea b o v ep o s i t i o n( t h em o u s ep o i n t e rs h o u l ds t i l lb e o v e rt h e

s c r e e n - t o - b a c kg a d g e t ) ,r e a c ho u tt o t h el e f tm o u s eb u t t o nw i t h

t h el i t t l ef i n g e ro f y o u rr i g h th a n da n dh o l di t d o w n ,b e i n gc a r e f u l

n o tt o m o v et h em o u s e .N o w ,g e tt h i s :W i t ht h em o u s eb u t t o n

s t i l lh e l dd o w n ,y o u h a v et o r e - i n s e r tt h ed i s k !U s ey o u rr i n g

f i n g e rf o r t h i s .A f t e r t h ed i s k" c a t c h e s " , p o o f !T h en a u g h t

m e s s a g e !W o n d e rw h a tt h e ym e a n ?

T h i si s n ' ta j o k e ;i t r e a l l yw o r k s ,b u ti t c a nb e t r i c k yt o d o .Y o u

m a yw a n tt o e n l i s tt h ea i do f a n a s s i s t a n tt o g e tt o s t a g et h r e e .

A n o t h e rw a yi s t o u s et h ep r o g r a mi n t h i si s s u e c a l l e d" E v e n t m

k e r "t o d o t h ew o r kf o ry o uj u s tb y t y p i n gi n a c o m m a n d .T h e

c o m m a n dt o g e t t h es e c r e tm e s s a g ei s g i v e na t t h ee n do f t h e

a r t i c l e .

T h eT r a n s a c t o r 1 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 15: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 15/84

Lt

R

G l o s s yp a p e rp r i c i n g :I l o v et h ew a yy o ug u y sw o r k .Y o us t a r t t o

u s em o r ee x p e n s i v eg l o s s yp a p e rr a t h e rt h a nt h et h i c kn o n - g l o s s

p a p e r( t h a ti s a l o t b e t t e rt h a ng l o s s y ) ,r a i s i n gt h e e x p e n s ef o r

m a t e r i a l s ,t h e ny o ur a i s ey o u rp r i c ef o rs u b s c r i p t i o n s .1 w o u l dt h i n k

t h a tt h e e x t r ap r i c ef o r s u b s c r i b i n g c o u l dg o t o s o m e t h i n gm o r e

u s e f u lt h a ne a s i l y - r i p p e dg l o s s yp a p e r( w h i c hI h a t e ! ) .H o wa b o u t

m o r ea r t i c l e sa n dp r o j e c t s .H o wa b o u tm o r em a i l o r d e rp r o d u c t s .I f

y o ur e a l l yn e e dm o r ei n c o m e ,g e t m o r ea d sf o r n o n - T r a n s a c t o r

p r o d u c t s .T h e nl o w e ry o u rp r i c e sf o rs u b s c r i p t i o n sa n dm a i l o r d e r

i t e m s .

I h o p e y o uw i l lt h i n km o r eh e a v i l ya b o u tt h ea b o v e .

S t e v e nT . C a m p b e l l ,M i s s i s s a u g a ,O n t a r i o

W ed o n ' tl i k ei n c r e a s i n g t h e p r i c eo f a s u b s c r i p t i o na n ym o r et h a n

y o ul i k ep a y i n gi t , S t e v e n( w h i c hi s w h yt h ep r i c ed i d n' t c h a n g ef o r

s o l o n g ) .A n ds t r a n g e l ye n o u g h ,w ea l s op r e f e r t h eo l d p a p e r ,t h o u g h

n o te v e r y o n ea g r e e sw i t hu s . B u ty o u ra s s u m p t i o nt h a tt h eg l o s s y

p a p e ri s m o r ee x p e n s i v ei s i n c o r r e c t- i t ' sa c t u a l l ya b o u t1 5p e rc e n t

c h e a p e r ,w h i c hi s o n er e a s o nw ec h a n g e di t . A n o t h e rr e a s o ni s t h a t

a d v e r t i s i n gc o p yl o o k sb e t t e ro n t h ec o a t e ds t o c k- a t l e a s ti n t h e

e y e s o ft h ea d v e r t i s e r s .Y o u ro t h e r p o i n t s a r e w e l l t a k e n :w e a r e

g o i n ga f t e rm o r eo u t s i d ea d v e r t i s i n g ,w e w i l lh a v em o r em a i lo r d e r

p r o d u c t sa n d ,a s t h e a d v e r t i s i n gs t a r t st o b u i l d ,w e a l s ow a n tt o

i n c r e a s e t h en u m b e ro f p a g e s p e ri s s u et o a c c o m m o d a t em o r e

a r t i c l e sa n dp r o j e c t s .M e a n w h i l e ,t h o u g h ,w e h a v et o s t a yi n

b u s i n e s s . .. a n dw eh o p e y o u' I Is t i c ka r o u n dt o w a t c hu s g r o w .

B l a z i n 'F o r t hd o c s :S i n c ed i s c o v e r i n gy o u rm a g a z i n ei n M a r c h ,I

h a v ef o u n di t t o b e a ne x c e l l e n ts o u r c eo f t e c h n i c a li n f o r m a t i o no n

C o m m o d o r e ' sc o m p u t e r s .I w a ss o i m p r e s s e db y t h a tf i r s ti s s u e

( M o r eL a n g u a g e s )t h a tI g o ta d i s ka n d m a g a z i n es u b s c r i p t i o n ,a n d

t h e c o m p a n i o nd i s kt o t h a t i s s u e .U n f o r t u n a t e l yI m i s s e dt h e

S i m u l a t i o n sa n dM o d e l l i n gi s s u e ,b u tI h a v e n ' tb e e nd i s a p p o i n t e ds i n c e .

O n ea r t i c l et h a ti n t e r e s t e dm e i n t h e M o r eL a n g u a g e si s s u ew a s

" B l a z i n 'F o r t h- E v e r y t h i n gy o u w a n t e dt o k n o wa b o u tF o r t h( b u t

w e r ea f r a i dt o a s k ) " .I w a st h r i l l e dt o g e tt h e F o r t hs y s t e mo n t h e

d i s k ,b u tw a sd i s a p p o i n t e dt o f i n dn o d o c u m e n t a t i o no n h o wt o u s e

i t . I n t h ef i r s tp a r a g r a p ho f t h ea r t i c l e ,t h ea u t h o rs t a t e d :" I w r o t et h e

f o l l o w i n ga s a n a i dt o p e o p l ew h om i g h tb e t r y i n gt o u n d e r s t a n dt h e

s o u r c et o B l a z i n ' F o r t h ,a n d i t s h o u l db e c o n s i d e r e dp a r to f t h e

d o c u m e n t a t i o nf o rt h es o u r c ef i l e st o t h e s y s t e m . "H o wc a nI g e t t h e

d o c u m e n t a t i o no n h o wt o u s ei t a n d ,i f p o s s i b l e ,t h es o u r c ef i l e sa s

w e l l ?

D a v i dN e t o ,T o r o n t o ,O n t a r i o

Y o u r si s o n eo fa n u m b e ro f i n q u i r i e sw eh a v er e c e i v e da b o u tm o r e

d o c sf o rB l a z i n 'F o r t h ,D a v i d .U n f o r t u n a t e l y , t h es o u r c ea n dd o c u

m e n t a t i o nf o rS c o t tB a l l a n t y n e' s s u p e r bi m p l e m e n t a t i o no fF o r t ha r e

j u s tt o ol a r g et o d i s t r i b u t eo u r s e l v e s .T h e ya r ea v a i l a b l e ,t h o u g h ,o n

t h eC o m m o d o r ep r o g r a m m i n g( C B M P R G )f o r u mo n C o m p u S e r v e .I f

y o uh a v ea C o m p u S e r v ea c c o u n t( o ri f y o uw e r et o g e to n e )y o u

c o u l da l s op u tq u e s t i o n st o S c o t tB a l l a n t y n eo n - l i n e ,i f y o ud e s i r e ,

a s h e c h e c k si n o n o u r f o r u m sf a i r l yr e g u l a r l y .I f y o u( o ra n y o n ef o r

t h a tm a t t e r )w o u l dl i k ea f r e eC o m p u S e r v eI n t r oP a k ,p l e a s ec a l lu s .

I t c o n t a i n sa n a c c o u n tn u m b e r ,a p a s s w o r d ,a n d$ 1 5o f o n - l i n e

t i m e .

D r i v eh e a dn o i s ea b a t e m e n t :I n a l e t t e ri n y o u rS e p t e m b e ri s s u e ,

W a r r e nP o l l a n sa s k e df o rs o l u t i o n st o t h ep r o b l e mo f h e a db a n g i n g

o n t h e d e s t i n a t i o n d r i v ew h e nu s i n gf a s td u a l - d r i v ec o p yp r o g r a m

( L e t t e r s ,V o l u m e8 , I s s u e2 ) .

I o v e r c o m et h i sp r o b l e mw h e nu s i n gF a s tH a c k ' e mb y p r e s s i n gF l ,

w h i c hc h a n g e st h es o u r c ef r o md e v i c e8 t o d e v i c e9 ; t h e nI c a l lf o ra

d i r e c t o r y ( b yp r e s s i n g' D ' )w i t ht h es o u r c ed i s ki n d e v i c e9 . T h e

h e a dd o e sn o tb a n gd u r i n gt h i so p e r a t i o n ,a n dt h eh e a dp o s i t i o ni s

n o wk n o w n ,s o c o p y i n gc a np r o c e e dw i t h o u tf e a r o fd a m a g et o t h e

h e a da l i g n m e n t .W h i l e o nt h e s u b j e c to f t h i sp a r t i c u l a rp r o g r a m ,u s i n gt h e d u a lf i l ec o p i e r si n F a s tH a c k ' e m( v 3 . 9 9 )s e e m st o b e

T h eT r a n s a c t o r 1 3 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 16: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 16/84

i m p o s s i b l eb e t w e e na 1 5 7 1 ( e v e ni n 1 5 4 1m o d e ) a n da 1 5 4 1 .

S o l u t i o n s ,a n y o n e ?

B r u c eL l o y d ,D a p t o ,N e wS o u t hW a l e s

T h e6 8 0 1 0 a n dc o m m e r c i a ld i s k s :T h ea r t i c l eo n t h e 6 8 0 1 0

A m i g a( T h e3 2 - b i tA m i g a ,V o l u m e8 , I s s u e2 ) r a i s e ds o m ec o n c e r n .

M o s tp u r c h a s e ds o f t w a r ei s l o a d e df o l l o w i n gK i c k s t a r ta n dh a si t s

o w ns t a r t u p - s e q u e n c e .A s I u n d e r s t a n di t , i fo n eg o e sf o ra c o n v e r

s i o no n ei s f a c e d w i t hm o d i f y i n gt h es t a r t - u ps e q u e n c eo f a l lo w n e d

s o f t w a r ea n dc o p y i n gD e c i G E Lt o a l ld i s k s .I s t h e r ea n yw a ya r o u n d

t h i sp r o b l e m ?

I a nR o b e r t s o n ,B e l l e v i l l e ,O n t a r i o

I n t e r e s t i n gp o i n t , I a n .N o , w e d o n ' tk n o wo f a n yw a yt o m a k e

D e c i G E La c t i v ea t b o o t - u pw i t h o u ta l t e r i n gt h es t a r t u p - s e q u e n c e .

D o n ' tg o c h a n g i n ga l l y o u rd i s k s ,t h o u g h .. . r e m e m b e rt h a to n l y

s o u r c eo f c o m p a t i b i l i t yp r o b l e m sw h e ny o ui n s t a l lt h e6 8 0 1 0i s t h e

c o m p a r a t i v e l yr a r eM O V ES R , < E A >i n s t r u c t i o n .C h a n c e sa r et h a t

m o s to f t h ep r o g r a m s y o uu s ed o n o t c o n t a i nt h i si n s t r u c t i o n ,s o

i n s t a l l i n gD e c i G E Lw o n ' tb e r e q u i r e da n y w a y( t h ew o r s tt h a tw i l l

h a p p e n ,b yt h ew a y ,i s t h a ty o u1 1g e ta S o f t w a r eE r r o rc a u s e d b yt h e

6 8 0 1 0d e t e c t i n gw h a t ,f o ri t , i s a p r i v i l e g em o d ev i o l a t i o n ) .A l s o ,

m a n yc o m m e r c i a lp r o g r a m sc a ni n f a c tb e l o a d e d f r o me i t h e rC L Io r

W o r k b e n c hw i t h o u th a v i n gt o r e b o o t ,s o y o uc a ni n s t a l lD e c i G E L

b e f o r ei n v o k i n gt h e m .I fn e c e s s a r y ,c o p yt h eA S S I G N a n dE X E C U T E

c o m m a n d st o R A M :( o rp u ty o u rW o r k b e n c hd i s ki n y o u re x t e r n a l

d r i v ei fy o u h a v eo n e ) ,p u tt h ec o m m e r c i a ld i s ki n t h ei n t e r n a ld r i v e ,

a n de x e c u t ea s c r i p tf i l el i k et h e f o l l o w i n g :

a s s i g ns y s :d f O :

a s s i g ns : d f O . s

a s s i g nl i b s :d f O i l i b s

a s s i g nI : d f O : l

a s s i g n d e v s :d f O : d e v s

a s s i g nf o n t s :d f O : f o n t s

a s s i g nc : d f O : c

N o we x e c u t et h e s t a r t u p - s e q u e n c eo n t h e p r o g r a md i s k ,a n d

c h a n c e sa r e t h ep r o g r a mw i l ll o a ds u c c e s s f u l l y .F a i l i n gt h a t ,y o uw i l l

h a v et o c h a n g et h ep r o g r a md i s k ,b u tt h a ts h o u l db e r e q u i r e do n l y

r a r e l y .

T a k i n gA m i g at o t a s k :Y o uh a v eb e e nl a m e n t i n gt h e s u p p o s i t i o n

t h a tt h eA m i g ai s n o ts e l l i n g .I t a k et h i sa s f i g u r a t i v er a t h e rt h a n

l i t e r a l ,l e a v i n gt h ei m p l i c a t i o nt h a tt h eA m i g ai s n o ts e l l i n ga s w e l l a s

i t s h o u l d ,c o u l d ,o r h a st o t om e e te x p e c t a t i o n s .M yq u e s t i o nt o y o u

i s t h i s :h o w m a n yu n i t ss h o u l d ,c o u l d , o rd o y o ue x p e c tt h eA m i g at o

s e l l t ob e c o n s i d e r e d" s e l l i n g ?M y n e x t q u e s t i o ni s : h o wd i dy o u

a r r i v ea t t h i sn u m b e ra n dw h y ?

F o ra l l i t s t e c h n o l o g i c a lg i m c r a c k e r y ,t h eA m i g ah a ss o m es e r i o u s

s h o r t c o m i n g s .F i r s t o fa l l , i t ' s n e w ,a n d t h a t ' sb a d .T h e v a s t ,

u n t a p p e dm a s s e so f c o m p u t e rp e a s a n t sh a v eh a da n o p p o r t u n i t yt o

t e s t - d r i v eV I C2 0 sa n dC o m m o d o r e6 4 s .F r o mt h es o u n d so f i t , t h e r e

a r e n ' t t o om a n yp e a s a n t sl e f to u t t h e r ei n t h e m a r k e t p l a c e .T h e

g e n e r a ll e v e l o fc o m p u t e ra w a r e n e s si n t h ep o p u l a t i o nh a sg o n e u p

c o n s i d e r a b l ys i n c e t h eh e y d a yo f t h eC o l e c oA d a m ,T I 9 9a n dR a d i o

S h a c k C o C o .

S e c o n d l y ,t h e o p e r a t i n gs y s t e mi s n e w ,a n dw o r s e , i n c o m p a t i b l e

w i t ht h e m a j o r i t yo f t h ei n s t a l l e ds y s t e m s .I t ' st h eo l d7 8 r p mv s 3 3

1 / 3 r p ms y n d r o m e :m a n yp e o p l eh a v et o om u c hi n v e s t e dt o s t a r t

f r o ms c r a t c ha g a i n .S o w h a tt h a tL P s h a v eb e t t e rs o u n dr e p r o d u c

t i o n ?

T h i r d l y ,t h eA m i g ai s n o ta n o p e na r c h i t e c t u r es y s t e m .I t ' sa m a z i n g

w h a ty o uc a nd o w i t ha n A p p l eo r P Ca n dt h er i g h ta d d - o nc a r d s .

Y e a r s f r o m n o w ,t h o s es y s t e m sw i l lb e u p g r a d e dt o v i r t u a l l ym a t c h

t h el a t e s tt e c h n o l o g y .T o u p g r a d et h eA m i g ab e c o m e sa n e x p e n s i v

k l u d g e .S u r e ,t h en e wA m i g a2 0 0 0m a yc o r r e c tt h a t ,b u ty o u rl a m e n t

d i d n ' tc o v e r t h en e wm a c h i n e s ,d i di t ?

A n df i n a l l y ,t h eA m i g ai s n o tc h e a p .L e t ' sn o tc o m p a r ei t t o I B M ,

t h o u g h .S o f e wp e o p l ea r e b u y i n gr e a lI B M s( m o s t l yn e wc l o n e

m a n u f a c t u r e r s ,I b e t ) t h a te v e nI B Mb e c a m ec o n c e r n e de n o u g ht o

t r ya n dm a r k e ts o m e t h i n gd i f f e r e n t .W h a ta b o u tt h et e c h n o f r e a k

M o s to f t h e mb u yA t a r i s ,w h i c ha r em u c hm o r er e a s o n a b l yp r i c e d ,

a n dt h e nt r yt o m a k et h e mr u nl i k eA m i g a s( A m i g a e ? ) .

T h e r ei s a n i c h ef o rt h eA m i g a ,b u ti t ' sa v e r ys m a l la n ds p e c i a l i z e

o n e ,v e r ys i m i l a rt o t h en i c h et h a tw a sc a r v e do u tf o ra s h o r tt i m eb y

t h e O h i oS c i e n t i f i cC h a l l e n g e r s .T h en i c h ec o n s i s t so f t h e m o s t

e c c e n t r i ct e c h n o f r e a k sw h oa l s oh a p p e nt o h a v el o t so f d i s c r e t i o n

a r ys p e n d i n gp o w e r .C o m m o d o r ec r e a t e dt h a tn i c h e ,a n de m p h a

s i z e di t w i t ht h e i rA n d yW a r h o l / B l o n d i ei n t r o d u c t i o nt o t h e w o r l d

U n l e s st h ep r i c ec o m e sd o w n ,o r t h ea v a i l a b l es o f t w a r ei n c r e a s e

t r e m e n d o u s l y ,t h eA m i g am a yd i e i n t h a t n i c h e ,j u s t l i k et h eO S I

C 1 P .

I t ' st a n t a l i z i n gt o t h i n kw h a tJ a c kT r a m i e l c o u l dh a v e d o n ew i t ht h e

A m i g ai f h i sb r a n do f m a r k e t i n gh a db e e nf o l l o w e d . I n s t e a d ,w ee n d

u p w i t h a r g u a b l yt h e m o s tp o w e r f u lm i c r oo n t h e m a r k e tt o d a y

b e i n gw i d e l ys e e na s h a v i n gn o n a t u r a lp l a c e .I t r e m i n d sm eo f t h e

C o r d ,w h i c hw a st o oa d v a n c e df o r i t s t i m e ,o r t h eT i t a n i c ,w h i c h

s u c c u m b e dt o i t so w np h a n t a s y .

A r et h e c o n s u m e r sw r o n gf o r n o tb u y i n gi t ? A r et h e d e v e l o p e r

w r o n gf o rn o tc h u r n i n go u ts o f t w a r e ?O r a r eo u ro w ne x p e c t a t i o

w r o n g ?I s u s p e c tt h el a t t e r .

B yt h ew a y ,I d o n ' to w na n A m i g a ,s i m p l yb e c a u s eI c a n ' t a f f o r do n e .

M yC o m m o d o r e6 4 w i l lj u s th a v et o d o f o ra w h i l el o n g e r .M yO S I

C 1 Pi s b e y o n dr e s u s c i t a t i o n ,a n da v a i l a b l et o a n y o n ew i t h ag o o d

s t o r y .

J o h nK u l a ,V i c t o r i a , B r i t i s hC o l u m b i

W e l l , t h e r e ' se n o u g ho p i n i o n si n t h a tl e t t e rt o f u e lh a l fa d o z e nl o n g

c o n v e r s a t i o n s ,J o h n ,b u tf o rn o ww e ' l lh a v et o m a k ed o w i t hs o m eq u i c k i er e s p o n s e st o t h ep o i n t sy o ur a i s e .H e r ew eg o ,o n e b yo n e .. .

N e w n e s s :i t ' s h a r dt o d e s i g na n e wc o m p u t e rt h a td o e s n ' ts u f f e r

f r o mt h i s" d e f e c t " .T h ef a c tt h a t t h em a r k e ti s m o r e a w a r en o w a

d a y st h a ni t o n c ew a ss h o u l dh e l pt h eA m i g a ,n o t h u r ti t - o n eo ft h e

p r o b l e m sw es e ei s t h a ti t ' sh a r dt o a p p r e c i a t ei t s u n i q u es t r e n g t h

u n t i ly o u' v eb e e na r o u n do t h e rc o m p u t e r sf o ra w h i l e .

O p e r a t i n gs y s t e m :y e s ,i t ' s i n c o m p a t i b l e w i t he v e r y t h i n g ,t h o u g h

C o m m o d o r eh a s g o n et o a l o to f t r o u b l et o m a k eI B Mc o m p a t i b i l

a v a i l a b l et o t h o s ew h ow a n ti t . B u tt h e r ei s n o p r o g r e s sw i t h o u t

c h a n g e ,e v e ni f i t t a k e sa w h i l e ,a n dt h es w i t c hf r o m7 8 t o 3 3 1 / 3

d i d n' t t a k ea l l t h a tl o n g .D o y o uh a v e al o to f 7 8 si n y o u rr e c o r d

c o l l e c t i o n ?

T h eT r a n s a c t o r 1 4 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 17: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 17/84

A r c h i t e c t u r e :w ej u s tp l a i n d i s a g r e eo n t h i so n e .T h o u g ht h e r ea r e

s o m ep r o b l e m sw i t ht h ee x p a n s i o ni n t e r f a c eo n t h eA m i g a1 0 0 0 ,

t h e yc a n b ea n da r e b e i n go v e r c o m e b y d o z e n so f h a r d w a r e

m a n u f a c t u r e r s .C o m m o d o r eh a sb e e nv e r yf o r t h c o m i n gw i t ht h e

e x p a n s i o ns p e c i f i c a t i o n s( o n e o ft h ep r o b l e m s h a sb e e nt h a tt h e

s p e c sh a v ec o n t i n u e dt o e v o l v ea f t e rt h er e l e a s eo ft h em a c h i n e )a n d

o t h e rd a t ar e l a t i n gt o t h e A m i g a ' si n t e r n a lo p e r a t i o n ;t h i si s i n

c o n t r a s tw i t ht h e h i s t o r yo f t h eM a c i n t o s h ,w h i c ht r u l yi s a c l o s e d -

a r c h i t e c t u r ec o m p u t e r .

C h e a p :o k a y ,i t ' s n o t t h a tc h e a p .I f y o u w a n ts o m ep e r s p e c t i v e ,

t h o u g h ,l o o ka t t h e e a r l y p r i c i n go ft h eC o m m o d o r e6 4 ,w h i c hc a m e

p r e t t y c l o s et o t h e c u r r e n t p r i c i n go f t h eA m i g aW O O .B y t h ew a y ,

t r y i n gt o m a k ea n A t a r iS T r u n l i k ea n A m i g ai s g o i n gt o b e a

f r u s t r a t i n ge x p e r i e n c ef o ra n y o n ew h ot r i e si t . . . s o r to f l i k et r y i n gt o

m a k ey o u rp o p - u pt o a s t e rr u nl i k ea m i c r o w a v eo v e n .

N i c h e :W e1 1h a v et o w a i to n a f i n a la n s w e rf o rt h i so n e , b u tA m i g ai s

a l r e a d ye s t a b l i s h i n gi t s e l fw e l lw i t ha r t i s t s ,v i d e op r o f e s s i o n a l s ,

m u s i c i a n sa n de n g i n e e r s .T o p - f l i g h t p r o d u c t i v i t ys o f t w a r eh a sb e e n

e m e r g i n gf o ra w h i l en o w , s ow e s h o u l ds t a r tt o s e e i t m a k i n g

i n r o a d si n t ot r a d i t i o n a lb u s i n e s sc i r c l e s ,e s p e c i a l l yw i t ht h er e c e n t

r e l e a s eo f t h eA m i g a2 0 0 0 .W h e t h e rt h eA m i g aw i l lm a k ei t a s a

" h o m ec o m p u t e r " r e m a i n st o b e s e e n ;w es t i l lb e l i e v et h a td e p e n d sa

l o to n h o ww e l lC o m m o d o r eg e t sa c r o s st h ep o i n ta b o u tm u l t i t a s k

i n g ,w h i c hi s f o ru s m a y b et h e b i g g e s t t h i n g t h em a c h i n e h a sg o i n g

f o ri t .

A s f o ry o u ro r i g i n a lq u e s t i o na b o u t n u m b e r s ,i t r e m a i n st o b e s e e n

h o wf a rt h eA m i g ac a ng o .W h a t ' sc e r t a i ni s t h a ti t h a sn o tb e e nw e l l

m a r k e t e d ,a n dh e n c ei s n o tw e l lu n d e r s t o o db y a l o t o f p o t e n t i a l

b u y e r s .W h e nt h a tc h a n g e s ( a n di n d i c a t i o n sa r et h a ti t m a yc h a n g e

s o o n ) ,I g u e s sw e' I Iq u i tg r i p i n g .

M y s t e r i o u s q u o t em o d ee x p l a i n e d :I n a r e c e n tT r a n s a c t o rt h e r e

w a sa B i ta b o u th o wa v a l u eg r e a t e rt h a n 1 2 7i n l o c a t i o n6 4 6( $ 0 2 8 6 )

o f t h eC o m m o d o r e6 4 a f f e c t st h e d e l e t ek e yi n q u o t em o d e( B i t s ,

V o l u m e8 , I s s u e1 ) . T h i s d i s c o v e r yi n t r i g u e dm e ,a n ds o I s t a r t e d

l o o k i n ga r o u n dt o s e ew h a tr e a l l yh a p p e n s .

T h ed e l e t e r o u t i n ec o n t a i n st h i sc o d e :

. . . a n di t i s f o l l o w e d

C T R Lc h a r a c t e r s :

e 7 7 7

e 7 7 a

e 7 7 c

I d a

s t a

b p l

b y t h i sc o d e]

e 7 7 e

e 7 8 0

e 7 8 2

I d x

b e q

j m p

$ 0 2 8 6

( $ f 3 ) , y

$ e 7 c b

T o mt h e r o u t i n e st h a th a n d l et h e

$ d 4

$ e 7 8 5

$ e 6 9 7

. . . w ef o l l o w t h ej m p ,a n df i n d :

e 6 9 7 o r a# $ 8 0

. . . t h e na f e wb y t e sl a t e r

e 6 a 2 j s r$ e a 1 3

T h i sl a s ti n s t r u c t i o ni s a c a l lt o t h er o u t i n et h a tp r i n t st h ec h a r a c t e r

c u r r e n t l yi n t h ea c c u m u l a t o r .

I t a p p e a r st h a tt h ep r o g r a m m e r sa s s u m e dt h ev a l u ei n 6 4 6 w o u l d

a l w a y sb e l e s st h a n1 2 8 ,w h i c hs h o u l db e t h ec a s e c o n s i d e r i n gt h e

C 6 4o n l yh a s1 6 c o l o u r s .P o k i n ga v a l u eg r e a t e rt h a n 1 2 7 c a u s e st h e

b r a n c ha t $ e 7 7 ct o f a i l ,a n dt h e r o u t i n ef a l l st h r o u g hi n t oc o d et h a ti s

i n t e n d e dt o h a n d l et h e p r i n t i n go f c o n t r o l c h a r a c t e r s .T h ed e l e t e

o c c u r s ,a n dt h ec u r s o rg e t sb u m p e db a c k , t h e nt h ec h a r a c t e rg e t s

p r i n t e d ,w h i c he x p l a i n sh o wt h ep r e v i o u sc h a r a c t e rg e t sc o r r u p t e d .

A f t e r p r i n t i n gt h en e wc h a r a c t e r ,t h ec u r s o ri s b a c kw h e r ei t s t a r t e d

b e f o r et h ed e l e t e .T h eb l a c k h o l ee f f e c ti s c a u s e d b e c a u s et h ec u r s o r

g e t sm o v e db a c k . N o t i c eh o wt h e c h a r a c t e rp r i n t e dr e f l e c t st h ev a l u eo f 6 4 6 .

N i c k e yM a c D o n a l d ,F r e d e r i c t o n ,N e wB r u n s w i c k

T h a n k sf o rt h ed e t e c t i v ew o r k ,N i c k e y .N o wi f o n l ys o m e o n ec o u l d

c o m eu p w i t ha u s ef o rt h i s' m o d e ' .. .

G u r um a i ld e p a r t m e n t :J i mB u t t e r f i e l dh a s p a s s e d o nt o u s t h e

f o l l o w i n gl e t t e rf r o mr e a d e r J o e l R u b i n ,w h oo f f e r st h e f o l l o w i n g

c o m m e n t so n J i m ' sa r t i c l eo n s e c o n d a r ya d d r e s s e sa n dt h eK e r n a l

( S e c o n d a r yA d d r e s sB i t s ,V o l u m e8 , I s s u e1 ) :

1 ) T h eK e r n a lO P E Nr o u t i n eO R A ' st h e s e c o n d a r ya d d r e s s w i t h

# $ 6 0 ,a t l e a s to n t h eC 6 4a n dC 1 2 8( $ F E F Do n t h e1 2 8 ) , s o :

I d a # 2 :I d x# 8 :I d y # $ f :j s rs e t l f s

. . . i so k a y .

2 ) S i n c er e g i s t e r s ,u n l i k eB a s i cf i l e p a r a m e t e r s ,h a v en o d e f a u l t

v a l u e :

I d a # 3 :I d x# 4 :j s rs e t l f s

. . . m a yw e l le n du p o p e n i n gt h ep r i n t e rt h ew r o n gw a y( e . g .i f . y

c o n t a i n e d7 g o i n gi n t ot h er o u t i n e ) .

3 ) Y o ud o s e e mt o n e e dO R A# $ 6 0i f y o uu s e K e r n a lT A L K , L I S T

e t a l .

J o e lR u b i n ,S a nF r a n c i s c o ,C a l i f o r n i a

T o w h i c h J i mr e s p o n d s :

R i g h to n a l lt h r e e c o u n t s .T og i v em o r ed e t a i l :

1 )E a r l i e rC o m m o d o r em a c h i n e sd i dn o ti n s e r tt h ee x t r as e c o n d a r y

b i t sw h e ny o uc a l l e dO P E N( S F F C O ) . T h u s ,t o s e t a s e c o n d a r y

a d d r e s s1 5 , y o uh a dt o L D Y* $ 6 Fb e f o r ey o u rc a l l t oS E T L F S ; a

v a l u e o f# $ 0 Fw o u l d n' t w o r k .I w r i t ec o d ef o ra w i d ev a r i e t yo f

C o m m o d o r em a c h i n e s .. . a n ds i n c ei t ' sa s e a s yt o " w r i t ei n "t h o s e

e x t r ab i t s ,I d o s o a n ds a v e m y s e l ft h e t r o u b l eo f n e e d i n gt o r e c o d e

w h e nI t a k ei t t o a n o t h e rm a c h i n e .O n t h en e w e rm a c h i n e s( V I C2 0

a n ds u b s e q u e n t ) ,y o uc a nl e tt h eO P E Nr o u t i n ed o t h ej o bf o ry o u .. .

a l t h o u g hi t ' s n o e x t r aw o r kt o a d dt h eb i t s i ny o u rc o d i n g ,a n dm i g h t

h e l py o u r e m e m b e rt h a tt h e y a r ea l w a y sa n e c e s s a r yp a r to f t h e

w o r k i n gS A .

2 ) A g r e e d .A s I s u g g e s t ,i fy o ud o n ' tw a n ta s e c o n d a r ya d d r e s sy o u

s h o u l ds t i l ls u p p l ya v a l u eo f2 5 5t o s i g n a l" n o S A " .

3 ) D i r e c tc a l l st o T A L K / L I S T E Nd e f i n i t e l yn e e dt h o s eb i t s ,a s y o u

s a y ;t h es y s t e ma s s u m e st h a tt h eS A w a ss e tu p w i t ht h ee x t r a$ 6 0 .

M o s tu s e r sw o n ' tn e e dt o c a l lT A L K / L I S T E N .. . t h e yw i l ld o l e s s

w o r kb y u s i n gC H K I N( $ F F C 6 , s w i t c hi n p u tp a t h ) o rC H K O U T( S F F C 9 ,s w i t c h o u t p u tp a t h ) ;t h e nG E T( S F F E 4 ,g e ta c h a r a c t e r )o r

T h eT r a n s a c t o r 1 5 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 18: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 18/84

C H R O U T( $ F F D 2 ,s e n da c h a r a c t e r ) ;a n df i n a l l yC L R C H N( S F F C C ,

r e s t o r ei n p u ta n do u t p u td e f a u l t p a t h s ) .

J i mB u t t e r f i e l d ,T o r o n t o ,O n t a r i o

M o r eP l u s / 4T e c hI n f o :T h e r ei s a n o t h e rs o u r c eo f t e c h n i c a l

i n f o r m a t i o nf o r r e a d e rJ i m W e l c h ,w h ow a sl o o k i n gf o r a P l u s / 4

c i r c u i td i a g r a m( L e t t e r s ,V o l u m e8 , I s s u e1 ) .

S A M SC o m p u t e r f a c t h a sc o m p l e t et e c h n i c a ld a t aa n ds c h e m a t i c

d i a g r a m sa v a i l a b l ef o r t h e P l u s / 4 .I f t h e ya r e n o t a v a i l a b l ei n h i s

a r e a ,t h e yc a nb e o r d e r e df r o m :T e n e xC o m p u t e rE x p r e s s ,P . O .B o x

6 5 7 8 ,S o u t hB e n d ,I n d i a n a4 6 6 6 0 .T h ep r o d u c tn u m b e ri s 3 3 5 5 1 ,

a n dt h ep r i c ei s $ 1 7 . 9 5( U S ) p l u s$ 3 . 7 5 s h i p p i n ga n dh a n d l i n g .

I f a n y o n eh a sa m a c h i n el a n g u a g es c r e e nd u m pp r o g r a mf o r t h e

P l u s / 4t h a tw o u l dw o r ki n m o n i t o rm o d eo r i n r e g u l a rm o d e ,I

w o u l dl i k et o o b t a i n o n e .T h a n ky o u .

P . W e n d t ,D o d s o n ,L o u i s i a n a

t R a n z b l o o p e R s

T h eB l u n d e r f u l M r .E d :I f y o ut y p e di n C h r i sM i l l e r ' sn i f t yt e x t

e d i t o r ,M r . E d ,f r o mV o l u m e8 , I s s u e2 , m a yh a v eb e e nd i s c o n c e r t e d

t o d i s c o v e rt h a tt h eV e r i f i z e rc o d ef o r l i n e5 5 3 0d i d n o tm a t c ht h e

o n ep r i n t e di n t h em a g a z i n e .T h el i n ei n q u e s t i o ni s :

5 5 3 0j s rl e f t; d i m

T h eV e r i f i z e rc o d eg i v e ni n t h em a g a z i n ew a sG E ,b u ti t s h o u l db e

O K .N o ,i t s h o u l d n ' tb e o k a y ,i t s h o u l db e " O K " .H o wd i d t h ew r o n g

V e r i f i z e rc o d eg e ti n t ot h el i s t i n g ,y o ua s k ?W e ' ds u r el i k e t ok n o w .

L o n g S y m a s sL a b e l s :W e d o n ' tk n o wh o w m a n yp e o p l eh a v e

a l r e a d y n o t i c e dt h i s ,b u t i t s e e m st h a ta l l v e r s i o n so f S y m a s s

r e l e a s e ds o f a rw i l ln o tp r o p e r l yh a n d l el a b e l so v e r8 c h a r a c t e r sl o n g

( w h a ts h o u l dh a p p e ni s t h a tl o n g e rl a b e l sw i l lb e a c c e p t e d , b u to n l y

t h e f i r s t8 c h a r a c t e r sa r e s i g n i f i c a n t ) .T h i sw i l lb e f i x e di n t h e

u p c o m i n gn e wv e r s i o no f S y m a s s .. . m e a n w h i l e ,b e t e r s e .

S p a c eo r N u l lS t r i n g :B e l i e v ei t o r n o t ,t h et y p e s e t t i n ge q u i p m e n t

w eu s eh a sn o c h a r a c t e r e q u i v a l e n tt o t h eq u o t e( " )s e e ns o o f t e ni n

n e a r l ye v e r yp r o g r a ml i s t i n g .U n t i lr e c e n t l y ,t h eq u o t eh a dt o b e

s i m u l a t e db y r o t a t i n ga n i n c hm a r k( " ) c o u n t e r - c l o c k w i s e2 4 d e

g r e e s .B u tf o rs o m er e a s o n , t h e t y p e s e t t e rr o t a t ec o m m a n dc r a s h e s

t h e p r e v i e ws c r e e nt h a ta l l a r t i c l e sa r e s e n tt o b e f o r ea c t u a l l yt y p e s e t t i n gt h e m .T h i sw a sr e s o l v e db y u s i n gy e ta n o t h e rk l u d g e .

T h et y p e s e t t i n gc o m p u t e ra l l o w sv a r i a b l e sj u s tl i k eC B MB a s i c . A l l

q u o t e sw e r es u b s t i t u t e dw i t h av a r i a b l e ,a n dw h i l ep r e v i e w i n gt h e

v a r i a b l ew a ss e tt o t h ec h a r a c t e rp a i r" . T h e n ,w h e nt h ea r t i c l ew a s

r e a d yt o b e t y p e s e t ,t h e v a r i a b l ew o u l db e r e - s e tt o t h er o t a t e di n c h

m a r k . O f t e nt h i sf i n a ls t e pw a sn e g l e c t e dw h i c hi s w h ys o m el i s t i n g s

a p p e a r e dw i t hq u o t e sa s " i n s t e a do f " .

W h e nA t t i ca c q u i r e dt h eC O M P U T E Rf o n t ,w ef o u n da n o t h e rs o l u t i o n .

T h i sf o n th a s a q u o t e s y m b o l ,b u t i t l o o k sl i k et h i s :" . Y e c h h !

H o w e v e r ,i n s u p e r s c r i p t e dm o d ei t l o o k sg r e a t( " )- a n di t d o e s n ' t

c r a s ht h ep r e v i e w !E x c e p tf o ro n el a s tp r o b l e m .W h e nt h e r e ' st w o

s i d e - b y - s i d e( i e . n u l l s t r i n g )i t c a n a p p e a rt o s o m ea s o n es p a c e

w i t h i nq u o t e s .A l t h o u g hi t c a nu s u a l l yb e d e t e r m i n e db y d e d u c t i o n ,

w ef e e li t m a yh a v e b e e nt h es o u r c eo f s o m ep r o g r a me n t r yt r o u b l e ,

e s p e c i a l l y s i n c et h eV e r i f i z e rw a sd e s i g n e dt o i g n o r es p a c e s .N a t u

r a l l yw eh a v ea s o l u t i o nf o rt h i s t o o ;f r o mn o wo n t h es p a c eb e t w e e n

t w oq u o t e ss i d e - b y - s i d ew i l lb e " t i g h t e n e du p "s o t h e r ec a nb e n o

q u e s t i o nt h a ti t m e a n s" n u l ls t r i n g " .W eh o p et h a tp r o b l e m sw i t h

q u o t em a r k s( w h i c hw o u l d h a v e b e e nf i v ey e a r so l dt h i sO c t o b e r

w i l lb e e l i m i n a t e df o r e v e r .

N o wi f w ec o u l dj u s tg e tC o m p u G r a p h i c st o c r e a t ea d e c e n tl o o k i n g

u n i - w i d t hf o n tf o rp r o g r a ml i s t i n g s .

A f e wT r a n s B a s i cb u g s :I n L e t t e r st h i s i s s u e ,w e q u o t ef r o ma

l e t t e rb y N i c k e yM c D o n a l do f F r e d e r i c t o n ,N e wB r u n s w i c k ,w h o

g a v eu s t h er e s u l to f h i si n v e s t i g a t i o n si n t ot h e" u n d o c u m e n t e C 6 4

e d i t i n gm o d e "l a t e l yr e p o r t e di n B i t s .H e r ew eq u o t eh i ma g a i n :

I h a v et y p e d e v e r yT r a n s B a s i cm o d u l e a n ds e e mt o h a v et h e ma l l

w o r k i n g ,b u tI f o u n da f e w b u g sa l o n gt h ew a y .F i r s ti s s o m et r i v i a ,

b u tI w o n d e r e di f a n y o n ee l s ee v e rn o t i c e d : t h eh e a d i n g T r a n s B

P a r t s1 t o 8 S u m m a r y 'n e v e rc h a n g e da f t e ri n s t a l m e n tn u m b e r8 . 1

m i s sT r a n s B a s i c ,a n ds o s t a r t e dt o m a k em yo w nm o d u l e sa n d e v e n

t o c o n v e r to t h e rp e o p l e s ' r o u t i n e st o T r a n s B a s i cf o r m a t .

S e c o n di s a p r o b l e mw i t ht h eT r a n s B a s i cU S E c o m m a n d .L i n e7 1 9 2

s h o u l dr e a d :

7 1 9 2 j s r e r r p g m

. . . a n dn o t " j s re r r m e m "a s p u b l i s h e d .L i n e7 2 4 2i n t h e s a m e

m o d u l ec a u s e sa p r o b l e mi f y o us p e c i f ya d e v i c en u m b e r .T h i si s

b e c a u s et h el i n ef o l l o w i n g" l d xd e v i c e "i s a t h r e e - b y t eo p e r a t i o n .T o

f i xt h i sp r o b l e m ,i t i s a s i m p l em a t t e ro f c h a n g i n g t w ol i n e s :

7 2 4 2 j m p u z 4 p 5

7 2 4 6 u z 4 p 5s t x t 2

T h i r di s t h e L a b e l l e dG o t om o d u l e .T h ea u t h o rd i dn o ts t o r et h e

d e s t i n a t i o nl i n en u m b e rw h e nc a l l i n ga l i n e ,s o i f a n e r r o rs h o u l d

o c c u ri n t h e c a l l e dl i n e ,t h e e r r o rh a n d l e rr e p o r t s t h ew r o n gl i n e

n u m b e r .I m a d et h e f o l l o w i n g m o d i f i c a t i o n :

6 0 3 6I g o t 7 I d y # 2 : I d a( $ 5 f ) , y :s t a$ 3 9

: i n y :I d a( $ 5 f ) , y :s t a$ 3 a :I d a$ 5 f

C a p a c i t a n c eM e t e rL i n eN u m b e r s :T h i so n eg o e sq u i t ea w h i l e

b a c k ,t o t h ea r t i c l eT h eC o m m o d o r e6 4 C a p a c i t a n c eM e t e r ,b y J i m

B a r b a r e l l oo fE n g l i s h t o w n ,N e wJ e r s e y( T r a n s a c t o r ,V o l u m e7 , I s s u e

4 ) .B a c ki n D e c e m b e rJ i ms e n tu s a c o r r e c t i o n ,w h i c hw ep r o m p t l

m i s p l a c e d . .. o n l yt o h a v ei t t u r nu p a g a i nt h eo t h e rd a y .H e r e ' sa ne x t r a c tf r o mJ i m ' sl e t t e r ,w i t ho u ra p o l o g i e sf o rt h ed e l a y :

S o m el e t t e r sI h a v er e c e i v e di n d i c a t ea p r o b l e mf o l l o w i n gt h e

" O p t i m i z i n gP e r f o r m a n c e "i n s t r u c t i o n s( p a g e3 2 ) . I t s e e m st h a t

m o d i f y i n gl i n e1 1 0 h a sn o e f f e c t .

U p o nr e v i e wo f t h ea r t i c l e ,I n o t i c e dy o ur e n u m b e r e dt h ep r o g r a m

b u t d i d n o tc h a n g et h el i n er e f e r e n c ei n " O p t i m i z i n g P e r f o r

P l e a s ep r i n ta c o r r e c t i o n i n d i c a t i n gt h a tt h et w or e f e r e n c e st o l i n e

1 1 0s h o u l dh a v eb e e nt o l i n e2 0 0 .

F i r s t - A i df o rP r o g r a m m e r ' sA i d :F r o mt h es a m ep i l eo f c o r r e

s p o n d e n c et h a ty i e l d e dJ i mB a r b a r e l l o ' s c o r r e c t i o na b o v ec o m e st h i s

f r o mJ a m e sG . R a eo f C h i l l i c o t h e ,O h i o . R e f e r r i n gt o t h e a r t i c l e

T h eT r a n s a c t o r 1 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 19: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 19/84

P r o g r a m m e r ' sA i df o r t h e C o m m o d o r e1 2 8 b yJ o s e p hC a f f r e y

( T r a n s a c t o r ,V o l u m e7 I s s u e5 ) ,J a m e sw r i t e s :

T h ep r o g r a mh a st h r e ek n o w np r o b l e m s .T h ef i r s t ,r e v e r s e p r i n t i n g

o f t h ef i r s tc h a r a c t e ro n t h el i n e i nt h e4 0 c o l u m nm o d eo n l yl o o k s

b a d a n dc a u s e sn o r e a lp r o b l e m s .

T h es e c o n do c c u r sw h e na p r o g r a ml i n eu s e sm o r et h a no n es c r e e n

l i n ea n d o n eo f t h e a d d i t i o n a ls c r e e nl i n e ss t a r t sw i t ha n u m b e r

( S Y S ,G O T O ,e t c )t h a t m a t c h e s a ne x i s t i n gl i n e n u m b e r .T h es c r o l l i n gr o u t i n ew i l lr e a dt h i sa s t h el a s tl i n en u m b e rl i s t e da n d

c o n t i n u el i s t i n gf r o mt h en e x tl i n en u m b e r .T h i si s a m a j o rp r o b l e m

i n t h e4 0 c o l u m nm o d e ,b u tc a nb e l i v e dw i t hi n t h e8 0 c o l u m n

m o d eb y l i m i t i n ga l l l i n e st o o n es c r e e nl i n e .

T h et h i r dp r o b l e mi s a c o m p u t e rl o c k u pw h e ns c r o l l i n gu p p a s t t h e

f i r s tl i n ei n t h e p r o g r a mi f t h e r ei s a n y t h i n ga p p e n d e dt o t h e

p r o g r a mb e t w e e nt h e e n do f t h e p r o g r a m a n dt h e e n do f b a s i c

p o i n t e r .W h e nt h i so c c u r s , t h et e c h n i q u eo f a s s u m i n gt h ee n do f

p r o g r a ml i n ki s a t t h e e n do f B a s i cm i n u s t w oi s i n c o r r e c t ,a n d

c a u s e st h e" r s t l i n k ; "r o u t i n et o g o i n t oa n e n d l e s sl o o p .

I h a v er e w r i t t e n t h e" f o u n d u p "r o u t i n et o e l i m i n a t et h i sp r o b l e m b y

e x e c u t i n gi t t w i c ea t t h ef i r s tt o l a s tl i n et r a n s i t i o n .T h ef i r s tt i m ei t

l o o k sf o rt h e p o i n t e r p o i n t i n gt o t h el a s tl i n el i n k ,w h i l et h es e c o n d

t i m ei t l o o k sf o rt h el i n kp o i n t i n gt o t h i sl i n k .

T h er e v i s e da s s e m b l e rc o d e b e l o wi s 9 b y t e s s h o r t e rt h a nt h e

o r i g i n a l ,s o t h e r e v i s e dc o d e c a ns i m p l yb e i n s e r t e di n t h eo r i g i n a l .

N o t e : t h e f o l l o w i n g B a s i cp r o g r a ml i n ew i l l s e tA Da s t h ea d d r e s so f

t h eb y t ef o l l o w i n gt h el a s tl i n el i n k .T h i sc a nb e c o m p a r e dw i t ht h e

e n do f B a s i ct o d e t e r m i n ei f a n yb y t e sh a v e b e e na p p e n d e dt o t h e

p r o g r a m :

6 3 9 9 9 a d= p e e k ( 4 6 1 0 )+ 2 5 6 * p e e k * 4 6 1 1 )+ 3 5 : r e t u r n

H e r ei s m yv e r s i o no f t h e" f o u n d u p "r o u t i n e :

f o u n d u pj s r p u t b a c k

j s r h u n t l i n e

b c c u p o u t

j s r s c r l d w n

l d x l i n k p n t r

I d a l i n k p n t r+ 1

c m ps o b+ 1

b n e f i n d

c p x s o b

b n e f i n d

j s r s c r o l d w n

j s r s c r o l d w n

I d a * 0

t a x

j s r i n i t

l d x l i n k p n t r

I d a l i n k p n t r + 1

f i n d j s r i n i t

j m ps e t u p1

r s t l i n k

; M o v e dn e x ts t xt o s t a r to f i n i t

M o v e dn e x ts t at o s t a r to f i n i t

B r a n c hi f l a s tl i n el i s t e dw a s

n o t t h ef i r s tl i n ei n t h ep r o g r a m

I n s e r tt w ob l a n kl i n e s

S e tO l d l i n ka t $ 0 0 0 0

F i n dt h ea d d r e s so f l i n k

p o i n t e rt o $ 0 0 0 0a n d

p u ti n t oO l d l i n k

F i n d a d d r e s so f l i n kp o i n t i n g

t o O l d l i n ka n dt h e nj m pt o t h e

l i n eL i s t e rr o u t i n e

l d x

I d a

s t x

s t a

j s r

c m p

b n e

c p x

r t s

s o b

s o b + 1

l i n k p n t r

l i n k p n t r+ 1

r d n w l n k

o l d l i n k + 1

r s t l i n k

o l d l i n k

; S t a r ts e a r c ha t S t a r t o fB a s i c

; R e a d v a l u eo f n e x tl i n k( x , a )

; L o o pu n t i ll i n k p n t r p o i n t s

; t oO l d l i n k

i n i t s t x o l d l i n k ; R e l o c a t e ds t xa n ds t ao p c o d e ss t a o l d l i n k + 1

X r e f 6 4 :I ' ma f r a i dt h e r e a r et w ob u g si n X r e f 6 4 , b u tt h a n k f u l l yb o t h

a r e p r e t t ye a s yt o f i x .S o h e r eg o e s .

C h a n g et h et h i r dn u m b e ro n l i n e1 5 3 0f r o m2 1 7t o 2 1 4 .

C h a n g et h el a s tn u m b e ro n l i n e1 7 7 0f r o m1 6 5t o 7 6 .

C h a n g et h ef i r s tt w on u m b e r so n l i n e1 7 8 0f r o m3 0 a n d 2 0 8t o 1 9 8

a n d1 6 6 .

R e p l a c el i n e s3 2 7 0 - 3 3 1 0w i t ht h e f o l l o w i n gl i n e s :

3 2 7 0d a t a 8 2 , 6 5 ,7 7 , 1 3 , 1 3 ,0 , 1 6 5 ,2 9 , 2 0 1

3 2 8 0d a t a 6 , 1 4 4 , 4 , 1 6 9 , 5 , 1 3 3 ,2 9 , 1 6 5 ,3 03 2 9 0d a t a2 0 8 , 3 , 7 6 , 1 3 4 , 1 6 1 ,7 6 , 1 4 5 , 1 6 1

3 3 0 0d a t a 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0 , 0

3 3 1 0d a t a 0 , 0 , 0 , 0 , 0 , 0 , 1 6 2 ,6 . 1 , 1 6 0

I ' ms o r r yf o ra n yi n c o n v e n i e n c e t h e s eb u g sm a yh a v ec a u s e d .

( I h a t eb u g s ! )

S i n c e r e l y ,D a v i dA r c h i b a l d

E d i t o r ' sN o t e :I f t h e r e ' ss p a c e ,a n dt h e r es h o u l db e ,w e1 1p u tn e w

v e r s i o n s o ft h eC 1 2 8P r o g r a m m e r ' s A i da n dX r e f 6 4o n T r a n s a c t o

D i s k# 2 0f o rt h i si s s u e .

D i v i s i o n R e v i s i o n :F o rt h ef o l l o w i n gc o r r e c t i o nw ea r e i n d e b t e dt o

R o s sC h u r c h m a no f T h u n d e rB a y ,O n t a r i o ,w h ow r i t e s :

I n t h es e c o n dp a r to f t h ea r t i c l e" H i g hS p e e dI n t e g e rM u l t i p l i e sa n d

D i v i d e s "( T r a n s a c t o r ,V o l u m e8 , I s s u e1 ) , t h e r e a r e s e v e r a lt y p i n g

e r r o r st h a tc a nb e m i s l e a d i n gi f n o tn o t i c e d , a sw a st h ec a s et h ef i r s t

t i m eI r e a dt h ea r t i c l e .A l lo c c u ri n t h e s e c t i o no n D i v i s i o n( p a g e4 3 ,

s e c o n dc o l u m n ) .T h el i n e" M 1 / M 2= R l r e mR 2 "l o o k sa s i f M l i s

d i v i d e db y M 2 , w h e r e a sM l i s a c t u a l l yd i v i d i n gi n t oM 2 .T h i s s h o u l

h a v ea p p e a r e da s :

M t ) M 2= R 1 r e m R 2

I n S t e p5 a t t h eb o t t o mo f t h es a m ec o l u m n ,t h el i n e" C M PR 2 - M 1

( c a r r yc l e a r ) "s h o u l dh a v er e a d" C M PR 2 - M 1( c a r r ys e t ) " .A t t h i s

s t e p ,R 2 i s e q u a lt o M l i n t h ee x a m p l eu s e d ,a n ds u b t r a c t i n gw i t h

t h ec a r r ys e t ,a s t h eM Lc o d ed o e s ,w i l ll e a v e t h ec a r r ys t i l ls e t .

T h e r ei s o n ef u r t h e rm i s t a k e ,i n t h e M Lc o d i n go f t h i sd i v i s i o n

a l g o r i t h m( p a g e4 5 ,s e c o n dc o l u m n ) .T h ef o u r t hl i n e ,w h i c hr e a d s

" R O LM 2+ 1 "s h o u l dh a v er e a d" R O LR 2+ 1 " .T h i sm a k e st h ec o d e

c o m p a t i b l e w i t ht h ee a r l i e rs t e p sa n dd e s c r i p t i o n .

A sa c o m p u t e rh o b b y i s ta n dt e a c h e ro f c o m m u n i t yn i g h tc o u r s e si n

m a c h i n el a n g u a g ea n d c o m p u t e ri n t e r f a c i n g ,I e n j o yy o u rm a g a z i n ev e r ym u c h .K e e pu p t h eg o o dw o r k !

T h eT r a n s a c t o r 1 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 20: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 20/84

T e l e C o l u m n

P u n t e r N e t B yG e o f f r e yW e l c h ,T o r o n t o ,O n t a r i o

M o s tT r a n s a c t o r r e a d e r sw i l lb e f a m i l i a rw i t ht h en a m eS t e v eP u n t e r .

S i n c eh e w r o t eh i sf i r s tB B S( B u l l e t i nB o a r dS y s t e m )p r o g r a my e a r s

a g o ,' t h eP u n t e rB B Sp r o g r a m 'h a sg a i n e dr e c o g n i t i o n a st h em o s t

p o l i s h e dB B Sp r o g r a ma v a i l a b l ef o rt h eC o m m o d o r e6 4 .H o w e v e r ,

t h e o n e t h i n gt h a tC o m m o d o r e - b a s e dB B S e sl a c k e dt h a tw a s

a v a i l a b l ef o rl a r g e rc o m p u t e r sw a st h ea b i l i t y t o' n e t w o r k ' ,t o h a v e

m e s s a g e st r a n s f e r r e df r o mo n eB B St o a n o t h e r .A l t h o u g hn e t w o r k

i n gh a d b e e nd i s c u s s e ds e v e r a lt i m e sb e f o r ea n dm e t h o d so f d o i n gi t

h a db e e nt h o u g h to f , n o o n eh a da c t u a l l yp r o d u c e da w o r k i n g

n e t w o r k .S t e v eP u n t e r ,s e e i n gt h a tt h e i n t e r e s ti n n e t w o r k i n gh a d

l e f tt h es t a g e so f t h e o r e t i c a ld i s c u s s i o na n dw a sn e a r i n gt h ee x p e r i

m e n t a t i o ns t a g e ,w o r k e do u th i so w ns o l u t i o na n dp u ti t i n t o t e s t i n g

w i t hs i xb o a r d si n t h eT o r o n t oa r e as t a r t i n gi n t h ef a l lo f 1 9 8 5 .T h es y s t e mp r o v e dr e l i a b l ea n d ,i n M a r c ho f 1 9 8 6 ,w a sm a d ea v a i l a b l et o

t h e g e n e r a lp u b l i c .I w a st h ef i r s tt o s i g nu p a n dh a v eb e e no p e r a t i n g

' N o d e7 ' e v e rs i n c e .

F r o mt h eb e g i n n i n g ,t h es y s t e mh a sb e e n' a h i t ' .A s I t y p et h i s ,8 9

b o a r d sh a v er e g i s t e r e dt o j o i nt h e n e t w o r k- a b o u ta t h i r dt h e

n u m b e ro f B B Sp r o g r a m sP u n t e r h a ss o l d- a n da b o u t6 0 a r ea c t i v e .

P u n t e r N e tu s e r sc a n s e n dm a i lf r o mH a l i f a xi n t h e e a s tt o H a w a i ii n

t h e w e s t ,s o u t ht o M i a m i ,a n do f f - s h o r et o B e r m u d a ,i n s o m ec a s e s

f o r l e s st h a nt h ec o s to f a s t a m p !M a n yo f t h ea c t i v eb o a r d sa r ei n t h e

T o r o n t oa r e a ,a n dT o r o n t ou s e r st a k ea d v a n t a g eo f t h i st o p a r t i c i p a t e

a c t i v e l yo n s e v e r a lb o a r d sw h i l eo n l yh a v i n gt o s i g no n t o o n e .

T h eB B Sp r o g r a mi t s e l fd i d n ' tl o o kd i f f e r e n t .T h ef i r s tt h i n ga n

u n s u s p e c t i n gu s e rs a ww e r em e s s a g e sf r o mp e o p l ew h o s ef i r s t

n a m e ss t a r t e dw i t ha n u m b e ra n da s l a s h ." 1 / S t e v eP u n t e r "a n d" 7 /

G e o f f r e yW e l s h "d i d n ' te x a c t l yl o o kl i k en a m e sa l o v i n gp a r e n t

w o u l dg i v et h e i rc h i l d r e n .. . t h o s ei n s p i r e de n o u g ht o r e a db u l l e t i n s

k n e w ,t h o u g h ,t h a tt h i sw a ss i m p l yh o wt h eB B Si n d i c a t e dt h a tt h e

m e s s a g eh a dc o m ef r o ma n o t h e rb o a r d .T h en u m b e rb e f o r e t h e

s l a s ht o l dy o uw h i c h' n o d e 't h em e s s a g ec a m ef r o ms o t h a t ,w h e n

y o ur e p l i e dt o t h em e s s a g e ,t h eB B Sc o u l dm a k es u r et h em e s s a g e

w a sr o u t e dt h r o u g ht h e c o r r e c tb o a r da n da r r i v ei n t h er e c i p i e n t ' s

m a i l b o x .

F o ri n s t a n c e ,i f S t e v eP u n t e rw a n t e dt o s e n dm e a m e s s a g e o nm y

b o a r d ,h e w o u l dt e l lh i sb o a r dt o s e n dt h em e s s a g et o " 7 / G e o f f r e y

W e l s h "a n d ,a f t e rm i d n i g h tt h a tn i g h t , h i sb o a r dw o u l dc a l ln o d e7

( m yb o a r d ) .W h e ni t g o tt h r o u g h ,i t t r a n s f e r r e d t h em e s s a g e a n dt h e

m e s s a g e w o u l da p p e a ro n m yb o a r da s h a v i n gc o m ef r o m" 1 / S t e v e

P u n t e r " . S i n c eo u r b o a r d sa r ew i t h i nl o c a l( f r e e )c a l l i n gd i s t a n c e ,t h e

b o a r dw i l ld e l i v e r t h em e s s a g et h es a m en i g h t .O b v i o u s l yt h i sc o u l d

p r o v ee x p e n s i v ei f t h e d e s t i n a t i o nw a sl o n g - d i s t a n c e , s o t h e p r o

g r a mo f f e r st h e m e s s a g es e n d e rt w oo p t i o n sf o r l o n g - d i s t a n c e

m e s s a g e s :r e g u l a ra n df a s td e l i v e r y .R e g u l a rd e l i v e r yk e e p sm e s

s a g e sg o i n gt o a g i v e nd e s t i n a t i o ni n a f i l eu n t i lt h e r e a r ef o u r

m e s s a g e sg o i n gt o t h e s a m ep l a c e( s o t h e c o s to f t h e c a l l i s

d i s t r i b u t e do v e rt h e f o u rm e s s a g e s )o r u n t i lt h em e s s a g ei s f o u rd a y s

o l d ( t o m a k es u r et h a tt h e m e s s a g ed o e s n ' ts i t a n dw a i t f o r e v e r

b e f o r ei t ' ss e n t ) .I f t h em e s s a g ei s i m p o r t a n ta n d m u s tg o t h r o u g h

i m m e d i a t e l y ,t h es e n d e rc a nd e s i g n a t et h em e s s a g ef o rf a s td e l i v e r y ,

w h i c hm e a n st h a tt h eb o a r dw i l ln o tw a i tf o rt h ef o u rm e s s a g e so r

f o u r d a y s ,b u ts e n di t i m m e d i a t e l y .F o rt h i sl u x u r y ,t h es e n d e rp a y s

d o u b l et h en o r m a lc o s to f s e n d i n gt h em e s s a g e .

T h a t ,o f c o u r s e ,b r i n g su p t h ec o s to f s e n d i n gt h em e s s a g et o b e g i n

w i t h .I f y o u rn o d ei s w i t h i nl o c a ld i a l i n gd i s t a n c eo f a n o t h e r ,i t

d o e s n ' tc o s ta n y t h i n gt o s e n da m e s s a g et o a u s e rt h e r e ,s o S Y S O P s

( S Y S t e mO P e r a t o r s )u s u a l l yl e t u s e r ss e n dm e s s a g e st o l o c a ln o d e s

f r e e .B u t c o n t a c t i n gm o s tb o a r d sr e q u i r e sa l o n g - d i s t a n c ec a l l ,a n d

t h a t c o s t sm o n e y .F o r t u n a t e l y ,t h en e t w o r kc a l l sa r ea l l m a d ew h i l e

t h et e l e p h o n ec o m p a n yo f f e r st h e h i g h e s t d i s c o u n t s .S t i l l ,t h ec a l l

c o s t sm o n e ya n dt h eS Y S O Pm u s tp a s so n t h a t c o s tt o h i s / h e ru s e r s ,

a n dt h eB B Sp r o g r a mh a sa b u i l t - i na c c o u n t i n gs y s t e mt o h a n d l e

t h i s .O n l yu s e r s w i t hm o n e yi n t h e i ra c c o u n tm a ys e n dm e s s a g e st o

l o n gd i s t a n c e d e s t i n a t i o n s ,a n d t h e p r o g r a ma u t o m a t i c a l l y c

l a t e st h ec o s to f a m e s s a g e( b a s e do n t h el e n g t ho f t h em e s s a g e a n

a m i n i m u mc h a r g e )a n dd e d u c t st h a tf r o mt h eu s e r ' sa c c o u n t .T h e

e x a c tc h a r g e sa r ec o m p l e t e l yu p t o t h eS Y S O P ,s o t h e yv a r yf r o m

b o a r dt o b o a r d .

F u r t h e r s a v i n g sa r e p o s s i b l eu s i n g' p a t h w a y s ' .F o ri n s t a n c e , t h e

a r eo v e ra d o z e nn e t w o r k n o d e si n t h eT o r o n t oa r e a .W h ys h o u l da

C a l i f o r n i a( o r , f o r t h a t m a t t e r ,H a w a i i )n o d ec a l le a c ho f t h e s e

s e p a r a t e l y ,w h e nt h e ya r ea l la f r e ec a l la w a yf r o m e a c ho t h e r ?T h e

p a t h w a yc o n c e p ta l l o w sS Y S O P st o r o u t em e s s a g e st o n o d e so t h e r

t h a nt h e i ra c t u a ld e s t i n a t i o n s ,s o t h a ta l l m e s s a g e st o t h eT o r o n t o

a r e ac a nb e s e n ti n a p h o n ec a l lt o o n en o d e ,a n dt h eT o r o n t on o d e

w o u l dt h e nd i s t r i b u t et h em e s s a g e st o t h e i rd e s t i n a t i o n s .A l t h o u g h

t h i si s m o s te f f e c t i v ei n T o r o n t o ,w h e r ea s i n g l ec a l lc a nd i s t r i b u t e

m e s s a g e st o n e a r l yt w e n t yb o a r d s ,t h e r ea r eo t h e r a r e a sw h e r et w o

o r t h r e en o d e sc a nc a l le a c ho t h e rf r e eo f c h a r g e .N a t u r a l l y ,o n l y

b o a r d sw i t hs t o r a g es p a c et o s p a r ec a n h a n d l et h eh e a v i e rl o a d st h a t

r e s u l tf r o mu s i n gt h e ma s p a t h w a y s ,b u t t h ec o n c e p tw o r k sw e l l .

B u th o wd o e sa n y n o d e( a n di t s u s e r s )k n o ww h a to t h e rn o d e sa r e

o n t h en e t w o r k ?T h i si s a c c o m p l i s h e d b yt w of i l e s- " N e t U p d a t

a n d" N O D E S " .T h ef i r s ti s a f i l ec o n t a i n i n gt h el a t e s tl i s to f n o d e s

a n d t h e i n f o r m a t i o na b o u tt h e m :t h e i rt e l e p h o n en u m b e r ,t h e i rs p e e d( 3 0 0o r 1 2 0 0b a u d ) ,i f t h e ya r et e m p o r a r i l yd o w n ,e t c .T h e

N e t U p d a t ef i l e i sk e p tu p t o d a t eb y S t e v eP u n t e ra t P u n t e r N e

' h e a d q u a r t e r s 'h e r ei n T o r o n t oa n di s a u t o m a t i c a l l yf e t c h e db y a n y

b o a r dt h a ts e n d sa m e s s a g et o n o d e1 ( o r ,i f t h ec a l l e ri s u s i n ga

p a t h w a yt o g e tt o n o d e1 , w h e n e v e ri t p a s s e sa m e s s a g et o t h eb o a r d

i t d e s i g n a t e da s t h ep a t h w a yt o n o d e1 ) .T h es e c o n df i l e ,N O D E S ,i s

j u s ta b u l l e t i nt h a tt h eb o a r df e t c h e sa l o n gw i t ht h eN e t U p d a t ef i l eI F

t h eS Y S O Ph a st o l di t t o d o s o . U s e r s c a ns e et h eN O D E Sf i l eb y

e n t e r i n gt h eb u l l e t i ns e c t i o na n dt y p i n gN O D E S .

T h a n k st o P u n t e r N e t ,I k e e pi n t o u c h w i t ha f r i e n di n K i t c h e n e r

O n t a r i o ,a n dp e o p l ei n L o sA n g e l e s ,M i l w a u k e e ,M o n t r e a l ,A l l e n -

t o w n , V a n c o u v e r .. . p e o p l eI w o u l dn e v e rh a dh e a r do f i f i t w e r e n ' t

f o rP u n t e r N e t .A n di t o n l yc o s t sm ea c o u p l eo f d o l l a r sa m o n t h !

T h eT r a n s a c t o r 1 8 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 21: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 21/84

A S w i t c h a b l e

R S - 2 3 2I n t e r f a c e

M a r kF a r r i s

T u l s a ,O k l a h o

A d o - i t - y o u r s e l f" V I C1 0 1 1 Aa d a p t e r "f o rt r u eR S - 2 3 2a t t h eu s e rp o r t !

I r e c e n t l yh a da c h a n c et o p u r c h a s ea s u r p l u s1 2 0 0b a u d H a y e s

c o m p a t i b l em o d e m .T h e s ee x t e r n a lm o d e mc a r d sw e r ec o m

p l e t ee x c e p tf o rt h ep o w e rs u p p l y a n d ,o f c o u r s e , t h ei n t e r f a c et o

c o n n e c ti t t o t h e6 4 ' su s e rp o r t .B u i l d i n g t h ei n t e r f a c ei s w h a t

m a d et h e d i f f e r e n c eb e t w e e na " g o o dd e a l "a n dp a y i n gf u l lr e t a i l

t o u p g r a d e f r o m3 0 0b a u d .I w a sf o r t u n a t ee n o u g ht o h a v es o m e

o f t h en e c e s s a r yp a r t so n h a n d ,s u c ha s t h eu s e rp o r tc o n n e c t o r

a n dt h ec a p a c i t o r s ,r e s i s t o r sa n dd i o d e s .T h i ss a v e da b o u th a l f

t h ec o s t o fb u y i n ga l lt h e p a r t sf o rt h ep r o j e c t .

P r e l i m i n a r i e s

I n t h e o r y ,a d d i n ga n R S 2 3 2p o r tt o t h e 6 4 w o u l da l l o wt h e

c o n n e c t i o no f j u s ta b o u ta n yd e v i c et h a tp r o v i d e sa n R S 2 3 2

c o n n e c t o r .I n p r a c t i c e ,t h e r e a r es o f t w a r ea n dh a r d w a r ed i f f e r

e n c e st h a tm a k et h i st y p eo f u n i v e r s a lc o n n e c t i o nd i f f i c u l t .T h e

f o l l o w i n gi n t e r f a c ew a sd e s i g n e dt o w o r kw i t h a s t a n d a l o n e

H a y e sc o m p a t i b l em o d e m ,b u t a s l o n g a s t h es o f t w a r er e q u i r e

m e n t sa r eu n d e r s t o o d ,i t s h o u l dw o r kw i t hj u s ta b o u ta n yD C E

d e v i c e .( S e eM a r t i nG o e b e l ' s " U n i v e r s a lR S - 2 3 2C a b l e "V o l7 ,

i s s u e4 , f o ra n e x p l a n a t i o no f D T Ev s . D C Ed e v i c e s ) .

T h el i n e st o a n df r o mt h e m o d e mc a n b es e p a r a t e di n t o2

g r o u p s :D a t al i n e sa n dC o n t r o ll i n e s .D a t al i n e sc a r r y t h ea c t u a l

d a t at o a n df r o mt h em o d e m ,a n dC o n t r o ll i n e sc o n t r o lt h a td a t a

f l o w .A n o t h e rw a yt o t h i n ko f i t i s : d a t at h a tp a s sv i at h eD a t a

l i n e sg o t h r o u g ht h e m o d e m ,d o w nt h e p h o n el i n e ,t o t h e

d e s t i n a t i o nc o m p u t e r a n db a c ka g a i n .T h e r ea r e2 D a t al i n e s :

T r a n s m i tD a t a ( T x D )i s a n o u t p u tf r o mt h ec o m p u t e ra n dR e c e i v e

D a t a( R x D )i s a n i n p u tt o i t .

C o n t r o ll i n e s ,o n t h eo t h e r h a n d ,g o t o a n df r o mt h e m o d e m

i t s e l f .T h e s el i n e sh a n d s h a k e b e t w e e nt h e m o d e ma n d t h e

c o m p u t e r ,a n da l l o wt h es o f t w a r et o m a k ed e c i s i o n sb a s e do nt h e p r e s e n c eo f h i g ho r l o ws i g n a l sa t t h e u s e rp o r t .T h e

C o m m o d o r e6 4 p r o v i d e s7 c o n t r o ll i n e s ,6 o f w h i c ha r es t a n d a r d

R S - 2 3 2c o n t r o ll i n e s :R e q u e s tT o S e n d( R T S ) ,D a t aT e r m i n a l

R e a d y( D T R ) ,R i n gI n d i c a t e( R I ) ,C a r r i e rD e t e c t ( D C D ) ,C l e a rT o

S e n d( C T S ) ,a n dD a t aS e tR e a d y( D S R ) .M o s tm o d e m sp r o v i d ea l l

6 o f t h e s ec o n t r o ll i n e s ,b u ts o m em o d e m sa l s op r o v i d ea S p e e d

I n d i c a t e( S I )l i n e .C o m m o d o r ed i d n ' tp r o v i d ea S I l i n eo n t h e6 4 ,

b u t f o r t u n a t e l yt h e yd i da d da n e x t r au n a s s i g n e dp i no n t h eu s e r

p o r t .T h i su n a s s i g n e dp i n( J )c a nb e u s e da s t h eS I h a n d s h a k e ,a s

w e l l a sa n yo t h e rc o n t r o ll i n e .I f p i nJ o n t h eu s e rp o r ti s t o b e

u s e da s a S p e e dI n d i c a t el i n e ,t h es o f t w a r ew o u l db e r e s p o n s i b l e

f o rt h a tc o n f i g u r a t i o n .T h i sb r i n g su p t h eq u e s t i o no f s o f t w a r ec o m p a t i b i l i t y .

U s e rP o r tR S - 2 3 2C o n f i g u r a t i o n

* = C o n t r o ll i n e

P i n

A , N

B , C

D

E

F

H

J

K

L

M

A s s i g n m e n t

G r o u n d

R e c e i v eD a t a

R e q u e s tT oS e n d

D a t aT e r m i n a lR e a d y

R i n gI n d i c a t e

C a r r i e rD e t e c t

U n a s s i g n e dC l e a rT o S e n d

D a t aS e tR e a d y

T r a n s m i tD a t a

( R x D )

( R T S ) *

( D T R ) *

( R I ) *

( D C D ) **

( C T S ) *

( D S R ) *

( T x D )

C o m p a t i b i l i t y

F o rs o m er e a s o n , n o ta l l c o m m e r c i a li n t e r f a c e sc o n n e c t e v e

c o n t r o ll i n ea v a i l a b l ea t t h eu s e rp o r t .O n ep o p u l a ri n t e r f a c eo n l y

c o n n e c t s4 o f t h e 7 c o n t r o ll i n e s :C T S ,R T S ,D T R ,a n dD S R .

T h o s e4 l i n e sa r e s w i t c h a b l e ,w h i c hm a k e sf o ra m o r ev e r s a t i l e

i n t e r f a c e ,b u t t h ef a c tt h a tt h eD C D ,R I ,a n dS I l i n e sa r el e f to u t

m a k e st h a t i n t e r f a c ei n c o m p a t i b l e w i t hm a n yt y p e so f s o f t w a r e .S o m eB u l l e t i nB o a r ds o f t w a r e " l o o k s "a t t h eR i n gI n d i c a t el i n e

f o ra n i n c o m i n gc a l l .T h eC o m m o d o r eV I C1 0 1 1 Ai n t e r f a c ed o e s

n o tc o n n e c tt h eR I l i n e ,m a k i n gi t i n c o m p a t i b l e w i t hs o m eo f t h e

m o s tp o p u l a rB B Ss o f t w a r ew r i t t e nf o r t h e 6 4 . T h e r ei s n o

s t a n d a r dm e t h o df o r a c c e s s i n gt h e c o n t r o ll i n e st h r o u g hs o f t

w a r e .P r o g r a m m e r sc a n ,a n dd o ,u s ed i f f e r e n tl i n e st o a c c o m

p l i s ht h es a m et h i n g .T h eD S Rp i nt e l l st h ec o m p u t e rw h e nt h e

m o d e mi s t u r n e do n ,a n dt h eD C Di n d i c a t e st h ep r e s e n c eo f a

c a r r i e r .B u tt h eD C Dl i n ec o u l db e u s e di n t h ep l a c eo f b o t ho f

t h e s el i n e s .A f t e ra l l ,i f t h e r ei s c a r r i e rp r e s e n t ,i t g o e sw i t h o u t

s a y i n gt h a tt h e m o d e mh a sp o w e r .T h e r ea r e a l s ot h o s e p r o

g r a m st h a ta r e w r i t t e nu n d e rt h ea s s u m p t i o nt h a ta C o m m o d o rm o d e mw i l lb e u s e d .P r o g r a m sw r i t t e nf o ru s e w i t ha 1 6 7 0w i l l

n o ta l w a y sw o r kp r o p e r l yw i t h aH a y e sc o m p a t i b l em o d e m .

A B e t t e rW a y

T h ep r o b l e mo f c o m p a t i b i l i t yc a n b e s o l v e db y b u i l d i n ga n

i n t e r f a c ec a p a b l eo f a d a p t i n gt o d i f f e r e n ts o f t w a r e r e q u i r e m

T h i si s a c c o m p l i s h e d b yc o n n e c t i n ga l lc o n t r o ll i n e sa n dm a k i n g

e a c ho n es w i t c h a b l e .D i g i t a ls i g n a l sa r e e x p r e s s e da s e i t h e r

b e i n g " h i g h "o r " l o w " ,w i t ha h i g h b e i n gi n t h e + 3 t o + 5 v o l t

r a n g ea n da l o wb e i n gc l o s et o 0 v o l t so r G r o u n d .T h eu s e rp o r t

w o r k s o nt h i s( T T L )d i g i t a lp r i n c i p l e .T h e R S - 2 3 2s t a n d a r da s s e tb y t h eE I Ad o e sn o tf o l l o wt h i sT T Ls y s t e m .R S - 2 3 2d e v i c e sc a n

T h eT r a n s a c t o r 1 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 22: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 22/84

s e n da w i d er a n g eo f v o l t a g e st o a n df r o m e a c ho t h e r .T h e ya r e

n o tl i m i t e dt o 5 v o l t s ,a n dq u i t eo f t e nu s ea 1 2 v o l t l e v e li f t h e r ei s

s o m ed i s t a n c eb e t w e e nt h e m .I n s t e a do f u s i n gp o s i t i v ev o l t a g e

a s a " h i g h " ,R S - 2 3 2a s s i g n sa n e g a t i v e v o l t a g e a st h e h i g h

s i g n a l .

T h e R S - 2 3 2s t a n d a r dd i c t a t e s t h a t s i g n a l sb e t w e e nd e v i c e sw i l l

b e + o r - 1 5 v o l t sw i t ht h ep o s i t i v ev o l t a g eb e i n ga " l o w " .I n p u t

a n do u t p u tv o l t a g eo n t h i si n t e r f a c ew i l lb e i n t h e+ / - 5 r a n g e .

N e g a t i v ev o l t a g ei s c o n s i d e r e da h i g hi n a n yR S - 2 3 2c a b l e ,b u t

a p p l y i n ga n e g a t i v e v o l t a g et o t h e6 4 ' su s e rp o r tc a nd a m a g et h e

c o m p u t e r .S o , i t ' s t h e i n t e r f a c e ' sj o b t o c o n v e r tt h e R S - 2 3 2

s i g n a l st o s i g n a l su s a b l eb y t h eu s e rp o r t .I n p u t st o t h eu s e rp o r t

f r o mt h e m o d e m ' sR S - 2 3 2c o n n e c t o rm u s tf i r s tg o t h r o u g ha

M C 1 4 8 9Q u a dL i n eR e c e i v e rI C .I t c h a n g e st h e- 5 v o l t( h i g h )a n d

+ 5 v o l t ( l o w ) s i g n a l st o n o r m a lT T Ll e v e l s .O u t p u t s f r o mt h e

u s e rp o r tm u s tg o t h r o u g ha M C 1 4 8 8Q u a dL i n eD r i v e rI C . I t

t a k e s t h eu s e rp o r ts i g n a l sa n dc o n v e r t st h e mt o R S - 2 3 2t y p e

s i g n a l s .

C o n t r o ll i n e sa r e n o t t r e a t e d t h es a m ea s D a t al i n e sb y t h e6 4 .

D a t al i n e sa r ec o n f i g u r e da s " a c t i v el o w "o n b o t ht h em o d e m

a n dc o m p u t e r .T h a ti s , t h e l i n ei s O N w h e ni t i s a t 0 v o l t s

( G r o u n dl e v e l ) .

C o n t r o ll i n e sa r e" a c t i v eh i g h "a t t h eu s e rp o r t( l i n ei s O Nw h e n

+ 5 v o l t si s a p p l i e d ) .S i n c et h e m o d e mw a n t sa l l l i n e s t ob e

" a c t i v el o w " ,t h eC o n t r o ll i n e sm u s tg o t h r o u g ha n e x t r a i n v e r

s i o n .M o s t c o m m e r c i a li n t e r f a c ed e s i g n s u s ea 7 4 0 4 H e x

I n v e r t e rI C t o t a k e c a r eo f t h i si n v e r s i o n ,b u t t h e r ei s a b e t t e r

w a y .T o m a k et h eC o n t r o ll i n e ss w i t c h a b l e ,t h e ya r ec o n n e c t e d

t h r o u g h2 7 4 L S 8 6Q u a dX O RG a t eI C ' s .E a c hC o n t r o ll i n ei s

c o n n e c t e dt o o n eo f t h e 2 i n p u t so n e a c hg a t e .T h eo t h e rg a t e

i n p u ti s h o o k e dt h r o u g ha D I Ps w i t c ht o g r o u n d .A 1 O Kr e s i s t o ri s

c o n n e c t e dt o + 5 v o l t si n p a r a l l e lw i t ht h e s w i t c hs o t h a tt h eD I P

s w i t c hs e l e c t s e i t h e r+ 5 v o l t so r g r o u n d .T h et r u t h t a b l ef o rt h e

X O RG a t eI Cs h o w st h a to n l ya n o d dn u m b e ro f i n p u t sp r o d u c e s

a h i g ho u t p u t .T h i sm e a n st h a tw h e nt h e s w i t c hi s o p e n ,t h e r e

w i l lb e a h i g ho n o n ei n p u t .A n ys i g n a lc o m i n gi n o n t h e c o n t r o l

l i n e w i l lb e i n v e r t e d .C l o s i n gt h e s w i t c hl e t s t h e s i g n a lg o

t h r o u g hu n i n v e r t e d .T h en o r m a ls e t t i n gw i l lb e a l l s w i t c h e s

o p e nb u t ,t o s a t i s f yd i f f e r e n ts o f t w a r e r e q u i r e m e n t s ,e a c hl i n e

c a n b ec h a n g e di n d e p e n d e n t l y .

C o n s t r u c t i o n T i p s

R a d i oS h a c k ' sD i g i t a lI C e x p e r i m e n t e r ' sc i r c u i tb o a r di s i d e a lf o r

t h i s p r o j e c t .T h eu s e rp o r tc o n n e c t o rs o l d e r sd i r e c t l yt o t h e " p l u g

i n "e d g eo f t h ec i r c u i tb o a r d .I t i s n o tn e c e s s a r yt o t r i m t h ec i r c u i t

b o a r dt o m a k ei t t h e s a m ew i d t ha s t h e u s e rp o r tc o n n e c t o r .

T h e r ea r e2 s e p a r a t es u p p l y b u s s e so n t h ec i r c u i tb o a r d .C o n n e c t

P i n2 o n t h eu s e rp o r tt o o n eo f t h es u p p l yb u s s e s .T h i sw i l lb e

t h e+ 5 v o l t( V c c )s u p p l yt o t h eI C s .C o n n e c tP i n s1 , 1 2 ,A , a n dN

t o t h e o t h e rs u p p l yb u s s .T h i sm a k e st h e V c c a n dG r o u n d

s u p p l i e se a s i l ya c c e s s i b l ef r o ma n y w h e r eo n t h eb o a r d .I t i s t h e n

a s i m p l e m a t t e ro f p l a c i n g t h eI C ' so n t h eb o a r dw i t ht h es u p p l y

b u s s e sr u n n i n gd i r e c t l yu n d e r e a c hc h i p .S o l d e rp i n s( 1 4 )a n d( 7 )

o n t h eI C ' s t ot h ep r o p e r b u s s( e x c e p tU l ) .

A l l I C ' sg e t t h e i rs u p p l yv o l t a g ef r o mt h e + 5 b u s s e x c e p tt h e

1 4 8 8Q u a dL i n eD r i v e r .T h e1 4 8 8r e q u i r e s aV c co f a t l e a s t+ 7

V D Ca n da V e eo f a t l e a s t- 2 . 5V D C .T h i s s u p p l yi s t a k e nf r o m

P i n 1 1 o n t h eu s e rp o r t .P o s i t i v eg o i n gc y c l e so f t h e9 V A Cg o

t h r o u g hD l , a n da r ef i l t e r e db y C l .T h i ss u p p l i e s p i n1 4 o f t h e

1 4 8 8w i t hV c c .N e g a t i v ec y c l e sg o t h r o u g h D 2 ,a r ef i l t e r e db y C 2

a n ds u p p l yp i n 7 w i t hV e e .C 3 a n dD 3 s e r v et h e p u r p o s eo f

e q u a l i z i n gb o t ht h ep o s i t i v ea n dn e g a t i v e v o l t a g e sf r o mp i n 1 1

o n t h eu s e rp o r t .W i t h o u tt h ea d d i t i o no f t h ee x t r aD i o d ea n d

c a p a c i t o r ,t h e v o l t a g eo n p i n 1 4 o f t h e 1 4 8 8I C w o u l d m e a s u

c l o s et o + 1 2 V D Ca n dt h e v o l t a g eo n p i n7 w o u l db e a p p r o x i

m a t e l y- 1 V D C .W i t ht h e a d d i t i o no f t h e e q u a l i z i n gc i r c u i t ,b o t h

s i d e ss h o u l dm e a s u r e b e t w e e n+ / - 1 0 t o 1 2 V D C .T h i si s w e l l

w i t h i n t h em a x i m u mo f + / - 1 5 V D Ca l l o w e d .

A f t e rc o n n e c t i n gt h es u p p l yc i r c u i tt o U l ,p l u gt h ec i r c u i tb o a r d

i n t ot h eu s e rp o r ta n d m e a s u r et h e v o l t a g eo n p i n s1 4 a n d1 t o

v e r i f y t h a tp i n 1 4 i s g e t t i n ga p p r o x i m a t e l y+ 1 0 v o l t sa n dp i n 1

h a s- 1 0v o l t s .( M a k es u r e t h ec o m p u t e ri s O F Fw h i l ep l u g g i n gi t

i n ) .N e x t , p l a c e t h eD I Ps w i t c ho n t h eb o a r dw i t ho n er o wo f p i n s

i n t h eG r o u n db u s s .C o n n e c tt h eo t h e re n do f e a c hi n d i v i d u a

s w i t c ht o t h ep r o p e rp i n so n t h e7 4 LS 8 6 .N o wt h e1 0 Kr e s i s t o r s

c a n b ec o n n e c t e d f r o mt h e + 5 v o l tb u s st o t h e p i n so n t h e

7 4 L S 8 6I C .C o n n e c t o n eo f t h er i b b o nc a b l ew i r e st o t h ec o r r e c t

p i no n t h eD B 2 5c o n n e c t o r .G o a h e a da n dc o n n e c tt h ew i r ea l l

t h ew a yf r o mt h eD B 2 5c o n n e c t o rt o t h eu s e rp o r t ,t h r o u g ht h e

7 4 L S 8 6w h e nn e c e s s a r y ,t h u sf i n i s h i n ge a c hl i n eo n ea t a t i m e .

G o s l o wa n df o l l o wt h es c h e m a t i c .A d i f f e r e n tc o l o r e dw i r ef o r

e a c hl i n ew o u l dm a k et r a c i n gt h e c i r c u i te a s i e rl a t e ro n , s o

r a i n b o wc o l o r e dr i b b o nc a b l ew o u l dc o m ei n h a n d yh e r e .

A f t e ra l l C o n t r o la n dD a t al i n e sa r eh o o k e du p , s o l d e r t h e. 1 m f

c a p a c i t o r sf r o mp i n 1 4 t o t h eg r o u n db u s so n a l l I C ' sa n df r o m

p i n 1 t o t h e g r o u n db u s so n t h e 1 4 8 8 . S o l d e rt h e 4 7 0 p f

c a p a c i t o r sf r o mp i n s6 , 8 ,a n d1 1 o n t h e1 4 8 8t o t h eg r o u n db u s s .

N o ws o l d e ra l l u n u s e di n p u t so n t h e 1 4 8 8a n d 1 4 8 9t o t h e

g r o u n db u s s .T h i s s h o u l dc o m p l e t ec o n s t r u c t i o no f t h ei n t e r f a c e

I f e v e r y t h i n gi s h o o k e du p r i g h t ,t h e r es h o u l db e 2 u n u s e dg a t e s

o n U 2 , 1 u n u s e dg a t eo n U 5 ,a n d 1 u n u s e ds w i t c ho n t h e 8

s w i t c hD I P .T h es c h e m a t i cs h o w so n el i n eo u to f U 2g o i n gt o t h e

u n u s e dg a t eo n t h e7 4 L S 8 6h o o k e dt o t h eu n u s e ds w i t c h .T h i s

l i n ec a n b ek e p ta s a s p a r ei f , f o rs o m er e a s o n ,o n eo f t h eo t h e r

l i n e sd e v e l o p sa p r o b l e m .

F i n a lT h o u g h t s

R a d i oS h a c kp a r tn u m b e r sa r el i s t e df o rs o m ec o m p o n e n t s .J u s t

a b o u ta n ye l e c t r o n i c p a r t ss u p p l i e rs h o u l dh a v em o s tp a r t ss t o c k

i n c l u d i n gt h e 7 4 L S 8 6X O RG a t e s .O r d e r i n ga l l p a r t sb y m a i l

w o u l dp r o b a b l yb e t h el e a s te x p e n s i v ew a yt o g o . U s eo n l yL S

v e r s i o n so f t h e7 4 8 6X O Rg a t eI C .T h e s eu s e v e r yl i t t l ec u r r e n t

a n dt h e r ei s o n l ya n e x t r a1 0 0m Aa v a i l a b l ea t t h eu s e rp o r t .I f

t h e r ei s a s o f t w a r ec o m p a t i b i l i t yp r o b l e m ,e x p e r i m e n tw i t ht h e

s w i t c hs e t t i n g s .C l o s i n g s w i t c h e st o t h e D C D ,D T R ,a n dC T S

l i n e s w i l le m u l a t ea 1 6 7 0m o d e mw i t hs o m es o f t w a r e .

T h eT r a n s a c t o r 2 O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 23: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 23/84

P a r t sL i s t

1 E x p e r i m e n t e r sc i r c u i tb o a r d( D i g i t a lI C )2 7 6 - 1 5 4 A

1 1 2 / 2 4. 1 5 6e d g ec a r dc o n n e c t o r( u s e rp o r t )

1 D B - 2 5c o n n e c t o r( 2 5p i nR S - 2 3 2 )2 7 6 - 1 5 4 7

3 1 0 0m f3 5 v o l t e l e c t r o l y t i cc a p a c i t o r s

3 4 7 0p f d i s k c a p a c i t o r s

6 . 1 m f d i s k c a p a c i t o r s

8 1 0 K1 / 4w a t tr e s i s t o r s

3 1 N 0 0 1r e c t i f i e rd i o d e s1 1 4 8 8Q u a dL i n eD r i v e rI C 2 7 6 - 2 5 2 0

2 1 4 8 9Q u a dL i n e R e c e i v e rI C s2 7 6 - 2 5 2 1

2 7 4 L S 8 62 i n p u tQ u a dX O RG a t eI C s

1 M i n i a t u r e8 r o c k e rD I Ps w i t c h2 7 5 - 1 3 0 1

1 8 - 3 6i n . o f r i b b o nc a b l e( 1 1o r m o r ec o n d u c t o r s )

S e v e r a lf e e to f 2 2 g a .o r s m a l l e rh o o ku p w i r e

U s e rP o r t

9 V A C1 1 o -

- w -1 N 4 0 0 1

J V 1 N 4 0 0 1

- w —

I ' ' I

1 0 0̂ F

MT x D

D O -

E O

R T S

+ 5 V D C °W W ~7 4 L S 8 6

N OC O N N E C T I O N

J O -

2 O

C o

B O

1 O

1 2 o

A ON O

F O

K O

L O

■ T .

7 1 4

1

R S - 2 3 2 D B - 2 5

l | | 0 7

■ 0 2

1 4 8 8

T x D

: 4 7 0p F

R T S

4 7 0p F

D T R

■ O 4

4 7 0p Fo 2 0

+ 5 V D C

o 1 2

H O

O 2 2

D C D 0 8

N o t e :O n 1 4 8 8a n d1 4 8 9 ' s

G r o u n da l l u n u s e dp i n s

A l lR e s i s t o r s a r e1 0 KV 4 W — 6 + 5 V D C

T h eT r a n s a c t o r 2 1 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 24: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 24/84

B u l l e tP r o o f

C o m p u t e r s

E v a nW i l l i a m

W i l l i a m sL a k e ,B r i t i s hC o l u m b

. . . t w oe n e m i e so fm o d e r ne l e c t r o n i c sa r e h i g hv o l t a g ea n de x c e s sh e a t .. .

I t w a sa d a r ka n ds t o r m yn i g h t .T h ec l o c ks t r u c k t w e l v e .W i t ha

b r i l l i a n tf l a s ha n d a c l a po f t h u n d e r ,a 5 0 m e g a v o l tb o l to f

l i g h t n i n gs t r u c k t h eh i g hg r o u n dw i r eo n t h ep o w e rl i n et h r e e

k i l o m e t e r sf r o mt h eh o u s e .T h i si n d u c e da 2 0 0 0v o l t t r a n s i e n t .I n

m i c r o s e c o n d si t a p p e a r e da t t h e i n p u tt o t h ep o w e rs u p p l yo f t h e

c o m p u t e r .T h et r a n s f o r m e rr e d u c e dt h i st o a m e r e2 0 0v o l t s .

U n f o r t u n a t e l y , t h e v o l t a g er e g u l a t o rd e v i c ei n t h ep o w e rs u p p l y

h a da m a x i m u mr a t i n go f o n l y3 5 v o l t s .I t d i e d .S od i da n u m b e r

o f p a r t si n t h ec o m p u t e r .. .

T h e s c e n a r i oa b o v ei s a v o i d a b l e .T w oe n e m i e so f m o d e r n

e l e c t r o n i c sa r eh i g hv o l t a g ea n de x c e s sh e a t . I nm o s tc o n s u m e r

e l e c t r o n i cd e v i c e s , e s p e c i a l l yt h o s ea t t h e l o we n do f t h ep r i c e

s c a l e ,l i t t l eo r n o p r o t e c t i o n a g a i n s th i g hv o l t a g ei s p r e s e n t .H i g h

v o l t a g et r a n s i e n t sw i l ld a m a g ei n t e g r a t e dc i r c u i t s( I C ' s )r e s u l t i n g

i n p r o m p tf a i l u r e o ft h e d e v i c e s .

I t i s a l s ou s u a lf o ra d e s i g nt o o p e r a t en e a ra n d s o m e t i m e s a b o v e

t h em a x i m u mt e m p e r a t u r er a t i n go f t h eI C ' s .E x c e s s i v eh e a tw i l l

c a u s ee v e n t u a lf a i l u r e o fa n I C b y i n c r e a s i n g t h e m o b i l i t yo f

d o p a n tm a t e r i a l si n t h es e m i c o n d u c t o r . T h i sd o p a n tm i g r a t i o n

c h a n g e st h e p r o p e r t i e so f t r a n s i s t o rj u n c t i o n su n t i lt h e ys t o p

w o r k i n g .T h er a t ea t w h i c ht h i sh a p p e n si s d i r e c t l y r e l a t e dt o t h e

o p e r a t i n gt e m p e r a t u r eo f t h e I C .T h i sr e l a t i o n s h i pi s n o t l i n e a r

a n d b e l o wa c e r t a i nt e m p e r a t u r et h ed o p a n ta t o m sa r e m o s t l y

l o c k e di n p l a c e .I f t h eI C i s o p e r a t e db e l o wt h i st e m p e r a t u r ei t

m a yb e e x p e c t e dt o f u n c t i o nf o r m a n yy e a r s .I f i t i s o p e r a t e d

m u c ha b o v et h i st e m p e r a t u r ei t m a yf a i l i n m o n t h so r e v e n

w e e k s .

W a r n i n g s a n dD i s c l a i m e r s

T h ef o l l o w i n gi n s t r u c t i o n sf o rm o d i f y i n g y o u rc o m p u t e re q u i p

m e n ti n c l u d ew o r k i n go n d e v i c e s w i t h1 1 0v o l tw i r i n g .A L W A Y S

u n p l u ga l l e q u i p m e n t .I f y o uh a v eA N Y D O U B Ta b o u ty o u r

a b i l i t y t ow o r ks a f e l yt h e nf i n da f r i e n dw h ok n o w sh o w .

M o d i f y i n gy o u rc o m p u t e rm a ya l s ov o i dt h e w a r r a n t y .A l t h o u g h

t h e s ec h a n g e sw i l lg r e a t l yr e d u c et h er i s k o ff a i l u r e ,i t i s i m p o s

s i b l e t op r o t e c ta g a i n s ta l l p o s s i b l ei n s u l t st o y o u r e q u i p m e n t .

P l e a s er e a dt h ee n t i r ea r t i c l e ,p a r t i c u l a r l yt h e s e c t i o no n s t a t i c

e l e c t r i c i t y ,b e f o r ep e r f o r m i n ga n yo f t h e o p e r a t i o n sd e s c r i b e d

h e r e .

T h e P o w e rS o u r c e

I n N o r t hA m e r i c a ,t h es t a n d a r dl i n ev o l t a g es u p p l yi s c o m m o n l y

r e f e r r e dt o a s 1 1 0v o l tA C .I n f a c t ,t h en o r m a ls p e c i f i c a t i o nf o r

h o u s e h o l de l e c t r i cp o w e ri s 1 0 7v o l t st o 1 2 5v o l t sA C .T h ea c t u a l

v o l t a g em a yb e a n yv a l u eb e t w e e nt h e s el i m i t sa n dw i l lv a r ya s

t h e l o a dc h a n g e s .I t i s c o m m o nf o r t h ev o l t a g et o g o b e y o n d

t h e s el i m i t s i ni n d u s t r i a lo r r u r a la r e a s .I n g e n e r a l ,l o wv o l t a g ei s

n o t h a r m f u lt o c o m p u t e r e q u i p m e n tu n l e s st h e s i t u a t i o ni s

e x t r e m e .T h em o s tn o t i c e a b l ee f f e c tm a yb e a r e d u c t i o ni n t h e

d i s p l a ys i z eo n t h ec o m p u t e rm o n i t o ro r T V .I f a " b r o w n o u t "o r

e x t r e m e l o wv o l t a g e c o n d i t i o n o c c u r s ,i t i s b e s tt o t u r no f fa l l

g e a r .S u c h b r o w n o u t sc a nb e f o l l o w e db y h i g hv o l t a g es u r g e sa s

m a j o rl o a ds h e d d i n go c c u r st o b r i n gu p s y s t e mv o l t a g e .

S u s t a i n e dh i g hv o l t a g e c o n d i t i o n sw h e r et h e v o l t a g ei s o n l y

s l i g h t l ya b o v en o r m a l c a n c a u s eo v e r h e a t i n go f t h e p o w e r

s u p p l ya n de v e n t u a lf a i l u r e .T h i ss i t u a t i o nc a n n o tb e e a s i l y

p r e v e n t e d .T o c h e c ky o u rl i n ev o l t a g eu s e a g o o dq u a l i t ya c

v o l t m e t e ra n dc h e c kt h e v o l t a g eo v e ra p e r i o do f d a y s .A m e t e r

w i t h ap e a kh o l df u n c t i o ni s m o s tu s e f u l .T h ea u t h o rh a s

m e a s u r e dl i n ev o l t a g e sa s h i g ha s as t e a d y1 3 0v o l t sw i t ht h e

v o l t a g e u s u a l l ya r o u n dt h e 1 2 5v o l tr a n g e .W h e nt h e v o l t a g ei s

t h i sh i g hi t c a n c a u s eo v e r h e a t i n go f t h ep o w e rs u p p l y .I f y o uf i n d

y o u rl i n ev o l t a g ei s o f t e na b o v e1 2 5v o l t sy o um i g h tt r y c o m

p l a i n i n gt o y o u rl o c a lp o w e rc o m p a n yb u td o n ' te x p e c tm u c hi n

t h e w a yo f a c t i o n .T h ef i r s tr e s p o n s ew i l lb e t o q u e s t i o nt h e

a c c u r a c yo f y o u rm e t e r . U n f o r t u n a t e l y , t h eo n l yr e m e d yf o ra

c o n s t a n to v e r v o l t a g ec o n d i t i o ni s t o b u y a ne x p e n s i v ea u t o t r a n s -

f o r m e rw i t he n o u g hw a t t a g ec a p a b i l i t yt o h a n d l ea l ly o u rg e a r .I f

a n a u t o t r a n s f o r m e ri s u s e d ,a l l e q u i p m e n tt h a ti s i n t e r f a c e d

t o g e t h e rm u s tb e o p e r a t e df r o mt h e t r a n s f o r m e r .I f n o t ,g r o u n d

i n gp r o b l e m sm a yr e s u l t .

E l e c t r i c a ls t o r m sa r e a m a j o rd a n g e ri n m a n ya r e a s .W h e n

l i g h t n i n g s t r i k e st h ep o w e rl i n ei t c a n p r o d u c ed a m a g i n gt r a n

s i e n t sm a n yk i l o m e t e r sa w a y .I f l i g h t n i n gs t r i k e sn e a rt h e s e r v i c e

c o n n e c t i o ns e v e r ed a m a g et o s o m eo r a l l e q u i p m e n tc o n n e c t e d

w i l lp r o b a b l yr e s u l t .N o c e r t a i np r o t e c t i o ni s p o s s i b l ei n t h i s

i n s t a n c eo t h e rt h a n u n p l u g g i n gA L Le q u i p m e n t . N o t et h a t

s i m p l yt u r n i n go f ft h ep o w e rm a yn o tb e e n o u g hs i n c ea c l o s e

s t r i k ew i l l p r o d u c ev o l t a g e sh i g he n o u g ht o j u m ps t r a i g h t

t h r o u g hs w i t c h e s .T h ea u t h o rh a sw o r k e d o n e q u i p m e n

c o m p o n e n t sh a v eb e e nv a p o r i z e dr i g h to f ft h ec i r c u i tb o a r db y a

T h eT r a n s a c t o r 2 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 25: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 25/84

n e a r b ys t r i k e .I f a n e l e c t r i c a ls t o r mi s o v e r h e a do r n e a r b y , t u r n

o f fa n du n p l u g y o u r e q u i p m e n t .

T h e m o r ec o m m o ns i t u a t i o ni s w h e nl i g h t n i n gs t r i k e st h ep o w e r

l i n es o m e w h e r ei n t h e s a m ec o u n t y .T h i sm a yp r o d u c em u c h

s m a l l e rb u ts t i l ld a m a g i n gt r a n s i e n t s .T h e s ec a nb e h a n d l e db y a

d e v i c ec a l l e da m e t a lo x i d ev a r i s t o r( M O V ) .T h eM O Vp r e s e n t s a

r e s i s t a n c et o e l e c t r i c a lc u r r e n tw h i c hi s v o l t a g ed e p e n d e n t .W h e nv o l t a g e a c r o s s t h eM O Vr i s e s t ot h e r a t e dv a l u e ,t h e

r e s i s t a n c ed r o p st o a v e r y l o wl e v e l , i n e f f e c tb e c o m i n ga s h o r t

c i r c u i t .T h i sp r e v e n t st h e v o l t a g er i s i n gm u c hh i g h e ra n d i s

c a l l e d" c l a m p i n g " .M O V ' sc a nw i t h s t a n dv e r yh i g hc u r r e n t sf o r

s h o r tp e r i o d so f t i m e .B y p l a c i n ga M O Va c r o s s t h e h o ta n d

n e u t r a lw i r e so f t h ep o w e rl i n e ,p r o t e c t i o na g a i n s tt r a n s i e n t si s

o b t a i n e d .T h ep o w e rd i s t r i b u t i o ns y s t e mi n t h eh o m es h o u l dn o t

b e m o d i f i e d s ot h ew a yt o d o t h i si s t o i n s t a l la M O Vi n a p o w e r

b a r .I f y o ua r e u s i n g ap o w e rb a r t h a t i n d i c a t e si t h a ss u r g e

p r o t e c t i o nt h e ni t a l r e a d yh a s s u c ha d e v i c e .D on o tc o n f u s et h i s

w i t ht h e r e q u i r e dc i r c u i tb r e a k e rf o u n do n a l l p o w e rb a r s .T h e

c i r c u i tb r e a k e ri s t h e r et o p r o t e c tt h ep o w e rb a rf r o mo v e r l o a d ,n o t t h ee q u i p m e n tp l u g g e di n t oi t .

I f y o uh a v ea p o w e rb a rt h a tc a nb e d i s a s s e m b l e d ,i t i s v e r y

s i m p l et o i n s t a l la M O V .

F o rc o m p l e t ep r o t e c t i o n a g a i n s tc o m m o nm o d et r a n s i e n t sa s

w e l l a sd i f f e r e n t i a lm o d et w om o r e M O V ' sm a yb e i n s t a l l e d ,o n e

f r o mt h e h o ts i d et o t h eg r o u n dl u ga n d o n ef r o mt h e n e u t r a ls i d e

t o t h eg r o u n dl u g .T u gl i g h t l yo n t h ew i r e si n t h ec o n n e c t o rh o l e s

t o e n s u r et h e ya r e p r o p e r l yt r a p p e d .T a p et h e M O Vt o t h e

r e c e p t a c l ew i t he l e c t r i c a lt a p e . R e i n s t a l lt h eb a c kc o v e ro f t h e

p o w e rb a ra n d y o ua r ed o n e .

A d d i t i o n a lC o n s i d e r a t i o n s

I f y o ul i v ei n a n a r e a w i t hu n d e r g r o u n dp o w e rs e r v i c ed o n o t

a s s u m ey o u rs y s t e mi s s a f e .T h ep o w e rd i s t r i b u t i o ns y s t e m

a l w a y sh a ss o m eo v e r h e a dc o n n e c t i o n st h a tc a n b es t r u c kb y

l i g h t n i n g( i e .s t r e e tl a m p sa n dt r a f f i cc o n t r o ld e v i c e s ) .

I f y o u rc o m p u t e ri s c o n n e c t e dt o a t e l e v i s i o nf o rd i s p l a yp u r p o s e s

t h i sp r e s e n t sa n o t h e rp a t hf o rd e s t r u c t i v ee n e r g y ,e s p e c i a l l yi f

t h et e l e v i s i o nu s e sa n o u t s i d ea n t e n n a . Y e ta n o t h e rp a t he x i s t si f

a m o d e mi s c o n n e c t e dt o t h ep h o n el i n ea n dt h ec o m p u t e r .

A g a i n ,t h eo n l y s u r ep r o t e c t i o nd u r i n ga n e l e c t r i c a ls t o r mi s t o

u n p l u ga l l d e v i c e st h a tc o u l d p r o v i d ea p a t hf o r d e s t r u c t i v

e n e r g yt o y o u rc o m p u t e r .

M o d i f y i n g aP o w e rB a r

U n p l u gt h ep o w e rb a ra n da l le q u i p m e n t .R e m o v et h ep o w e rb a r

b a c kc o v e r .I f t h e p o w e rb a ru s e s o r d i n a r yr e c e p t a c l e si t w i l l

m o s tl i k e l yb e w i r e du s i n gp u s h - i nc o n n e c t o r so n e a c hr e c e p t a

c l e .T h ee n dr e c e p t a c l es h o u l dh a v et w of r e ep u s h - i nc o n n e c t o rp o s i t i o n s( s e e f i g u r e1 ) .B e n dt h ew i r e so f t h eM O V( R a d i oS h a c k

# 2 7 6 - 5 7 0o r # 2 7 6 - 5 6 8 )t o t h ec o r r e c ts p a c i n g w i t hr i g h ta n g l e

l e g ss o t h a tw h e np r e s s e di n t o t h ec o n n e c t o rh o l e st h eM O Vw i l l

l i e f l a ta g a i n s tt h e r e c e p t a c l eb o d y .I n s t a l lt h eM O Vb y p r e s s i n g

t h ew i r e si n t ot h eh o l e s .O n ew i r e s h o u l dg o i n t oa h o l eo n t h e

h o ts i d ea n d o n e o nt h e n e u t r a ls i d e .I t d o e s n ' tm a t t e rw h i c hw i r e

g o e sw h e r es i n c ea M O Vi s n o n - p o l a r .

E u a n

T h e C o m p u t e r P o w e rS u p p l y

M a n y h o m ec o m p u t e r su s ea n e x t e r n a lp o w e rs u p p l y .T h i si s

d o n ef o ra v a r i e t yo f r e a s o n s .T h em o s ti m p o r t a n t r e a s o ni s t h a t

u s i n g as e p a r a t es u p p l yl i m i t st h e1 1 0v o l ta c p o w e rd i s t r i b u t i o

t o t h a ta r e ao n l y .T h i sm a k e st e s t i n ga n da p p r o v a lb y o r g a n i z at i o n sl i k eU . L .a n dC . S . A .q u i c k e ra n de a s i e r .I t a l s or e m o v e sa

m a j o rs o u r c eo f h e a ta n db u l kf r o mt h em a i nc o m p u t e rc a s ea n d

a l l o w sm o r ea t t r a c t i v ed e s i g n . U n f o r t u n a t e l y ,m o v i n gh e a tt o

a n o t h e rb o xd o e sn o t e l i m i n a t ei t .

S o m e C o m m o d o r ep o w e rs u p p l i e s a r e n o t o r i o u sf o rf a i l i n g e a r l

e s p e c i a l l yt h eC - 6 4u n i t s .I t i s e s s e n t i a l t h a tt h ep o w e rs u p p l yb e

p l a c e di n a c o o l ,w e l lv e n t i l a t e da r e a w i t hn o

o b s t r u c t i o no f a i r f l o w .I t h e l p si f t h e u n i ti s

r a i s e db y a d d i n gs m a l lf e e tt o i t o r p l a c i n gi t

o n b l o c k s .I t s h o u l dn e v e rb e p l a c e do n a

c a r p e t o ri n a c l o s e dc o m p a r t m e n t .T h eb e s ts o l u t i o ni s t o p l a c e as m a l lq u i e tf a n s o i t

m o v e sa i ro v e rt h eu n i t .I f y o uh a v ea n e a r l y

m o d e lC - 6 4p o w e rs u p p l yi t m a yb e o f t h e

r e p a i r a b l et y p e .T h ea u t h o rh a ss u c ha u n i t

a n dh a sd r i l l e dn u m e r o u s1 / 4i n c h h o l e sa l l

o v e rt h ec a s e( a f t e rr e m o v i n gt h ei n t e r n a l s ! )

T h i sh e l p st r e m e n d o u s l yi n k e e p i n gt h eu n i t

c o o l .A l ll a t e rm o d e lC - 6 4s u p p l i e sa r eN O T

( e a s i l y )r e p a i r a b l ea s t h ec o m p o n e n t sa r e p o t

t e d i n e p o x y m a k i n gt h e u n i ta s o l i d b r i c k

T h i sd o e sn o t h e l p t h ec o o l i n g .T h eV I C - 2 0

s u p p l yr u n sc o o l e r a s t h ep o w e r d e m a n d a r e

T h eT r a n s a c t o r 2 3 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 26: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 26/84

l e s st h a nt h eC - 6 4 .T h e C - 1 2 8p o w e rs u p p l y

r u n sm u c hc o o l e r( b e t t e rd e s i g n )a n ds h o u l d

n o tp r e s e n t ap r o b l e m .

I f a p r o b l e ma p p e a r sw i t ht h eC - 6 4s u p p l yi t i s

a d v i s a b l et o r e p l a c ei t w i t h as e c o n ds o u r c e

u n i ts u c ha s t h eC P S - 1 0m a d eb y E s t e sa n d

a v a i l a b l ef r o mJ a m e c oE l e c t r o n i c sf o r U S$ 3 9 . 9 5 .T h i su n i ti n c l u d e s1 1 0v o l ta c o u t l e t s

w i t hs p i k ep r o t e c t i o n .A l s oa v a i l a b l ef r o m a

n u m b e ro f s o u r c e sa r e f a n / o u t l e tu n i t sw i t h

s p i k ep r o t e c t i o ni n t h e$ 3 0t o $ 4 0p r i c er a n g e .

H e a ta n dt h eC o m p u t e r

I T ® S G 3 S I ?

e w b i

F r o mt h eU N I V A Ct o t h eC - 6 4h e a th a sb e e n

a p r o b l e m .T h eR O M ' si n t h e a u t h o r sP E T

2 0 0 1r a n s oh o tt h e y c o u l dn o tb e t o u c h e dc o m f o r t a b l y .T h i si s a

s u r e s i g nt h a ta n I C i s t o oh o t .A t h e r m o c o u p l em e a s u r e m e n ts h o w e da t e m p e r a t u r eo f 7 1 C e l s i u s( 1 6 0F ) .T h em a x i m u ms a f e

o p e r a t i n gt e m p e r a t u r ef o rm o s tI C ' si s 7 0 d e g r e e sC e l s i u s( 1 5 8F ) .

S o m eI C ' si n t h eC - 6 4a n d1 5 4 1d i s k d r i v ea l s or u nh o t .T h e

s o l u t i o ni s t o i n s t a l lh e a t - s i n k so n t h e I C ' s .T h em o s ts u i t a b l e

t y p ea r e h e a t - s i n k sd e s i g n e df o r T O - 2 2 0s e m i c o n d u c t o rd e

v i c e s .T h e s ea r e a v a i l a b l ea t m o s te l e c t r o n i c s s t o r e si n c l u d i n g

R a d i oS h a c k( c a t a l o gn u m b e r2 7 6 - 1 3 6 3 ) .

O p e nt h ec a s eo f t h ec o m p u t e ro r d i s k d r i v eb y r e m o v i n gt h e

s c r e w sf o u n di n t h e u n d e r s i d e . C a r e f u l l yl i f tt h e t o ph a l fo f t h e

c a s eo f f .M o s tC - 6 4 ' sw i l lh a v ea f o i lc o v e r e dp i e c eo f c a r d b o a r d

o v e rt h ec i r c u i tb o a r d .T h i si s a R Fs h i e l d .I t i s a l s oa h e a tt r a p .I n

m o s tc a s e st h ea u t h o rh a s f o u n dl i t t l eo r n o i n c r e a s ei n T Vo r

r a d i o i n t e r f e r e n c ei f t h i ss h i e l di s r e m o v e d .E a r l yC - 6 4 ' sd i d n o t

h a v et h i s s h i e l d .I t i s n o ti l l e g a lt o r e m o v et h i ss h i e l db u ti f y o u r

e q u i p m e n tc a u s e si n t e r f e r e n c ea n da c o m p l a i n ti s m a d et o t h e

D e p a r t m e n to f C o m m u n i c a t i o n s y o uw i l lh a v et o c o r r e c tt h e

p r o b l e m .R e m o v i n gt h es h i e l dc a n d e g r a d et h ep i c t u r ei f y o ua r e

u s i n ga T Vs e ta s y o u rm o n i t o r .E x p e r i m e n tb y t e a r i n g t h e s m ac o p p e rt a p ea t t h er e a ra n db e n d i n gt h ee n t i r es h i e l dt o w a r d st h e

f r o n t o ft h ec o m p u t e r .P l a c e t h ek e y b o a r dl o o s e l yo n t o po f t h e

l o w e r c a s e w i t ht h es h i e l d s t i c k i n go u t t h ef r o n ta n dt u r no n t h e

p o w e r .I f n o n o t i c e a b l e i n t e r f e r e n c ee x i s t so n y o u rT Vo r r a d i o

t h e ny o ua r es a f ei n r i p p i n g t h es h i e l do u t .R e m o v i n gt h i ss h i e l d

w i l ln o th a r my o u rc o m p u t e r ,b u tw i l lv o i d t h e w a r r a n t y .

N e x t ,l e a v et h ec o m p u t e rr u n n i n gf o rh a l fa n h o u r .T h e r ea r en o

d a n g e r o u sv o l t a g e s p r e s e n ti n t h ec o m p u t e r .W a t c ho u tf o rr i n g s ,

m e t a ls h i r tb u t t o n s , n e c k l a c e s ,c h a i n so r a n yo t h e r m e t a lo b j e c t s

t h a tm i g h tf a l li n t h em a c h i n ea n ds h o r t o u tp o w e r .A l t h o u g hn o t

d a n g e r o u st o t h e u s e ri t c o u l df r y y o u rc o m p u t e r .A f t e ri t i sw a r m e du p , o p e nt h e l i d a n dp l a c ey o u rf i n g e ro n e a c hl a r g e

i n t e g r a t e dc i r c u i t .S e v e r a lI C ' sw i l lb e f o u n dt h a ta r eq u i t ew a r m .

A l s o ,t h ev i d e oc i r c u i t sm e t a lb o x( s e ef i g u r e2 ) w i l lb e w a r m .T o

a t t a c hh e a ts i n k st o t h eI C ' sa n dt h ev i d e oc i r c u i t sb o xt h ea u t h o r

u s e so n l ys i l i c o n eh e a ts i n kg r e a s e ( R a d i oS h a c kp a r tn u m b e r

o o © ©

U I D E G C I R C U T 5a a © o

T h eT r a n s a c t o r 2 4 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 27: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 27/84

2 7 6 - 1 3 7 2 ) .T h i si s s t i c k ye n o u g hi f t h ec o m p u t e ri s n o tm o v e d

m u c h . U s ej u s te n o u g ht o c o v e ra n a r e ao n t h eI C e q u a lt o t h e

s i z eo f t h e h e a ts i n k .P l a c e t h eh e a ts i n ko n t h e I Ca n dp r e s si n t o

p l a c e( s e e f i g u r e3 ) . I f t h ec o m p u t e ri s m o v e da r o u n da l o t u s e

j u s te n o u g hg r e a s et o c o v e rt w ot h i r d so f t h e h e a t s i n ka r e ao n

t h e I C .C o v e rt h eo t h e rt h i r dw i t hc o n t a c tc e m e n ta n dw h e n

t a c k yp r e s s t h e h e a t s i n ki n t op l a c e .T h e s a m ep r o c e d u r ei s u s e d

o n t h ev i d e ob o x .T h ea u t h o ru s e dt h r e eh e a ts i n k si n a r o wf o r

t h ev i d e o b o x . T h i so v e r a l lp r o c e d u r es h o u l da l s ob e c a r r i e d o u t

o n t h e1 5 4 1d i s kd r i v e .B ec a r e f u lt o c h e c kf o rc l e a r a n c eo f t h e

h e a t s i n kf i n sw i t h s u r r o u n d i n gp a r t sa n dt h e u p p e rc a s e .I f

i n t e r f e r e n c ee x i s t st h e h e a t s i n kc a n b eh a c k e d , b e n to r c h o p p e d

a s n e e d e d .

T h eC - 1 2 8h a sa n a l l m e t a ls h i e l dc o v e r i n gt h ee n t i r ec i r c u i t

b o a r dc l o s e l y .I n t h i ss h i e l da r e c u t o u t t a b st h a tc o n t a c tc e r t a i n

I C ' sb e l o w .O n t w oo f t w oC - 1 2 8 ' se x a m i n e dt h et a b sw e r en o t

c o n t a c t i n gp r o p e r l ya n dd i d n o th a v ee n o u g hh e a t s i n k g r e a s e .

T h eC - 1 2 8s h i e l di s f a s t e n e di n p l a c ew i t ha s e r i e so f s c r e w s

a r o u n dt h ep e r i m e t e ra n ds o m es m a l lb e n tm e t a lt a b sf r o mt h e

l o w e rs h i e l d .B yr e m o v i n gt h es c r e w sa n ds t r a i g h t e n i n g t h et a b s

t h e s h i e l dm a yb e l i f t e do f f . T h eh e a t s i n kt a b ss h o u l db e

r e f o r m e dt o e n s u r eg o o dc o n t a c tw i t ht h e I C ' sa n da g e n e r o u s

a m o u n to f h e a ts i n kg r e a s ea p p l i e d .R e i n s t a l lt h es h i e l d .D o n o t

o v e r t i g h t e nt h es c r e w sh o l d i n gi t . R e b e n dt h e s m a l lm e t a lt a b s

w h i c hp r o v i d ec o n t a c tw i t ht h e l o w e rs h i e l da n dr e i n s t a l lt h e

c a s e .

• N e v e rc o v e ry o u rc o m p u t e rg e a rw i t ha n y t h i n gw h i l ei t i s

o p e r a t i n g ;n o m a g a z i n e s ,n o d i s kj a c k e t so r a n y t h i n ge l s e .

• A l w a y sl e a v es o m es p a c ef o ra i rc i r c u l a t i o na r o u n dt h ee q u i p

m e n t .D o n o ts t a c k d i s k d r i v e su n l e s s af a n i s u s e dt o c o o l

t h e m .

• O p e r a t i n gt h ee q u i p m e n ti n t h ed i r e c ts u ni s a g o o dw a yt o

o v e r h e a ti t . R e m e m b e r ,t h ep r i m a r yc a u s eo f c o m p o n e n ta g i n g

a n de v e n t u a lf a i l u r ei s e x c e s sh e a t .

A l lo f t h ea u t h o r ' sc o m p u t e r sa n dr e l a t e da c c e s s o r i e sh a v eb e e n

o v e r h a u l e da s a b o v e .S o m eo f t h e s y s t e m so p e r a t e2 4 h o u r sa

d a y .S i n c e1 9 7 8o n l yt w oc o m p o n e n tf a i l u r e sh a v eo c c u r r e da n d

o n ew a sa n e a r l yf a i l u r e i nt h e f i r s tm o n t ho f o w n e r s h i p .T h e

s e c o n dw a si n d u c e db y z a p p i n gt h ej o y s t i c kp o r to n a C - 6 4w i t h

s t a t i ce l e c t r i c i t y .

S t a t i cE l e c t r i c i t y

S t a t i c e l e c t r i c i t yi s a c h a r g ec a u s e d b yf r i c t i o n .W a l k i n ga c r o s sa

p l a s t i cc a r p e to n a d r yw i n t e rd a y c a nb u i l da n a m a z i n gc h a r g e

o n y o u rb o d y .T o u c h i n ga n yc o n d u c t i v eo b j e c ta t a d i f f e r e n t

p o t e n t i a lc a nc a u s et h ec h a r g et o a r co v e r .T h ei n s u l a t i n gv a l u e

o f d r ya i ri s a b o u t2 0 , 0 0 0v o l t sp e rc e n t i m e t e r .A n y o n ew h ol i v e s

i n a d r yc l i m a t eh a sp r o b a b l ys e e na s p a r ka t l e a s t t h i sl o n g

j u m p i n gf r o mt h e i rf i n g e rt o a n o t h e ro b j e c t .T h em a x i m u m

v o l t a g et h a tm o s tI C ' sc a nw i t h s t a n di s a b o u t2 5 v o l t so r l e s s .A

s t a t i cc h a r g el a r g ee n o u g ht o d a m a g ea n I C c a n b es o s m a l lt h a t

n o e v i d e n c eo f i t e x i s t st o t h e s e n s e s . C e r t a i np a r t so f a l l

c o m p u t e r sa r e e a s i l yd a m a g e db y t h e s l i g h t e s tt o u c hw h e n

c o n d i t i o n sa r ej u s tr i g h t( w r o n g ! ) .

T h e C - 6 4h a st w ov e r yv u l n e r a b l ej o y s t i c kp o r t sr i g h tn e x tt o t h e

o f t e nu s e do n / o f fs w i t c h .T h e s ep o r t su s ee x p o s e dm a l ep i n so n

t h ec o m p u t e rs i d e( a r r r g g g h h h ) s oa s t o b e c o m p a t i b l e w i t hA t a r i

j o y s t i c k s .U n d e rn o c i r c u m s t a n c e ss h o u l dt h e s ep i n sb e t o u c h e d .

W o r s ey e t ,o n t h eC - 1 2 8t h e r e s e ts w i t c hi s r i g h tn e x tt o t h e

j o y s t i c kp o r t s .

T h es o l u t i o ni s t o r e m o v es t a t i cc h a r g e sf r o mt h e u s e r .T h e

s i m p l e s tw a yi s t o t o u c hs o m e t h i n gm e t a lt h a ti s g r o u n d e dt o t h e

s a m eo u t l e ta s t h ec o m p u t e rb e f o r et o u c h i n ga n yp a r to f t h e

c o m p u t e r . T h i si s n o ta l w a y sp r a c t i c a la n dt h e r ei s a b e t t e rw a y .

A n e x p e n s i v es o l u t i o ni s t o b u y a na n t i - s t a t i cm a tt o p l a c e t h e

c o m p u t e ro n .T h i si s c o n n e c t e dt o t h eo u t l e tg r o u n dw i t h a w i r

a n dd r a i n ss t a t i cc h a r g e sp a i n l e s s l yw h e nt o u c h e d .T h ea u t h o r

u s e sa c h e a pb u te f f e c t i v em e t h o d .B u ya s m a l lr o l lo f 3 / 1 6i n c h

t i np l a t e dc o p p e rt a p ef r o ma s t a i n e dg l a s ss u p p l i e r .S t i c ks t r i p s

o f t h i st a p et o t h es i d eo f t h ec o m p u t e rs u r r o u n d i n gt h ej o y s t i c k

p o r t ss o t h a ta n y o n ep l u g g i n gi n a j o y s t i c kc a n n o ta v o i dt o u c h

i n g t h et a p e .B r i n go n e e n do f t h et a p ei n s i d et h ec a s e .S o l d e r a

o n em e g o h mr e s i s t o r t ot h et a p ea n dw i t h ap i e c eo f f l e x i b l ew i r e

s o l d e r t h eo t h e re n do f t h er e s i s t o rt o t h eg r o u n dt r a c eo n t h e

m a i nc i r c u i tb o a r d( s e ef i g2 f o rC - 6 4 ) .O n t h eC - 1 2 8 ,s o l d e rt o

t h e m e t a lR F s h i e l d .W r a pt h e r e s i s t o rw i t he l e c t r i c a lt a p eo r

s h r i n k t u b i n ga n dc l o s e t h ec a s e .T h er e s i s t o ri s n e c e s s a r yt o

p r e v e n t as u d d e ns u r g eo f v o l t a g e .T h i sm o d i f i c a t i o nc o s t sv e r y

l i t t l ea n di s e f f e c t i v ew i t h s m a l lc h i l d r e n .

W h e nd o i n ga n yw o r ko n e l e c t r o n i ce q u i p m e n ti s i sa d v i s a b l et o

w e a rc o t t o n c l o t h i n gt h a td o e sn o t p r o d u c es t a t i cc h a r g e s .

A l w a y sm a k es u r et h a ty o ut o u c hs o m e t h i n gg r o u n d e db e f o r e

t o u c h i n ga n yc o m p o n e n t s .B e f o r es o l d e r i n g ,t o u c ht h et i po f t h e

i r o nt o g r o u n do r u s e a g r o u n d e di r o n .I t i s b e s tt o a v o i d

d i s a s s e m b l ya t a l l i f t h ea i r i s r e a l l yd r ya n ds t a t i ci s z a p p i n g

e v e r y w h e r e .

A F i n a lO b s e r v a t i o n

T h ea u t h o rh a sa l w a y sf o l l o w e dt h ep r a c t i c eo f " b u r n i n gi n "n e w

e l e c t r o n i ce q u i p m e n t .T h i sm e a n sj u s ts e t t i n gt h en e wu n i tu p ,

t u r n i n gi t o n a n dl e a v i n gi t o n 2 4 h o u r sa d a yf o ra t l e a s ta w e e k .

F o rs o m er e a s o n ,t h i ss e e m st o p r e v e n tf u t u r ef a i l u r e s .T h e

a u t h o rh a sn o c e r t a i ne x p l a n a t i o nf o r t h i sb u t t h e r e a r es o m e

e f f e c t ss u c ha s " o x i d eh e a l i n g "t h a tc o u l de x p l a i ni t . I t s e e m s

b e s tn o tt o s u b j e c tt h en e wg e a rt o o n / o f fp o w e rs u r g e su n t i l t h i s

b u r n - i ni s d o n e .T h ea u t h o ri s a c o n f i r m e d t e c h n oj u n k i ea n d

b u y se v e r yn e ww i d g e tt h a tc o m e sa l o n g .A l li t e m sa r eb u r n e d

i n .O v e rt h ey e a r s a l m o s tn o f a i l u r e sh a v eo c c u r r e df r o mc l o c k s

t o s t e r e o st o c o m p u t e r s .T h i si s a G O O DT H I N G .T h ea u t h o r

r e p a i r sc o m p u t e r i z e dd e v i c e sf o ra l i v i n ga n dw o u l dr a t h e rn o t

d o i t a t h o m ea s w e l l .

T h eT r a n s a c t o r 2 5 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 28: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 28/84

T h e1 5 8 1D i s kD r i v e :

A t e c h n i c a le v a l u a t i o n

M . G a r a m s z e

T o r o n t o ,O n t a r i

. . t h e1 5 8 1s u p p o r t ss u b d i r e c t o r i e so r , m o r ec o r r e c t l y ,d i s k

p a r t i t i o n i n g ,w i t he a c hp a r t i t i o nh a v i n gi t so w nB A Ma n dd i r e c t o r y .. .

A f e w d a y sb e f o r e t u r n i n gt h e b i g3 - 0 , 1r e c e i v e d a b i r t h d a y p r e s e n t

i n t h ef o r mo f a l i t t l ep l a i nb r o w n b o xf r o mC o m m o d o r e ,c o u r t e s yo f

D a na n dJ i m a t W e s t c h e s t e r .I n s i d e ,I d i s c o v e r e dC B M ' sl a t e s t

o f f e r i n gf o ri t s 8 - b i tl i n e :t h e 1 5 8 13 > / 2i n c hd i s kd r i v e .( A l t h o u g h

t h el a b e lo n t h ef r o n to f t h ed r i v es p e c i f i c a l l ys a y s" F L O P P YD I S K

D R I V E " ,I r e f u s et o c a l la 3 ' / 2i n c h d i s k" f l o p p y " , e s p e c i a l l yw h e n

m y 1 5 7 1m e r e l ys a y s" D I S K D R I V E " .F o rt h o s en o tf a m i l i a rw i t h a

m i c r od i s k ,i t i s e n c a s e di n a r i g i dp l a s t i ch o u s i n gm a k i n gi t t h el e a s t

f l o p p yo f f l e x i b l e d i s k s . )

T h i sl i t t l eb e a s ti s c o m p a c t ,q u i e t ,f a s t ,a n dv e r s a t i l e .I t r u n so n t h e

s t a n d a r do r f a s ts e r i a lp o r ta n di s p r i m a r i l yd e s i g n e df o ru s e w i t ht h e

C 1 2 8 ,b u tw o r k sq u i t en i c e l yw i t ht h eC 6 4 ,P l u s / 4 ,C 1 6a n de v e n

t h e V I C2 0 . E a r l y p r o t o t y p e sw e r er e p o r t e dt o h a v ep r o b l e m s

d e a l i n gw i t ht h es l o ws e r i a lb u so f t h e s e o t h e rm a c h i n e s ,b u tt h e s e

a p p e a rt o h a v eb e e nc o r r e c t e dn o w .T h ee x t e r n a lp o w e rs u p p l y

a l l o w st h e d r i v et o r u nm u c hc o o l e rt h a nt h e1 5 4 1o r 1 5 7 1 .I t s t i l l

r u n sa b i t w a r m ,b u tn o t h i n gl i k em yd u a lp u r p o s e t o a s t e r - c u m -

1 5 4 1d i s kd r i v e .T h ep h y s i c a ls i z e o ft h e 1 5 8 1i s m i n u s c u l ec o m

p a r e dt o t h e1 5 4 1 / 1 5 7 1t y p ed r i v e .

T h ed r i v ei s s m a l le n o u g ht o r e s tn i c e l yo n t h e l e d g eb e h i n dt h e

k e y b o a r do f m yC - 1 2 8 .T h eo n l yp h y s i c a l l a y o u ti t e mw h i c hm i g h t

b e c o n f u s i n gt o 1 5 4 1 / 1 5 7 1o w n e r si s t h e l o c a t i o no f t h e p o w e r

s w i t c h .O nt h e5 ' Ai n c hd r i v e s ,t h es w i t c hi s i n t h er i g h tr e a r c o r n e r .

O n t h e 1 5 8 1 ,i t i s i n t h e l e f tr e a rc o r n e r .W h e ny o ua r e u s e dt o

f u m b l i n ga r o u n do n o n es i d et o t u r n t h e d r i v e o n ,s w i t c h i n gs i d e s

i s n ' tf a i r .O n t h e 1 5 8 1t h i si s r e a d i l yo v e r c o m e d u et o t h e s m a l l

d i m e n s i o n .J u s tb y p u t t i n gy o u rh a n db e h i n di t , o n ef i n g e ri s a l m o s t

b o u n dt o b e i n c o n t a c tw i t ht h e s w i t c h ,n o m a t t e rw h e r ei t i s .

T h e 3 V 2i n c hd i s k s a r eo b v i o u s l ya l s om u c hs m a l l e rt h a nt h e5 ' / 4

f l o p p i e s .S m a l l e ry e s ,b u tt h e ya l s oh o l dm o r et h a nt w i c ea s m u c h

d a t aa s a d o u b l es i d e d1 5 7 1d i s k !T h eb u i l t - i nr i g i d p l a s t i cc a s e so f

3 V 2i n c hd i s k sm a k et h e mm u c he a s i e rt o c a r ef o r ,t r a n s p o r tw i t h o u t

t h eb o x ,s e n di n t h em a i l ,e t c .

T h eq u i e ts m o o t ho p e r a t i o no f t h e1 5 8 1i s a j o y( n o t )t o l i s t e nt o . I n

f a c t ,w i t ht h ee x c e p t i o no f a s l i g h tc l i c ka s t h eh e a ds t e p sb e t w e e n

a d j a c e n tt r a c k s o ra l o wp i t c hs q u e a la s i t h o m e so n t oa d i s t a n tt r a c k ,

y o u w o u l dh a r d l ye v e nk n o wt h a t t h e d r i v ew a sr u n n i n g . S e v e r a l

t i m e so v e rt h ec o u r s eo f t e s t i n gi t , I t h o u g h tt h a tt h e1 5 8 1h a dd i e d

o n m eo n l yt o d i s c o v e r af e ws e c o n d sl a t e rt h a ti t w a si n d e e da l i v e

a n dw e l la n dg o i n ga b o u ti t s n o r m a lb u s i n e s s .

I n s i d e ,t h e1 5 8 1i s n i c e l yl a i do u tw i t ha w e l ls h i e l d e dC H I N O N8 0

t r a c k d r i v em e c h a n i s mc o n n e c t e dt o t h em a i nc i r c u i tb o a r dv i aa

H a r d w a r eG l i t c ho n E a r l y1 5 8 1 s

T h ef i r s tb a t c ho f 1 5 8 1d r i v e sh a v ea n e r r o ro n t h eP Cb o a r d

t h a t c r e a t e sa l l s o r t s o fp r o b l e m s ,a n dc a nl e a dt o t h el o s so f

d a t ao n d i s k .T h ep r o b l e mi s t h e l a c ko f a g r o u n dc o n n e c t i o n

o n a n 1 C :p i n 1 0 o f U 1 0( a 7 4 L S 9 3 )s h o u l db e c o n n e c t e dt o

g r o u n da t p i n1 o f U l ( t h e6 5 0 2 ) .I f y o ua r eh a v i n g p r o b l e m

w i t hy o u r1 5 8 1 ,m a k et h i sc o n n e c t i o ny o u r s e l f ,o r b r i n gy o u r

d r i v et o y o u rd e a l e rt o h a v et h ef i xm a d eu n d e rw a r r a n t y .U 1 0

i s m a r k e do n t h eP Cb o a r d ,a n di s l o c a t e dn e a rt h ef r o n to f t h e

d r i v e ,o n t h er i g h ts i d eo f t h eb o a r d .C o m m o d o r ei s a w a r eo f

t h ep r o b l e m ,a n dh a se i t h e r f i x e di t a l r e a d y , o rp l a n st o f i x i t

o n f u t u r ev e r s i o n so f t h e P C b o a r d .O u rt h a n k st o H i l a i r e

G a g n eo f L a u r e n t i a n B u s i n e s s P r o d u c t sf o r b r i n g i n gt h i s

p r o b l e mt o o u ra t t e n t i o n .

p l u g g e dm u l t i - c o n d u c t o r r i b b o nc a b l ea n d a s m a l l e rd u a l -

c o n d u c t o rc a b l e .T h em a i nr i b b o n c a b l ee d g ec o n n e c t o ro n t h e d r i v e

m e c h a n i s ma p p e a r st o b e a s t a n d a r dt y p e ,p e r h a p sa S A S I .I f t h i si s

t h ec a s e ,i t m i g h tb e p o s s i b l et o u s et h e c o n t r o l l e rb o a r dw i t hi t s

b u i l t - i nD O St o i n t e r f a c et o o t h e r " s t a n d a r d " t y p ed r i v e ss u c ha s 8 0

t r a c k5 ' Ai n c ho n e s .H m m m .. .

S p e c i f i c a t i o n s

T h et e c h n i c a lp a r a m e t e r sa r e s u m m a r i z e di n T a b l e1 . N o t et h e

d i f f e r e n c eb e t w e e nt h e " p h y s i c a l "a n d" l o g i c a l "o r g a n i z a t i o no f

T h eT r a n s a c t o r 2 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 29: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 29/84

t h ed i s k .T h i sw i l lb e e x p l a i n e di n g r e a t e rd e t a i ll a t e r .A l s on o t e

t h em e n t i o no f d i r e c t o r yp a r t i t i o n .T h i st o ow i l lb e e x p l a i n e dl a t e r .

A c o u p l eo f t h e1 5 8 1' s m o r es a l i e n tp o i n t sa r ei t sc a p a c i t y( 8 0 0 ko r

3 1 6 0b l o c k sf r e e )a n ds p e e d( a v e r a g ea b o u t1 . 5t i m e sa s f a s ta s a

1 5 7 1w h e nu s e dw i t ha C - 1 2 8o r 1 . 5t i m e sa s f a s ta s a 1 5 4 1w h e n

u s e dw i t ha C - 6 4 ,e t c . ) .U n l i k et h e 1 5 7 1 , t h ef u l lc a p a c i t yo f t h e

d r i v e ,a l o n g w i t hi t s a d v a n c e df e a t u r e s( e x c e p tb u r s tm o d e ) ,a r e

a v a i l a b l et o a l l c o m p u t e r sc a p a b l eo f s u p p o r t i n gt h es e r i a lp o r t .

L a r g es e q u e n t i a l ,p r o g r a ma n du s e rf i l e sa r el i m i t e do n l yb y d i s ks p a c e( o ra v a i l a b l ec o m p u t e r m e m o r y ) .L a r g er e l a t i v ef i l e sa r ef u l l y

s u p p o r t e du p t o f u l ld i s ks i z e( m i n u s ,o f c o u r s e ,t h eo v e r h e a df o r

s i d es e c t o r s ,e t c . )b y t h e u s eo f " s u p e rs i d es e c t o r s "o r e x t e n d e d

s i d es e c t o r b l o c k s .

A s p e e dt e s to f t h e1 5 8 1a n d c o m p a r i s o nt o o t h e rc o m p u t e r / d r i v e

c o m b i n a t i o n si s s u m m a r i z e di n T a b l e2 . T h et e s t sw e r ec o n d u c t e d

w i t ha C - l 2 8r u n n i n gi n s l o w( 1 M H z )m o d ea n d C - 6 4m o d eu s i n g

t h eC I A* 2 T O Dc l o c k a sa n a u t o m a t i ch a r d w a r et i m e r .T h eT O D

( o rt i m eo f d a y )h a r d w a r ec l o c k s a r eb a s e d o nt h es y s t e mc l o c k ,

a n da r ev e r ya c c u r a t e .T h e ya r en o ta f f e c t e db y d i s k o p e r a t i o n so r

s y s t e mi n t e r r u p t s .U n f o r t u n a t e l y , t h eT O Dc l o c k s( o n ef o r e a c h

C I A )a r en o tu s e di n C B MR O M w a r e .

A l lf u n c t i o n sw e r ep e r f o r m e df r o mB A S I Cu s i n gc o m m a n d ss u c h

a s L O A D ,S A V E ,P R I N T * ,I N P U T * ,e t c . T h e r e l a t i v ef i l e t e s t

i n c l u d e dd o u b l er e c o r dp o s i t i o n i n g ,a l t h o u g ht h e 1 5 8 1m a n u a l

a s s u r e s u st h a tt h i si s n o t r e q u i r e df o rt h e1 5 8 1 .( I t i s s t i l lu s e di n

t h ee x a m p l e si n t h em a n u a lt o " m a i n t a i nc o m p a t i b i l i t yw i t ho t h e r

d r i v e s " . )A t t h es t a r to f e a c ht e s t ,t h ed i s k sc o n t a i n e di d e n t i c a l s e t s

o f t e s tf i l e s ,s t o r e di n t h es a m eo r d e r .T h es p e e d sa r eo n l ym e a n tt o

b e a r e l a t i v ei n d i c a t i o no f d i s kI / Of r o mB A S I Cf o ra g i v e ns e t o f

c o n d i t i o n s .D i s kI / Os p e e dd e p e n d s o na n u m b e ro f f a c t o r ss u c h

a s w h e r e( i . e .p r o x i m i t yt o d i r e c t o r yt r a c k )a n dh o w( c o n t i g u o u s -

n e s s )a f i l ei s s t o r e d .

A s y o uc a ns e e ,t h e 1 5 8 1i s c o n s i d e r a b l yf a s t e ri n a l l m o d e so f

o p e r a t i o nt h a ne i t h e r a1 5 4 1 * o r a1 5 7 1 .T h ei n c r e a s e ds p e e di s

p r i m a r i l yd u et o t h e t r a c kc a c h e u s e d b yt h e 1 5 8 1t o b u f f e ra n

e n t i r e t r a c ka t o n c ei n R A Mf o ra l lI / Oo p e r a t i o n s . A f t e rr e a d i n ga n

e n t i r e t r a c ki n t oR A M ,a n yf u r t h e rr e f e r e n c e st o t h a tt r a c k ,e i t h e r

r e a d so r w r i t e s ,o n l y i n v o l v eR A M - t o - R A Mt r a n s f e ro f d a t a .T h e

t r a c kc a c h ei s t h e nw r i t t e nb a c kt o t h e d i s ki f i t h a sb e e nc h a n g e d

b y D O S .I n c i d e n t a l l y ,t h e1 4 6b l o c kf i l eb u r s tl o a d e di n 5 . 3s e c o n d s

w i t ht h e 1 5 8 1 / C - 1 2 8c o m b i n a t i o ni s a b l i s t e r i n g7 0 0 0b y t e sp e r

s e c o n d !I t i s a l s o i n t e r e s t i n gt o n o t et h a t ,w h e nu s e dw i t ha C - 6 4 ,

t h ew r i t es p e e di s c o n s i s t e n t l yf a s t e rt h a nt h er e a ds p e e d !A n y o n e

c a r et o h a z a r da g u e s so n t h er e a s o nf o rt h i s ?

1 5 8 1D O S

T h e1 5 8 1d i s k o p e r a t i n gs y s t e ms u p p o r t sa l l o f t h es t a n d a r dD O S

c o m m a n d so f o t h e rC B Md r i v e st h a tw e h a v ec o m et o k n o wa n d

l o v ea n dc o n t a i n sa n u m b e ro f r e f i n e m e n t so v e rt h e s e p r e v i o u s

D O S e s .S i n c e t h eD O Sw a ss u p p o s e d l yr e -w r i t t e nf r o ms c r a t c hf o r

t h en e wh a r d w a r e ,t h e n o t o r i o u sS A V Ea n dr e l a t i v ef i l eb u g sa r e

s a i dt o b e f i n a l l ya n dt o t a l l ye r a d i c a t e d .( A tl e a s t ,t h e yh a v en o t

s u r f a c e dy e t . )B u r s tm o d ei s a l s os u p p o r t e df o rC - 1 2 8u s e r s .T h e

1 5 8 1b u r s tc o m m a n ds e ti s v i r t u a l l yi d e n t i c a l t ot h e1 5 7 1s e tw i t h

a f e wc h a n g e st o t h eu t i l i t yc o m m a n d s :

" u 0 > b 0 "f o r c e st h es e r i a lb u st o s l o wm o d e( d e f a u l tf o ra C - 6 4 ,e t c . )

" u 0 > b l "f o r c e s t h es e r i a lb u st o f a s tm o d e ;( d e f a u l tf o ra C - 1 2 8 )

T h e s e t w ot a k e t h ep l a c eo f t h e " u 0 > m 0 "a n d " u O > m l "m o d e

c o m m a n d so n t h e 1 5 7 1 ) .

" u O > v O "t u r n so n v e r i f ya f t e rw r i t e

" u O > v 1 "t u r n so f fv e r i f y a f t e rw r i t e

" u 0 > m r "+ c h r $ (> m e m o r ya d d r e s s )+ c h r $ ( n u m b e ro f p a g e s ) ;

a n d" u 0 > m w " +c h r $ (> m e m o r ya d d r e s s )+ c h r $ ( n u m b e ro f p a g e s )

T h e s ea r em e m o r yr e a da n dw r i t ec o m m a n d sa l l o w i n gt r a n s f e ro f

m u l t i p l eb l o c k so f d a t a( i n 2 5 6b y t e p a g e s )v i ab u r s tm o d e .T h i s

a l l o w sd i r e c tr e a d i n ga n ds t u f f i n go f t h e t r a c kc a c h eb u f f e r .I n

a d d i t i o n ,a n e ws w i t c hb i th a sb e e np r o v i d e df o rt h eb u r s tr e a da n d

w r i t ec o m m a n d st o s e l e c tl o g i c a lo r p h y s i c a l t r a c ka n d s e c t o r

n u m b e r i n gs y s t e m s .

A n e x t e n d e db l o c k r e a da n db l o c kw r i t ec o m m a n ds e t i s a l s o

p r o v i d e d .

" b - R " ( t h a t ' sb - < s h i f t >r ) a n d

" b - W ( b - < s h i f t >w )

T h e s ea r e s i m i l a rt o " u a : "a n d" u b : ' ,e x c e p tt h a tD O Sd o e sn o tc h e c k

t o s e e i f t h e t r a c ka n ds e c t o rn u m b e r sf a l l i n t ot h e r a n g et h a ti t

n o r m a l l ye x p e c t s .P r e s u m a b l y ,t h i si s s o t h a ty o uc a nr e a da n dw r i t e

n o n - s t a n d a r dd i s k s ,m a y b ee v e nw e i r dc o p yp r o t e c t i o ns c h e m e s

a n df o r e i g nd i s kf o r m a t s ,w i t h b l o c k r e a da n db l o c kw r i t e .

A l t h o u g hi t i s n o ts p e c i f i c a l l ym e n t i o n e di n t h eU s e r ' sG u i d e ,t h e

1 5 8 1s u p p o r t se x t e n d e dd i r e c t o r yp a t t e r nm a t c h i n g .T h ep a t t e r n

m a t c hc h a r a c t e rc a n b ep l a c e da n y w h e r ei n t h e p a t t e r ns t r i n g .F o r

e x a m p l e :

" * b a s "w i l lf i n da l l f i l e sw h i c he n dw i t h" b a s "

" a * b "w i l lf i n da l l f i l e sw h i c hs t a r tw i t h" a "a n d e n dw i t h" b \

r e g a r d l e s so f t h el e n g t ho f t h ef i l e n a m e .

T h i sf e a t u r ei s v e r y c o n v e n i e n tf o rp e o p l ew h oa p p e n df i l et y p e s ,

s u c ha s " b a s " ," m l " ," t e x t " ," a s m " ," o b j " e t c .t o f i l en a m e s .S e a r c h i n g

f o ra s e r i e so f a s s e m b l e r s o u r c ef i l e so n a d i s ki s a s e a s ya s :

d i r e c t o r y " * . a s m "

T h ee x t e n d e dp a t t e r nm a t c h i n g c a na l s ob e u s e di n o t h e rD O S

c o m m a n d ss u c ha s o p e n i n go r L O A D i n ga f i l e ,s c r a t c h i n g as e r i e s

o f f i l e s ,e t c .A n i c et o u c h ,C o m m o d o r e .

A s p r e v i o u s l yr u m o u r e d ,t h e 1 5 8 1s u p p o r t ss u b d i r e c t o r i e so r ,

m o r ec o r r e c t l y ,d i s kp a r t i t i o n i n g ,w i t he a c hp a r t i t i o nh a v i n gi t s

o w nB A Ma n dd i r e c t o r y .E a c hp a r t i t i o nc a n t h u sh a v e 2 9 6f i l e

n a m ee n t r i e s .A l l t h i sc o m e sa t a c o s t :e a c hp a r t i t i o nu s e da s a

s u b d i r e c t o r ya l s or e q u i r e s4 0 b l o c k so f o v e r h e a df o r t h i sa d d i

t i o n a lB A M / d i r e c t o r yt r a c k . I ng e n e r a l ,t h ep a r t i t i o n sc a n b e a n y

s i z e ,f r o m1 l o g i c a ls e c t o ru p t o a b o u th a l fo f t h e d i s kc a p a c i t y ,a n d

a r ec r e a t e db y a s i m p l eD O Sc o m m a n d :

/ 0 : { p a r t i t i o nn a m e } "+ c h r $ ( s t a r t i n gl o g i c a lt r a c k # )

c h r $ ( s t a r t i n gl o g i c a ls e c t o r * )+ c h r $ (< # s e c t o r st o p a r t i t i o n

c h r $ ( > #s e c t o r st o p a r t i t i o n )+ " , C "

T h eT r a n s a c t o r 2 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 30: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 30/84

T h i sc o m m a n dm u s tb e s e n tf r o mt h ec o m p u t e rt o t h e d i s k d r i v e

o v e rt h ec o m m a n dc h a n n e l ,s i m i l a rt o a n yo t h e rB A S I C2 . 0t y p e

d i s ko p e r a t i o n ,b e c a u s en e i t h e rB A S I C2 . 0 n o r 7 . 0 s u p p o r t sa

p a r t i t i o n i n gc o m m a n d .T h ep a r t i t i o nc a n n o to v e r l a pt h e n o r m a l

B A Ma n d d i r e c t o r ya r e a s ,h e n c et h e l i m i t a t i o no n m a x i m u m

p a r t i t i o n s i z e( t h eB A M / d i r e c t o r yt r a c ki s s m a c ki n t h em i d d l eo f

t h e d i s ko n l o g i c a lt r a c k # 4 0 ) .T h ep a r t i t i o n i n gc o m m a n dc a n b e

u s e df o rp r o t e c t i n ga l m o s ta n ys i z ea r e ao n t h ed i s kf r o mb e i n g

o v e r w r i t t e nb y D O S .I n r e a lt e r m s ,t h ep a r t i t i o nc o m m a n dw o r k s

b y a s s i g n i n gt h e d i s ka r e at o a f i l ei n t h er o o td i r e c t o r y( y o uc a n

a l s o n e s tp a r t i t i o n sb u t t h ep r o c e d u r es o o nb e c o m ev e r yc o m p l i

c a t e d )w i t ht h en e wf i l et y p eC B M .T h en u m b e ro f b l o c k si n d i c a t e d

f o rt h eC B Mf i l e i st h ep a r t i t i o n e da r e as i z e .T h e" f i l e "o c c u p i e sa

c o n t i g u o u sa r e ao n t h e d i s k ,a n d o n c es e t c a n n o tb e e a s i l y

c h a n g e di n s i z ew i t h o u t d e s t r o y i n gi t .

T o u s et h ep a r t i t i o na s as u b d i r e c t o r ya r e a ,s e v e r a ls p e c i a l s t e p s

a r e r e q u i r e d .F i r s t ,t h es t a r t i n gl o g i c a ls e c t o rn u m b e rm u s tb e 0 .

N e x t ,t h ep a r t i t i o n s i z em u s t b ea m u l t i p l eo f 4 0 b l o c k s( i . e .w h o l e

t r a c k s ) .T h i r d , t h ep a r t i t i o nm u s tb e a m i n i m u mo f 1 2 0b l o c k s

l o n g .A f t e r c r e a t i n g ap a r t i t i o n ,i t c a nb e s e l e c t e db y :

7 0 : { p a r t i t i o nn a m e } "

O n c es e l e c t e d ,t h ep a r t i t i o nm u s tb e f o r m a t t e d b e f o r ef i r s tu s ea s a

s u b d i r e c t o r y .T h i si s d o n eu s i n gt h e n o r m a lD O Sf o r m a tc o m

m a n d :

' N O i d i s kn a m e . l D "o r

H E A D E R ' d i s kn a m e " , l i d

T h es p e c i f i e dd i s kn a m ea n dI D c o d e n e e dn o tb e t h es a m ea s f o r

t h er e s to f t h ed i s k .T h i sp u t s t h eB A Ma n dd i r e c t o r yi n f o r m a t i o n

i n t ot h ef i r s tt r a c ko f t h ep a r t i t i o n .Y o uh a v et o b e c a r e f u lw i t ht h i s

p a r t i t i o n i n gs c h e m e :I f y o uf o r m a tw i t h o u t p r o p e r l ys e l e c t i n gt h e

d e s i r e dp a r t i t i o n ,y o uw i l le r a s e t h ee n t i r e d i s k !( I t i si n t e r e s t i n gt o

n o t et h a tt h eI D c o d ei s n o te m b e d d e di n t ot h es e c t o rh e a d e rd a t a

i n t h e m a n n e ro f 1 5 4 1 / 1 5 7 1d r i v e sa n di n f a c ts e r v e sn o r e a l

p u r p o s eo n t h e1 5 8 1 e x c e p ta s as i m p l ei d e n t i f i e rf o rD O St o t e l l

w h a td i s ki t h a s .Y o uc a nc h a n g et h eI D c o d ea s o f t e na s y o ul i k e

b e c a u s ei t i s o n l ys t o r e di n c e r t a i na r e a ss u c ha s t h eD i r e c t o r y

h e a d e rb l o c k ) .

O n c ea p a r t i t i o nh a sb e e ns e l e c t e d ,a l lr e a d sa n dw r i t e st o d i s kw i l l

b e m a d et o f i l e si n t h a td i r e c t o r yo n l y .A l l o t h e rf i l e si n o t h e r

d i r e c t o r i e so n t h ed i s kw i l ln o tb e f o u n d .C o p i e so f f i l e sm a yr e s i d e

i n s e v e r a lp a r t i t i o n s ,e v e n u n d e rt h es a m en a m e s ,b u t t h e s ea r e

t o t a l l ys e p a r a t ec o p i e s .T h er o o t o rm a i nd i r e c t o r yc a n b es e l e c t e db y a :

7 0 : "w i t hn o p a r t i t i o nn a m es p e c i f i e d .

A f e wn e wD O Ss t a t u sa n de r r o rc o d e s h a v eb e e np r o v i d e dt o

i n d i c a t e t h e s e l e c t i o no f a p a r t i t i o no r a n i l l e g a lp a r t i t i o ns p e c i f i c a

t i o n .I f y o ua r e p r o t e c t i n g a s m a l l e r a r e ao f t h ed i s k ,s a y t h eB O O T

s e c t o r ,y o u m u s ts e tu p t h ep a r t i t i o nB E F O R Ey o uw r i t et o t h a t p a r t

o f t h ed i s k .T h ep a r t i t i o n i n gp r o c e s sw i l lw i p ec l e a nt h ea r e at h a t

i s b e i n gp r o t e c t e d .O n et h i n gw h i c hI d o n o tl i k ei s t h a tt h eC B M

f i l e sa r en o t" l o c k e d "e n t r i e s .T h i sm e a n st h a ty o uc a nw i p eo u ta n

e n t i r es u b d i r e c t o r y w i t ha n e r r a n tS C R A T C Hc o m m a n d .

F o ra d v a n c e du s e r s ,t h e i n t e r n a lD O Sf u n c t i o n s ,s u c ha s r e a da

s e c t o r ,e t c . ,c a n b ea c c e s s e dv i aa K E R N A Lt y p ej u m pt a b l ei n h i g h

R O M .A l l o ft h em o s ti m p o r t a n tf u n c t i o n s a r ea l s op a s s e d t h r o u

i n d i v i d u a l i n d i r e c tR A Mv e c t o r s a l l o w i n gt h e mt o b e t r a p p e da n d

r e d i r e c t e d .T h ei n t e r n a lD O Sr o u t i n e s a l s oa l l o wy o ut o b y p a s st h e

t r a c kc a c h ea n dr e a do r w r i t ea d i s ks e c t o rd i r e c t l y v i ao n eo r m o r e

o f t h ej o bb u f f e r s .T h i sh a n d yf e a t u r ef r e e su p 5 K b y t e so f d r i v e

R A Mw h i c hc a n b e u s e df o rc u s t o md r i v ep r o g r a m m i n g .Y o uc a n

s t u f fq u i t ea b i to f m l c o d ei n t o5 K !

A n o t h e rf e a t u r ep r o v i d e di s t h ea u t o m a t i c e x e c u t i o no f a n " & "t y p e

u t i l i t yf i l eo n p o w e r - u po r s o f t r e s e t .W h e na r e s e to c c u r s , t h e

1 5 8 1 s e a r c h e st h e r o o td i r e c t o r yf o ra f i l en a m e d" C O P Y R I G

C B M8 6 " ,t h e nl o a d sa n de x e c u t e si t i n d r i v eR A Mi f f o u n d .T h i s

m u s t b ea U S Rt y p e" & "d i s ku t i l i t yf i l e .I t c a n b eu s e dt o s e tu p

c u s t o mp r o g r a m m i n gr o u t i n e s ,s u c ha s c h a n g i n gt h eR A Mj u m p

v e c t o r s ,a u t o m a t i c a l l yo n d r i v es t a r t u p o ri n i t i a l i z a t i o n .

P h y s i c a la n dL o g i c a lD i s k s

T h e1 5 8 1d i s ki s p h y s i c a l l yc o n f i g u r e da s 5 1 2b y t e sp e rs e c t o r ,1 0

s e c t o r sp e rt r a c k ,2 s i d e s ,8 0 t r a c k sp e rs i d e .I t i s i n t e r e s t i n gt o n o t e

t h a tt h es i d e so n t h e1 5 8 1a r ef l i p p e dc o m p a r e dt o t h en u m b e r i n g

s y s t e m u s e d b yM S - D O Sa n dA T A R I S Td i s k so f t h es a m es i d e( i . e .

s i d e0 i s s i d e1 a n ds i d e1 i s s i d e0 . U s et h ed e m op r o g r a ma t t h e

e n do f t h i sa r t i c l et o s e et h i sf o ry o u r s e l fi f y o uw i s h ) .T h et r a c k s

a r en u m b e r e df r o m0 t o 7 9 a s p e rt h es t a n d a r dM F Mn u m b e r i n

s c h e m e ,a n dt h es e c t o r sf r o m1 t o 1 0 o n e a c hs i d e .T h e5 1 2b y t e

p h y s i c a l s e c t o rs i z ea l l o w sa n e x t r a5 1 2u s e rb y t e sp e rt r a c kt o b e

s q u e e z e do n ,m a x i m i z i n gd i s k u s a g e .T h eW D1 7 7 2d i s kc o n t r o l

l e rc h i pc a no n l yh a n d l e1 8 x 2 5 6b y t es e c t o r sp e rt r a c k ,e q u i v a

l e n t t o9 x 5 1 2 ,a t i t sn o r m a lr e c o r d i n g d e n s i t yw h e ny o ut a k ei n t o

a c c o u n tt h eo v e r h e a db y t e s r e q u i r e df o re a c hs e c t o r .T h e1 5 8 1i s a

r a d i c a ld e p a r t u r ef r o mo t h e r8 - b i tC B Md r i v e si n t h a ti t u s e s t h e

i n d u s t r ys t a n d a r dI B MS y s t e m3 4 M F Mr e c o r d i n gf o r m a ti n s t e a d

o f C o m m o d o r e ' s4 f o r5 G C Re n c o d i n g s c h e m e .T h i sm e a n st h a t

y o uc a np h y s i c a l l yr e a da n dw r i t e o t h e r d i s kt y p e s( s u c h a s3 ' / 2

i n c hM S - D O Sa s u s e di n m a n yl a p t o p sa n dA T A R IS T )i n t h e1 5 8 1

a n d ,p e r h a p sm o r ei m p o r t a n t l y ,r e a da n dw r i t e1 5 8 1d i s k si n t h e s e

o t h e rm a c h i n e s .O f c o u r s e ,y o uw i l ln e e da s u i t a b l ec o n v e r s i o

p r o g r a mb e c a u s et h e l o g i c a lf o r m a to f e a c ho f t h e a b o v em e n

t i o n e dd i s kf o r m a t si s t o t a l l yd i f f e r e n t .

F o rs o m er e a s o n ,p r o b a b l yt o m a i n t a i ns o m ed e g r e eo f s i m i l a r i t y

w i t he a r l i e rD O S e s( a l t h o u g hI d o n ' ts e ew h yb e c a u s et h em e d i u m

i s t o t a l l yi n c o m p a t i b l e ) ,t h eD O Su s e sa d i f f e r e n t l o g i c a la d d r e s s i n

s c h e m e .T h el o g i c a ls c h e m e ,w h i c hi s u s e d b ya l l o f t h eu s e rD O S

c o m m a n d s ,s u c ha s b l o c k - r e a d ,e t c , s o m eo f t h e j o b q u e u e

c o m m a n d sa n ds o m eo f t h eb u r s tm o d ec o m m a n d s ,c o n s i s t so f :s i n g l es i d e d ,8 0 t r a c k s( 1 t o 8 0 ) ,2 5 6b y t e sp e rs e c t o r ,4 0 s e c t o r s

p e rt r a c k( 0 t o 3 9 ) . I n t h i ss c h e m e ,l o g i c a ls e c t o r s0 t o 1 9 a r eo n

s i d e0 a n d2 0 t o 3 9 a r eo n s i d e1 . T h e r ea r et w ol o g i c a ls e c t o r si n

e a c hp h y s i c a ls e c t o r .A s w i t ho t h e r v e r s i o n so f D O S ,t h ef i r s tt w o

b y t e so f e a c hl o g i c a ls e c t o rr e p r e s e n t t h el i n kt o t h en e x tl o g i c a l

s e c t o ri n a g i v e nf i l e .

T h er o o to r m a i nd i r e c t o r yi s o n l o g i c a lt r a c k4 0 ( p h y s i c a l t r a

3 9 ) .T h ed i r e c t o r yh e a d e ri s l o g i c a ls e c t o r0 , B A Mf o rl o g i c a lt r a c k s

1 t o 4 0 i s i n l o g i c a ls e c t o r 2a n dB A Mf o rl o g i c a lt r a c k s4 1 t o 8 0 i s i n

l o g i c a ls e c t o r2 . T h ed i r e c t o r yp r o p e rs t a r t si n l o g i c a ls e c t o r3 a n d

u s e st h e r e s t o ft h e t r a c k .T h ef o r m a tf o rp a r t i t i o n d i r e c t o r i s

i d e n t i c a l ,e x c e p tt h a t t h e B A Mi s o n l yl o c a l f o rt h e s p e c i f i c

p a r t i t i o n .

T h eT r a n s a c t o r 2 8 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 31: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 31/84

I t s h o u l db e n o t e dt h a tb e c a u s et h e d i r e c t o r ya n dB A Mi s i n a

d i f f e r e n tl o c a t i o no n t h e 1 5 8 1 ,a n y 1 5 4 1 / 1 5 7 1s o f t w a r et h a t

a c c e s s e s t h ed i r e c t o r yt r a c kd i r e c t l y ,s u c ha s u n s c r a t c h ,d i r e c t o r y

a l p h a b e t i z i n ga n dl o c k - u n l o c k p r o g r a m s ,w i l ln o tw o r kw i t ht h e

1 5 8 1w i t h o u tm o d i f i c a t i o n s .

U t i l i t i e sa n d D o c u m e n t a t i o n

T h eu s e r ' sg u i d et h a tc o m e sw i t ht h e 1 5 8 1i s c l e a r l ys u p e r i o rt o

a n ys u p p l i e dw i t ht h e 1 5 4 1o r 1 5 7 1 .I t e v e nt a k e s t h ea d v a n c e d

p r o g r a m m e rt o h e a r t w i t hm e m o r ym a p s( a l b e i tn o tv e r yd e t a i l e d )

a n da d e t a i l e d d e s c r i p t i o no f h o wt h e j o bq u e u es y s t e mw o r k s ,

c o m p l e t ew i t ha l i s t i n g o fj o bc o d e s ,e r r o rr e t u r n sa n da B A S I C

e x a m p l e .T h eg u i d e c o n t a i n sm a n ym o r ed e t a i l e de x a m p l e st h a n

p r e v i o u sg u i d e s ,b u ti s s t i l ll a c k i n gi n t h ea r e ao f b u r s tm o d e .T h e

b u r s tm o d ed e s c r i p t i o n s a r ei n t h es a m ew e a kf o r m a ta s t h e1 5 7 1

m a n u a lw i t hn o a c t u a le x a m p l e sb e y o n da c r y p t i cv e r b a l d e s c r i p

t i o n .T o C B M ' sc r e d i tt h o u g h ,t h ed e m od i s kt h a tc o m e sw i t ht h e

d r i v ec o n t a i n sa f a i r l yd e t a i l e de x a m p l eb u r s tm o d ep r o g r a m ,

c o m p l e t ew i t ha n n o t a t e da s s e m b l e rs o u r c ec o d e .

T h em a n u a lm a k e sv i r t u a l l yn o r e f e r e n c et o t h ef a c tt h a tt h e1 5 8 1

c a n b ee a s i l yp r o g r a m m e dt o r e a do t h e r3 V 2i n c hd i s k f o r m a t s ,

s u c ha s I B MP Cs y s t e m2 a n dA t a r i S T .I t w i l ln o t r e a dA m i g ao r

M a c i n t o s hd i s k sd i r e c t l yf r o mD O Sd u et o a c o m p l e t e l yd i f f e r e n t

p h y s i c a ld i s ks t r u c t u r e .H o w e v e r ,w i t ho v e r5 K s p a c ea v a i l a b l ef o r

c u s t o m p r o g r a m m i n g ,a n y t h i n gi s p o s s i b l e .

T h eu t i l i t yd i s ks u p p l i e d w i t ht h e 1 5 8 1c o m e sw i t ha n u m b e ro f

r e a l l yu s e f u lp r o g r a m s .T h e b a c k - u pr o u t i n e sf o rb o t ht h eC - 1 2 8

a n d C - 6 4s u p p o r te x p a n s i o nR A Ma n d / o rm u l t i p l e d r i v e st o

m i n i m i z ed i s ks w a p p i n g .A f a s tl o a d e r ," Z A P L O A D " ,i s p r o v i d e d

f o rt h e C - 6 4 ,w h i c hd o u b l e st h e s p e e da t w h i c hf i l e sw i l ll o a d .

F i l e st o l o a da r es e l e c t e df r o ma m e n u .A l s oi n c l u d e da r ea s e c t o r

e d i t o rf o rt h eC - 1 2 8( n o tj u s t" d i s p l a yt r a c ka n ds e c t o r " )a n do t h e r

u t i l i t i e sf o rc r e a t i n gB O O Ts e c t o r s , p a r t i t i o n s ,e t c .T h eo n l yt h i n g

w h i c hI d i dn o tl i k ea b o u tt h es e c t o re d i t o rw a st h a ti t w o r k s o n

C B MD O Sd i s k so n l yu s i n gl o g i c a ls e c t o rn u m b e r sa n dw i l ln o tl e t

y o ue x a m i n ef o r e i g nd i s kf o r m a t sv e r ye a s i l y .T h es i m p l ed e m o

p r o g r a mi n c l u d e d w i t ht h i s a r t i c l ew o r k sw i t ha n yr e a d a b l ed i s k

t y p e ,i n c l u d i n gM S - D O S ,a n dA T A R IS T .

A f e wh i - r e sp i c t u r e s a r e a l s oi n c l u d e di n a s l i d es h o wf o rt h eC -

1 2 8i n 4 0 c o l u m nm o d et o d e m o n s t r a t et h ed r i v e ' ss p e e d .

C o m p a t i b i l i t y

A s m e n t i o n e dp r e v i o u s l y ,a n y p r o g r a mt h a tt r i e s t oa c c e s st h e

d i r e c t o r y t r a c kd i r e c t l yw i t hb l o c k r e a d so r w r i t e sw i l ln o tf i n di t

a n dt h e r e f o r ew i l ln o tw o r kw i t ht h e 1 5 8 1 w i t h o u tm o d i f i c a t i o n .

T h i si n c l u d e sC - 6 4 G E O S .I t w i l lp r o b a b l yt a k es o m et i m eb e f o r e

c o m m e r c i a ls o f t w a r ei s s u p p l i e di n t h e3 V 2i n c hf o r m a ta n d ,u n t i l

i t i s ,y o um a yh a v et o b o o tu p y o u rf a v o u r i t ep r o g r a m o ny o u r5 ' A

i n c hd r i v ea n d u s e t h e 1 5 8 1f o r d a t as t o r a g eo n l y .A m i n o r

i n c o n v e n i e n c e ,b u t g e n e r a l l yl i v a b l e .T h e1 5 7 1D O Ss h e l lf o rt h e

C - 1 2 8w o r k sw i t ht h e 1 5 8 1i n i t s f i l ec o p y i n gm o d ef o rt r a n s f e r

r i n ga r a n g eo f f i l e sb e t w e e nd r i v e s .T h ev a r i o u sd i r e c t o r yr o u

t i n e s ,s u c ha s u n s c r a t c ha n dr e - o r d e r ,d o n o tw o r kf o rt h er e a s o n s

p r e v i o u s l yo u t l i n e d .

F a s t l o a d e r s ,f a s tc o p yu t i l i t i e s ,n i b b l e c o p i e r sa n d1 5 4 1b a s e d c o p

p r o t e c t i o ns c h e m e sw i l lp r o b a b l yn o tw o r kw i t ht h e1 5 8 1b e c a u s e

t h e ya r e t o o h a r d w a r e a n dD O Ss p e c i f i c t ot h e o l d e r5 ' A i n c h

d r i v e s .H o w e v e r ,o t h e rn o n -c o p yp r o t e c t e d s o f t w a r ew o r k sw e l l

w i t ht h e1 5 8 1. C - 1 2 8C P / Mw i l lc u r r e n t l y n o tb o o tf r o mt h e 1 5 8 1 ,

a l t h o u g hI u n d e r s t a n dt h a ta n u p g r a d ew i l lb e a v a i l a b l e .O n c e

b o o t e df r o ma 1 5 7 1o r 1 5 4 1 ,C P / Mw i l lw o r k ,t o a l i m i t e d e x t e n

w i t ht h e 1 5 8 1 .T h ep h y s i c a ld i s kf o r m a ti s v e r ys i m i l a rt o E P S O N

Q X -1 0 f o r m a t .T h e r e f o r e ,C P / Mt h i n k si t i s a Q X - 1 0d i s ka n d

t r e a t si t a c c o r d i n g l y .T h et r o u b l ew i t ht h i si s t h a ty o ul o s e h a l fo f

y o u rd i s kc a p a c i t y( Q X - 1 0i s o n l ys e tu p f o r4 0 t r a c k s ) .F o rt h o s e

d i d d l e r si n t e r e s t e d ,y o uc a n u s e a l l 8 0 0k i n C P / Mm o d eb y

c h a n g i n ga f e wb y t e si n t h eC P M+ . S Y Sf i l ed i s kp a r a m e t e rt a b l e

u s i n g ad e b u gt o o ls u c ha s D D To r S I D .O f c o u r s e ,y o u l o s e

c o m p a t i b i l i t yw i t ht r u eQ X - 1 0 ,b u tw h ou s e st h a tf o r m a ta n y w a y ?

( C o m p l e t ed e t a i l s w i l lb e p u b l i s h e di n t h en e x tT r a n s a c t o r ) .

D e m o

L i s t i n g1 i s a s h o r td e m op r o g r a mf o rt h e 1 5 8 1 .T h es o u r c ec o d e

f o r t h e m a c h i n el a n g u a g ep o r t i o ni s c o n t a i n e di n l i s t i n g2 . T h e

p r o g r a mi s a s i m p l ed i s p l a y t r a c ka n ds e c t o ru t i l i t yt h a tw o r k sb y

d i r e c ta c c e s st o t h ej o bq u e u ea n dd i s kI / Ob u f f e r s .I t w o r k sw i t h

t h eC - 1 2 8i n 8 0 c o l u m nm o d eo n l ya n dw i l lr e a dm a n yt y p e so f

3 V 2i n c hd i s k s .T h ep r o g r a mi s v e r ys i m p l et o u s ea n d w o r k si n

t e r m so f p h y s i c a l t r a c k sa n ds e c t o r s r a t h e rt h a tC B MD O Sl o g i c a l

s e c t o r s .T h eo p e r a t i n gd e t a i l sa n dc o m m a n dk e y sa r ec o n t a i n e di n

t h eR E Ms t a t e m e n t sa n ds c r e e n p r o m p t s ,s o I w o n ' tr e p e a tt h e m

h e r e .

A s m e n t i o n e dp r e v i o u s l y ,y o uw i l l f i n dt h es i d e s f l i p p e df o rn o n

C B MD O Sd i s k s .T h eM S - D O SB O O Tr e c o r di s a l w a y so n s i d e0 ,

t r a c k0 , s e c t o r1 , w h i l e t h e1 5 8 1f i n d si t o n s i d e1 . S i m i l a r l y

s i n g l e - s i d e dd i s k s ,s u c ha s A T A R IS T ,s h o u l dh a v et h ed a t ao n s i d e

0 , y e tt h e1 5 8 1s e e si t o n s i d e1 . B o t hM S -D O Sa n dA T A R IS Tu s e

a 5 1 2b y t es e c t o rs i z e ,9 s e c t o r sp e rt r a c k ,n u m b e r e d1 t o 9 . T h e

d i r e c t o r ys t r u c t u r ea n dd i s ka l l o c a t i o nm e t h o df o rA T A R IS T a n d

M S -D O Sa r e q u i t es i m i l a r ,a l t h o u g hl o c a t e di n s l i g h t l yd i f f e r e n t

a r e a so f t h ed i s k .

S i n c et h ed e m op r o g r a mu s e sp h y s i c a l t r a c ka n ds e c t o rn u m b e r s

t h eC B MD O Sd i r e c t o r yw i l lb e o n s i d e0 , t r a c k3 9 .T h ed i r e c t o r y

p r o p e rs t a r t sa t p h y s i c a l s e c t o r2 x h( i . em i d w a yt h r o u g hs e c t o r2 )

a n dc o n t i n u e st o t h ee n do f s i d e1 , t r a c k 3 9 , s e c t o r1 0 .T h eC - 1 2 8

B O O Ts e c t o ri s l o c a t e di n t h ef i r s th a l fo f s i d e0 , t r a c k0 , s e c t o r1 .

F i n a lW o r d

T h e1 5 8 1i s w e l lw o r t hi t s l o n g d e l a yi n g e t t i n gt o m a r k e tb u t , l i k e

s o m eo t h e r p r o d u c t s ,i t s u s e f u l n e s si s l i m i t e db y t h e l a c ko f

s o f t w a r ea v a i l a b l ef o ri t . I n a l lf a i r n e s s ,I m u s tg i v e t h eg u y sa t C B M

c r e d i tf o rd o i n ga n e x c e l l e n t j o bo n t h i so n e .I t sl a r g ed i s k c a p a c i

i s a b r e a t ho f f r e s ha i r , e s p e c i a l l yf o r C - 6 4u s e r sw h oh a v e

f r e q u e n t l yc o m p l a i n e da b o u tt h e1 5 4 1" s p u n y1 7 0K c a p a c i t y .

T h eT r a n s a c t o r 2 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 32: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 32/84

T a b l e1 : 1 5 8 1T e c h n i c a lS p e c i f i c a t i o n s T a b l e2 : S u m m a r yo f D i s kD r i v eT e s tS p e e d s

T o t a lf o r m a t t e dc a p a c i t y8 0 8 , 9 6 0b y t e s

N u m b e ro f d i r e c t o r ye n t r i e s2 9 6( e a c hd i r e c t o r yp a r t i t i o n )

M a x i m u mS E Qf i l es i z e 8 0 2 , 6 4 0b y t e s

M a x i m u mR E Lf i l es i z e 8 0 0 , 0 0 0b y t e s ( a p p r o x )

M a x .r e c o r d sp e rR E Lf i l e6 5 , 5 3 5

N u m b e ro f D O SR A Mb u f f e r s9 ( 7 I / O+ 2 r e s e r v e df o rB A M )

T r a c kc a c h eb u f f e r 5 K b y t e s

R e c o r d i n gf o r m a tM F M( I B M s y s t e m3 4 )

P h y s i c a lD i s kO r g a n i z a t i o n :( a ss e e no n t h ed i s k )

N u m b e ro f s i d e s 2 ( n u m b e r e d0 a n d1 )

N u m b e ro f t r a c k sp e rs i d e 8 0 ( n u m b e r e d0 t o 7 9 )

N u m b e ro f s e c t o r sp e rt r a c k 1 0 ( n u m b e r e d1 t o 1 0 )

N u m b e ro f b y t e sp e rs e c t o r5 1 2

L o g i c a lD i s kO r g a n i z a t i o n :( a ss e e nb y D O S )

N u m b e ro f s i d e s 1

N u m b e ro f t r a c k s 8 0 ( n u m b e r e d1 t o 8 0 )

N u m b e ro f s e c t o r sp e rt r a c k 4 0 ( n u m b e r e d0 t o 3 9 )

N u m b e r - o fb y t e sp e rs e c t o r2 5 6

N u m b e ro f b l o c k sf r e e 3 1 6 0

N o t e s :

1 1 l o g i c a lt o p h y s i c a lc o n v e r s i o n sa r ed o n ea u t o m a t i c a l l yb y D O S

E a c hp h y s i c a l s e c t o ri s s u b d i v i d e di n t o2 l o g i c a ls e c t o r s .

E a c hl o g i c a ls e c t o rb e g i n s w i t ht h e t r a c ka n ds e c t o rp o i n t e rt o

t h en e x tl o g i c a l s e c t o r ,a s p e rn o r m a lC B MD O S . )

C h i p s :

M i c r o p r o c e s s o r

I / OI n t e r f a c e

3 2 K b y t e sR O M

8 K b y t e sR A M

D i s kc o n t r o l l e r

6 5 0 2A

8 5 2 0A

2 3 2 5 6

4 3 6 4

W D 1 7 7 2

P h y s i c a lD i m e n s i o n s :

H e i g h t

W i d t h

D e p t h

W e i g h t

6 3 m m

1 4 0m m

2 3 0m m

1 . 4k g

E x t e r n a lP o w e rS u p p l y :

N o r t hA m e r i c a 1 0 0 - 1 2 0V A C ,6 0 H z , 1 0WE u r o p e 2 2 0 - 2 4 0 V A C ,5 0 H z ,1 0 W

O p e r a t i o n D i s kD r i v e /C o m p u t e r

1 5 4 1 / 6 4 1 5 7 1 / 1 2 8 1 5 8 1 / 1 2 81 5 8 1 / 6 4

F O R M A Td i s k

L O A Ds h o r t

L O A Dl o n g

Z A PL O A Dl o n g

B u r s tL O A Ds h o r t

B u r s tL O A Dl o n g

S A V Es h o r t

S A V El o n g

W R I T ES E Qf i l e

R E A DS E Qf i l e

W R I T ER E Lf i l e

R E A DR E Lf i l e

8 0

4 . 5

9 3

3 0

6 . 5

1 0 0

9 . 3

8 . 1

1 5 5

4 0

1 . 5

1 1 . 5

0 . 4

1 0 . 4

5 . 7

7 1

7 . 8

4 . 6

1 0 9

7 7

1 0 0

0 . 4

6 . 4

0 . 4

5 . 3

2 . 1

3 1 . 5

5 . 7

3 . 8

5 7 . 3

3 2 . 3

1 0 0

3 . 5

7 5

4 . 5

5 2

6 . 8

7 . 3

8 9 . 5

3 7 . 5

N o t e s :

1 ) A l lt i m e sa r ei n s e c o n d sa n dw e r eo b t a i n e du s i n gt h eC I A# 2 T O D

c l o c ka s a t i m e r .T h et i m e sy o ug e t m a yv a r yd e p e n d i n go n d i s k

u s a g e( i . ei f t h ef i l e sa r e s t o r e dc o n t i g u o u s l yo r n o t ,a n dh o wf a rt h e

h e a dh a st o m o v et o a c c e s st h ef i l e s ) .

2 ) T h es h o r tp r o g r a mi s 5 b l o c k si n s i z ea n dt h el o n gi s 1 4 6b l o c k s .

3 ) Z A P L O A D6 4 i s a f a s tl o a d e rf o rt h eC - 6 4a n d1 5 8 1w h i c hi s s u p p l i e d

o n t h e1 5 8 1d e m od i s k .I t t a k e s6 s e c o n d st o l o a d .

4 ) T h eS E Qf i l ec o n s i s t so f 1 0 0s t r i n g s o f2 4 c h a r a c t e r se a c h .F i l er e a d s

a n dw r i t e s a r e v i aB A S I C ' SI N P U T *a n dP R I N T *s t a t e m e n t si n a

F O R - N E X Tl o o p .

5 ) T h eR E Lf i l ec o n s i s t so f 1 0 0r e c o r d so f 6 4 b y t e s l o n g e a c h .R e c o r d s

a r er e a da n dw r i t t e ni n B A S I Ci n p s e u d o - r a n d o mo r d e r( 1 0 0 ,1 , 9 8 ,

3 , . .. , 9 9 , 2 ) d e s i g n e dt o m a x i m i z er e c o r ds e a r c h i n g .R e c o r d

p o s i t i o n i n gc o m m a n d sg i v e nt w i c ef o re a c hr e c o r d .T h ew r i t es p e e d s

i n c l u d ei n i t i a lc r e a t i o no f a 6 4 b y t ex 1 0 0r e c o r df i l e .

L i s t i n g1 : 1 5 8 1d r i v ed e m op r o g r a mf o rt h eC 1 2 8 .

N o t e :W i t ht h ee x c e p t i o no f" [ Ns p c s ] " ,l i t e r a l ss u c ha s " < l e f t > "a n d

" < u p > "t h a ta p p e a ri n t h i sp r o g r a ms h o u l db e e n t e r e dA SS H O W N

- d o N O Tr e p l a c et h e s e w i t h c u r s o rc o n t r o l c h a r a c t e r s .

G H

G D

G B

H F

M B

O F

A O

C H

G M

G L

J M

K M

F H

F P

" l O O O r e m* * :

1 0 1 0r e m*

1 0 2 0 r e m*

1 0 3 0 r e m*

1 0 4 0r e m*

1 0 5 0 r e m*

1 0 6 0 r e m*

1 0 7 0r e m* »

1 0 8 0r e m* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

1 0 9 0 :

1 1 0 0 d v= 9 : r e md i s k d r i v ed e v i c en u m b e r

1 1 1 0 :

1 1 2 0 f a s t : p r i n t c h r $ ( 1 4 7 ) ; : b 1= 3 3 2 8 : b 2= 3 3 3 8

1 1 3 0f o ri = 2 8 1 6t o 2 9 3 5 : r e a d x : p o k ei . x . n e x t

: r e m p o k em a c h i n ec o d e

1 5 8 1d e m op r o g r a m

b y

m . g a r a m s z e g h y

f o r c - 1 2 8 a n d1 5 8 1d r i v e

I O

M H

M P

K P

H K

N N

E C

P G

D J

P E

M E

L F

K E

D K

1 1 4 0 :

1 1 5 0p r i n f [ 7s p c s ] * * * * * * * 1 5 8 1d i s p l a y t & s< c >m .

g a r a m s z e g h y1 9 8 7* * * * * * * *

1 1 6 0 :

1 1 7 0 s p $= " s " : p r i n t : p r i n t : i n p u t ' [ s ] c r e e no r [ p ] r i n t e r " ; s p

1 1 8 0p d = 3 : i fs p $= " p "t h e np d = 4

1 1 9 0o p e n1 , p d :r e mo p e no u t p u tf i l e

1 2 0 0:

1 2 1 0p r i n t p r i n t " i n s e r td i s kt h e np r e s sa k e y. . . "

: g e t k e yi $

1 2 2 0o p e n1 5 , d v ,1 5 ," u O "+ c h r $ ( 1 0 ) :s y s2 8 1 6 , 0

: r e ma n a l y s es i d e0

1 2 3 0p r i n t # 1 5 , ' u O 1+ c h r $ ( 2 6 ) :s y s2 8 1 6 , 1 0

: r e ma n a l y s es i d e1

1 2 4 0 :

1 2 5 0 1 1= p e e k ( b 1 )a n d1 4 : t 2= p e e k ( b 2 )a n d1 4

: r e mb u r s ts t a t u sb y t es i d e0 a n d1

1 2 6 0i f t 1 a n dt 2 t h e np r i n t" * * *d i s ke r r o r * * * "

: g e t k e ya $ : g o t o1 7 2 0

1 2 7 0s z = p e e k ( b 1 )a n d4 8 :i f t 1 t h e n s z= p e e k ( b 2 )

a n d4 8 :r e mc h e c ks e c t o rs i z e

T h eT r a n s a c t o r 3 O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 33: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 33/84

F M

H F

N G

J C

N E

N P

E l

J G

E M

C K

L N

H O

M OH J

F D

K AN l

M K

M O

L A

G E

C E

A F

O P

C D

O G

A A

D A

I K

G J

A K

J L

L A

C G

I D

C N

G l

C A

C C

B N

H K

1 2 8 0 s z =s z / 1 6 : i f s z= 3 t h e n s z =4

1 2 9 0s 1 = p e e k ( b 1 + 4 ) : m 1 = p e e k ( b 1 + 5 )

1 3 0 0s 2 = p e e k ( b 2+ 4 ) : m 2= p e e k ( b 2+ 5 )

1 3 1 0w i n d o w0 , 2 , 7 9 , 2 4 , 1: i fp d = 4 t h e nc m d1

: g o s u b1 9 4 0 : p r i n t # 1 : c l o s e 1 : o p e n 1 , p d

1 3 2 0g o s u b1 9 4 0

1 3 3 0s i = - 1 : i n p u t " s i d e , t r a c k , s e c t o r " ; s i , t , s : i fs i = - 1

t h e n1 7 2 0

1 3 4 0p r i n t # 1 5 , " m - w i ' c h r $ ( 2 0 6 ) c h r $ ( 1) c h r $ ( 1) c h r $ ( s i )

: r e ms e ts i d e

1 3 5 0p r i n t # 1 5 , " m - w " c h r $ ( 1 1 ) c h r $ ( 0 ) c h r $ ( 2 ) c h r $ ( t ) c h r $ ( s )

: r e ms e tt & s

1 3 6 0 :

1 3 7 0 r e mt h e ns t u f fj o bc o d ef o rr e a dp h y s i c a ls e c t o r

i n t oj o bb u f f e r

1 3 8 0p r i n t *1 5 , " m - w " c h r $ ( 2 ) c h r $ ( 0 ) c h r $ ( 1) c h r $ ( 1 6 4 )

1 3 9 0g o s u b1 4 1 0 :g o t o1 4 4 0 :r e mw a i tt i l lj o bd o n e

1 4 0 0 :

1 4 1 0p r i n t # 1 5 , " m - r " c h r $ ( 2 ) c h r $ ( 0 ) c h r $ ( 1 ) :r e mc h e c k

j o bs t a t u s

1 4 2 0g e t # 1 5 , a $ : i fa s c ( a $ ) > 1 2 7t h e n1 4 1 0: e l s er e t u r n

1 4 3 0 :1 4 4 0w i n d o w0 , 2 4 , 7 9 , 2 4 , 1: p r i n t # 1/ s i d e» " s i ,

" t r a c k» " t ," s e c t o r» " s ;

1 4 5 0w i n d o w0 , 2 0 , 7 9 , 2 3

1 4 6 0p r i n t " < l e f t >- d e c r e a s es e c t o r # [ 1 1 s p c s ]

< r i g h t >- i n c r e a s es e c t o r # "

1 4 7 0p r i n t " < d o w n >- d e c r e a s et r a c k # [ 1 5 s p c s ]

< u p >- i n c r e a s et r a c k # "

1 4 8 0p r i n t 1< e s c >- s e l e c tn e wt r a c k ,s e c t o r [ 3s p c s ]

< s p a c e >- n e x t2 5 6b y t e s" ;

1 4 9 0i f a s c ( a $ ) > 1 t h e np r i n t # 1, " * * *e r r o r# " a s c ( a $ )

" * * * " : g o t o 1 3 2 0

1 5 0 0 :

1 5 1 0 p r i n t # 1 5 , " u 0 > m r " c h r $ ( 3 ) c h r $ ( s z )

: r e mb u r s tm o d em e m o r yr e a d

1 5 2 0s y s2 8 1 9 , s z: r e mr e a d d a t av i ab u r s tm o d e

1 5 3 0 :

1 5 4 0i f p d = 4 t h e np r i n t # 1 , '"

1 5 5 0f o ri = 4 8 6 4t o 4 8 6 4+ s z * 2 5 6 - 1s t e p2 5 6

: r e md i s p l a yd a t ai n h e xf o r m

1 5 6 0w i n d o w0 , 2 , 7 9 , 1 9 , 1

1 5 7 0f o rj = 0 t o 2 5 4s t e p1 6 : r e m 1 6b y t e s p e rl i n e ,

2 5 6b y t e s p e rp a g eg r o u p

1 5 8 0 :

1 5 9 0 n u $ =r i g h t $ ( h e x $ ( i + j - 4 8 6 4 ) , 3 )+ " : " : n 2 $= " : "

1 6 0 0 f o r k= 0 t o1 5 : n 2= p e e k ( i+ j + k )

: n u $= n u $+ r i g h t $ ( h e x $ ( n 2 ) , 2 )+ " "

1 6 1 0n $ = c h r $ ( n 2 ) : i fn 2 < 3 2o r ( n 2 > 1 2 7 a n dn 2 < 1 6 0 )

t h e nn $ = " . "

1 6 2 0 n 2 $= n 2 $+ n $ : n e x t : p r i n t # 1, n u $ ; n 2 $ : n e x t

1 6 3 0 :

1 6 4 0i f p d = 3 t h e ng e t k e ya $ : r e mg e ta k e yp r e s s

1 6 5 0i f a $ = c h r $ ( 1 4 5 ) t h e nt = t + 1 : g o t o1 3 4 0

: r e mc u r s o ru p = i n c r e a s et r a c k#

1 6 6 0i f a $ = c h r $ ( 1 7 )t h e nt = t - 1 : g o t o1 3 4 0

: r e mc u r s o rd o w n= d e c r e a s et r a c k#

1 6 7 0i f a $ = c h r $ ( 1 5 7 ) t h e ns = s - 1 : g o t o1 3 4 0

: r e mc u r s o rl e f t= d e c r e a s es e c t o r#

1 6 8 0i f a $ = c hr $ ( 2 9 )t h e ns = s + 1 :g o t o1 3 4 0

: r e mc u r s o rr i g h t= i n c r e a s e s e c t o r#

T h eT r a n s a c t o r 3 1

A C

B L

C C

E A

G D

E K

K E

F D

H H

P O

F O

P B

A A

K O

D D

J D

A P

G l

H J

H DI K

G J

K O

N G

O P

F l

E D

B L

E F

E G

O N

1 6 9 0 i f a $= c h r $ ( 2 7 )

: r e me s c a p e=

1 7 0 0n e x t :g o t o1 3 1 0

: r e mo t h e rk e y

1 7 1 0 :

t h e n1 3 1 0

= s e l e c tn e wv a l u e s

= d i s p l a y n e x tg r o u p

1 7 2 0d c l o s eu ( d v ) : c l o s e1 : w i n d o w0 , 0 , 7 9 , 2 4 ,

1 7 3 0 :

1 7 4 0r e m m a c h i n ec o d ed a t a

1 7 5 0 :

1 7 6 0d a t a 7 6 , 4 4 ,

1 7 7 0d a t a1 4 1 , 0 ,

1 7 8 0d a t a2 2 0 ,2 4 0 ,

1 7 9 0d a t a1 4 1 , 0 ,

1 8 0 0d a t a 4 4 , 1 3 ,

1 8 1 0d a t a1 4 1 , 0 ,

1 8 2 0d a t a 1 1 , 1 6 9 ,

1 8 3 0d a t a1 6 0 , 0 ,

1 8 4 0d a t a 1 4 , 2 0 8 ,

1 8 5 0d a t a 3 2 , 1 2 ,

1 8 6 0d a t a2 0 8 ,2 4 6 ,

1 8 7 0d a t a1 3 3 ,2 5 0 ,

1 8 8 0d a t a 1 1 , 3 2 ,1 8 9 0d a t a 1 1 , 1 4 5 ,

1 9 0 0d a t a2 4 0 ,2 2 4 ,

1 9 1 0 :

1 1 , 7 6 , 8 4 ,1 1 , 1 6 9

2 5 5 , 9 6 , 1 6 9 ,8 , 4 4

2 5 1 , 1 7 3 ,0 , 2 2 1 ,7 3

2 2 1 , 1 7 3 ,1 2 , 2 2 0 ,9 6

2 2 0 , 1 7 3 ,0 , 2 2 1 ,7 3

2 2 1 , 9 6 , 1 3 3 , 2 5 0 , 3 2

1 3 , 1 3 3 , 2 5 1 ,3 2 , 3 1

3 2 , 1 2 , 1 1 , 1 4 5 , 2 5 0

1 5 , 2 0 0 , 1 9 2 ,2 , 2 0 8

1 1 ,1 4 5 , 2 5 0 , 2 0 0 , 1 9 2

8 8 , 9 6 , 1 3 3 , 2 5 2 , 1 6 9

1 6 9 , 1 9 , 1 3 3 , 2 5 1 , 3 2

3 1 , 1 1 , 1 6 0 ,0 , 3 2

2 5 0 , 2 0 0 , 2 0 8 , 2 4 8 ,1 9 8

2 3 0 , 2 5 1 ,7 6 , 1 0 2 ,1 1

1 9 2 0r e mp r i n td i s kd e t a i l s

1 9 3 0 :

1 9 4 0p r i n t" s e c t o rs i z e = " s z * 2 5 6 : p r i n t : i ft 1 o r

p r i n t" s i n g l e s i d e d ! ! '

1 9 5 0i f t 1 t h e n1 9 7 0

1 : e n d

, 0

, 1 3

, 1 6

, 1 2 0

, 1 6

, 6

, 1 1

, 4 1

, 2 4 2

, 7

, 0

, 6

, 1 2, 2 5 2

, 2 5 5

t 2 t h e n

1 9 6 0p r i n t" s i d eO : " : p r i n t" m i ns e c t o r # " ; s 1 , " m a x

s e c t o r# " m 1

1 9 7 0i f t 2 t h e n1 9 9 0

1 9 8 0p r i n t :p r i n t" s i d e

s e c t o r# " m 2

1 9 9 0p r i n t :r e t u r n

1 : " : p r i n t" m i ns e c t o r# " ; s 2 , " m a x

L i s t i n g2 : S o u r c ec o d e( i n" B u d d y "o r " P A L 1a s s e m b l e rf o r m a t )f o rt h e

m a c h i n el a n g u a g e c o d e u s e di

1 0 0 ; "

1 1 0 ;

1 2 0; <

1 3 0 ;

1 4 0 ;

n t h ed e m op r o g r a m .

5 8 1d i s p l a yt & sb u r s tm o d es o u r c ec o d e

; c >m . g a r a m s z e g h y 1 9 8 7

1 5 0p n t r = $ f a

1 6 0s i z e = $ f c

1 7 0m m u = S f f O O

1 8 0d a t a = $ 1 3 0 0

1 9 0 c o n f = $ 0 d 0 0

2 0 0c l o c k = S d d O O

2 1 0d d r = $ d c 0 c

2 2 0d i c r = $ d c O dp e r i .

2 4 0;

2 5 0 *= $ 0 b 0 0

2 6 0. o p to o

2 7 0;

2 8 0j m p t a b l e= *

2 9 0 j m pt e s t d s k

; z e r op a g ep o i n t e r

; n u m b e ro f b l o c k st o r e a d

; m m uc o n f i g r e g

; s t a r to f d a t ab u f f e r

; s t a r to f d i s kt y p eb u f f e r

; b u r s tc l o c kl i n e

; b u r s td a t ar e g i s t e r

; b u r s ti n t e r r u p t r e g i s t e r

; d e c i m a l 2 8 1 6

; a s s e m b l et o m e m o r y

; a n a l y z ed i s k

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 34: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 34/84

3 0 0

3 1 0 ;

3 2 0s e t b n k

3 3 0

3 4 0

3 5 0

3 6 0 ;

3 7 0t o g g l e

3 8 0

3 9 0t o g1

4 0 0

4 1 0

4 2 0

4 3 0

4 4 0

4 5 0

4 6 0 ;

4 7 0r e s e t

4 8 0

4 9 0

5 0 0

5 1 0

5 2 05 3 0

5 4 0 ;

5 5 0t e s t d s k

5 6 0

5 7 0

5 8 0

5 9 0

6 0 0

6 1 0

6 2 0t e s 1

j m p

=

I d a

s t a

r t s

=

I d a

b i tb e q

I d a

e o r

s t a

I d a

r t s

=

s e i

b i t

I d a

e o r

s t ar t s

=

s t a

j s r

I d a

s t a

j s r

I d y

j s r

r e a d d a t a

*

# 0

m m u

*

# 8

d i c rt o g 1

c l o c k

# $ 1 0

c l o c k

d d r

*

d i c r

c l o c k

# $ 1 0

c l o c k

p n t r

s e t b n k

# > c o n f

p n t r+ 1

r e s e t

# 0

t o g g l e

; b u r s tm e m o r yr e a d

; s e t t ob a n k1 5

; t o g g l ed a t al i n e

; w a i t f o ri c r

; t o g g l ec l o c k

; g e ta d a t a b y t e

; i n i tb u r s tm o d e

; t o g g l ec l o c k

; b u r s tm o d eq u e r yd i s kf o r m a t

; s a v eo f f s e ti n t of o r m a tb u f f e r

; g o t o b a n k1 5

; h i g hb y t eo f f o r m a tb u f f e r

; s t a r tb u r s tm o d e

; g e tf i r s ts t a t u sb y t e

6 3 0

6 4 0

6 5 0

6 6 0

6 7 0

6 8 0

6 9 0t e s 2

7 0 0

7 1 0

7 2 07 3 0

7 4 0e x i t t e s

7 5 0

7 6 0

7 7 0 ;

s t a

a n d

b n e

i n y

c p y

b n e

j s r

s t a

i n y

c p yb n e

t =

c l i

r t s

7 8 0r e a d d a t a=

7 9 0

8 0 0

8 1 0

8 2 0

8 3 0

8 4 0

8 5 08 6 0

8 7 0r e a l

8 8 0

8 9 0

9 0 0

9 1 0

9 2 0

9 3 0

9 4 0

s t a

I d a

s t a

I d a

s t a

j s r

j s r

I d y

j s r

s t a

i n y

b n e

d e c

b e q

i n c

j m p

( p n t r ) , y

# $ 0 e

e x i t t e s t

# 2

t e s 1

t o g g l e

( p n t r ) , y

# 7t e s 2

*

s i z e

# < d a t a

p n t r

# > d a t a

p n t r

s e t b n k

r e s e t

# 0

t o g g l e

( p n t r ) , y

r e a l

s i z e

e x i t t e s t

p n t r+ 1

r e a l

; a n ds t a s hi t

; c h e c kf o re r r o r s

; g e tn e x ts t a t u sb y t e

; g e td a t ab y t e

; a n ds a v ei t

; c h e c k f o r a l ld o n e

; e x i td i s kt e s tr o u t i n e

; r e s t o r ei n t e r r u p t s

; b u r s tm o d em e m o r yr e a d

; n u m b e ro f p a g e st o r e a d

; s e tp o i n t e rt o d a t ab u f f e r

; s e tb a n kt o 1 5

; s t a r tb u r s tm o d e

; g e td a t ab y t e

; a n ds a v ei t

; e n do f p a g e ?

; l a s tp a g e ?

; g og e tn e x tp a g e

9 5 0 ;

T h eT r a n s a c t o r 3 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 35: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 35/84

C P / Ma n dt h e

1 5 8 1D i s kD r i v e

M . G a r a m s z e

T o r o n t o ,O n t a r i

U p g r a d ey o u rC 1 2 8C P / Mf o rt h en e wC B Md r i v e s

O l d e rv e r s i o n so f C - 1 2 8C P / Mw i l ln o tf u l l ys u p p o r tt h e n e w

1 5 8 1d i s kd r i v e .T h i si s a p i t yb e c a u s et h el a r g ec a p a c i t yo f t h e

1 5 8 1c o m b i n e dw i t hi t sh i g hs p e e dm a k ei t a n i d e a lC P / Md r i v e .

O f c o u r s e ,y o uc a nm a i li n t h ec o u p o n w h i c hc o m e sw i t ht h e

1 5 8 1a l o n g w i t hs o m eo f y o u r h a r d e a r n e dc a s ha n dg e t y e t

a n o t h e r" u p g r a d e "v e r s i o no f C P / Mw h i c hd o e ss u p p o r tt h e

1 5 8 1 . 1a l r e a d yh a v et h r e ed i f f e r e n tv e r s i o n so f C P / Mf o rm yC -

1 2 8( t h eo r i g i n a lp l u st w o" u p g r a d e s " ) s ow h yd o I n e e da n o t h e ro n ej u s tt o u s et h e1 5 8 1 ?T h es h o r ta n s w e ri s t h a tI d o n o t .

T h ef i r s tp r o b l e mi n v o l v e s c r e a t i n ga 1 5 8 1C P / Mf o r m a td i s k .

T h i si s e a s i e s tt o d o w i t ht h eC - 1 2 8i n n a t i v em o d eu s i n gt h e

b u r s tm o d ef o r m a tc o m m a n ds i n c e o l d e r v e r s i o n so f C P / M ' s

F 0 R M A T . C O Mu t i l i t yd o n o tw o r kp r o p e r l y w i t ht h e1 5 8 1 .T h e

f o l l o w i n gc o m m a n ds t r i n gc a nb e u s e d ,a s s u m i n gy o u r1 5 8 1i s

d e v i c e9 :

o p e n 1 5 , 9 , 1 5

p r i n t # 1 5 , ' u O "+ c h r $ ( 1 3 4 )+ c h r $ ( 2 )+ c h r $ ( 7 9 )+ c h r $ ( 1 0 )

+ c h r $ ( O )+ c h r $ ( 2 2 9 )+ c h r $ ( 1 )c l o s e1 5

T h i sw i l lf o r m a tt h e d i s ki d e n t i c a lt o a 1 5 8 1D O Sd i s kp h y s i c a l

s t r u c t u r e( i . e .5 1 2b y t e / s e c t o r ,1 0 s e c t o r st r a c k )b u tw i t h o u tt h e

d i r e c t o r y ,B A M ,e t c .a n df i l li t w i t hC P / Mb l a n kd i s k b y t e s( $ e 5

o r d e c2 2 9 ) .

N e x t ,w i t ha f e ws i m p l em o d i f i c a t i o n st o t h eC P M+ . S Y Sf i l e ,y o u

c a n t a k ef u l la d v a n t a g eo f t h e c a p a c i t yo f t h e 1 5 8 1 w i t h o u t

f o r k i n g o u tf o rt h el a t e s tu p g r a d ed i s k .Y o uc a ns t i l lu s et h e d i s k

f o r m a t t e db y t h em e t h o da b o v ew i t hC P / Mi f y o u d on o tm a k e

t h e f o l l o w i n gm o d s ,b u ty o uw i l lo n l yb e a b l et o f i l l i t h a l ff u l l .T h i sm o dw i l ln o ta l l o wy o ut o b o o tC P / Mf r o mt h e1 5 8 1 ,b u ti t

w i l la l l o wy o uu s et h e1 5 8 1o n c eC P / Mh a sb e e nb o o t e d f r o ma

1 5 7 1o r 1 5 4 1 .( I nm yp r e s e n ts e tu p , t h e1 5 7 1i s d e v i c e 8a n dt h e

1 5 8 1i s d e v i c e9 . C P / Mc a no n l yb e b o o t e d f r o md e v i c e8

a n y w a y ) .A n o t ei n C o m m o d o r e ' sf a v o ri s t h a tt h e C P / Mu p

g r a d ew i l la l l o wy o ut o b o o tf r o mt h e1 5 8 1i f i t i s c o n n e c t e da s

d e v i c e8 .

T h ep r o c e d u r ei n v o l v e sc h a n g i n ga f e wb y t e si n p a r to f t h e

C P M+ . S Y Sf i l ek n o wa s t h e" d i s kp a r a m e t e rb l o c kt a b l e " .T h i s

t a b l e ,w h i c hi s d e s c r i b e di n d e t a i li n t h e" C P / M3 S y s t e mG u i d e "

u n d e rs e c t i o n 3 . 3B I O SD a t aS t r u c t u r e so n p a g e s4 0 t o 4 4 ,

c o n t a i n st h ed a t af o rt h ep h y s i c a lc h a r a c t e r i s t i c so f t h eM F Md i s k

f o r m a t s s u p p o r t e db y C - 1 2 8C P / M .T h el o c a t i o no f t h et a b l ei n

t h eC P M+ . S Y Sf i l ed e p e n d s o nt h e v e r s i o no fC P / Mt h a ty o ua r e

u s i n g .T h ei n s t r u c t i o n sf o ra l lt h r e e c u r r e n t v e r s i o n s a r

b e l o w .T h el o c a t i o n sa r es u m m a r i z e di n T a b l e1 a n dr e f e r e n c e

i n t h et e x t .

B e f o r ec o n t i n u i n g ,y o uw i l ln e e da f o r m a t t e dC P / Md i s k( C - 1 2 8

1 5 4 1s i n g l eo r 1 5 7 1d o u b l es i d e d f o r m a t )c o n t a i n i n gt h eC P / Ms y s t e mf i l e s( C P M+ . S Y Sa n dC C P . C O M )a n dt h eu t i l i t yS I D . C O

( o rt h e. o l d e rD D T . C 0 Mo r e q u i v a l e n td e b u g g e ru t i l i t y ) .Y o uc a n

a l s oi n c l u d ea c o p yo f S H O W . C O Mt o c h e c kt h e r e s u l t sa f t e r

w a r d s .T h eS I D . C O Mp r o g r a mr e s i d e so n t h eC P / Ma d d i t i o n a

u t i l i t i e sd i s kt h a tc o m e sw i t ht h e D i g i t a lR e s e a r c hC P / Mp l u s

d o c u m e n t a t i o n .S e v e r a lo t h e rp u b l i cd o m a i nd e b u g g e r sa r ea l s o

a v a i l a b l ei f y o ud o n o th a v eS I D .

N O T E :U S EA B A C KU PW O R KD I S K .

D ON O TD OT H I SW I T HY O U RO R I G I N A LS Y S T E M

D I S KB E C A U S EI T W I L LM A K EP E R M A N E N T

C H A N G E ST OT H EO P E R A T I N GS Y S T E M .

A f t e rb o o t i n gu p C P / M ,n o t et h e v e r s i o n d a t ep r i n t e do n t h e

s c r e e n .T h i sw i l lb e u s e da s a r e f e r e n c ef o r t h e a d d r e s s e si n

T a b l e1 . I n s e r ty o u rw o r kd i s ka n dt y p ei n :

s i dc p m+ . s y s < r e t u r n >

N o t et h a tf o rc l a r i t y ,I w i l lu s el o w e r c a s el e t t e r st o i n d i c a t ei t e m s

t h a ty o ut y p ei n a n dU P P E R C A S Ef o r p r o m p t sm a d eb y t h e

c o m p u t e r .

A f t e ra f e wm o m e n t s ,t h e f o l l o w i n gs t a t u sm e s s a g ew i l lb ed i s p l a y e d :

C P / M3 S I D- V e r s i o nx . x

N E X TM S Z EP C E N D

z z z z z z z z0 1 0 0C E F F

#

w h e r ez z z zi s a h e x a d e c i m a ln u m b e rb a s e do n t h ev e r s i o nd a t e ,

a s l i s t e d i nT a b l e1 . J o tt h i sd o w nf o rf u t u r er e f e r e n c e a si t w i l lb e

n e e d e dw h e ns a v i n gt h e c h a n g e s .T h e" # " s y m b o li s S I D ' s

c o m m a n dp r o m p t .

N o ww ea r er e a d yt o m a k et h ec h a n g e s .T h ep h y s i c a lf o r m a to f a1 5 8 1d i s ki s i d e n t i c a lt o t h a to f t h eE P S O NQ X - 1 0( 1 0s e c t o r s

T h eT r a n s a c t o r 3 3 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 36: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 36/84

p e rt r a c k ,5 1 2b y t e sp e rs e c t o r ,2 s i d e s ) .T h eo n l yd i f f e r e n c ei s i n

t h en u m b e ro f t r a c k sp e rs i d e( 8 0f o rt h e1 5 8 1c o m p a r e dt o 4 0

f o rt h eE P S O N ) .I t m a k e st h i n g se a s i e rt o s t a r tw i t ht h eE P S O N

p a r a m e t e r sa n d c h a n g et h e ma b i t r a t h e rt h a nc r e a t ea w h o l e

n e we n t r y .( T h em o d i f i c a t i o n sw i l ls t i l lp e r m i tf u l lr e a dc o m p a t i

b i l i t yw i t ht h eE P S O Nd i s k sa n dn e a r l yf u l lw r i t e c o m p a t i b i l i t y

o n t h e 1 5 7 1 .T h ei n c o m p a t i b i l i t yi n w r i t i n gi s o n l yt h a tt h e

o p e r a t i n gs y s t e mm a ya t t e m p tt o w r i t em o r et o t h eE P S O Nd i s k

t h a ni t c a nh o l d ,t h u s c a u s i n ga d i s k e r r o ri f y o ut r yt o w r i t et o a n

a l m o s tf u l ld i s k ) .

W h e nS I Dp r o m p t sw i t h :

s n n n n

n n n n 4 5

T y p ei n a q u o t e( " )f o l l o w e db y 3 s p a c e s t h e n 1 5 8 1a n d3 m o r e

s p a c e sa n da r e t u r n .A t t h e n e x t p r o m p t , t y p ei n a p e r i o dt o

r e t u r nt o t h em a i nS I Dp r o m p t .T y p ei n : d y y y y < r e t u r n >a g a i n

t o c h e c k y o u rc h a n g e s a n dt h e f o l l o w i n gs h o u l db e d i s p l a y e d :

N e x tt y p ei n :y y y y : 5 0 0 0 0 4O F0 0 8 60 1 7 F 0 0 C O0 0 2 0 0 0 0 20 0 0 2 P .

y ym m :0 3 0 A2 0 2 0 2 03 1 3 5 3 8 3 1 2 0 2 0 2 04 9 A 50 0 8 1 1 5 8 1

d y y y y< r e t u r n >

w h e r e y y y yi s t a k e nf r o mT a b l e1 . T h i si s S I D ' sd o r d i s p l a y

m e m o r yc o m m a n d .N o t et h a ti n t h i s ,a n da l l o t h e rS I Dc o m

m a n d s ,t h e r ei s n o s p a c eb e t w e e nt h ec o m m a n dl e t t e ra n dt h e

c o m m a n dp a r a m e t e r s .F o re x a m p l e ,d y y y y w o u l dp r o d u c ea n

e r r o rp r o m p t .

S I Dw i l lr e s p o n dw i t h ad i s p l a ys i m i l a rt o :

y y y y : 5 0 0 00 4 O F0 1 B D 0 07 F 0 0C O0 0 2 00 0 0 20 0

y y m m :0 3 0 A4 5 7 07 3 6 F 6 E 2 0 5 1 5 8 3 1 3 0 4 9 A 50 0

T h ef i n a ls t e pi s t o s a v et h ec h a n g e s .T h i si s d o n ew i t hS I D ' sw o r

w r i t ec o m m a n d :

w c p m+ . s y s 0 1 0 0z z z z < r e t u r n >

O n c et h i sh a sb e e nd o n e ,y o u rn e wC P / Ms y s t e mi s r e a d yf o r

a c t i o n .R e - b o o tt h ec o m p u t e r( y o un e e dt o b o o tt h e m o d i f i e d

C P / Ms y s t e m )a n dt u r no n y o u r1 5 8 1a s d r i v eb : ( d e v i c e9 ) .Y o u

c a nn o wP I Ps o m ef i l e st o a

f o r m a t t e d1 5 8 1d i s k( a so u t

l i n e da b o v e )a n du s ei t a t w i l l

f o r a l l f i l es t o r a g e .Y o uc a n

0 2 P

8 1 . . E p s o n Q X 1 0 I. . .

p l u ss o m em o r er o w so f s i m i l a rh e x a d e c i m a ln u m b e r sf o l l o w e d

b y t h e" * "p r o m p t .T h en e x ts t e pi s t o c h a n g es o m eo f t h eb y t e s .

T h eo n e st h a ta r ec h a n g e da r er e f e r r e dt o i n D i g i t a lR e s e a r c h ' s

d o c u m e n t a t i o na s E X M( e x t e n tm a s k- 1 b y t e ) ,a n dD S M( t o t a l

d r i v e s t o r a g e- 2 b y t e w o r d ) .T h e s ea r e t h et w op a r a m e t e r s

w h i c ht e l lt h es y s t e mh o w m u c hd a t ai t c a ns t o r eo n a d i s k .T h e

c h a n g ei s d o n ew i t hS I D ' ss o r s e tm e m o r yc o m m a n d .T y p ei n :

s x x x x< r e t u r n >

w h e r e x x x xi s t a k e nf r o mT a b l e1 . S I Dw i l lr e s p o n dw i t h :

x x x x0 1

T h e0 1 i s t h e c u r r e n tv a l u eo f t h eb y t ea t t h i sl o c a t i o n .C h a n g ei t

t o t h e d e s i r e dv a l u eb y t y p i n gi n 0 0 f o l l o w e db y r e t u r n .S I Dw i l l

t h e np r o m p tf o rt h en e x tb y t e :

x x x 1B D

T y p ei n 8 6 f o l l o w e db y r e t u r n .S I Dw i l lt h e np r o m p tf o rt h en e x t

b y t e :

x x x 20 0

C h a n g et h i sb y t y p i n gi n a 0 1 f o l l o w e db y r e t u r n .T h a tc o m

p l e t e st h em a j o rc h a n g e s .A t t h en e x tp r o m p t

x x x 37 F

E n t e ra p e r i o d" . "f o l l o w e db y r e t u r n .T h i s s h o u l db r i n gb a c kt h e

m a i nS I Dp r o m p t" * " .I f y o u w a n tt o c h a n g et h e d i s kt y p en a m ef r o mE p s o nQ X 1 0t o s a y 1 5 8 1 , u s et h es c o m m a n da g a i n :

c h e c kt h e c a p a c i t yo f t h e

d r i v eb y u s i n gt h eS H O W . C O Mu t i l i t y :

s h o wb :

w i l ld i s p l a y t h ea m o u n to f s p a c ec u r r e n t l y a v a i l a b l eo n t h e1 5 8 1 .

I f i t d o e sn o t g i v es o m e t h i n gl i k e8 0 0 kr e a dw r i t es p a c ef r e ew i t h

a f o r m a t t e db l a n kd i s k ,t h e ny o u rc h a n g e sm a yh a v eg o n ea w r y .

D o u b l ec h e c kt h ec h a n g e so u t l i n e da b o v e a n dt r y a g a i n .

T h ep r o c e d u r eo u t l i n e da b o v ec a na l s ob e d o n eu s i n gt h eR A M

d i s k( d r i v em : )a s t h ew o r k i n gd r i v ei f y o uh a v ea 1 7 5 0R A M

e x p a n d e r .I n t h i sc a s e ,y o u w o u l dP I Pt h e r e q u i r e df i l e st o t h e

R A Md i s k ,d o t h e m o d i f i c a t i o n sa n dP I Pt h e mb a c ka g a i nt o y o u r

w o r kd i s k .T h e s a m e m e t h o dc a n b eu s e dt o a l t e rt h e d i s k

p a r a m e t e rt a b l et o s u p p o r t o t h e rC P / Md i s kf o r m a t so n t h e

1 5 7 1 ,s u c ha s T e l e v i d e o ,X e r o x ,D E C ,e t c w h i c ha r e n o tn o r

m a l l y s u p p o r t e db y C - 1 2 8C P / M .I n t h i sc a s e ,I w o u l ds u g g e s t

t h a ty o uc o n s u l t t h ee x p l a n a t i o no f t h et a b l ep a r a m e t e r si n t h e

C P / MS y s t e mG u i d e .Y o ua l s on e e dt o h a v ea t h o r o u g hu n d e rs t a n d i n go f t h e d i s kf o r m a tt h a ty o uw i s ht o i m p l e m e n t .

T a b l e1 : S u m m a r yo f C P M+ . S Y Sf i l ea d d r e s s e s

P a r a m e t e r *

z z z z

y y y y

x x x x

n n n n

N o t e :

V a l u e sb y C P / MV e r s i o nD a t e

1 A u g8 5

5 d 0 0

1 4 0 0

1 4 0 4

1 4 1 2

R e f e rt o t e x t f o r

6 D e c8 5

6 4 0 0

2 1 6 1

2 1 6 5

2 1 7 3

8 D e c8 5

6 4 0 0

2 1 6 1

2 1 6 5

2 1 7 3

e x p l a n a t i o no f p a r a m e t e r s

T h eT r a n s a c t o r 3 4 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 37: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 37/84

P r o g r a m m i n g

T h e1 5 4 1

F r a n kD i G i o i

S t o n eM o u n t a i n ,G A .

. . . N o w , e v e nt h ew e e k e n dh a c k e rc a ne n j o yt h et h r i l l sa n d

c h i l l so f b e i n gi n c o m p l e t ec o n t r o lo f t h ed i s kd r i v e .. .

T h e r ew a sa t i m ew h e nt h ei d e ao f p r o g r a m m i n gt h eC o m m o

d o r e 1 5 4 1d i s kd r i v ew a sl i t t l em o r et h a na w h i m s i c a ld e s i r eo f

l a t en i g h t ,d i e - h a r dh a c k e r s . B u tn o w ,p r o g r a m sr a n g i n gf r o m

w o r dp r o c e s s o r st o n e wo p e r a t i n gs y s t e m sa r eu t i l i z i n gt h ef r e e

R A Mi n t h e1 5 4 1t o r e p r o g r a mt h ed r i v e ,a l l o w i n gi t t o p e r f o r m

t r i c k sn o o n ep r e v i o u s l yw o u l dh a v ed r e a m e dp o s s i b l e .A w e a l t h

o f i n f o r m a t i o nc o n c e r n i n gt h e i n n e rw o r k i n g so f t h e 1 5 4 1h a s

b e c o m ea v a i l a b l et o t h ep u b l i c .N o w , e v e nt h ew e e k e n dh a c k e r

c a ne n j o yt h et h r i l l sa n dc h i l l s o fb e i n gi n c o m p l e t ec o n t r o lo f t h e

d i s kd r i v e .T h i sa r t i c l ei s i n t e n d e dp r i m a r i l yf o rt h o s ew h oj u s t

w a n tt h ec h a n c et o t r ys o m ee a s y - t o - t y p e - i ne x p e r i m e n t sw i t h

t h e i r1 5 4 1d i s kd r i v e s .I a m ,h o w e v e r ,i n c l u d i n gs o m ed e t a i l e d

t e c h n i c a li n f o r m a t i o n s ot h a tt h o s e r e a d e r sw h od e s i r et o e x p e r i

m e n tb e y o n dw h a ti s p r e s e n t e di n t h i s a r t i c l em a yb e b e t t e r

e q u i p p e dt o d o s o . I nt h e f o l l o w i n gp a r a g r a p h s1 w i l lp r o v i d e

b r i e fc o v e r a g eo f t h eJ o bQ u e u e ,t h eM - Rc o m m a n d ,t h eM - W

c o m m a n da n dt h eM - Ec o m m a n d .W ew i l lw r a pt h i n g su p w i t h

a n e x a m p l e m a c h i n el a n g u a g ep r o g r a m y o u c a ne x e c u t ei n y o u r

1 5 4 1( i fy o ud a r e ! ) .

T h eM e m o r y C o m m a n d s

W ew i l l s t a r to u r a d v e n t u r ew i t ht h em e m o r yc o m m a n d s .E a c h

o f t h em e m o r y c o m m a n d s( i nf a c t ,A L Lo f o u rc o m m u n i c a t i o n s

w i t ht h e d r i v e )w i l lb e s e n to v e rt h e e r r o rc h a n n e l* 1 5( I ' l l

a l w a y su s ef i l en u m b e r1 5 i n m ye x a m p l e s ) .T h e s ec o m m a n d s

a r ea l lc o v e r e di n y o u r1 5 4 1m a n u a l ,b u tw ew i l lf o c u sh e r eo n

t h e i ru s ei n p r o g r a m m i n gt h e d i s kd r i v e .L e tu s b e g i n w i t ht h e

M e m o r y - R e a d( M - R )c o m m a n d .T h eM - Rc o m m a n da l l o w sy o u

t o p e e ka t t h e c o n t e n t so f t h ed i s kd r i v e ' s i n t e r n a lm e m o r y-

b o t hR A Ma n dR O M .T ou s et h i sc o m m a n dy o us i m p l yg i v e t h e

a d d r e s s( i nl o / h if o r m a t )o f t h ef i r s tb y t ey o uw i s ht o r e a d .I f y o u

w a n tt o r e a dm o r et h a no n eb y t e ,t h ea d d r e s sm u s tb e f o l l o w e d

b y t h e n u m b e ro f c o n s e c u t i v eb y t e s ( u pt o 2 5 5 )y o uw i s ht o

r e c e i v e .I f y o ua r ew o r k i n gf r o mB A S I Ct h e s ep a r a m e t e r sm u s t

b e s e n t a sc h a r a c t e rc o d e s .T h eg e n e r a lf o r m a to f t h ec o m m a n d

i s

P R I N T # 1 5 , " M - R " C H R $ ( l o ) C H R $ ( h i ) C H R $ ( n )

p r o t e c t t h ep r o g r a md i s ko r t o u n w r i t e - p r o t e c tt h e d a t ad i s k .

T h er o u t i n ew o r k sb y e x a m i n i n gb i t4 o f l o c a t i o n$ 1 C O O( 7 1 6 8 )

i n y o u rd r i v e ' sm e m o r y .T h i sl o c a t i o ni s t h em a i nc o n t r o lr e g i s t e r

f o rt h e1 5 4 1 .

4 0 0 O P E N 1 5 , 8 , 1 5 , " M - R "+ C H R $ ( 0 )+ C H R $ ( 2 8 )

4 1 0G E T # 1 5 , A $ : A= A S C ( A $+ C H R $ ( 0 ) ) : C L O S

4 2 0W P= A A N D1 6 : R E T U R N

I f W P= 0 t h e nt h e d i s ki s w r i t e p r o t e c t e d .

T h eM e m o r y - W r i t e( M - W )c o m m a n di s u s e dt o p o k ed a t ai n t o

t h e1 5 4 1 ' sR A M .T h i sc o m m a n di s u s e dt o s e tv a l u e si n v a r i o u s

m e m o r yl o c a t i o n sa n dt o t r a n s f e rp r o g r a m sf r o mt h eC 6 4t o t h e

1 5 4 1 .T h eg e n e r a l f o r m a to f t h ec o m m a n di s

P R I N T # 1 5 , " M - W " C H R $ ( l o ) C H R $ ( h i

A s y o uc a ns e e ,t h i sc o m m a n du s e st h es a m ep a r a m e t e r sa s t h e

M - Rc o m m a n d( y o um a yN O To m i tt h e l e n g t hp a r a m e t e

e x c e p ty o ua d d i t i o n a l l y p l a c e t h e d a t at o b e s e n to n t h e c o m

m a n dl i n e .T h ed a t am a yb e a s i n g l ec h a r a c t e rc o d eo r as t r i n go f

u p t o 3 4 c h a r a c t e r s .T h ef o l l o w i n g r o u t i n ew i l lt u r n t h e 1 5 4

m o t o ro n b y R E A D I N Gt h ec o n t e n t so f t h em a i nc o n t r o lr e g i s t e r

S E T T I N GB I T2 a n dW R I T I N Gt h e r e s u l tb a c kt o t h e c o n t r o l

r e g i s t e r .T h em o t o ri s t u r n e do f fa g a i nb y c l e a r i n gb i t 2 .

T u r nm o t o ro n :

1 0 O P E N 1 5 , 8 , 1 5 , " M - R l l+ C H R $ ( 0 )+ C H R $ ( 2 8 )

2 0 G E T # 1 5 , A $ : A =A S C ( A $+ C H R $ ( 0 ) )

3 0 X= A O R 4

4 0 P R I N T # 1 5 , " M - W " C H R $ ( 0 ) C H R $ (

5 0 C L O S E 1 5

T o t u r n t h em o t o ro f f ,r e p l a c el i n e3 0 w i t h :

3 0 X= A A N D 2 5 1

O n c ey o ui s s u et h ec o m m a n dt o t h ed r i v e ,y o uc a nr e a dt h e Y o um a yh a v en o t i c e dt h a tb o t ho f t h er o u t i n e sa b o v ew o r kb yr e s u l to v e rt h e e r r o rc h a n n e l ,v i aG E T # ,a s c h a r a c t e rd a t a .H e r e

i s a u s e f u ls u b r o u t i n ew h i c hu t i l i z e st h eM - Rc o m m a n dt o t e l l

w e a t h e ro r n o ta d i s ki s w r i t e p r o t e c t e d .Y o um i g h t u s et h i s

r o u t i n ei n y o u ro w np r o g r a m si n o r d e rt o w a r nt h eu s e rt o w r i t e -

r e a d i n go r c h a n g i n ga b i ti n t h e c o n t r o lr e g i s t e rl o c a t e da t $ 1 C O O

i n t h e 1 5 4 1 . S i n c et h i si s a f a i r l yi m p o r t a n tr e g i s t e r1 w i l l

i n t e r r u p tm y s e l ff o ra m o m e n tt o l i s tw h a te a c hb i ti n t h er e g i s t e r

d o e s .

T h eT r a n s a c t o r 3 5 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 38: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 38/84

R E Ga t $ 1C O O B I T S :7 6 5 4 3 2 1 0

B I T 0 -B i t s0 a n d1 a r eu s e dt o m o v et h ed r i v eh e a d

B I T1 - S e ee x a m p l e p r o g r a ma t e n do f a r t i c l e .

B I T2 - T u r nm o t o ro n / o f f

B I T3 - T u r nr e dl i g h to n / o f f

B I T4 - W r i t e - p r o t e c ti n d i c a t o r

B I T5 - R e c o r d i n gd e n s i t yb i t 1

B I T6 - R e c o r d i n gd e n s i t yb i t2

B I T7 - S y n cb y t ei n d i c a t o r

O k a y .. . b a c kt o t h em e m o r yc o m m a n d s :

T h eM E M O R YE X E C U T E( M - E )c o m m a n di s l i k ea S Y Sc o m

m a n df o ra n yd i s kd r i v e r o u t i n ei n R O Mo r R A M .S i m p l yg i v e t h e

a d d r e s so f t h e r o u t i n ei n L O / H If o r m a t .T h ef o l l o w i n ge x a m p l e

w i l le x e c u t et h eR O Mr o u t i n ew h i c hi n i t i a l i z e st h ed i s k e t t ei n t h e

d r i v e .I t h a st h es a m ee f f e c ta s t y p i n gO P E N1 5 , 8 , 1 5 , " I " .

1 0 O P E N 1 5 , 8 , 1 5 : P R I N T # 1 5 , " M - E " C H R $ ( 5 ) C H R $ ( 2 0 8 )

: C L O S E 1 5

D i g g i n gD e e p e r

T h em e m o r y c o m m a n d sa r e n i c ef o rl i t t l et r i c k ss u c ha s t h eo n e s

i n t h e e x a m p l e p r o g r a m sa b o v e .W h e ni t c o m e st o r u n n i n g

" r e a l "j o b si n y o u rd r i v e ,h o w e v e r ,i t i s o f t e nc o n v e n i e n tt o u s e

t h ej o bq u e u e .S o m ep e o p l et e n dt o b e s c a r e do f fb y t h em e n t i o n

o f t h ej o bq u e u e ,b u tl e tm et r yt o e x p l a i nh o wj o b sa r ee x e c u t e d

i n t h e 1 5 4 1a n d y o uw i l lt h e ns e et h a tu s i n gt h ej o bq u e u ei s

r e a l l yj u s ta s h o r t c u tt o p r o g r a m m i n gt h ed i s kd r i v e .

A l l o wm e t o p r e s e n tt h r e es h o r tp a r a g r a p h so f b a c k g r o u n d

m a t e r i a lb e f o r ew ej u m pi n t ou s i n gt h ej o bq u e u e .

T h e6 5 0 2i n y o u rd i s kd r i v eh a sa s p l i tp e r s o n a l i t y .P a r to f t h e

t i m ei t i s a c t i n g a st h e i n t e r f a c ep r o c e s s o r( I P )a n dp a r to f t h e

t i m ei t i s a c t i n g a s t h e f l o p p y d i s kc o n t r o l l e r( F D C ) .F o r t h es a k e

o f b r e v i t y ,I w i l lj u s tr e f e r t ot h e I Pa n dF D Ca s t h o u g ht h e yw e r e

t w oc o m p l e t e l yd i f f e r e n tp r o c e s s o r sr u n n i n ga t t h es a m et i m e ,

s i n c et h i si s t h ei l l u s i o nt h a tt h ed e s i g n e r so f t h e1 5 4 1i n t e n d e d

t o c r e a t e .{ I n f a c t ,i n e a r l i e rC o m m o d o r ed u a ld r i v e sl i k et h e

4 0 4 0a n d8 0 5 0 ,t h e r ew e r et w os e p a r a t ep r o c e s s o r s- t h e1 5 4 1' s

D O Si s c l o s e l yb a s e d o nt h eD O Sf r o mt h e e a r l yd r i v e s .- E d . )

T h ei n t e r f a c ep r o c e s s o ri s p r i m a r i l y r e s p o n s i b l ef o rt h o s et a s k s

h a v i n gt o d o w i t hc o m m u n i c a t i o nb e t w e e nt h ec o m p u t e ra n d

t h e d i s kd r i v e ,a n db e t w e e nt h ed i s k d r i v ea n dt h eu s e r . I no t h e r

w o r d s ,i t i s r e s p o n s i b l ef o rp a r s i n gd i s kc o m m a n d s ,t r a n s f e r r i n g

d a t a o v e rt h es e r i a lb u sa n do p e r a t i n gt h e r e dl i g h to n t h ef r o n to f

y o u rd r i v e . I na d d i t i o nt o i t sc o m m u n i c a t i o nj o b s ,t h eI P i s a l s o

r e s p o n s i b l ef o rt h e" s o f t " s i d e o ff i l em a n a g e m e n t( i e .a l l o c a t i n g

b u f f e r s ,o p e n i n gf i l e s ,k e e p i n gt r a c ko f t h eB A M ,e t c ) .

T h ef l o p p yd i s kc o n t r o l l e r ,o n t h eo t h e rh a n d , c o n c e r n si t s e l f

p r i m a r i l yw i t h t h o s et a s k st h a ta r ed i r e c t l y r e l a t e dt o r e a d i n go r

w r i t i n gt o t h ed i s k ,o r w h i c hd i r e c t l yc o n t r o l t h eh a r d w a r eo f t h e

d r i v e .T h e s et a s k s i n c l u d em o v i n gt h e d r i v eh e a d ,c o d i n g /

d e c o d i n gG C Rd a t a ,r e a d i n ga n dw r i t i n gG C Rd a t af r o m / t ot h e

d i s ks u r f a c e ,f o r m a t t i n ga d i s k e t t ea n dv a r i o u s o t h e rh a r d w a r

r e l a t e dt a s k s .( T e c h n i c a ln o t e :G C Rs t a n d sf o r G r o u pC o d e d

R e c o r d i n g .A l l d a t ai s c o n v e r t e dt o G C Rf o r m a t b e f o r eb e i n g

w r i t t e nt o t h e d i s ks u r f a c e .T h eG C Rc o d i n gs c h e m ei n s u r e st h a t

n o d a t aw i l le v e rp r o d u c eb i tp a t t e r n sc a p a b l eo f c o n f u s i n gt h e

d i s kh a r d w a r e ) .

T h eJ o bQ u e u e

D o e si t s o u n da s t h o u g ht h eF D Cr o u t i n e sm i g h tb e c o m p l e xo r

d i f f i c u l tt o u s e ?W e l l ,f o rt h em o s tp a r t ,t h e ya r e .F o r t u n a t e l yf o r

u s , t h e r ei s a n e a s yw a yt o g e ta t t h eF D Cr o u t i n e sa n dt h a ti s

t h r o u g ht h eJ O BQ U E U E .

A b o u t1 0 0t i m e sp e rs e c o n d ,t h eF D Cs c a n st h e j o bq u e u et o s e e

i f t h e r ei s a n yw o r kf o r i t t o d o . W h e ny o ug i v e t h e d r i v a

c o m m a n d ,t h eI P p a r s e si t a n db r e a k si t u p i n t oa s e r i e s o fJ O B S .

I t d r o p st h ej o b si n t ot h ej o bq u e u e a n dt h eF D Ce x e c u t e st h e m .

B o s s i n gt h eF D Ca r o u n di s a s e a s ya s s i m p l yd r o p p i n ga n u m b e r

i n t ot h ej o bq u e u e .H e r e ' sw h a ty o u n e e dt o k n o w :

T h eJ O BQ U E U Ei s s i m p l yl o c a t i o n s$ 0 0t o $ 0 5i n y o u rd i s k

d r i v e ' sz e r op a g em e m o r y .W ew i l lo n l yc o n c e r no u r s e l v e sw i t h

t h e f i r s tf o u r p o s i t i o n s( $ 0 0t o $ 0 3 ) .A s s o c i a t e d w i t he a c h

p o s i t i o ni n t h e j o bq u e u ea r et w ob y t e st h a tt e l lt h eF D Cw h i c h

t r a c ka n ds e c t o rt h ej o bs h o u l da c to n .A l s oa s s o c i a t e dw i t he a c h

o f t h ef i r s tf o u r p o s i t i o n si n t h e j o bq u e u ei s a d a t ab u f f e r t h a ti s t o

b e u s e db y t h ej o b .I t h i n kn o ww o u l db e a g o o dt i m ef o ra t a b l e :

J o bQ u e u e

P o s i t i o n

$ 0 0 0 0$ 0 0 0 1

$ 0 0 0 2

$ 0 0 0 3

L o c a t i o no f

T R / S EI n f o

L o c a t i o no f

D a t aB u f f e r

$ 0 0 0 6 / $ 0 0 0 7 $ 0 3 0 0 - $ 0 3 $ 0 0 0 8 / $ 0 0 0 9$ 0 4 0 0 - $ 0 4 F F

$ 0 0 0 A / $ 0 0 0 B$ 0 5 0 0 - $ 0 5 F F

$ 0 0 0 C / $ 0 0 0 D$ 0 6 0 0 - $ 0 6 F F

T h e r ea r eo n l ys e v e nj o bc o d e st o c h o o s ef r o mw h e nu s i n gt h e

j o bq u e u e .

H E XC o d e

$ 8 0

$ 9 0

$ A 0

$ B 0

$ C 0

$ D 0

$ E 0

D E CC o d e

1 2 8

1 4 4

1 6 0

1 7 8

1 9 2

2 0 8

2 2 4

J o bC o d eD e s c r i p t i o n

R e a da s e c t o r

W r i t ea s e c t o r

V e r i f ya s e c t o r

S e e ka t r a c k

S l a mh e a da g a i n s te n ds t o p

J M Pt o s t a r to f b u f f e r

E x e c u t ep r o g r a mi n b u f f e r

T o u s et h ej o bq u e u ey o uj u s th a v et o m a k et h r e ed e c i s i o n s :( 1 )

W h i c hJ o bs h o u l dI r u n ?( 2 ) W h i c hb u f f e rs h o u l di t u s e ?( 3 )

W h i c ht r a c ka n ds e c t o rs h o u l di t a c tu p o n ?

I t i s i m p o r t a n tt h a ty o ur e a l i z e t h a tt h eF D Cw i l lb e g i n e x e c u t

y o u rj o bt h em o m e n ty o up l a c e t h ej o bc o d ei n t ot h eq u e u e .I t i s

t h e r e f o r ei m p o r t a n tt h a ty o up l a c e t h et r a c ka n ds e c t o ri n f o r m a

t i o n( w h e nr e q u i r e d )i n t ot h ep r o p e rp o s i t i o no f t h eT R / S Et a b l e

b e f o r ed r o p p i n ga c o d ei n t ot h ej o bq u e u e .

T h eT r a n s a c t o r 3 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 39: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 39/84

W h e nt h eF D Cf i n i s h e st h ej o by o ua s k e di t t o p e r f o r m ,i t w r i t e s

a R E T U R NC O D Ei n t h es a m ej o bq u e u ep o s i t i o nw h e r ey o ul e f t

t h e j o b c o d e .J o b c o d e sa r ea l lg r e a t e rt h a no r e q u a lt o $ 8 0( 1 2 8 )

a n dr e t u r nc o d e sa r ea l w a y sl e s st h a n$ 8 0 .T h i sd i s t i n c t i o ni s

h o wt h e F D Ct e l l sw h e t h e ra n u m b e ri n t h e q u e u ei s a j o b

r e q u e s t o r a r e t u r nc o d e .Y o uc a nu s et h e r e t u r nc o d ef o rt w o

p u r p o s e s .F i r s to f a l l ,i t t e l l sy o ut h ej o bh a s c o m p l e t e d( w h e na

n u m b e rl e s st h a n 1 2 8i s i n t h e q u e u e )a n ds e c o n d l y ,i t t e l l s

w h e t h e ro r n o tt h ej o bc o m p l e t e ds u c c e s s f u l l y .I f t h e r e t u r nc o d e

i s 1 , t h ej o bw a ss u c c e s s f u l l yc o m p l e t e d- a n yo t h e rr e t u r nc o d e

i n d i c a t e s t h a tt h ej o bw a sn o ts u c c e s s f u l .

T h em a i na d v a n t a g e( a n dd a n g e r )i n u s i n gt h ej o bq u e u ei s t h e

f a c tt h a tn o e r r o rc h e c k i n gi s d o n eo n t h et r a c ka n ds e c t o ry o u

s u p p l yi n t h eT R / S Et a b l e .T h i sm e a n st h a ty o uc a nr e a da n d

w r i t eb e y o n dt h en o r m a l3 5 t r a c k so f a d i s k e t t e .W h i l eI h a v en o t

b e e nt o o s u c c e s s f u li n m ya t t e m p t st o w r i t ed a t ab e y o n dt r a c k

3 5 ( p r o b a b l yb e c a u s eI d i d a s l o p p yj o b o f f o r m a t t i n g t h e s e

t r a c k s )I h a v eh a ds u c c e s si n R E A D I N Gd a t ab e y o n dt r a c k3 5 .

T h eB A S I C p r o g r a mc a l l e dR E A DA N YS E C T O Rf o u n da t t h e

e n do f t h i s a r t i c l e w i l la l l o wy o ut o r e a d d a t af r o ma n ys e c t o ro f a

d i s kf r o mt r a c k1 t o t r a c k4 0 . I h a v eu s e dt h i sp r o g r a mt o r e a d

" s e c r e t "d a t ao n s o m ep r o t e c t e dd i s k e t t e s .T h ep r o g r a mi s

c a p a b l eo f r e a d i n g" u n d e r "e r r o r sa n dw i l la l l o wy o ut o v i e w

d a t af r o ma n ys e c t o ro n y o u rd i s kw h e t h e rt h es e c t o rc o n t a i n s

A S C I Id a t a ,s c r e e nc o d e so r m a c h i n el a n g u a g e .T h ep r o g r a m

w i l l' h a n g ' ,h o w e v e r ,i f y o ut r yt o r e a da t r a c kt h a th a sn o tb e e n

f o r m a t t e da t a l l .

E x e c u t i n gP r o g r a m sI n T h eD r i v e

T h el a s tt o p i cI w o u l dl i k e t oc o v e ri n t h i s a r t i c l ei s n o tf o rt h e

f a i n th e a r t e d .I t c o n c e r n sa c t u a l l yp r o g r a m m i n gt h e d r i v eb e

y o n ds i m p l yu s i n gt h ej o bq u e u e .I t s h o u l db e m e n t i o n e dh e r e

t h a ta n ym i s t a k e sm a d ea t t h i s l e v e lo f p r o g r a m m i n gc o u l d

e a s i l yd e s t r o y d a t ao n a n yd i s kt h a th a p p e n st o b e i n t h e d r i v e

a n dc o u l d ,i n f a c t ,c a u s eh a r mt o y o u rd r i v ei t s e l f .

T h em a i np o w e ro f t h ej o bq u e u e ,a s m e n t i o n e de a r l i e r ,i s t h a t

y o uc a nd o n o r m a lt a s k s( r e a d i n g ,w r i t i n g ,e t c )w i t h o u tb e i n g

l i m i t e db y e r r o rc h e c k i n gr o u t i n e s .Y o ua r e s t i l ll i m i t e d ,h o w

e v e r ,t o t h es e v e nj o b sl i s t e da b o v e .I f y o u w a n tt o d o s o m e t h i n g

a b i t m o r er a d i c a l ,s u c ha s w r i t i n g an e wf o r m a t t i n gr o u t i n e ,

c r e a t i n g e x o t i c p r o t e c t i o nt e c h n i q u e sa n ds o o n , y o uw i l lf i n d

t h a tt h ej o bq u e u ed o e sn o ta f f o r dy o ut h ep o w e rt h a ty o un e e d .

Y o uw i l lh a v et o g oo n t o t h el e s s - t r a v e l l e dp a t ho f p r o g r a m m i n gt h e d i s kd r i v e .B e f o r ey o u c a n e v e nb e g i nt h i n k i n ga b o u t

p r o g r a m m i n gt h e d i s kd r i v e ,h o w e v e r ,y o un e e da c o m p l e t e

z e r o - p a g em e m o r ym a po f t h e d r i v ea n da l i s t i n go f t h eR O M s .

( T h eT r a n s a c t o rp l a n st o p u b l i s hJ i mB u t t e r f i e l d ' sc o m m e n t e d

D i s a s s e m b l yo f t h e1 5 4 1a n d1 5 7 1R O M si n b o o kf o r ma t s o m e

t i m ei n t h en e a rf u t u r e .I f y o ua r e i m p a t i e n t , t h e r e a r e s e v e r a l

o t h e rg o o d b o o k sc u r r e n t l ya v a i l a b l ea s I ' ms u r ee v e r yr e a d e ri s

a w a r e . )

A s a n e x a m p l eo f p r o g r a m m i n gt h e d i s kd r i v e ,1 w r o t ea

p r o g r a mc a l l e dD I S KD E S T R O Y E R .I c h o s et h i sp r o g r a m b e

c a u s ei t i s s i m p l e ,s h o r ta n dc a nh a r d l yf a i lt o w o r k .A st h en a m ei m p l i e s ,t h i sp r o g r a mw i l ld e s t r o yw h a t e v e rd i s kh a p p e n st o b e

i n t h e d r i v ew h e nt h e p r o g r a mi s r u n .T h ep r o g r a mw i l ln o t

p h y s i c a l l yh a r mt h ed i s k e t t eb u tw i l ls c r a m b l et h ec o n t e n t s s

b a d l yt h a tt h e d r i v el i g h tw i l ln o te v e nc o m eo n w h e ny o ut r yt o

l o a da d i r e c t o r yf r o mi t . T h i sp r o g r a mi s u s e f u lm a i n l yf o rd a t a

s e c u r i t y .I t w i l lc o m p l e t e l yp u r g ea d i s ki n a b o u t 1 0s e c o n d s

( c o m p a r e dt o a m i n u t ea n da h a l ft o f o r m a ta d i s k )a n dw i l ln o t

l e a v e at r a c eo f t h eo r i g i n a l d a t a .T h i sc a p a b i l i t yc a nb e u s e f u lf o r

d e s t r o y i n go l d d a t a d i s k s o rf o rc r e a t i n g ap r o g r a m w h i c hc a n

o n l yb e r u no n c e .A sa n e x a m p l eo f t h el a t t e r ,s u p p o s ey o uw i s h

t o h a v ea f r i e n d t r yo u t ap r o g r a my o ua r ew r i t i n g .I f y o u d on o t

w a n ty o u rf r i e n dt o b e a b l ek e e pa c o p yo f t h ep r o g r a m ,y o uc a n

h i d ed i s kd e s t r o y e ri n a n u n u s e ds e c t o ro n t h ed i s k e t t e ( s e et h e

p r o g r a mD E A T HS E C T O Ra t t h ee n do f t h i sa r t i c l e ) .A t t h ee n do f

y o u r b o o tp r o g r a my o u c a n e x e c u t ed i s kd e s t r o y e rw i t h a

B L O C K - E X E C U T Ec o m m a n da n dd i s k d e s t r o y e rw i l lw i p eo u t

t h e d i s ki n a m a t t e ro f s e c o n d s .

D i s k D e s t r o y e r

D i s k D e s t r o y e rw o r k sb y s t e p p i n gt h e d r i v eh e a d b a c kt o t r a c k

o n e a n dt h e nc a l l i n ga R O Mr o u t i n ew h i c he f f e c t i v e l yd e s t r o y s

t h et r a c k .D i s k D e s t r o y e rt h e nm o v e st h eh e a dt o t h en e x tt r a c k

a n dr e p e a t si t s e l fu n t i li t r e a c h e st h ee n d i n gt r a c k .Y o us h o u l d

n o t et h a tt h ec u r r e n tt r a c kn u m b e ri s s t o r e di n l o c a t i o n$ 2 2a n d

t h a tt h ed r i v eh e a di s m o v e db y r o t a t i n gb i t s1 a n d2 o f t h em a i n

c o n t r o lr e g i s t e r( $ 1C O O ) .

A t t h e e n do f t h i sa r t i c l ey o uw i l lf i n da B A S I Cl i s t i n gc a l l e d

D E A T HS E C T O Ra n dt h ec o m m e n t e da s s e m b l yl a n g u a g es o u r c e

c o d ef o rD i s kD e s t r o y e r .D E A T HS E C T O Rw i l lw r i t eD i s kD e

s t r o y e ro n t oa n ys e c t o ro f y o u rd i s k e t t ei n a f o r mw h i c hc a nb e

e x e c u t e dw i t ht h e B l o c k - E x e c u t e( B - E )c o m m a n d .A f t e r t h e

s e c t o ri s w r i t t e n ,D E A T HS E C T O Rw i l lp r i n ta c o m m a n dl i n eo n

y o u rs c r e e nw h i c hc a n b e u s e dt o d e s t r o yt h ed i s k .I f y o uw i s ht o

d e s t r o yt h e d i s ki m m e d i a t e l y ,m o v ey o u rc u r s o rt o t h e l i n e

w h i c hD E A T HS E C T O Rj u s tp r i n t e da n dh i tr e t u r n .I f y o ud o n ' t

w i s ht o d e s t r o y t h ed i s kr i g h tn o w ,w r i t ed o w nt h e l i n et h a t

D E A T HS E C T O Rp r i n t e d .T h i sc o m m a n dl i n ec a nb e u s e da t a n y

t i m et o d e s t r o yy o u rd i s ki n a m a t t e ro f s e c o n d s .T h ef o r m a to f

t h eB L O C K - E X E C U T Ec o m m a n dt o d e s t r o y a d i s kw h i c h c o

t a i n sa d e a t hs e c t o ri s a s f o l l o w s :

O P E N 1 5 , 8 , 1 5 : O P E N 2 , 8 , 2 , " # 0 " : P R

- B - E ' 2 ; 0 ; T ; S : C L O S E 2 : C L O S E 1 5

T a n dS a r e t h et r a c ka n ds e c t o rw h e r e D I S KD E S T R O Y Ei s

h i d d e no n t h e d i s k .N o t e :I t i s v e r yi m p o r t a n tt h a ty o uo p e n

b u f f e r" # 0 -r a t h e rt h a nt h e u s u a lO P E N 2 , 8 , 2 , " # - .

W a r n i n g s& H i n t s

A l t h o u g hI d o n ' tw i s ht o s c a r eo f fa n yp o t e n t i a l1 5 4 1p r o g r a m

m e r s ,y o u n e e dt o u n d e r s t a n d ,b e f o r ea t t e m p t i n gt o p r o g r a m

y o u rd r i v e ,t h a ti t i s p o s s i b l et o s e r i o u s l yh a r my o u rd r i v ei f y o u

a r e n ' t c a r e f u l( a n dp e r h a p se v e ni f y o ua r e )w i t hy o u rw o r k .

A l t h o u g ht h ep r o g r a m sp r e s e n t e dh e r eh a v e b e e nt e s t e do n m y

e q u i p m e n t ,y o us h o u l db e c a r e f u lt h ef i r s tt i m ey o ur u nt h e mo n

y o u r si n c a s ey o um a d ea n e r r o ri n t y p i n go r i n c a s ea n e r r o rw a sm a d ei n t y p e s e t t i n gt h i sa r t i c l e .I n a n yc a s e ,n e i t h e rI n o rT h e

T h eT r a n s a c t o r 3 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 40: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 40/84

T r a n s a c t o rc a n a c c e p ta n y l i a b i l i t yf o r d a m a g e so f a n y t y p e

r e s u l t i n gf r o mt h eu s eo r m i s u s eo f t h e s er o u t i n e s .T h e r e f o r ey o u

a r e w e l la d v i s e dt o b e c e r t a i nt h a ty o uu n d e r s t a n dw h a ti s g o i n g

o n b e f o r eu s i n ga n y p r o g r a m sp r e s e n t e d w i t ht h i sa r t i c l e .

H e r ea r es o m eg u i d e l i n e sw h i c hm a ys a v ey o ua h e f t yr e p a i rb i l l

i n c a s et h i n g sD Og o w r o n gw h e ny o ua r ep r o g r a m m i n gy o u r

d i s kd r i v e .F i r s to f a l l ,k e e py o u rh a n do n t h ed i s kd r i v e ' sp o w e r

s w i t c hw h e nt e s t i n ga p r o g r a m .T U R N I N GO F FT H EC O M

P U T E RW I L LN O TS T O PT H EP R O G R A ME X E C U T I N GI N S I D ET H ED R I V E .Y o um u s tt u r n t h ed r i v ei t s e l fo f f t o s t o pi t .

S e c o n d l y ,i f s o m e t h i n gD O E Sg o w r o n ga n dt h ed r i v ed o e s n ' t

s e e mt o w o r kp r o p e r l yt r yt y p i n g

O P E N 1 5 , 8 , 1 5 , T ' : C L O S E 1 5

w h i l et h ed r i v e ' sd o o ri s o p e na n dn o d i s ki n t h ed r i v e .T h e np u t

a d i s kt h a ty o uk n o wt o b e g o o d( b u tm a k es u r ey o uh a v ea

b a c k u po f t h ed i s k )i n t ot h e d r i v ea n ds e ei f t h e d r i v ec a nr e a di t .

I t i s q u i t el i k e l yt h a t t h i s w i l lf i x a n y p r o b l e m sy o u m a y

e n c o u n t e rp r o v i d e dy o u h a v ea q u i c kh a n d o nt h e d r i v e s w i t c h .

I n w r i t i n ga n dt e s t i n gD i s kD e s t r o y e r ,I m a d et w om i s t a k e s- o n e

t h a ts e n t t h e d r i v eh e a do f fs e a r c h i n gf o rt r a c k1 0 0a n da n o t h e r

w h i c hc a u s e di t t o t r y t o s t e pb a c k w a r d s 2 5 5t r a c k s .N e i t h e ro f

t h e s ee r r o r sc a u s e da n y d a m a g et o m y d r i v ea l t h o u g ht h e

r e p e a t e dk n o c k i n gc a u s e db y t h e d r i v eh e a dt r y i n gt o m o v e

o u t w a r d2 5 5t r a c k sc o u l dh a v es e n tm et o t h er e p a i rs h o pi f I h a d

n o t q u i c k l yt u r n e do f ft h ed r i v ew h e nI h e a r dt h eb u z z i n gs o u n d

o f t h e d r i v eh e a dh a m m e r i n ga g a i n s tt h ee n ds t o p .T h ea t t e m p t

t o f i n dt r a c k1 0 0s i m p l yr e q u i r e dm et o u s et h el i n e o fc o d eg i v e n

a b o v et o i n i t i a l i z et h e d r i v e- p u l l i n gt h er e a d / w r i t eh e a d b a c k

i n t of a m i l i a rt e r r i t o r y .

O n el a s tw o r do f w i s d o mi s t o t u r no f fy o u rs t e r e o ,d r i v e f a n o r

w h a t e v e rn o i s ya p p l i a n c eh a p p e n st o b e r u n n i n gw h i l et e s t i n g

y o u rd r i v e r o u t i n e s s i n c es o u n di s y o u r k e yi n d i c a t o ro f s o m e

t h i n gg o i n gw r o n g .E a c ht i m et h eh e a dm o v e sb y o n et r a c k ,y o u

s h o u l dh e a ra s l i g h tc l i c k i n gs o u n d .I f y o uh e a ri t m o v em o r e

t h a n4 0 t r a c k sy o uk n o ws o m e t h i n g m u s t b ew r o n g .L i k e w i s e ,i f

y o uh e a rt h eh e a ds l a m m i n ga g a i n s tt h ee n ds t o py o uk n o wt o

s w i t c ho f ft h e d r i v eF A S T .

W h i l ey o us h o u l db e a w a r eo f t h e p o t e n t i a lt o d a m a g ey o u r

e q u i p m e n t ,i t i s m ye x p e r i e n c et h a ta q u i c kh a n do n t h ed r i v e ' s

p o w e rs w i t c hs h o u l dm a k ep r o g r a m m i n gy o u rd i s kd r i v ea l m o s tr i s kf r e e .

L i s t i n gl : T h i sp r o g r a mw i l lc r e a t e a " d e a t hs e c t o r "o n t h e t r a c k

a n ds e c t o ro f y o u rc h o i c eo n t h e d i s k c u r r e n t l yi n t h ed r i v e ,a n d

s h o wy o u t h e c o m m a n dr e q u i r e dt o a c t i v a t ei t . W h e nt h e

c o m m a n di s g i v e na t a n yt i m ew h e nt h a td i s ki s i n t h ed r i v e ,t h e

c o n t e n t so f t h e d i s kw i l lb e c o m p l e t e l y d e s t r o y e dw i t h i nt e n

s e c o n d s . T h i s p r o v i d e sa n e a s yw a yt o d e s t r o ys e n s i t i v ed a t ai n a

h u r r y .( W ec a l li t " T h eO l i v e rN o r t hS p e c i a l " . )

T h ea c t u a lp r o g r a mt h a tt h e d r i v ee x e c u t e st o d e s t r o yt h e d i s kc a nb e s e e ni n a s s e m b l e rf o r mi n L i s t i n g3 .

C K

O M

F P

A M

C K

E N

J A

P G

I H

L C

C N

A B

P H

M MF D

N G

K M

N F

D K

D E

O C

G CI E

O O

K l

K M

E C

H F

G J

C l

G A

I H

I D

E JO D

D M

H J

F F

I C

P N

B P

I J

D H

H L

H D

M KO G

D G

C l

1 0

N A

P B

H K

B J

K A

P F

K K

K C

E M

1 0 0

1 1 0

1 2 0

1 3 0

1 4 0

1 5 0

1 6 0

1 7 0

1 8 0

1 9 0

2 0 0

2 1 0

2 2 0

2 3 0

2 4 0

2 5 0

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 0

3 6 0

3 7 0

3 8 0

3 9 0

4 0 0

4 1 0

4 2 0

4 3 04 4 0

4 5 0

4 6 0

4 7 0

4 8 0

4 9 0

5 0 0

5 1 0

5 2 0

5 3 0

5 4 0

5 5 05 6 0

5 7 0

5 8 0

5 9 0

6 0 0

6 1 0

6 2 0

6 3 0

6 4 0

6 5 0

6 6 0

6 7 0

6 8 0

r e m * * * * * * * * * * * * * * * * * * * * * * * * * *

r e m d e a t hs e c t o r

r e m f r a n ke . d i g i o i a

r e m * * * * * * * * * * * * * * * * * * * * * * * * *

r e m t h et r a n s a c t o rv o l8 i s s u e3

r e m* * * * * * * * * * * * * * * * * * * * * * * * * * * *

1 d a t a " w a r n i n g ! ! !t h i sp r o g r a mw i l l "

1 d a t a " c r e a t ea s e c t o ro n y o u rd i s k"

1 d a t a ' w h i c hw i l lc a u s et h ed i s kt o "

d a t a " s e l f - d e s t r u c ti f b - ec o m m a n d "

d a t a ' i si s s u e do n t h a ts e c t o r ."

r e m * * * * * * * * * * * * * * * * * * * * * * * * * *

r e a da $ , b $ , c $ , d $ , e $ : r e m r e a dw a r n i n g

r $ = c h r $ ( 1 3 ) : p r i n t a $ r $ b $ r $ c $ r $ d

g o s u b 5 7 0 : r e mv e r i f yd i s kn a m e

o p e n 2 , 8 , 2 , " # 0 " : r e mo p e nb u f f e r0

p r i n t # 1 5 , " b - p " ; 2 ; 0 : r e ms t a r to f b u f

| f o ri = 1 t o 1 4 6 : r e a dm l : c k= c k + m l

p r i n t # 2 , c h r $ ( m l ) ; :n e x t :r e mf i l lb u f

' d a t a 2 3 4 ,2 3 4 , 2 3 4 ,1 6 9 , 1 , 1 3 3 ,

' d a t a 0 , 1 3 3 , 7 ,

d a t a 3 , 1 7 2 , 1 4 4 ,

' d a t a 1 , 3 , 1 4 0 ,

' d a t a 0 , 1 6 5 , 0 ,

' d a t a2 4 0

d a t a1 3 3

d a t a1 9 8

d a t a2 5 3

' d a t a1 7 6

' d a t a1 0 9

d a t a1 4 1

' d a t a 3 , 1 6 9 , 1

d a t a 2 8 , 2 0 2 ,7 6 , 1 1 3 ,3 ,

d a t a2 3 2 ,1 3 8 , 4 T , 3 , 1 4 1 ,d a t a 0 , 2 8 , 4 1 , 2 5 2 ,1 3 ,

d a t a 0 , 2 8 , 1 6 0 ,5 , 1 6 2 ,

d a t a2 5 3 ,1 3 6 ,2 0 8 , 2 5 0 ,9 6 ,

d a t a 3 , 0

i f c k < > 1 4 4 3 2t h e np r i n t ' b a d d a t a " : s t o p

p r i n t # 1 5 , " u 2 " ; 2 ; 0 ; t ; s : r e mw r i t e b l k

p r i n f u s et h i sl i n et o e r a s ed i s k : "

p r i n t" [ d o w n ] o p e n 1 5 , 8 , 1 5 : o p e n 2 , 8 ,

p r i n tc h r $ ( 3 4 ) " # 0 " c h r $ ( 3 4 ) " : p r i n t # "

p r i n t " 1 5 , " c h r $ ( 3 4 ) " b - e " c h r $ ( 3 4 ) ;

p r i n t" 2 ; 0 ; " ; t ; " ; " s ; " : c l o s e 1 5 : c l o s e 2 "

i c l o s e 1 5 : c l o s e 2 : e n d : r e mf i n i s h e d !r e m * * * * * * * * * * * * * * * * * * * * * * * * * * *

r e m * * * * *r e a dd i s kn a m e * * * * *

* * * * * * * * * * * * * * * * * * * * * * * * * * * * *

4 , 2 0 1 ,

3 4 , 3 2 ,

6 , 1 6 9

1 7 3 , 1 4 2 ,3 , 1 7 4 , 1 4 3

3 , 1 4 1 , 0 , 3 , 1 4 2

2 , 3 , 1 6 9 , 2 2 4 , 1 3

4 8 , 2 5 2 , 9 6 , 1 6 5 ,3 4

4 , 1 6 9 ,4 6

3 2 , 1 0 2 ,3

3 4 , 3 2 ,1 6 3

3 4 , 2 0 1 ,3 6

3 6 , 1 4 4 ,

1 0 2 , 3 ,

3 4 ,2 0 8 , 2 4 6 , 2 3 0 ,

3 2 , 0 , 2 5 4 , 1 6 5 ,

2 3 0

7 6

3

1 1

3

6 2

1 6 9

3 4 , 3 2 , 1 0 9 ,3 , 3 2

6 2 , 3 , 1 7 3 , 1 4 1 ,3

1 4 1 , 6 3 , 3 , 1 4 1 ,6 4

7 6 , 1 0 5 , 2 4 9 , 1 7 4 ,0

1 7 4 , 0 , 2 8

1 4 5 , 3 , 1 7 31 4 5 , 3 , 1 4 1

2 5 5 , 2 0 2 ,2 0 8

2 3 4 , 7 6 , 3 8

i o p e n 1 5 , 8 , 1 5 , " i O " : r e mr e f r e s hb a m

r n $= c h r $ ( 1 4 4 )+ c h r $ ( 7 )+ c h r $ ( 1 6 )

p r i n t # 1 5 , " m - r " r n $ : r e mp o i n tt o n a m e

r i = 1 t o 1 6 : g e t # 1 5 , p $ : n $= n $ + p $ : n e x t

p r i n t " [ 2d o w n ] d i s kn a m e : " ; n $

■ i n p u t " [ d o w n ] w r i t ed e a t hs e c t o r " ; y n $

i f l e f t $ ( y n $ , 1 ) O " y "t h e ne n d

p r i n t " [ d o w n ] w h e r ed o y o u w a n td e a t hs e c t o r ? "

i n p u f t r a c k" ; t : i n p u t " s e c t o r" ; s

r e t u r n

T h eT r a n s a c t o r 3 8 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 41: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 41/84

L i s t i n g2 : E x a m i n et h e d a t ai n a n ys e c t o ro n a d i s k ,i n c l u d i n g

t h o s eb e y o n dt h en o r m a lm a x i m u mo f 3 5 .

C K

A K

A B

A M

C K

E N

E L

O C

O M

L K

L N

C O

P E

P A

C N

K L

N C

O M

I N

P B

B E

B B

I B

E N

K D

I I

0 0

A N

B l

E M

P A

I N

C G

E N

D C

A E

B E

D D

D B

N H

1 0 0

1 1 0

1 2 0

1 3 0

1 4 0

1 5 0

1 6 0

1 7 0

1 8 0

1 9 0

2 0 0

2 1 0

2 2 0

2 3 0

2 4 0

2 5 0

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 0

3 6 C

3 7 0

3 8 0

3 9 0

4 0 0

4 1 0

4 2 0

4 3 0

4 4 0

4 5 0

4 6 0

4 7 0

4 8 0

4 9 0

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

r e m * * * r e a da n ys e c t o r * * *

r e m * * * b y f r a n kd i g i o i a * * *

r e m

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

t h e t r a n s a c t o rv o l7 i s s u e6

* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

o p e n 1 5 , 8 , 1 5 , " i O "

t = 1 : s= 1 : x = 0 : d i m a ( 2 5 5 )

t s $= " m - w "+ c h r $ ( 6 )+ c h r $ ( O )+ c h r $ ( 2 )

s j $= " m - w 1+ c h r $ ( O )+ c h r $ ( O )+ c h r $ ( 1 )

i n p u f [ c l r ] t r a c k " ; t

i f t < 1o r t > 4 0t h e n2 0 0

i n p u t " s e c t o r " ; s : i fs < 0t h e n2 2 0

p r i n t # 1 5 , t s $ ; c h r $ ( t ) c h r $ ( s )

p r i n t *1 5 , s j $ ; c h r $ ( 1 7 6 ) : r e md o s e e k

g o s u b4 2 0 : r e ma w a i tc o m p l e t i o n

p r i n t # 1 5 , t s $ ; c h r $ ( t ) c h r $ ( s )

p r i n t # 1 5 , s j $ ; c h r $ ( 1 2 8 ) : r e md o r e a d

g o s u b4 2 0 : r e ma w a i tc o m p l e t i o n

p r i n t # 1 5 , " m - r " c h r $ ( 0 ) c h r $ ( 3 ) c h r $ ( 2 5 5 )

p r i n t " [ c l r ] " : f o r i= 0 t o 2 5 5 : g e t # 1 5 , a $

a ( i )= a s c ( a $+ c hr $ ( 0 ) ) :p r i n t a $ ; :n e x t

p r i n t ' h i ta n yk e yf o rs c r e e nc o d e s "

p o k e 1 9 8 , 0 : w a i t 1 9 8 , 1 : g e t a $ : p r i n t " [ c l r ] [ d o w n ]

f o r i= 0 t o 2 5 5 : p o k e 1 0 2 4 +i , a ( i ) : n e x t

p r i n t " [ 5d o w n ] h i ta k e yf o ra s c i ic o d e s "

p o k e 1 9 8 , 0 : w a i t 1 9 8 , 1 : g e t a $ : p r i n t " [ 2 d o w n ] "

f o r i= 0 t o 2 5 5 :p r i n t a ( i ) ; : n e x t

p r i n t # 1 5 , " i O " : c l o s e 1 5 : e n d

r e m * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

w a i tf o r a c t i v i t yc o m p l e t er e m

r e m ** * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *

f o r i= 1 t o 3 0 0 0 : n e x t : r e mi n i t i a ld e l a y

p r i n t # 1 5 , " m - r " c h r $ ( 0 ) c h r $ ( 0 )

g e t # 1 5 , a $ : a= a s c ( a $+ c h r $ ( O ) )

i f a = 1 7 6t h e np r i n f ' s e e k i n gt r a c k "

i f a = 1 2 8t h e np r i n f r e a d i n gs e c t o r "

x = x + 1 : i f a > 1 2 7 a n d x < 1 1t h e n4 2 0

i f a = 1 t h e np r i n t " o k a y " : x= 0 : r e t u r n

p r i n f ' e r r o r ! ! ! " :p r i n t # 1 5 ," u : " :s t o p

L i s t i n g3 : A s s e m b l e rs o u r c ec o d ef o rt h e d r i v e - r e s i d e n tp r o

g r a mt o d e s t r o ya d i s k .T h i sc o d ei s w r i t t e ni n t ot h e 1 5 4 1 ' sR A Mb y " D e a t hS e c t o r "i n L i s t i n g1 .

K N

H B

O O

J J

H I

M A

K A

A C

C P

H I

B J

C E

G l

N J

1 0 0

1 1 0

1 2 0

1 3 0

1 4 0

1 5 0

1 6 0

1 7 0

1 8 0

1 9 0

2 0 0

2 1 0

2 2 02 3 0

; d i s kd e s t r o y e r / s r c

; f r a n kd i g i o i a

; 0 9 / 2 8 / 8 6

• = $ 0 3 0 0

e n t r y n o p

n o p

n o p

I d a # $ 0 1

s t a $ 0 6

I d a # $ 0 0

T h eT r a n s a c t o r

; n o t r e l o c a t a b l e ! !

; t r a c k1

; s e tt r a c k

; s e c t o r0

P M

O K

E E

D C

K C

L B

B P

C H

O F

P H

F B

K EO N

A P

E l

H F

E J

G J

K B

J P

D D

I D

C K

I B

C C

H F

O G

I I

O H

N A

J O

O C

B K

F L

L P

A MK M

D E

C O

O l

J E

I J

D DP D

F C

P G

C D

G A

D l

P H

K J

E G

A P

F L

G N

H G

E K

D G

H C

E G

O P

P E

C N

H J

F H

G MJ H

J G

I F

O l

C C

F N

A N

J A

2 4 0

2 5 0

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 03 6 0

3 7 0

3 8 0

3 9 0

4 0 0

4 1 0

4 2 0

4 3 0

4 4 0

4 5 0

4 6 0

4 7 0

4 8 0

4 9 0

5 0 0

5 1 0

5 2 0

5 3 0

5 4 0

5 5 0

5 6 0

5 7 0

5 8 0

5 9 0

6 0 0

6 1 0

6 2 0

6 3 0

6 4 0

6 5 0

6 6 06 7 0

6 8 0

6 9 0

7 0 0

7 1 0

7 2 0

7 3 0

7 4 0

7 5 0

7 6 0

7 7 0

7 8 0

7 9 0

8 0 0

8 1 0

8 2 0

8 3 0

8 4 0

8 5 0

8 6 0

8 7 0

8 8 0

8 9 0

9 0 0

9 1 0

9 2 0

9 3 0

9 4 0

9 5 0

9 6 0

9 7 0

w a i t

p u r g e

;

b a c k

w i p e

f i n i s h

j

s t e p

s t e p b

d e l a y

;

n o p i n s

j m p i n s

t e m p

s t a

I d a

I d x

I d y

s t a

s t x

s t y

I d a

s t a

I d a

b m i

r t s

=

I d a

b e q

$ 0 7

j m p i n s

j m p i n s +1

j m p i n s +2

e n t r y

e n t r y+ 1

e n t r y + 2

# $ e 0

$ 0 0

$ 0 0

w a i t

$ 2 2

* + 6

c m p # $ 2 4

b c c

I d a

s t a

=

j s r

j s r

d e c

b n e

i n c

j s r

j s r

I d a

b a c k

# $ 2 e

$ 2 2

s t e p

s t e p

$ 2 2

b a c k

$ 2 2

$ f d a 3

$ f e O O

$ 2 2

c m p# 3 6

b c s

i n c

j s r

j s r

i m p

=

I d a

s t a

s t a

s t a

I d a

i m p

=

I d x

d e x

j m p

=

I d x

i n x

t x a

a n d

s t a

I d a

a n d

o r a

s t a

I d y

I d x

d e x

b n e

d e y

b n e

r t s

n o p

j m p

f i n i s h

$ 2 2

s t e p b

s t e p b

w i p e

n o p i n s

w i p e

w i p e+ 1

w i p e +2

# $ 0 1

$ f 9 6 9

*

$ 1 c 0 0

s t e p b +4

*

$ 1 c 0 0

# $ 0 3

t e m p

$ 1 c 0 0

# $ f c

t e m p

$ 1 c 0 0

# $ 0 5

# $ f f

d e l a y

d e l a y

p u r g e

. b y t e$ 0 0

; s e ts e c t o r

; c o p y j m p i n s t r t o

; e n t r yp o i n t ,s i n c e

; e x e c u t i o nw i l lj u m p

; t o e n t r ya s s o o na s

; t h e$ e 0i s p l a c e di n

; t h ej o bq u e u e .

; j o bc o d e= e x e c u t e

; p l a c ei n j o bq u e u e

; g i v ei t a f e wm i l i -

; s e c o n d s t ok i c ki n .

; g e tc u r r e n tt r a c k

; z e r o p r i n t p r i n t p r i n t

; i s i t b i g g e r t h a n3 6

; n o / g oa h e a d &m o v e

; s e t t r a c k t o 4 6

; t h a ts h o u l df i xi t

; s t e ph e a d b a c kt o t r a k1

; s t e ph e a db a c k1 / 2 t r a k

; s t e ph e a db a c k1 / 2t r a k

; d e c rc u r r e n tt r a c k

; u n t i la t t r a c kz e r o

; s e tt r a c kt o 1

; w i p et r a c k

; s e tr e a dm o d eo n

; g e tc u r r e n tt r a c k

; b i g g e r t h a n3 5 p r i n t

; d o n e / n o p r o b l e m

; b u m pt r a c k

; m o v e1 / 2 t r a c k

; m o v e1 / 2 t r a c k

; w i p en e x t t r a c k

; c l e a n u p a n dg e to u t

; g e tn o pi n s t r

; r e n d e rc o d eh a r m l e s s

; s e tr e t u r nc o d e

; m a i ne r r o r r o u t i n e

; s t e ph e a d b a c k1 / 2t r k

; g e tc o n t r o lr e g

; r o t a t el o w o r d e rb i t s

; s t e ph e a df r w d1 / 2t r k

; g e tc o n t r o lr e g

; r o t a t el o w o r d e rb i t s

; p u ti n . a

; i s o l a t el o w o r d e rb i t s

; s a v ei t

i g e t c o n t r o lr e ga g a i n

; c l e a rl o w o r d e rb i t s

; s e tl o w e r o r d e rb i t s

; s e t c o n t r o lr e g

; t i m i n gl o o pi t e r a t i o n s

; i n n e rl o o pt i m i n g

; a l l o wh e a dt o s e t t l e

; i n n e rl o o p

; o u t e rl o o p

; c o n t i n u e

; t h i si s d a t a

; t h i si s d a t a

; w o r k i n gs t o r a g e

3 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 42: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 42/84

A u t oT r a n s m i s s i o n

f o rt h eC o m m o d o r e6 4T h i sp r o g r a md e v e l o p e do u to f n e c e s s i t y .O v e ra p e r i o do f t i m eI h a v e

c o l l e c t e dp r o g r a m st h a tc o n v e r tB a s i cp r o g r a m st o m a k et h e ma u t o - r u n -

w h e ny o uL O A Dt h e mw i t h' , 8 , 1 't h e yw i l la u t o m a t i c a l l yR U Nu p o n

c o m p l e t i o no f t h e L O A D .S o m eo f t h e s ep r o g r a m s- J i m B u t t e r f i e l d ' s

' L o c k D i s k 'i s o n e- a l s oa l t e rs y s t e mv e c t o r si n s u c ha w a ya s t o c a u s et h e

p r o g r a mt o r e - R U N w h e n e v e rR E A D Ym o d eo c c u r s ( d u et o a n e r r o r ,o r t h e

p r o g r a me n d i n g ) .

T h i si s a g o o df e a t u r ei n m o s tc a s e s , b u t n o ta l w a y s .S u p p o s e y o uw r i t ea

n i c ep r o g r a m .Y o uR U Ni t a n dt e s ti t a n di t s e e m st o b e a l ly o ui n t e n d e di t t o

b e . S o y o uL O A Du p y o u rf a v o r i t ea u t o - r u nc r e a t o ra n d s o o ny o u r

p r o g r a mh a s a u t o - r u nc a p a b i l i t y .W e l l ,y o u n ol o n g e rn e e dt h eo r i g i n a l

B a s i cp r o g r a m ,s o y o us c r a t c hi t i n f a v o ro f k e e p i n go n l yt h ea u t o - r u n

v e r s i o n .I f y o u ' r el i k em e ,s o o n e ro r l a t e ry o u ' l lw a n tt o m a k es o m e

c h a n g e st o t h a tp r o g r a m .S o r r y ,i t ' s a n a u t o - r u np r o g r a mn o w .I f y o u

L O A Di t ' , 8 , 1 'i t w i l l s t a r tr u n n i n go n i t s o w n .D e p e n d i n go n b u i l t i n

s a f e g u a r d s ,y o um a yo r m a yn o tb e a b l et o s t o py o u rp r o g r a mf o re d i t i n gp u r p o s e s .I f y o uL O A Di t ' , 8 't h ep r o g r a mr e m a i n su n l i s t a b l e .T h i si s t h e

p r o b l e mI e n c o u n t e r e d .

M yf i r s ta p p r o a c ht o a s o l u t i o nw a st o l o o kt h r o u g ha l lo f m yC o m m o d o r e

r e l a t e dm a g a z i n e sf o ra p r o g r a mt o r e v e r s et h ea u t o - r u np r o c e s s .N ol u c k

t h e r e .I t s e e m e da p p a r e n tI w o u l dh a v et o t a c k l et h ep r o b l e mf r o mt h e

g r o u n dl e v e l .I w e n tt h r o u g he a c ho f m y a u t o - r u nc r e a t i n gp r o g r a m s ,

a n a l y z i n gB a s i cl i s t i n g sa n d d i s a s s e m b l i n gm a c h i n ec o d e .M y e f f o r t s

t u r n e du p s i m i l a r i t i e si n A L Lo f t h ea u t o - r u nc r e a t i n gp r o g r a m s .

F i r s t ,l o w e rm e m o r yv e c t o r s a r e w r i t t e nt o t h ed i s k ,w i t hc h a n g e st h a tw i l l

l a t e ri m p l e m e n tt h ea u t o - r u nf e a t u r e .N e x t ,a l l o f t h er e m a i n i n gm e m o r y

b e t w e e nt h ev e c t o rt a b l ea n dt h es t a r to f B a s i c ,i n c l u d i n gs c r e e nm e m o r y ,

i s w r i t t e nt o t h ed i s k .F i n a l l y ,t h e B a s i cp r o g r a mi t s e l fi s a l s ow r i t t e n .T h i s

e x p l a i n sw h yt h ep r o g r a mi s u n l i s t a b l ew h e ni t i s L O A D e d' , 8 ' :t h el o w e r

m e m o r yv e c t o r s a r ea t t h es t a r to f B a s i cp r o g r a ms p a c e .I t a l s oe x p l a i n s

h o wa u t o - r u np r o g r a m sa r e i m p l e m e n t e d .W h e nt h ep r o g r a mi s l o a d e d

' , 8 , 1 ' ,t h ep r o g r a ms t a r t sL O A D i n go v e rt h e t o po f t h e v e c t o rt a b l e ,m a k i n g

i t so w nc h a n g e si n t h ep r o c e s s .T h eo r i g i n a lB a s i cp r o g r a mf a l l sr i g h tb a c k

w h e r ei t o r i g i n a l l ys a t . U p o nr e t u r n i n gt o R E A D Ym o d e ,t h e a l t e r e d

v e c t o r sc a u s ei t t o b e g i nr u n n i n g .

S o m e t h i n ge l s eo f i m p o r t a n c e :N o m a t t e rw h e r ei n m e m o r yt h e l o a d

b e g i n s ,i t s a d d r e s si s r e c o r d e do n t h ed i s kw i t ht h ep r o g r a m .C o m p a r i n g

t h i sa d d r e s s w i t ht h es t a r to f B a s i ca t 2 0 4 9( B a s i cp r o g r a m ss t a r tl o a d i n ga t

2 0 4 9 )t h e d i f f e r e n c ew i l l e q u a lt h e n u m b e ro f b y t e s s e p a r a t i n g t h e

b e g i n n i n go f a n a u t o - r u np r o g r a mw i t ht h eo r i g i n a lu n d o c t o r e dv e r s i o n .

N o wt o w r i t ea u t i l i t yt o d o t h ej o b .F i r s t ,I N P U Tt h eL O A D i n ga d d r e s so f

t h ea u t o - r u np r o g r a m a n ds u b t r a c t t h a tf r o m2 0 4 9 .G E Tt h a tm a n yb y t e s

w i t ha F O R - N E X Tl o o p .N e x t ,c r e a t ea n e wp r o g r a m o nd i s kb y f i r s t

w r i t i n ga C H R $ ( 1 ) a n da C H R $ ( 8 )( t h en e wL O A Da d d r e s si n l o w b y t e / h i g h

b y t ef o r m a t )t h e nc o p y i n gt h e B a s i cp o r t i o no f t h ea u t o - r u nf i l eo n eb y t ea t

a t i m eu n t i lt h ew h o l ef i l ei s t r a n s f e r r e d .

N o wf o rt h et e s t .I w r o t ea o n el i n ep r o g r a m a n ds a v e di t t o d i s k .T h e nI

u s e da l lo f t h ea u t o - r u nc r e a t o rp r o g r a m sI h a d o ni t . T h et e s tw a st o s e ei f

m y p r o g r a mc o u l dc o n v e r te a c ho f t h e s ea u t o - r u np r o g r a m s b a c ki n t ot h e i r o r i g i n a lB a s i c f o r m a t .T h et e s tw a sa s u c c e s s !

D o u gR e s e n b e

R o c k f o r d ,I L

I h o p ea l lo f y o uw i l lf i n dt h i su t i l i t ya s u s e f u la s I h a v e .

C 6 4A u t oT r a n s m i s s i o n :

R e m o v eA u t o - R U N f r o mB A S I Cp r o g r a m s .

F A

B K

E F

L I

N D

D A

J A

G A

E L

P G

P F

P BI D

G D

P F

B M

E E

F H

B M

K P

B M

D C

I H

L D

L K

B O

B E

L K

L F

K H

B M

L C

E L

K E

M E

G E

D H

O F

O K

C G

I C

O H

C P

P H

1 0

H N

P I

F J

M lK O

1 0 r e m* t h i sp r o g r a mc h a n g e sa u t o - r u n

2 0 r e m* p r o g r a m s b a c kt o t h e i r

3 0 r e m* o r i g i n a lb a s i cf o r m a t

4 0 r e m* w r i t t e nb y d o u gr e s e n b e c k1 0 / 8 6

5 0 p r i n t c h r $ ( 1 4 7 ) c h r $ ( 1 7 ) c h r $ ( 1 7 )

6 0 p r i n t "n a m eo f b a s i ca u t o - r u np r o g r a m '

7 0 p r i n t : i n p u t a r $ : t= l e n ( a r $ )

8 0 g o s u b 4 4 0

9 0 i f s= 1 t h e n s= 0 : g o t o 5 0

1 0 0p r i n t c h r $ ( 1 4 7 ) c h r $ ( 1 7 ) c h r $ ( 1 7

1 1 0p r i n t "n e wn a m ew i t ha u t o - r u nr e m o v e d "

1 2 0p r i n t : i n p u t u a $ : t= l e n ( u a $ )1 3 0 g o s u b 4 4 0

1 4 0i f s= 1 t h e n s= 0 : g o t o 1 0 0

1 5 0p r i n t c h r $ ( 1 4 7 ) c h r $ ( 1 7 ) " a u t o - r u" a r $

1 6 0 p r i n t c h r $ ( 1 7 ) " t o "

1 7 0p r i n t c h r $ ( 1 7 ) " u n / a u t o - r u n " u a

1 8 0p r i n t c h r $ ( 1 7 ) " p l e a s ew a i f

1 9 0o p e n 2 , 8 , 2 , a r $+ " , p , r "

2 2 0o p e n 8 , 8 , 8 , u a $+ " , p , w "

2 5 0 g e t # 2 , a $ , b $

2 6 0i f a $= " t h e n a $= c h r $ ( O )

2 7 0a = a s c ( a $ )

2 8 0i f b $= " "t h e n b $= c h r $ ( O )

2 9 0b = a s c ( b $ ) : c= a + 2 5 6 * b : d= 2 0 4 9 - c

3 0 0i f d > 0 t h e n 3 2 0

3 1 0p r i n t c h r $ ( 1 4 7 ) c h r $ ( 1 7 ) " p r o g r a i s n o ta

b a s i ca u t o - r u np r o g r a m " : g o t o 3 8 0

3 2 0f o r x= 1 t o d : g e t # 2 , a $ : n e x t

3 3 0 p r i n t # 8 , c h r $ ( 1 ) ;

3 4 0p r i n t # 8 , c h r $ ( 8 ) ;

3 5 0g e t # 2 , a $ : s w= s t : i f a $= " t h e n a $= c h r $ ( O )

3 6 0p r i n t # 8 , a $ ; : i f s w= 0 t h e n 3 5 0

3 7 0p r i n t c h r $ ( 1 4 7 ) c h r $ ( 1 7 ) " d o n e "

3 8 0c l o s e 2 : c l o s e 8

3 9 0g o s u b 4 8 0

4 0 0i f e > 0 t h e n 5 0 0

4 1 0p r i n t c h r $ ( 1 7 ) : i n p u t " m o r e " ; n $

4 2 0 i f n $= " y " t h e n 5 0

4 3 0 e n d

4 4 0 i f t < 1 7 t h e n r e t u r n

4 5 0p r i n t c h r $ ( 1 7 ) : p r i n f f i l e n a m e t o ol o n g "

4 6 0f o r x= 1 t o 1 5 0 0 : n e x t : s= 1

4 7 0r e t u r n

4 8 0 c l o s e 1 5 : o p e n 1 5 , 8 , 1 5

4 9 0i n p u t # 1 5 , e , e $ , t r , s : c l o s e 1 5 : r e t u r

5 0 0p r i n f ' d i s ke r r o r# " ; e

5 1 0 p r i n t e $

5 2 0p r i n f t r a c k " ; t r

5 3 0p r i n t ' s e c t o r " ; s5 4 0c l o s e 2 : c l o s e 8

T h eT r a n s a c t o r 4 O N o v e m b e r1 9 8 7 :V o l u m e6 , I s s u eO 3

Page 43: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 43/84

C o m m o nC o d e J a c kR . F a r r a

C i n c i n n a t i ,O h i o

. . . I ts o u n d e dl i k ea j o bf o rT H EC O M P U T E R !

T h eS c e n a r i o :

T h a tn i f t ym a c h i n el a n g u a g ep r o g r a my o u ' v el a b o r e do v e rf o r

w e e k si s f i n a l l yc o m p l e t e .A n a t u r a lf o r s u b m i s s i o nt o T h e

T r a n s a c t o r ,y o ut h i n k .B u tw a i t !Y o u rp r o g r a m m i n gt e c h n i q u e

( p e r h a p sl i k em i n e )i s a b i tl o n gw i n d e d .W r i t t e na n dd e b u g g e d

i n s e c t i o n st h a tw e r et h o u g h to u ti n d e p e n d e n t l y ,i t w o r k sb u ti t ' s

e x t r e m e l yl o n g .W h a ti f i t ' s t o o l o n g ?W o u l di t h a v ea b e t t e r

c h a n c ei f i tw e r e1 0 0 ,2 0 0 ,5 0 0b y t e ss h o r t e r ?F r a n t i c a l l yy o u

s c a nt h e c o d e , l o o k i n gf o r t h i n g st o e l i m i n a t e ,s h o r t e no r

c o m b i n e .N og o o d !Y o u re y e sk e e pg l a z i n go v e ra t t h et a s k .A f t e r

a l l ,y o u ' v eb e e na t t h i s f o rw e e k sa n dt h et h o u g h to f a m a j o rr e

w r i t ei s n o t p l e a s a n t .

T h i si s n o t f i c t i o nf r i e n d .I t h a p p e n e dt o m e .A f t e ra l l t h e

s e a r c h i n g ,a l l t h ec u t t i n go u to f t i t l es c r e e n s ,h e l p s c r e e n sa n d

s u p e r f l u o u s u s e rp r o m p t s ,I s t i l lh a do v e r3 5 0 0b y t e so f c o d e .I n

d e s p e r a t i o nm y m i n dt u r n e dt o s u b r o u t i n e s .M a y b e ,a m o n g s t

t h e s et h i r t yp a g e so f a s s e m b l y ,t h e r ew e r ei d e n t i c a ls e c t i o n so f

c o d et h a tI c o u l dc o n s o l i d a t ei n t os u b r o u t i n e st o s h o r t e nt h e

p r o g r a m .B u th o wt o f i n dt h e m ?I t s o u n d e dl i k ea j o bf o rT H E

C O M P U T E R !

T h eS o l u t i o n :

A t y p i c a l ,k n e e - j e r kr e a c t i o nf r o ma p r o g r a m m i n gb u f fy o us a y ?

W e l l ,p e r h a p s ,b u tt h e r e ' sn o t h i n gt h a tp u m p sm eu p m o r et o s i t

d o w na n dw r i t ea p r o g r a mt h a nt o p e r c e i v e at a n g i b l en e e d .

M o r es o i f i t sm yo w n !C o m m o nC o d ei s m ya n s w e rt o t h i sn e e d .

H e r e ' sw h a ti t d o e s .A f t e rl o a d i n ga n dr u n n i n g , t h ep r o g r a m

a s k sy o uf o ra s t a r t i n ga d d r e s si n m e m o r y ,i n h e x a d e c i m a l( d o

n o t i n c l u d e$ ' s ) .N e x t ,a n e n d i n ga d d r e s s . E n t e r< R E T U R N >

a f t e re a c hi n p u t .T h e ny o ua r e a s k e dw h e t h e r y o uw a n tt h e

p r o g r a mo u t p u tt o g o t o t h es c r e e no r y o u rp r i n t e r .E n t e r" s "o r

" p " .I f y o ua r es p e c i f y i n g ap r i n t e r ,i t m u s t b et u r n e do n b e f o r e

h i t t i n gt h e" p " .F i n a l l y ,y o ua r eg i v e nt h eo p p o r t u n i t yt o s p e c i f y

h o wm a n yb y t e so f i d e n t i c a lc o d ey o uw a n tt h ep r o g r a mt o f i n d .

A n yn u m b e rb e t w e e n0 0 a n d F F( 2 a n d2 5 5 )i s a c c e p t a b l e .A n

0 0 o r 0 1 e n t r yw i l l e x i ty o uf r o mt h e p r o g r a m .T h ed e f a u l t

s e t t i n gi s 7 b y t e sa n di s d i s p l a y e da t t h ep r o m p t .E n t e r< R E -

T U R N >o n l yt o a c c e p tt h ed e f a u l t .

F r o mh e r eo n t h ep r o g r a mb e g i n si t s s e a r c ha n dd i s p l a yr o u

t i n e s .E a c h p r o g r a mb y t ei s t a k e ni n t u r na s t h eb e g i n n i n go f a

p o t e n t i a ls u b r o u t i n e .I t i s c h e c k e da g a i n s tt h ef o l l o w i n gb y t e si n

t h ep r o g r a m .I f a f u l lm a t c hi s f o u n d , t h es t a r ta d d r e s si s p r i n t e d ,

t h e ne a c h m a t c h i n gg r o u p ' ss t a r ta d d r e s si s p r i n t e di n d e n t e db e l o wi t . T h e r e ' sn o r e q u i r e m e n tt h a ty o us e a r c h o n l yb e t w e e n

t h e " r e a l "s t a r ta n de n do f y o u r p r o g r a m .Y o uc a nl i m i tt h e

s e a r c ht o t h o s e a r e a sw h e r e y o u w a n tt o c o n c e n t r a t e .A s s u m i n

y o u r p r o g r a mh a st e x ta n do r d a t at a b l e sa t t h eb e g i n n i n go r

e n d , e n t e ra d d r e s s e st h a to m i tt h o s e a r e a so f c o d e .

T h ec h e c k i n gr o u t i n e sr u nf a s ta n dd e p e n d i n go n t h ep r o g r a m

l e n g t h ,t h e b y t e l e n g t hb e i n gc h e c k e da n d t h e n u m b e ro f

m a t c h e sf o u n d , t h e o u t p u tt o y o u rs c r e e nm a yf l a s hb y t o o

q u i c k l y .Y o uc a n p a u s et h el i s t i n g( a n dt h es e a r c h )b y h i t t i n gt h e

s p a c eb a r .R e s t a r tb y h i t t i n gi t a g a i n .B ea w a r et h a tt h es p a c e b a

i s o n l yc h e c k e dd u r i n gt h ep r i n t o u tr o u t i n e .

W h e nc o m p l e t e ,t h ed e f a u l tb y t ec o u n ti s r e i n s t a t e d ,t h ep r i n t e r

f i l ec l o s e da n d y o ua r er e t u r n e dt o B A S I Cw i t ha R E A D Yp r o m p t .

A l l t h a t ' sl e f ti s f o ry o ut o c h e c kt h ec o d ef r o ma n a s s e m b l

p r o g r a mp r i n t o u t ,a g a i n s tt h em a t c h i n gg r o u p s .P i c kt h ev i a b l e

s u b r o u t i n e sa n dr e v i s ey o u rc o d e .

T h eW o r k s :

C o m m o nC o d ei s w r i t t e nt o r e s i d ei n t h en o r m a lB A S I Cp o r t i o n

o f m e m o r ys o t h a ti s h a st h el e a s tp o s s i b i l i t yo f m e m o r yc o n f l i c t

w i t ht h em a c h i n el a n g u a g ep r o g r a m s y o uw i l lc h e c kw i t hi t .T h e

f u n c t i o n i n go f t h ep r o g r a mi s r e l a t i v e l y s t r a i g h tf o r w a r d .T h e r e

a r e f o u rm a i na d d r e s s e st r a c k e da n do r u p d a t e dd u r i n gt h e

c o u r s eo f e x e c u t i o n .T h eS t a r tA d d r e s s y o ue n t e ri s t h eb e g i n

n i n gb y t et o t r ya n dm a t c h .T h eC h e c kA d d r e s si s t h ef i r s tb y t e

w h e r ea m a t c hi s a t t e m p t e d .C h e c ki s l o c a t e di n i t i a l l ya t S t a r t

A d d r e s s+ N b y t e s .N i s t h ev a l u ey o u ' v es p e c i f i e df o rt h e b y t e

l e n g t hm a t c h .A n ya d d r e s sc l o s e rt o S t a r tw o u l dn o t a l l o w t

r e q u i s i t el e n g t hi n t h ef i r s tg r o u p .I f a m a t c hi s f o u n da t C h e c k ,

N - l m o r eb y t e sa r e c h e c k e d .I f t h e ym a t c h ,w e p r i n tt h e

a d d r e s s e s .W h e t h e ro r n o tt h e ym a t c h ,C h e c ki s i n c r e m e n t e db y

1 a n dw es t a r ta g a i n . A f t e r t h ee n t i r ep r o g r a mh a sb e e n c h e c k

a g a i n s tS t a r t ,S t a r ti s i n c r e m e n t e d b y1 a n dt h e w h o l et h i n g

h a p p e n sa g a i n !Y o u ' l ln o t i c et h e o u t p u ts p e e d u pa s w e m o v e

t h r o u g ht h ep r o g r a m ,b e c a u s et h ef a r t h e rS t a r tm o v e st o w a r d s

t h e e n d ,t h es h o r t e r t h e l e n g t ho f b y t e si t sm u s t c h e c k b e c o

T w oa d d r e s s e sa t t h ee n da r eu s e dt o d e t e r m i n ew h e no n ep a s s

o r t h ew h o l ep r o c e s si s c o m p l e t e .E n dC h e c ki s y o u r p r o g r a

e n d i n ga d d r e s sm i n u s( N - 2 ) .T h i si s t h ea d d r e s sf r o mw h i c ha n

i n a d e q u a t en u m b e ro f b y t e sr e m a i nt o b e c o m ea N l e n g t h

s u b r o u t i n e .E a c ht i m eC h e c ki s i n c r e m e n t e di t i s c o m p a r e dw i t h

t h i sa d d r e s s .I f t h e ym a t c h ,i t st i m et o r a i s et h eS t a r tA d d r e s s b

o n e , r e - f o r m u l a t eC h e c ka n db e g i na g a i n .M a t c hC h e c ki s N

b y t e sb a c ki n t ot h ep r o g r a mf r o mE n dC h e c k .E a c ht i m eS t a r ti s

i n c r e m e n t e di t i s c o m p a r e dw i t hM a t c h .I f t h e ya r e t h es a m e ,

t h e r ea r e a n i n s u f f i c i e n tn u m b e ro f b y t e sr e m a i n i n gi n t h e

p r o g r a mt o g e tt w om a t c h i n gg r o u p s .A t t h i sp o i n tw e ' r e d o n e

T h eT r a n s a c t o r 4 1 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 44: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 44/84

T h eC a v e a t s :

C o m m o nC o d ew i l lp r o v i d ey o uw i t ha l l t h e i n f o r m a t i o ny o u

n e e dt o i d e n t i f ye x i s t i n gs u b r o u t i n em a t e r i a lw i t h i ny o u rp r o

g r a m ,b u t :

1 . I f y o u ' v ew r i t t e nd i f f e r e n tc o d ei n t w op l a c e si n y o u rp r o g r a m

t h a tp e r f o r m st h es a m ef u n c t i o n ,C o m m o nC o d ew o n ' tf i n di t

( O b v i o u s ,y e s ,b u tI t h o u g h tI ' d m e n t i o ni t . ) .

2 . B e c a u s et h ep r o g r a ml e a v e sn o s t o n eu n t u r n e di n s e a r c h i n g

f o r m a t c h i n gg r o u p s ,m o r es t o n e st h a ny o u n e e da r e t h e

r e s u l t .N o ta l l m a t c h e sw i l lo c c u ro n v a l i db o u n d a r i e s .A

m a t c hm a yb e g i nw i t ha n o p e r a n dr a t h e rt h a n a n o p c o d e .I f

y o ua r e s e a r c h i n gf o r a s m a l lb y t es t r i n gl e n g t ha n d t h e

p r o g r a mc o n t a i n sc o m m o ns e c t i o n so f g r e a t e r l e n g t h ,o u t p u t

w i l ls h o wu p a s m u l t i p l eg r o u p s ,e a c hs e p a r a t e db y o n eb y t e .

3 . S o m eg r o u p sw i l lc o n t a i nb r a n c h e so r j u m p so u t s i d eo f t h e m

s e l v e sa n dw i l lt h e r e f o r eb e u n u s a b l e .

4 . F i n a l l y ,s o m eu s a b l eg r o u p i n g s m a y ,t o t h e r e a d e ro f y o u r

s o u r c e ,m a k et h e p r o g r a mi n t e n tl e s sc l e a r .C o m m o nC o d e

w i l lp r o v i d ey o uw i t ho p p o r t u n i t i e s .Y o um u s td e c i d ew h e r e

c l a r i t yt a k e sp r e c e d e n c eo v e rb r e v i t y .

H o wd i dC o m m o nC o d ep e r f o r m o nm y l o n gp r o g r a m ?I w a s

a b l et o a c h i e v ea 1 0 %r e d u c t i o ni n p r o g r a ml e n g t h( a r o u n d3 5 0

b y t e s ) .D o n ' tt a k et h i sa s at y p i c a l r e s u l ti n a p p l y i n gt h i su t i l i t y .

Y o u rr e s u l t sd e p e n de n t i r e l yo n w h a t ' si n y o u rp r o g r a m .G o o d

h u n t i n g !

C o m m o nC o d e :C r e a t e sM Lm o d u l eo n d i s k

I A

K J

C G

I J

E l

M OB C

G K

G F

L G

B O

K D

F B

C l

D O

C P

B L

C B

E l

F O

K K

I N

I K

0 0H C

D A

1 0 0 0 r e ms a v e " 0 : c o m m o nc o d e . g e n " , 8

1 0 1 0 r e ma l o c a t e& d i s p l a yu t i l i t yt o

1 0 2 0 r e mf i n d i d e n t i c a lc o d e s e q u e n c e s

1 0 3 0 r e mi n m a c h i n el a n g u a g ep r o g r a m s

1 0 4 0 :

1 0 5 0 r e mt h i sp r o g r a mw i l lc r e a t e

1 0 6 0 r e ma l o a da n dr u nm o d u l eo n

1 0 7 0 r e md i s k c a l l e d' c o m m o nc o d e '

1 0 8 0 r e m

1 0 9 0f o rj = 1 t o 9 1 0 :r e a dx

1 1 0 0c h = c h + x : n e x t

1 1 1 0i f c h < > 9 8 1 5 6t h e n p r i n t " c h e c k s u me r r o r "

: e n d

1 1 2 0p r i n t" d a t a o k ,n o wc r e a t i n gf i l e " :p r i n t

1 1 3 0r e s t o r e

1 1 4 0o p e n 8 , 8 , 8 ," 0 : c o m m o nc o d e , p , w "

1 1 5 0p r i n t # 8 , c h r $ ( 1 ) c h r $ ( 8 ) ;

1 1 6 0f o r j = 1 t o 9 1 0 :r e a dx

1 1 7 0p r i n t # 8 , c h r $ ( x ) ;: n e x t

1 1 8 0c l o s e8

1 1 9 0p r i n t" p r gf i l e' c o m m o nc o d e 'c r e a t e d .. .

1 2 0 0p r i n t" t h i sg e n e r a t o rn o l o n g e rn e e d e d .

1 2 1 0 r e m

1 0 , 0 , 1 5 8 ,5 0 , 4 8 , 5 4

0 , 0 , 1 6 9 , 1 4 7 ,3 2 , 2 1 0

0 , 1 4 2 , 1 3 8 ,1 1 , 1 4 2 , 1 4 0

3 5 , 1 0 , 2 4 0 ,6 , 3 2 , 2 1 0

1 2 2 0d a t a 1 1 , 8 ,

1 2 3 0d a t a 4 9 , 0 ,

1 2 4 0d a t a2 5 5 ,1 6 2 ,

1 2 5 0d a t a 1 1 , 1 8 9 ,

H P

I B

B F

F B

J A

D l

O B

K B

K J

M GG D

M L

G N

G l

E L

C P

H J

H C

O P

K C

D L

M MP O

P M

F N

E P

C D

C B

C E

N P

G D

G N

F K

A B

F G

O M

N L

P E

P P

M L

D N

E C

I E

P H

D K

H I

G D

D F

G M

L P

D D

J C

H L

C B

G E

B P

M M

C F

M G

1 2 6 0d a t a2 5 5 ,

1 2 7 0d a t a 1 1 ,

1 2 8 0d a t a2 0 2 ,

1 2 9 0d a t a 3 2 ,

1 3 0 0d a t a2 1 0 ,

1 3 1 0d a t a 7 6 ,

1 3 2 0d a t a2 0 8 ,

1 3 3 0d a t a1 3 0 ,

1 3 4 0d a t a 1 0 ,

1 3 5 0d a t a 3 2 ,

1 3 6 0d a t a1 0 9 ,

1 3 7 0d a t a2 2 2 ,

1 3 8 0d a t a1 7 3 ,

1 3 9 0d a t a1 3 3 ,

1 4 0 0d a t a 1 3 ,

1 4 1 0d a t a 0 ,

1 4 2 0d a t a 2 5 5 ,

1 4 3 0d a t a 1 1 ,

1 4 4 0d a t a1 3 0 ,

1 4 5 0d a t a1 4 1 ,

1 4 6 0d a t a1 6 2 ,

1 4 7 0d a t a2 1 0 ,

1 4 8 0d a t a2 4 0 ,

1 4 9 0d a t a2 0 8 ,

1 5 0 0d a t a 0 ,

1 5 1 0d a t a2 5 5 ,

1 5 2 0d a t a 2 1 ,

1 5 3 0d a t a 1 3 ,

1 5 4 0d a t a 1 0 ,

1 5 5 0d a t a1 4 1 ,

1 5 6 0d a t a 3 2 ,

1 5 7 0d a t a 1 0 ,

1 5 8 0d a t a 2 0 3 ,

1 5 9 0d a t a 2 5 5 ,

1 6 0 0d a t a2 5 5 ,

1 6 1 0d a t a1 4 1 ,

1 6 2 0d a t a 1 1 ,

1 6 3 0d a t a 1 1 ,

1 6 4 0d a t a1 4 4 ,

1 6 5 0d a t a1 6 5 ,

1 6 6 0d a t a1 6 5 ,

1 6 7 0d a t a 9 ,

1 6 8 0d a t a1 3 7 ,

1 6 9 0d a t a 0 ,

1 7 0 0d a t a1 6 5 ,

1 7 1 0d a t a1 0 5 ,

1 7 2 0d a t a 1 1 ,

1 7 3 0d a t a2 0 8 ,

1 7 4 0d a t a2 5 1 ,

1 7 5 0d a t a 0 ,

1 7 6 0d a t a 1 1 ,

1 7 7 0d a t a2 0 8 ,

1 7 8 0d a t a1 6 2 ,

1 7 9 0d a t a2 4 0 ,

1 8 0 0d a t a2 4 3 ,

1 8 1 0d a t a 3 7 ,

1 8 2 0d a t a2 5 5 ,

1 8 3 0d a t a 2 5 5 ,

1 8 4 0d a t a2 5 3 ,

1 7 9 ,

1 3 0 ,

2 3 2 , 2 0 8 , 2 4 5 ,

3 2 , 1 6 5 ,1 0 ,

2 2 4 , 2 5 5 , 2 4 0 ,

1 9 1 , 1 0 , 1 4 4 ,

2 5 5 , 3 2 , 2 6 ,

1 0 , 2 4 0 ,1 9 7 ,

2 4 5 , 1 6 2 ,0 ,

1 1 , 3 2 , 1 7 9 ,

1 5 7 , 1 3 0 ,1 1 ,

1 0 , 2 2 4 ,

1 1 , 1 4 1 ,

2 4 , 1 0 9 ,1 3 2 ,

1 3 8 , 1 1 , 2 0 8 ,

2 5 2 ,1 7 3 ,1 3 2 ,

3 2 , 2 1 0 , 2 5 5 ,

1 8 9 , 8 9 , 1 0 ,

2 3 2 , 2 0 8 ,2 4 5 ,

3 2 , 1 6 5 ,1 0 ,

1 1 , 1 4 1 ,1 3 7 ,

1 3 6 , 1 1 , 1 6 9 ,

0 , 1 8 9 ,1 1 0 ,

2 5 5 , 2 3 2 ,2 0 8 ,

2 5 1 , 2 0 1 ,8 0 ,

2 4 3 , 2 4 0 ,3 ,

1 8 9 , 1 4 3 ,1 0 ,

2 3 2 , 2 0 8 , 2 4 5 ,

1 1 , 3 2 , 2 2 8 ,

2 4 0 , 4 6 , 3 2 ,

3 2 , 1 7 9 ,1 0 ,

1 4 1 , 1 1 , 3 2 ,

2 1 0 , 2 5 5 ,3 2 ,

2 4 , 1 0 9 , 1 4 1 ,

1 4 1 , 1 3 9 ,1 1 ,

3 2 , 2 6 , 1 1 ,

1 7 3 . 1 3 9 ,1 1 ,

1 1 , 1 7 3 ,1 3 6 ,

1 4 1 . 1 3 6 ,1 1 ,

5 6 , 2 3 7 ,1 3 9 ,

2 9 , 1 7 3 , 1 3 7 ,

2 5 1 , 2 4 , 1 0 9 ,

2 5 2 , 1 0 5 ,0 ,

2 0 6 . 1 3 7 ,1 1 ,

1 1 ,2 3 3 , 1 ,

1 7 7 , 2 5 1 , 2 0 9 ,

2 5 3 , 1 0 5 ,1 ,

0 , 1 3 3 , 2 5 4 ,

2 0 8 , 2 2 8 ,1 6 5 ,

2 2 1 , 2 4 , 1 6 5 ,

1 6 5 , 2 5 2 ,1 0 5 ,

1 4 2 . 1 4 0 ,1 1 ,

2 0 8 , 1 0 , 1 6 5 ,

3 , 7 6 , 1 1 8 ,

0 , 1 6 0 , 0 ,

1 0 , 2 0 0 ,1 7 7 ,

7 6 , 1 2 8 ,9 ,

3 2 , 2 3 7 ,1 0 ,

3 2 , 2 1 0 , 2 5 5 ,1 6 0 , 0 , 1 9 2 ,

0 , 1 5 3 ,1 4 1 ,

6

0

4 5

1 7 3

3 2

1 6 2 , 0

2 2 4 , 5

2 9 , 1 8 9

2 4 3 , 1 6 9

1 1 , 1 6 2

3 2 , 2 1 0

3 2 , 2 6

1 0 , 1 0

2 3 2 ,1 8 9

3 , 2 4 0

1 3 0 , 1 1

1 1 , 1 4 1

4 2 , 1 7 3

1 1 , 1 3 3

1 4 1 , 1 3 8

2 4 0 ,

1 6 2 ,

7 6 ,

1 1

1 3

1 0 , 2 4 0

2 4 5 , 3 2

2 4 0 , 6

3 2 , 2 1 4

2 4 0 , 9

7 6 , 6 2

2 5 5 ,2 4 0

2 1 0 , 2 5 5 ,

1 0 , 1 0 ,

2 2 8 ,2 5 5 ,

1 9 1 , 1 0 ,

1 1 , 2 0 1 ,

1 6 9 , 1 3 ,

1 6 9 , 1 3 ,

5 6 ,2 3 3 ,

1 1 , 5 6 ,

1 4 4 , 3 5 ,

1 1 , 1 4 1 ,

1 1 , 1 4 1 ,

1 3 9 , 1 1 ,

1 3 3 , 2 5 4 ,

7 6 , 7 1 ,

7 6 , 8 6 ,

2 5 3 ,2 4 0 ,

1 3 3 , 2 5 3 ,

1 6 5 , 2 5 3 ,

2 5 4 ,2 0 5 ,

2 5 1 ,1 0 5 ,

0 , 1 3 3 ,

1 6 5 , 2 5 1 ,

2 5 2 ,2 0 5 ,

1 1 , 7 6 ,

2 3 2 ,2 3 6 ,

2 5 1 , 2 0 9 ,

1 7 3 , 1 4 0 ,

1 6 9 , 3 2 ,

1 6 9 , 3 6 ,2 , 2 4 0 ,

1 1 , 2 0 0 ,

3 2 , 2 1

1 7 6 , 1 3

1 3 0 , 1 1

1 3 , 3 2

0 , 1 8 9

2 5 5 , 2 3 2

1 1 , 1 8 9

1 0 , 1 0

1 3 0 , 1 1

1 0 , 2 4

2 3 2 , 2 0 8

1 3 2 , 1 1

1 3 0 , 1 1

2 5 1 , 1 6 9

1 1 , 1 6 2

3 2 , 2 1 0

3 2 , 2 1

8 , 1 7 3

1 3 2 , 1 1

2 1 0 , 2 5 5

6 , 3 2

2 2 8 , 2 5 5

2 0 1 , 8 3

1 0 , 1 6 2

3 2 , 2 1 0

8 , 3 2

, 2 5 1 , 2 0 1

3 2 , 1 9 1

1 0 , 1 0

2 4 0 , 2 5 1

3 2 , 1 7 9

2 , 1 4 4

3 2 , 2 1 0

3 2 , 2 1 0

2 , 1 4 1

2 3 7 , 1 4 1

1 7 3 ,1 3 6

1 3 4 , 1 1

1 3 5 , 1 1

1 3 3 , 2 5 3

7 6 ,1 2 0

9 , 1 7 3

9 , 1 6 0

6 5 , 2 4

1 6 5 , 2 5 4

2 0 5 ,1 3 6

1 3 7 , 1 1

1 , 1 3 3

2 5 2 , 1 6 2

2 0 5 ,1 3 4

1 3 5 , 1 1

8 9 , 9

1 3 9 , 1 1

2 5 3 , 2 4 0

1 1 , 2 4 0

3 2 , 2 1 0

3 2 , 2 1 09 , 1 8 5

2 0 8 , 2 4 3

T h eT r a n s a c t o r 4 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 45: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 45/84

B O

1 0

C G

B C

P J

M K

A B

G GP A

I P

I M

C N

C F

B D

C A

H C

L N

N K

I F

H J

P F

C B

A B

F F

L J

E E

N L

L H

O A

G K

H K

F N

C K

F E

D P

H M

A B

A J

L P

B M

N K

N M

E A

A A

G MB B

N O

M A

P E

J K

J E

1 8 5 0

1 8 6 0

1 8 7 0

1 8 8 0

1 8 9 0

1 9 0 0

1 9 1 0

1 9 2 0

1 9 3 0

1 9 4 0

1 9 5 0

1 9 6 0

1 9 7 0

1 9 8 0

1 9 9 0

2 0 0 0

2 0 1 0

2 0 2 0

2 0 3 0

2 0 4 0

2 0 5 0

2 0 6 0

2 0 7 0

2 0 8 0

2 0 9 0

2 1 0 0

2 1 1 0

2 1 2 0

2 1 3 0

2 1 4 0

2 1 5 0

2 1 6 0

2 1 7 0

2 1 8 0

2 1 9 0

2 2 0 0

2 2 1 0

2 2 2 0

2 2 3 0

2 2 4 0

2 2 5 0

2 2 6 0

2 2 7 0

2 2 8 0

2 2 9 02 3 0 0

2 3 1 0

2 3 2 0

2 3 3 0

2 3 4 0

2 3 5 0

d a t a 3 2 ,

d a t a 3 2 ,

d a t a1 6 0 ,

d a t a 0 ,

d a t a 9 4 ,

d a t a2 1 8 ,

7 7 ,

6 9 ,

8 4 ,

8 3 ,

3 2 ,

3 2 ,

6 9 ,

6 9 ,

6 9 ,

8 0 ,

8 3 ,

7 9 ,

7 8 ,

8 4 ,

7 2 ,

1 3 ,

1 3 ,

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a

d a t a2 4 3 ,

d a t a 4 8 ,

d a t a1 7 6 ,

d a t a1 7 6 ,

d a t a1 0 4 ,

d a t a 4 ,

d a t a 3 2 ,

d a t a 3 2 ,

d a t a 1 1 ,

d a t a 6 0 ,

d a t a1 6 5 ,

d a t a1 4 1 ,

d a t a 1 1 ,

d a t a 9 6 ,

d a t a1 6 0 ,

d a t a 7 4 ,

d a t a1 0 5 ,

d a t a2 4 0 ,

d a t a1 8 9 ,

d a t a 1 1 ,

d a t a1 4 1 ,

d a t a 0 ,d a t a1 6 2 ,

d a t a 1 1 ,

d a t a 1 3 ,

d a t a1 6 9 ,

d a t a 9 6 ,

d a t a 0 ,

9 4 ,

2 1 0 ,

0 ,

1 5 3 ,

1 1 ,

9 ,

7 7 ,

1 4 6 ,

3 2 ,

3 2 ,

1 3 ,

6 9 ,

7 8 ,

8 3 ,

8 8 ,

8 5 ,

1 4 6 ,

8 2 ,

8 4 ,

6 9 ,

3 2 ,

5 5 ,

2 4 0 ,

9 6 ,

9 6 ,

1 4 ,

6 ,

1 0 4 ,

1 6 0 ,

1 8 9 ,

2 0 1 ,

1 6 5 ,

2 0 8 ,

2 0 3 ,

1 3 8 ,

2 0 8 ,

1 6 9 ,

0 ,

7 4 ,

4 8 ,

2 1 ,

1 4 1 ,

2 4 ,

1 1 ,

7 6 ,0 ,

3 2 ,

3 2 ,

7 ,

0 ,

0 ,

1 1 ,

2 5 5 ,

1 9 2 ,

1 4 1 ,

1 6 9 ,

3 2 ,

7 9 ,

1 3 ,

6 5 ,

7 3 ,

0 ,

8 2 ,

6 8 ,

8 3 ,

3 2 ,

8 4 ,

6 7 ,

3 2 ,

6 9 ,

3 2 ,

7 3 ,

1 5 7 ,

6 ,

2 0 1 ,

5 6 ,

2 0 1 ,

2 0 1 ,

7 6 ,

2 5 5 ,

2 5 5 ,

2 5 5 ,

2 0 3 ,

1 9 ,

2 0 1 ,

1 1 ,

2 2 2 ,

1 ,

1 8 9 ,

7 4 ,

1 5 3 ,

1 7 6 ,

1 1 ,

1 0 5 ,

7 6 ,

3 5 ,2 2 4 ,

2 1 0 ,

2 1 0 ,

1 4 1 ,

0 ,

7 ,

7 6 , 1 2 8 ,

1 6 9 , 3 6 ,

2 , 2 4 0 ,

1 1 , 2 0 0 ,

1 ,

3 2 ,

7 8 ,

1 3 ,

6 8 ,

7 8 ,

7 3 ,

8 2 ,

3 2 ,

3 2 ,

1 3 ,

3 2 ,

8 2 ,

1 8 ,

8 2 ,

7 6 ,

1 4 1 ,

3 2 ,

3 2 ,

8 3 ,

6 8 ,

3 2 ,

7 8 ,

7 9 ,

6 5 ,

7 3 ,

0 ,

8 4 ,

6 9 ,

8 0 ,

1 3 ,

6 9 ,

7 8 ,

0 ,

9 , 1 6 9 , 1 3

3 2 , 2 1 0 , 2 5 5

9 , 1 8 5 , 2 5 1

2 0 8 , 2 4 3 ,3 2

1 4 0 , 1 1 ,

1 8 , 6 7 ,

6 7 , 7 9 ,

8 4 , 6 5 ,

8 2 , 6 9 ,

6 9 ,

8 5 ,

1 3 ,

6 8 ,

3 2 ,

8 5 ,

3 2 ,

7 8 ,

8 2 ,

3 2 ,

3 2 ,

1 5 7 ,1 3 0 ,

5 8 ,1 7 6 ,

2 3 3 , 5 5 ,

6 5 ,1 7 6 ,

4 8 ,1 4 4 ,

6 2 , 8 ,

3 2 , 1 8 6 ,

3 2 , 1 9 2 ,

9 6 , 1 6 9 ,

2 0 1 , 6 4 ,

1 7 3 ,1 3 8 ,

6 4 ,2 0 8 ,

7 6 ,2 4 2 ,

9 6 ,1 6 9 ,

1 3 3 , 2 0 4 ,

1 4 1 , 1 1 ,

2 0 1 , 1 0 ,

1 3 0 , 1 1 ,

3 2 ,2 2 4 ,

4 1 , 1 5 ,

5 5 , 7 6 ,

6 8 , 1 1 ,

1 1 , 9 6 ,4 , 2 4 0 ,

2 5 5 ,2 3 2 ,

2 5 5 , 9 6 ,

1 3 9 , 1 1 ,

0 , 0 ,

0 , 0 ,

7 2 ,

8 0 ,

8 2 ,

6 8 ,

7 8 ,

7 9 ,

7 9 ,

6 9 ,

1 4 6 ,

0 ,

7 8 ,

7 2 ,

7 6

7 9

6 8

8 2

8 3

8 8

8 4

0

8 2

7 2

8 4

1 8

3 2

7 3

8 9

8 4

8 8

6 6

7 1

6 9

2 0 7 , 2 5 5 ,2 0 1

1 1 , 2 3 2 , 2 0 8

4 , 5 6 , 2 3 3

9 6 , 2 0 1 ,7 1

8 , 2 0 1 ,5 8

2 , 2 4 , 9 6

1 6 9 , 7 , 1 6 2

2 5 5 ,1 6 9 , 0

2 5 5 ,1 6 2 , 7

0 , 1 4 1 ,1 3 8

2 4 0 , 2 3 , 2 0 1

1 1 , 2 0 8 , 1 9

2 5 0 ,1 6 9 , 1

1 0 , 1 7 3 ,1 3 8

0 , 1 3 3 , 2 0 4

9 6 , 1 6 2

4 1 , 2 4 0

1 7 6 , 2 6

2 0 0 ,1 9 2

0 , 2 4 0

2 0 2 , 7 6

1 1

2

3 19 , 1 8 9 ,1 3 0

2 0 8 , 2 4 3 ,1 6 9

3 2 ,2 0 4 ,2 5 5

3 2 , 1 9 5 , 2 5 5

0 , 0 , 0

0

5 1 ,

1 6 0 ,

3 2 ,

1

7 4

2 4

3

2 1

4 4

1 8 9

1 6 2

1 1

C o m m o nC o d e :P A Ls o u r c ec o d e

D A

N B

N MJ C

P J

M H

1 0 0 0 r e ms a v e ' O x o m m o nc o d e . p a l 1 , 8

1 0 1 0o p e n8 , 8 , 8 , ' 0 : c o m m o nc o d e . p . w

1 0 2 0 s y s 7 0 01 0 3 0 .o p t0 8

1 0 4 0; • c o m m o nc o d eb y j a c kr . f a r r a h

1 0 5 0p r o g r a mt o f i n d i d e n t i c a lc o d es e q u e n c e s

M NC NC PC GP F

D P

I F

N l

N CK O

E E

C l

G GP L

E D

O EE F

C GC A

L K

H B

D DD H

A L

P L

J A

P P

I K

P J

J NF OH F

N l

E M

E F

G BM DJ K

C E

E A

I N

N L

E N

K L

C D

O A

G CO l

G K

F O

I L

J G

F E

C JH B

G CC F

J l

I E

N N

M H

G K

E G

L J

P E

J F

L N

K CD P

G PN DH A

O CL B

F G

K H

I L

K OF J

H MN D

A l

F E

1 0 6 0; i nm a c h i n el a n g u a g ep r o g r a m sf o ru s e

1 0 7 0; a sp o s s i b l e s u b r o u t i n e s .

1 0 8 0; t e s t e dp r o g r a mt o b e i n m e m o r y .

1 0 9 0; a l l u s e rn p u t si n h e x .

1 1 0 0; s c r e e no r p r i n t e ro u t p u t .

1 1 1 0; s p a c eb a rp a u s e sl i s t i n g .

1 1 2 0; * c o n s t a n t s<

1 1 3 0 c h r m

1 1 4 0 c h r o u t

1 1 5 0g e t i n

1 1 6 0 s t a d d

1 1 7 0 c k a d d

1 1 8 0s e t l f s

1 1 9 0 s e t n a m

1 2 0 0o p e n

1 2 1 0c l o s e

1 2 2 0 c h k o u t

1 2 3 0 c l r c h n

=

=

=

=

=

=

=

=

=

=

1 2 4 0 * = $ 0 8 0 1

1 2 5 0. w o r d t w o b r k

1 2 6 0. b y t e1 0 , 0

1 2 7 0. b y t e$ 9 e

1 2 8 0. a s c ' 2 0 6 1■

1 2 9 0

1 3 0 0 t w o b r k

1 3 1 0

1 3 2 0

1 3 3 0b e g i n

1 3 4 0

1 3 5 0

b r k

$ f f c f

$ f f d 2

$ f f e 4

$ f b

$ f d

$ f f b a

$ f f b d

S f f c O

$ f f c 3

$ f f c 9

$ f f c c

. w o r d 0

I d a

j s r

I d x

s t x

s t x

# 1 4 7

c h r o u t

# 0

i n f l g

m t c h f l g1 3 6 0; * g e tu s e rs t a r ta d d r e s s *

1 3 7 0t i t l

1 3 8 0

1 3 9 0

1 4 0 0

1 4 1 0

1 4 2 0s t a r t

1 4 3 0

1 4 4 0

1 4 5 0 c h e c k

1 4 6 0

1 4 7 0c k 1

1 4 8 0

1 4 9 0

1 5 0 0

1 5 1 0

1 5 2 0

I d a

b e q

j s r

i n x

b n e

I d x

j s r

j s r

c p x

b c s

d e x

c p x

b e q

I d a

j s r

b c c

t i t l e . x

s t a r t

c h r o u t

t i t l

# 0

c r o n

g e t

# 5

e r r o r

# 2 5 5

c o n v e r t

h x a d d . x

e v a l

c k 1

1 5 3 0; * e r r o rm e s s a g el o o p *

1 5 4 0e r r o r

1 5 5 0

1 5 6 0

1 5 7 0

1 5 8 0e r 1

1 5 9 0

1 6 0 0

1 6 1 0

1 6 2 0

I d a

j s r

j s r

I d x

I d a

b e q

j s r

i n x

b n e

# $ 0 d

c h r o u t

c r o f

# 0

e r m e s s . x

b e g i n

c h r o u t

e r 1

; g e t m u l t . c h a r . i n p u t

; p r i n tt o d e v i c e

; g e ts i n g l e c h a r .

; s t a r ta d d r e s s

; c h e c ka d d r e s s

; s e t l o g .f i l e

; n a m e f i l e

; o p e nf i l e

; c l o s ef i l e

; s e to u t p u tf i l e

; r e s t o r e d e f a u l t s

; 2 0 4 9

; f o r w a r d p o i n t e r

; l i n en u m b e r

; ' s y s 'k e y w o r dt o k e n

; s y sa d d r e s s

; c l e a rs c r e e n

; c l e a r f l a g s

; p r i n tp r o g ,n a m e

; a n ds t a r ta d d .

; i n p u tm e s s a g e

; s e ti n d e x

; b l i n kc u r s o r

; g e ta d d r e s s

; ' > 4c h a r a c t e r s ?

; o n l yw a n t4

; r e s e tf o rc r c o u n t e d

; o n l ya f t e r4

; m a k eb i n a r y

; g e th e xa s c i i

; c h e c ki f v a l i d

; o k . g e tn e x tc h a r .

; c r

; t u r no f fc u r s o r

; p r i n te r r o rm e s s a g e

; s t a r to v e r

1 6 3 0; * c h a n g ea s c i ih e xt o b i n a r y& s t o r e

1 6 4 0c o n v e r t

1 6 5 0

1 6 6 0l o o p

1 6 7 0

1 6 8 0

1 6 9 0

1 7 0 0a s l

1 7 1 0a s l

1 7 2 0

1 7 3 0

1 7 4 0

1 7 5 0

1 7 6 0

1 7 7 0

1 7 8 0

1 7 9 0

1 8 0 0

1 8 1 0

1 8 2 0

1 8 3 0o v e r

1 8 4 0

1 8 5 01 8 6 0 e n d

1 8 7 0

1 8 8 0

I d x

j s r

I d a

j s r

a s l

a s l

s t a

i n x

I d a

j s r

c p x

b e q

c l c

a d c

s t a

i n x

b n e

c l c

a d c

s t aI d a

b n e

I d a

# 0

c r o f

h x a d d . x

m a k b i

h x a d d . x

h x a d d , x

m a k b i

# 3

o v e r

h x a d d

h x a d d

l o o p

h x a d d +2

h x a d d +2i n f l g

o u t p u t

h x a d d

; s e ti n d e x

; u n b l i n kc u r s o r

; g e ta s c i i

; m a k eb i n a r y

; s h i f tv a l u ei n t o

; h i g hn y b b l ep o s i t i o n

; s a v ei t

; r a i s ei n d e x

; g e tn e x ta s c i i

; m a k eb i n a r y

; ' 4 t hc h a r a c t e r ?

; y e s .f i n i s hh e r e

; n o

; a d d t o h i g hn y b b l e

; s a v ec o m b i n e dv a l u e

; r a i s ei n d e x

; a l w a y sb r a n c h

; a d dl o wn y b b l eo f

; l o wb y t et o h i g h

; a n ds a v ei t

; ' d o n ee n da d d r e s s ?

; y e s . f l a gs e t

; n o . s a v es t a r ta d d .

T h eT r a n s a c t o r 4 3 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 46: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 46/84

M F

N MO CK K

B GK P

J F

K K

J A

F N

N J

M K

O DP I

B A

C BD OD B

M GB l

G KO F

F B

H D

J J

F C

M CH E

G FP L

N L

M CN NK E

P KC AB OP F

A H

D F

L I

A A

N NM OB L

O NN M0 0M CD NB A

N l

B L

E J

K E

D DN DH EO MA MO HH I

F BI P

A F

K DA MF B

L L

O DF P

A HC OG GN BG AL N

I A

K CC OD A

I J

O E

1 8 9 0

1 9 0 0

1 9 1 0

1 9 2 0

1 9 3 0

1 9 4 0

s t a s t a d d+ 1

I d a h x a d d+ 2

s t a s t a d d

I d a # $ 0 d

j s r c h r o u t

s t a i n f l g

1 9 5 0; * g e tu s e re n da d d r e s s *

1 9 6 0

1 9 7 0 e n d 1

1 9 8 0

1 9 9 0

2 0 0 0

2 0 1 02 0 2 0n e x t

2 0 3 0

2 0 4 0

2 0 5 0

2 0 6 0o u t p u t

2 0 7 0

2 0 8 0

2 0 9 0

2 1 0 0

2 1 1 0

I d x # 0

I d a e n d m e s s . x

b e q n e x t

j s r c h r o u t

i n x

b n e e n d 1I d x # 0

j s r c r o n

j s r g e t

j m p c h e c k

I d a h x a d d

s t a e n c k + 1

I d a h x a d d+ 2

s t a e n c k

I d a # $ 0 d

j s r c h r o u t

; o n z e r op a g e

; c r

; s e tf l a g

; c l e a ri n d e x

; p r i n tm e s s a g e

; c l e a rf o rc h a r ,c o u n t

; b l i n kc u r s o r

; g e t t h ea d d r e s s

; c h e c k & m a k eb i n a r y

; g e tb i n a r ye n da d d .

; a n ds t o r ei n z e r op a g e

; c r

2 1 2 0; * g e to u t p u td e s t i n a t i o nf r o m u s e r *

2 1 3 0

2 1 4 0o u t 1

2 1 5 0

2 1 6 0

2 1 7 0

2 1 8 0

2 1 9 0g e t i t

2 2 0 0

2 2 1 0

2 2 2 0

2 2 3 0

2 2 4 0

2 2 5 0

2 2 6 0p r i n t

I d x # 0

I d a o u t m e s s . x

b e q g e t i t

j s r c h r o u t

i n x

b n e o u t 1

j s r g e t i n

b e q g e t i t

c m p# 8 0

b e q p r i n t

c m p# 8 3

b n e g e t i t

b e qb y t e

j s r p r o u t

2 2 7 0; * g e tb y t eI g t h .f r o mu s e r *

2 2 8 0b y t e

2 2 9 0b y t l u p

2 3 0 0

2 3 1 0

2 3 2 0

2 3 3 0

2 3 4 0e r j m p

2 3 5 0g t b y t

2 3 6 0g t 2

2 3 7 0

2 3 8 0

2 3 9 0

2 4 0 0

2 4 1 0

2 4 2 0

2 4 3 0

2 4 4 0a s l

2 4 5 0a s l

2 4 6 0a s l

2 4 7 0

2 4 8 0g t 1

2 4 9 0

2 5 0 0

2 5 1 02 5 2 0

2 5 3 0

2 5 4 0

2 5 5 0

2 5 6 0

2 5 7 0

2 5 8 0

2 5 9 0

I d x # 0

I d a b y t m e s s . x

b e q g t b y t

j s r c h r o u t

i n x

b n e b y t l u p

j m p e r r o r

j s r c r o n

j s r g e t i n

b e qg t 2

c m p# $ 0 d

b e qs e t e n d

j s r c h r o u t

j s r e v a l

j s r m a k b i

a s l

s t a h l d r

j s r g e t i n

b e qg t 1

j s r c h r o u t

j s r e v a lj s r m a k b i

c l c

a d c h l d r

c m p# 2

b c c e r j m p

s t a c k b y t

I d a # $ 0 d

j s r c h r o u t

2 6 0 0; * c a l c u l a t ee n da d d r e s s e s

2 6 1 0 s e t e n d

2 6 2 0

2 6 3 0

2 6 4 0

2 6 5 0

2 6 6 0

2 6 7 0

2 6 8 0

2 6 9 0

2 7 0 0

2 7 1 0

T h eT r a n s a c t o r

j s r c r o f

I d a # $ 0 d

j s r c h r o u t

I d a c k b y t

s e c

s b c # 2

s t a h l d r

I d a e n c k

s e c

s b c h l d r

s t a e n c k

; p r i n tm e s s a g e

; g e t' s ' o r ' p '

; w a i tf o rk e y

; ' p ?; y e s .o p e np r i n t e r

; " n o .s ?

; n o . g ob a c kf o rk e y

; s c r e e n o u t p u t

; o p e np r i n t e rf i l e

; p r i n tm e s s a g e

; o u to f r a n g ea v o i d e r

; b l i n kc u r s o r

; g e tk e y

; w a i tf o rk e y

; - c r ?

; d e f a u l ts e l e c t e d

; n e wv a l u e ,p r i n ti t

; c h e c kr a n g e

; m a k eb i n a r y

; s h i f tt o h i n y b b l e

; s a v ei t

; g e ts e c o n dc h a r .

; w a i tf o ri t

; p r i n t i i t

; c h e c kr a n g e; m a k eb i n a r y

; a d dt o h i n y b b l e

; ' > 1 ?

; < 2n o ta l l o w e d

; s t o r en e wv a l u e

; c r

; u n b l i n kc u r s o r

; c r

; g e tI g t h .t o c h e c k

; s u b t r a c t2

; t e m p o r a r ys a v e

; l o wb y t ee n da d d .

s u b t r a c t v a l u e

; s a v en e wv a l u e

C F

O l

F D

L A

F J

L K

D CD N

B J

A HL G

P L

H EO EH E

N l

M J

C KN HL F

E M

M JH NF M

F K

D F

O NB A

H J

G NO HD L

O OG NP A

I E

B P

H K

L K

I B

N F

C l

C A

I A

F D

B A

F P

J D

F M

L G

E E

H CO MN H

H I

H I

J C

G F

P C

F E

O FF A

L CC G

H OB B

P A

E B

L J

O MI A

I H

H E

B F

H CF G

M KG KH MO NC ON FO H

4 4

2 7 2 0

2 7 3 0s e t 1

2 7 4 0

2 7 5 0

2 7 6 0

2 7 7 0

2 7 8 0

2 7 9 0s e t 2

2 8 0 0s e t 3

2 8 1 0

2 8 2 0

2 8 3 0

2 8 4 02 8 5 0

2 8 6 0

2 8 7 0

2 8 8 0s u b h i

2 8 9 0

2 9 0 0s u b 2

2 9 1 0

2 9 2 0

2 9 3 0 ; * m a i n

2 9 4 0m a i n

2 9 5 0

2 9 6 0

2 9 7 0

2 9 8 0m a 1

2 9 9 0

3 0 0 0

3 0 1 0

3 0 2 0

3 0 3 0

3 0 4 0

3 0 5 0

3 0 6 0

3 0 7 0

3 0 8 0

3 0 9 0

3 1 0 0

3 1 1 0

3 1 2 0

3 1 3 0

3 1 4 0

3 1 5 0

3 1 6 0

3 1 7 0

3 1 8 0

3 1 9 0

3 2 0 0

3 2 1 0

3 2 2 0

3 2 3 0

3 2 4 0

3 2 5 0

3 2 6 0

3 2 7 0r e t u r n

b c c s u b h i

I d a e n c k

s e c

s b c c k b y t

s t a m t c h c k

b c c s u b 2

I d a e n c k + 1

s t a m t c h c k +1

I d a s t a d d

c l c

a d c c k b y t

s t a c k a d d

I d a s t a d d+ 1a d c # 0

s t a c k a d d+ 1

j m p m a i n

d e c e n c k + 1

j m ps e t 1

I d a e n c k+ 1

s b c # 1

j m p s e t 2

s r o g a ml o o p *

I d y # 0

I d a ( s t a d d ) . y

c m p( c k a d d ) , y

b e q g o t m t c h

c l c

I d a c k a d d

a d c # 1

s t a c k a d d

I d a c k a d d +1

a d c # 0

s t a c k a d d+ 1

I d a c k a d d

c m pe n c k

b n e m a i n

I d a c k a d d+ 1

c m pe n c k+ 1

b n e m a i n

c l c

I d a s t a d d

a d c # 1

s t a s t a d d

I d a s t a d d+ 1

a d c # 0

s t a s t a d d+ 1

I d x # 0

s t x m t c h f l g

I d a s t a d d

c m pm t c h c k

b n e r e t u r n

I d a s t a d d+ 1

c m pm t c h c k + 1

b n e r e t u r n

j m p e x i t

j m p s e t 3

; r e d u c eh i b y t e

; g e tn e we n da d d .

; s u b t r a c tb y t eI g t h

; s a v ea s c h e c kv a l u e

; r e d u c eh i b y t e

; g e th i b y t en e we n d

; m a k es a m eh e r e

; s t a r ta d d .l o wb y t e

; a d d b y t eI g t h

; c h e c kp o i n t e r

; h ib y t e; a d dc a r r y

; p u t i n p o i n t e r

; s t a r t m a i nl o o p

; c l e a rf o ri n d .a d d .m o d e

; g e tv a l u ea t s t a r t

; n e x t t oc h e c k

; t h e ym a t c h . c h e c km o r e .

; n om a t c h :

; a d d1 t o c h e c ka d d .

; s t o r eb a c k

; f i xh i g h b y t e

; s t o r e

; h a v ew e r e a c h e d

/ e n do f p o s s i b l eb y t e s ?

; n o . s t a r tn e x ts e r i e s

; l ob y t e sm a t c h e d

/ h i b y t e ss a m e ?

; n o . c o n t i n u e

; d o n ew i t ht h i ss e r i e s

; m o v es t a r tp o i n t e r

; t on e x th i g h e s t b y t e

; s t o r ei t

; f i xh i b y t e

; c l e a rf l a gt o s h o wp r i n t

; r o u t i n et h i si s n e wa d d .

; c o m p a r es t a r ta d d .

; w i t hl a s tc h e c k a b l eb y t e

; n o m a t c hl o wb y t e

; c h e c kh i b y t e

; n o m a t c h

; a l ld o n e ,c l o s eu p

; o u t o fr a n g ea v o i d e r

3 2 8 0; * c h e c kr e m a i n i n g b y t e sf o rm a t c h *

3 2 9 0 g o t m t c hI d x # 0

3 3 0 0

3 3 1 0l u p

3 3 2 0

3 3 3 0

3 3 4 03 3 5 0

3 3 6 0

3 3 7 0

3 3 8 0

I d y # 0

i n x

c p x c k b y t

b e q p r n t

i n y

I d a ( s t a d d ) . y

c m p( c k a d d ) , y

b e q l u p

j m p m a 1

3 3 9 0; * h e r ei f a l lb y t e sm a t c h .

3 4 0 0p r n t

3 4 1 0

3 4 2 0p m t 1

3 4 3 0

3 4 4 0

3 4 5 0

3 4 6 0

3 4 7 0

3 4 8 0

3 4 9 0 m r 2

3 5 0 0

3 5 1 0

3 5 2 0

3 5 3 0

3 5 4 0

I d a m t c h f l g

b e q p r s t

j s r w a i t

I d a # 3 2

j s r c h r o u t

j s r c h r o u t

I d a # 3 6

j s r c h r o u t

I d y # 0

c p y # 2

b e q m r 1

I d a c k a d d , y

s t a h l d r . y

i n y

b n e m r 2

; c l e a ri n d i c e s

; x c o u n t sb y t e sm a t c h e d

/ c h e c k e da l l ?

; y e s . p r i n t' e m

; n o .i n d e xt o n e x tb y t e; g e tn e x tf r o ms t a r t

; c h e c kf o re q u a l i t y

; m a t c h e s . g e t a n o t h e r

; n om a t c h . m o v eu p a b y t e

/ p r i n t e dt h i ss t a d d ?

; n o ,s o p r i n ti t

; c h e c kf o rs p a c eb a r

; i n d e n t2 s p a c e s

; $

; s e tu p t o g e t 2 b y t e s

; g e ta d d .o f m a t c h i n gb y t e s

; s t o r ef o rc o n v e r s i o n

; g e t2 n db y t e

; a l w a y sb r a n c h

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 47: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 47/84

H L

P F

O MM FN ND L

B P

F M

I D

G FL F

O G

D MM GG NP D

P F

N M

N P

O L

J B

K K

A E

G N

F OL D

M E

M E

P H

G GK N

J C

F K

H I

P I

G CF L

C J

N F

I L

A KA D

N D

P M

D C

P MG J

C NP F

G D

P F

B P

A GG GJ D

K D

H I

N OK N

F A

P K

D M

I B

B l

B l

N NI I

B L

B P

G HM F

J H

J H

M OJ l

J H

O J

E A

F M0 0F E

I M

J E

3 5 5 0m i i

3 5 6 0

j s r p r n t h x

j m p m a 1

; c o n v e r ta n dp r i n ta d d .

; r e s e tc k a d d a n dl o o p a g a i n

3 5 7 0; * p r i n ts t a r ta d d r e s sm a t c h e d *

3 5 8 0p r s t

3 5 9 0

3 6 0 0

3 6 1 0

3 6 2 0

3 6 3 0p r 2

3 6 4 0

3 6 5 0

3 6 6 0

3 6 7 0

3 6 8 0

3 6 9 0p r 1

3 7 0 0

3 7 1 0

3 7 2 0

3 7 3 0 ; * t e x t *

3 7 4 0t i t l e

I d a # $ 0 d

j s r c h r o u t

I d a # 3 6

j s r c h r o u t

I d y # 0

c p y # 2

b e q p r 1

I d a s t a d d . y

s t a h l d r . y

i n y

b n e p r 2

j s r p r n t h x

I d a # 1

s t a m t c h f l g

j m p p r n t i

; c r

; $

; s e tt o g e t2 b y t e s

; g e t1 s t b y t e

; s a v ef o rc o n v e r s i o n

; s e tf o rn e x tb y t e

; c o n v e r ta n dp r i n t

; s e tf l a g t os h o w

; s t a d dw a sp r i n t e d

; g op r i n tc k a d d

. b y t e $ 2 0 , $ 2 0 , $ 2 0 , $ 1 2

3 7 5 0. a s c■ c o m m o nc o d e ' :. b y t e$ 9 2 , $ 0 d , $ 0 d

3 7 6 0. a s c' s t a r ta d d r e s si n h e x'

3 7 7 0e r m e s s

3 7 8 0 e n d m e s s

3 7 9 0o u t m e s s

3 8 0 0. a s c" S " : .

. a s c' i n p u t e r r o r "

. b y t e $ O d , $ O O

. b y t e$ 0 d , $ 0 0

. a s c" e n da d d r e s si n h e x' : . b y t e$ 0 d , $ 0 0

. a s c" o u t p u tt o ' :

b y t e$ 9 2

3 8 1 0. a s c' c r e e n o r ' :. b y t e $ 1 2

3 8 2 0. a s c" p 1 :b y t e$ 9 2

3 8 3 0. a s c' r i m e r ' :. b y t e$ O d , $ O C

3 8 4 0b y t m e s s. a s c" b y t el e n g t h

3 8 5 0; * s u b r o u t i n e s *

3 8 6 0g e t

3 8 7 0

3 8 8 0

3 8 9 0

3 9 0 0

3 9 1 0

3 9 2 0 d o n e

3 9 3 0 ; » m a k e 1

3 9 4 0m a k b i

3 9 5 0

3 9 6 0

3 9 7 0

3 9 8 0

3 9 9 0l e t

4 0 0 04 0 1 0

j s r c h r i n

c m p # $ 0 d

b e q d o n e

s t a h x a d d , x

i n x

b n e g e t

r t s

b y t e$ 1 2

i n h e x " :. b y t e $ 0 d , $ 3 7 , $ 9 d , $ 0 0

; g e tu s e ri n p u t

; ' c r ?

; y e s . e x i tr o u t i n e

; s t o r ea s c i ic h a r .

; r a i s ei d e xf o rn e x t

; g og e ti t

b y t ea s c i ii n a b i n a r y *

c m p# 5 8

b c s l e t

s e c

s b c # 4 8

r t s

s e c

s b c # 5 5r t s

4 0 2 0; * c h e c ki f v a l i dh e xa s c i i *

4 0 3 0e v a l

4 0 4 0

4 0 5 0

4 0 6 0

4 0 7 0

4 0 8 0

4 0 9 0

4 1 0 0

4 1 1 0g o o d

4 1 2 0

4 1 3 0b a d

4 1 4 0

4 1 5 0

c m p# 7 1

b c s b a d

c m p# 6 5

b c s g o o d

c m p# 5 8

b c s b a d

c m p# 4 8

b c c b a d

c l c

r t s

p l a

p l a

j m p e r r o r

4 1 6 0; * s e t u pp r i n t e rf i l e *

4 1 7 0 p r o u t

4 1 8 0

4 1 9 0

4 2 0 0

4 2 1 0

4 2 2 0

4 2 3 0

4 2 4 0

4 2 5 0

4 2 6 0

I d a # 7

I d x # 4

I d y # $ f f

j s r s e t l f s

I d a # 0 0

j s r s e t n a m

j s r o p e n

I d x # 7

j s r c h k o u t

r t s

; ' = > 9 ?

; y e s ,i t sa l e t t e r

; n os o s u b t r a c t4 8

; f o re q u i v .n u m b e r

; r e t u r n

; f o ra t o f

; s u b t r a c t 5 5

; ' = > g ?; y e s ,n o g o o d

; " i t s <g . i s i t= > a ?; y e s ,i t sv a l i d

; " i t s < a . i s i t= > : ?

; y e s . n og o o d

; " < : . i s i t < 0 ?

; y e s .n o g o o d

; r a n g eo k .

; b a c kt o c a l l e r

; i n v a l i d . p u l lr e t u r n

; a d d .f r o ms t a c k

; u s e rr e s t a r t

; f i l e#

; d e v i c e

; b o g u s s e c o n d ,a d d .

; d e f i n et h ef i l e

; n o n a m e ,n o l e n g t h

; r e q u i r e dc a l l

; o p e nf i l e7

; s e tf i l e7 f o ro u t p u t

; b a c kt o c a l l e r

4 2 7 0; * c h e c k / a c c e p ts p a c eb a rp a u s e *

4 2 8 0w a i t

4 2 9 0

4 3 0 0w a 2

4 3 1 0

4 3 2 0

4 3 3 04 3 4 0

4 3 5 0

4 3 6 0

4 3 7 0 w a 1

T h eT r a n s a c t o r

I d a # 0

s t a i n f l g

I d a $ c b

c m p# 6 4

b e q g o o n

c m p# 6 0b n e g o o n

I d a i n f l g

b n eg 1

I d a $ c b

; c l e a rf l a g t os h o w

; w e ' r e n o tw a i t i n g

; c u r r e n tk e y p r e s s e d

; 6 4= n o k e y

; n o k e y ,n o t h i n gt o d o

; " s p a c e b a r ?; n o ,s o i g n o r e

; w a ss p a c eb a r .

; i f s e t , w a i ti s o v e r

; s t a r tt h ew a i t

L F

O A

L P

G FF D

K E

G NM KB K

A L

F l

G HB K

H GN KO J

E N

D GI L

A A

H MK H

B N

L N

F OA ON J

M OL A

M J

D CE O

E F

B A

D KO NA N

H EM KL M

I M

L E

N PO PF L

C JL MF E

I C

N OK GM B

C J

H I

B A

P B

E M

F N

F E

B E

H L

G DC AM HD E

F B

F D

E E

A D

C D

M MN B

F G

O l

L H

G O

4 5

4 3 8 0

4 3 9 0

4 4 0 0

4 4 1 0

4 4 2 0

4 4 3 0 g o o n

4 4 4 0

4 4 5 0g 1

c m p# 6 4

b n ew a 1

I d a # 1

s t a i n f l g

j m pw a 2

I d a i n f l g

b n ew a 2

r t s

4 4 6 0; * s t a r tc u r s o rb l i n k *

4 4 7 0c r o n

4 4 8 0

4 4 9 0

I d a # 0

s t a $ c c

r t s

4 5 0 0; * s t o pc u r s o rb l i n k *

4 5 1 0c r o f

4 5 2 0

4 5 3 0

I d a # 1

s t a $ c c

r t s

; f o rs p a c eb a rr e l e a s e

; k e e pw a i t i n g

; s e tf l a g t os h o w

; w e ' r e l o o k i n gf o r2 n d

; h i to f s p a c e b a r

; i ff l a gs e t

; k e e pl o o k i n g

; t h ew a i t so v e r

; c l e a rt h i sb y t e

; t os t a r tb l i n k

; s e tb y t et o

; s t o p b l i n k

4 5 4 0; * 2b y t e b i n a r yt o 4 b y t ea s c i ih e x *

4 5 5 0m a k h x

4 5 6 0

4 5 7 0h x 3

4 5 8 0

4 5 9 0

4 6 0 0I s r

4 6 1 0I s r

4 6 2 0I s r

4 6 3 0h x 1

4 6 4 0

4 6 5 0

4 6 6 0

4 6 7 0h x 2

4 6 8 0

4 6 9 0

4 7 0 0

4 7 1 0

4 7 2 0

4 7 3 0

4 7 4 0

4 7 5 0h x 4

4 7 6 0

4 7 7 0

4 7 8 0a d m o r

4 7 9 0

4 8 0 0

4 8 1 0s k i p

4 8 2 0

4 8 3 0n x t b y t4 8 4 0

4 8 5 0

4 8 6 0d u n

I d x # 1

I d y # 0

I d a h l d r . x

a n d # $ f 0

I s r

c m p# 1 0

b c s a d m o r

c l c

a d c # 4 8s t a h x a d d , y

i n y

c p y # 3

b e q s k i p

b c s d u n

c p x # 0

b e q n x t b y t

I d a h l d r . x

a n d # $ 0 f

d e x

j m p h x 1

c l c

a d c # 5 5

j m p h x 2

I d a h l d r . x

j m p h x 4

I d y # 2I d x # 0

j m p h x 3

r t s

; x s e tt o g e tb y t e

; y s e tt o s a v ea s c i i

; g e tb y t e ( h if i r s t )

; m a s kl o wn y b b l e

; s h i f th i n y b b l et o l o w

; " = > 1 0 ?

; y e s ,m a k el e t t e r

; n o .n u m b e r

; a d d4 8 f o ra s c i i

; s t o r ei t

; r a i s ec o u n t e r

; " d o n e 3 n y b b l e s ?

; y e s , d o 4 t h

; y > 3 . w e ' r ed o n e

; " y < 3 . h i b y t e d o n e ?

; y e s . d ol o w

; n o . g e t l o n y b , h i b y t e

; m a s kh i n y b b l e

; l o w e rc o u n t e r

; m a k ea s c i i

; c o n v e r tb i n a r yl e t t e r

; t oa s c i ib y

; a d d i n g5 5

; g e tl o b y t el a s tt i m e

; d o l on y b b l e

; r e s e ti n d i c e sf o; 2 n da d d r e s sb y t e

; l o o pa g a i n

; r e t u r n

4 8 7 0; * p r i n th e xa d d . s t o r e di n h x a d d *

4 8 8 0p r n t h x

4 8 9 0

4 9 0 0l u p e

4 9 1 0

4 9 2 0

4 9 3 0

4 9 4 0

4 9 5 0

4 9 6 0f i n

4 9 7 0

4 9 8 0

j s r m a k h x

I d x # 0

c p x # 4

b e qf i n

I d a h x a d d , x

j s r c h r o u t

i n x

b n e l u p e

I d a # $ 0 d

j s r c h r o u t

r t s

; b i n a r yt o h e x

; c l e a ri n d e x

; d o 4n u m b e r s

; g e ta s c i ih e x

; p r i n ti t

; p o i n tt o n e x tc h a r .

; a l w a y sb r a n c h

; c r

; r e t u r n

4 9 9 0; * p r o g r a mf i n i s h e d ,c l e a nu p *

5 0 0 0e x i t

5 0 1 0

5 0 2 0

5 0 3 0

5 0 4 0

j s r c l r c h n

I d a # 7

s t a c k b y t

j s r c l o s e

r t s

5 0 5 0; * s t o r a g e *

5 0 6 0 h x a d d

5 0 7 0 m t c h c k

5 0 8 0e n c k

5 0 9 0i n f l g

5 1 0 0 c k b y t

5 1 1 0m t c h f l g

5 1 2 0h l d r

5 1 3 0. e n d

. b y t e0 , 0 , 0 , 0

. b y t e0 , 0

. b y t e0 , 0

. b y t e O

. b y t e$ 0 7

. b y t e O

. b y t e0 , 0

; r e s e t d e f a u l td e v i c e s

; d e f a u l tv a l u e& f i l e #

; s a v ei t

; c l o s e f i l e 7

; b a c kt o b a s i c

; 4 b y t e st o h o l da s c i ih e x

; l a s ta d d .t o c h e c k

; l a s t a d d .f o rm a t c h

; u s e ra d d .i n p u tf l a g

; # b y t e st o m a t c h

; n e wg r o u pf l a g

; t e m p o r a r y s t o r a g e

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 48: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 48/84

G e t t i n gA r o u n d

W i t hG o g oD a n c e r

O n eo f t h en i c e s tt h i n g sC o m m o d o r ed i df o rt h e6 4 w a sb u i l di n a

f a i r l yg u t l e s sB a s i cw i t hl o t so f R A Mv e c t o r sf o rh a c k e r st o p l a y

w i t h . I ' ma w a r et h a tt h ew o r l dp r o b a b l yd o e sn o tr e a l l yn e e d

a n o t h e rC H R G E Tw e d g eb u t w h e nt h i s i d e ac a m et o m e , I

c o u l d n ' ts e e mg e ti t o u to f m ym i n d .A sa m a t t e ro f f a c t ,I a l m o s t

n a m e dt h e p r o g r a mG O G OC R A Z Y ,a n dn o wI w o u l dl i k e t o

s h a r ei t w i t h y o u .

M y f a v o u r i t el a n g u a g ew i l lp r o b a b l ya l w a y sb e a s s e m b l e r b e

c a u s eo f t h e p o w e ri t g i v e sy o uo v e rt h e f l o wo f a p r o g r a m .

G O G OD A N C E RW E D G Ew i l la l l o w B a s i cp r o g r a m m e r st o

p r a n c ea b o u tt h e i rc o d ew i t hm u c ht h es a m ea g i l i t y .

G O T Oa n dG O S U Bn o ws u p p o r tt h r e en e wt y p e so f p a r a m e t e r s :

E x p r e s s i o n sO f Y o u rD e s i r e

1 . Y e s ,n o wi n s t e a do f t y p i n gG O T O1 0 0 0y o uc o u l d t y p eG O T O

1 0 * 1 0 * 1 0o r G O T O5 0 0+ 5 0 0 .O r h o wa b o u ti n s t e a do f O NX

G O S U B1 0 0 , 2 0 0 , 3 0 0u s i n gG O S U BX * 1 0 0 .T h a t ' sr i g h t ,y o uc a n

u s ea n yt y p eo f e x p r e s s i o ni n c l u d i n gv a r i a b l e s .A n dy o ut h o u g h ty o u rp r o g r a m s w e r eh a r dt o u n d e r s t a n dn o w .

W h a t ' sI n A N a m e

2 . L a b e l s !E v e nb e t t e r ,y o u ' l lb e a b l ec a l ly o u rr o u t i n e sb y n a m e

i f y o u w a n tt o . T h i sm e a n sy o uc a nd o a d u m br e n u m b e ro r

m o v es t u f fa r o u n dw i t h o u tm e s s i n gt h i n g su p f o ry o u rG O T O s

a n dG O S U B s .

M a c r o s( K i n dO f )

3 . L a s t l y ,y o uc a n u s es t r i n gv a r i a b l e s i n s t e a do f l i t e r a ll a b e l

a r g u m e n t s .I m a g i n er e a d i n gi n y o u rs u b r o u t i n ec a l l sf r o mD A T A

s t a t e m e n t s .W a n tt o c h a n g et h eo r d e ri n w h i c ht h i n g s a r ed o n e ?

J u s tc h a n g et h eD A T A .

A W o r dO f W a r n i n g

T h e s ea b i l i t i e sc a nc u tt w ow a y s .Y o uc a nu s eG O G OD A N C E R

t o m a k ey o u rp r o g r a m sm o r em a i n t a i n a b l ea n de a s i l yu n d e r

s t o o d ,o r y o uc a nu s ei t t o c o n f u s et h el i v i n gd a y l i g h t so u to f

a n y o n ew h ol a y se y e so n t h e m( i n c l u d i n gy o u r s e l f ) .

T h eT r a n s a c t o r 4 6

C h r i sM i l l e

K i t c h e n e r ,O n t a r

H e r ea r ea f e wt r i v i a le x a m p l e st o d e m o n s t r a t et h e s y n t a x :

5 r e mu s i n ge x p r e s s i o n s

1 0 f o rI n = 1 0 0t o 5 0 0s t e p1 0 0

2 0 g o s u bI n

3 0 n e x t

4 0 e n d

1 0 0p r i n t" t h i s " ; :r e t u r n

2 0 0p r i n t " c o u l d " ; :r e t u r n

3 0 0p r i n t" m a k e " ; :r e t u r n

4 0 0p r i n t" y o u " ; :r e t u r n

5 0 0p r i n t" c r a z y " ; :r e t u r n

5 r e mu s i n gl a b e l s

1 0 g o s u b© h e l l o

2 0 g o s u b© g o o d b y e

3 0 e n d

4 0 © h e l l o

5 0 p r i n t" h it h e r e "

6 0 r e t u r n

7 0 © g o o d b y e :p r i n t" s ol o n g " :r e t u r n

N o t i c et h e" @ "m u s tp r e c e d et h en a m eb o t hi n t h ec a l la n dt h e

d e f i n i t i o na n dt h a tt h en a m ei s d e f i n e da s as i n g l es t a t e m e n

K e e pi n m i n dt h a tr e d e f i n i t i o ne r r o r sa r en o tc h e c k e df o r .T h e

f i r s to c c u r r e n c eo f a l a b e l w i l la l w a y sb e u s e d .

5 r e mu s i n gs t r i n gv a r i a b l e s

1 0 f o rx = 1 t o 3

2 0 r e a dg $

3 0 g o s u b' g $

4 0 n e x t

5 0 e n d

6 0 © x x x x :p r i n t" m a yn o tb e f o u n d" ; : r e t u r n

7 0 © y y y y :p r i n t" t o k e n i z e dl a b e l s" ; : r e t u r n

8 0 © z z z z :p r i n t" u s i n gt h i st e c h n i q u e" ; : r e t u r n

9 0 d a t az z z z , y y y y , x x x x

A si t i s , t h ea b o v e p r o g r a m w o u l dp r i n t ( q u i t et r u t h f u l l y ) ,

" u s i n gt h i st e c h n i q u et o k e n i z e dl a b e l sm a yn o tb e f o u n d "

I f y o u w e r et o c h a n g et h ed a t al i n et o 9 0 y y y y . x x x x . z z z t h e n

t h ep r o g r a m w o u l dp r i n t

" t o k e n i z e dl a b e l sm a yn o tb e f o u n du s i n gt h i st e c h n i q u

N o t i c et h a tt h e' © 'i s u s e db e f o r e t h es t r i n gv a r i a b l en a m ea l s o .

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 49: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 49/84

V a r i a b l e su s e di n G O T Oa n dG O S U Bp a r a m e t e r sm u s ta l w a y sb e

d e f i n e d .N U L Lo r Z E R Ov a l u e sw i l ln o tb e s u b s t i t u t e d( a sB a s i c

s o l o v e st o d o ) .I n s t e a dy o uw i l lg e t a n U N D E F I N E DS T A T E

M E N Te r r o r .

G O G OD A N C E Ri s o n l y a b o u t2 0 0b y t e so f c o d ea n ds h o u l d n ' t

b e m u c ht r o u b l et o e n t e ra s d a t a s t a t e m e n t s .I f y o ue n t e ra n d

c o n v e r tt h es o u r c et o w h a t e v e ra s s e m b l e ry o ul o v eb e s t ,t h e n

y o uw i l lb e a b l et o r e l o c a t ei t e a s i l ya n dm o d i f yi t i f y o us o d e s i r e .

T oa c t i v a t ei t u s e :

S Y S4 9 1 5 2

e i t h e rf r o mt h e i m m e d i a t eo r w i t h i n ap r o g r a m .A S Y S 4 9 1 5 2

w i t ht h ew e d g ee n a b l e dw o n th u r ta n y t h i n g .

G O G OD A N C E Rw a sw r i t t e nm o s t l yf o rf u na n de d u c a t i o n( m y

o w n ) .N o n e t h e l e s s ,t h es e l f - m o d i f y i n gp o w e r s a n dr e d u c t i o no f

B a s i c ' sl i n en u m b e rd e p e n d e n c em a yp r o v eu s e f u li n p r o t e c t i o n

s c h e m e s ,c o m p l e xB a s i ci n t e l l i g e n c es i m u l a t i o n sa n di n r e d u c

i n gt h es i z e o fs o u r c e p r o g r a m s .

G o g oD a n c e r6 4 :B A S I CL o a d e r

G o g oD a n c e r6 4 :S o u r c eC o d e( B u d d y6 4 F o r m a t )

D P

E P

M OB D

E O

H F

E B

A OG O

B F

L M

E D

H E

E E

J B

P B

B A

J D

I G

E F

H E

C l

K H

A l

I K

M K

H A

P F

H I

O J

M J

G A

C D

1 0 0

1 1 0

1 2 0

1 3 0

1 4 0

1 5 0

1 6 0

1 7 01 8 0

1 9 0

2 0 0

2 1 0

2 2 0

2 3 0

2 4 0

2 5 0

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 0

3 6 0

3 7 0

3 8 0

3 9 0

4 0 0

4 1 0

4 2 0

r e ms a v e " 0 : g o g o w e d g e . l d r " , 8

r e m* * w r i t t e nb y c h r i sm i l l e r ,k i t c h e n e r ,O n t a r i o

f o rj = 4 9 1 5 2t o 4 9 3 5 7 :r e a dx : p o k e j . x

: c h = c h + x : n e x t

i f c h < > 2 6 6 9 4t h e np r i n t" * *c h e c k s u m

e r r o r* * " :s t o p

p r i n t" s y s 4 9 1 5 2 :r e mt o e n a b l e " :e n d

d a t a1 6 9 , 1 1 ,d a t a 9 , 3 ,

d a t a1 9 2 , 7 6 ,

d a t a2 0 1 ,1 4 1 ,

d a t a 7 6 , 2 4 8 ,

d a t a1 6 7 , 1 6 9 ,

d a t a 7 2 ,1 6 5 ,

d a t a 5 7 , 7 2 ,

d a t a 7 6 , 1 7 4 ,

d a t a2 4 0 , 1 2 ,

d a t a 3 2 , 2 4 7 ,

d a t a1 6 9 , 1 3 6 ,

d a t a 3 2

d a t a1 7 7

d a t a 7 1

d a t a 1

d a t a1 4 0

d a t a1 6 5

d a t a1 6 5 ,

d a t a1 7 7 ,

d a t a1 3 6 , 1 7 7 ,

d a t a 9 5 , 2 0 8 ,

d a t a 9 5 ,2 4 0 ,

d a t a 0 , 1 7 7 ,

d a t a 9 6 ,1 3 4 ,

d a t a2 2 7 ,1 6 8 ,

1 1 5 ,

7 1 ,

1 7 0 ,

1 3 6 ,

1 9 2 ,

1 2 3 ,

4 4 ,

9 5 ,

1 4 1 , 8 , 3 ,

9 6 , 3 2 , 1 1 5 ,

1 7 4 ,1 6 7 , 2 0 1 ,

2 4 0 , 1 3 , 2 0 1 ,

1 6 8 , 3 2 , 1 2 4 ,

3 , 3 2 , 2 5 1 ,

1 2 2 , 7 2 , 1 6 5 ,

1 6 9 , 1 4 1 ,7 2 ,

1 6 7 , 3 2 , 1 1 5 ,

3 2 , 1 2 4 ,0 ,

1 8 3 , 7 6 , 1 6 3 ,

1 7 7 ,1 2 2 , 2 0 1 ,

0 , 3 2 , 1 3 9 ,

2 4 0 , 9 1 , 1 3 3 ,

2 0 0 , 1 7 7 ,7 1 ,

2 0 2 , 1 3 4 , 2 5 3 ,

1 3 2 , 2 5 5 ,1 6 5 ,

1 3 3 , 2 5 4 ,1 6 5 ,

1 3 3 , 9 6 , 1 6 0 ,

2 0 1 , 6 4 , 2 0 8 ,

2 5 3 , 2 0 0 , 2 0 0 ,

1 2 , 2 0 2 , 2 0 8 ,

2 3 , 2 0 1 ,5 8 ,

9 5 ,1 7 0 , 2 0 0 ,

9 5 , 1 7 7 ,9 5 ,

5 6 , 7 6 , 1 9 7 ,

1 6 9 ,1 9 2 ,

0 , 3 2 ,

1 3 7 , 2 4 0 ,

6 4 ,2 0 8 ,

0 , 7 6 ,

1 6 3 , 1 6 5 ,

5 8 , 7 2 ,

3 2 , 6 7 ,

0 , 2 0 1 ,

3 2 ,1 5 8 ,

1 6 8 , 3 2 ,

3 6 ,2 0 8 ,

1 7 6 , 1 6 0 ,

2 5 5 ,2 0 0 ,

1 6 8 , 1 3 8 ,

1 3 2 , 2 5 4 ,

1 2 2 ,1 3 3 ,

4 3 , 1 3 3 ,

4 , 1 6 6 ,

2 5 ,1 3 6 ,

2 0 0 , 2 0 0 ,

2 4 0 , 2 0 0 ,

2 4 0 , 1 9 ,

1 7 7 , 9 5 ,

2 0 8 , 2 0 5 ,

1 6 8

1 4 12 0

4 3

3

2 3 7

1 2 3

1 6 5

1 9 2

6 4

1 7 3

6

3 4

0

1 7 7

2 0 8

7 6

2 5 3

9 5

2 5 5

1 3 6

2 0 9

1 7 7

1 6 0

1 3 3

7 6

D l

K J

B l

G B

E H

N OA G

A F

A D

K A

A M

K F

G GA O

E L

D J

O P

A F

L BM J

G C

I E

K D

L B

A G

L C

A J

C O

G H

K K

D P

M E

H H

I K

K l

N D

I B

A N

O E

C E

O O

G D

N H

M AD J

A C

N J

C P

N N

N N

C F

G M

B O

B J

E M

K lF N

O E

1 0 0 0

1 0 1 0

1 0 2 0

1 0 3 0

1 0 4 0

1 0 5 0

1 0 6 0

1 0 7 0

1 0 8 0

1 0 9 0

1 1 0 0

1 1 1 0

1 1 2 0

1 1 3 0

1 1 4 0

1 1 5 0

1 1 6 0

1 1 7 0

1 1 8 01 1 9 0

1 2 0 0

1 2 1 0

1 2 2 0

1 2 3 0

1 2 4 0

1 2 5 0

1 2 6 0

1 2 7 0

1 2 8 0

1 2 9 0

1 3 0 0

1 3 1 0

1 3 2 0

1 3 3 0

1 3 4 0

1 3 5 0

1 3 6 0

1 3 7 0

1 3 8 0

1 3 9 0

1 4 0 0

1 4 1 0

1 4 2 0

1 4 3 0

1 4 4 0

1 4 5 0

1 4 6 0

r e ms a v e " 0 : g o g o w e d g e . s r c' , 8

r e m b yc h r i sm i l l e r J a n .4 , 1 9 8 7

r e me n a b l e sc a l c u l a t e dg o t o ( s u b )l n #

r e me . g .n = 1 0 :g o t o n * n( i . <3 . g o t o1 0 0 )

r e me n a b l e sg o t o ( s u b )l a b e l s

r e me . g .g o s u b@ p i g

r e me n a b l e sg o t o ( s u b )v a r i a b l en a m e $

r e me . g .x $= " p i g " :g o s u b( 8

r e me . g .5 0 0 0@ p i g :( t of l a g

r e m* * s o u r c ei n b u d d y6 4

a s s e m b l e r ) f o r m a t

s y s 9 9 9

; s y s 7 0 0f o rp a la n d s y m a s s

;

* = 4 9 1 5 2

. m e m; . o p to o f o rp a l

|

s r c p t r = $ 5 f

a r g p t r = 2 5 3l e n g t h = 2 5 5

J

; * *w e d g ef o rv a r i a b l eg o t o '

;

I d a # < w d g

s t a $ 3 0 8

I d a # > w d g

s t a $ 3 0 9

r t s

;

w d g = *

j s r $ 7 3

j s r p a r s e

j m p $ a 7 a e

J

p a r s e = *

c m p # 1 3 7

b e q g o t o

;

c m p # 1 4 1

b e q g o s u b

J

c m p # " @ "

b n e t o b a s i c

;

j m p $ a 8 f 8

;

; * *b a c kt o b a s i c

1 4 7 0 t o b a s i c

1 4 8 0

1 4 9 0

1 5 0 0

1 5 1 0

1 5 2 0

1 5 3 0

1 5 4 0

1 5 5 01 5 6 0

1 5 7 0

j s r $ 7 c

j m p $ a 7 e d

J

g o s u b = *

I d a # 3

j s r $ a 3 f b

I d a $ 7 b

p h aI d a $ 7 a

p h a

) X $

r o u t i n e )

p o w e r

s & g o s u b s

i n s t a l lc m dw e d g e

g e tc o m m a n d

i s i t g o t o

y e s / t h e nd o g o t o

i s i t g o s u b

y e s / t h e nd o g o s u b

i s i t a l a b e l

y e s / t h e n i g n o r e

r e a dt o e o l n

s e t sc h rf l a g sa g a i n

c o n t i n u ep a r s i n g

c h e c ks t a c ks p a c e

p u s hs t u f fo n s t a c k

t e x tp o i n t e r

T h eT r a n s a c t o r 4 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 50: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 50/84

B O

O GN N

G M

B K

I C

G MB M

C P

O F

P O

A C

K G

E C

J K

M H

A J

P P

G F

C K

N A

E HA O

L J

I H

M F

B N

C H

B F

E M

A O

C GE N

B M

J B

N l

K A

N F

I I

O G

E C

G K

D OJ K

O B

D F

O GN L

C l

P B

H N

H O

0 0D L

O L

E O

N H

H J

G l

K K

E E

1 5 8 0

1 5 9 0

1 6 0 0

1 6 1 0

1 6 2 0

1 6 3 0

1 6 4 0

1 6 5 0

1 6 6 0 ;

1 6 7 0g o t o

1 6 8 0

1 6 9 0

1 7 0 0

1 7 1 0 ;

1 7 2 0; * *e v a l

1 7 3 0

1 7 4 0

1 7 5 0

1 7 6 0 ;

1 7 7 0g o t o l i n e

1 7 8 0

1 7 9 0 ;1 8 0 0 ; * * l a b e

1 8 1 0i s l a b e l

1 8 2 0

1 8 3 0

1 8 4 0

1 8 5 0

1 8 6 0

1 8 7 0 ;

1 8 8 0; * *e l s e

1 8 9 0

1 9 0 0

1 9 1 0

1 9 2 0

1 9 3 0

1 9 4 0 ;

1 9 5 0

1 9 6 0

1 9 7 0

1 9 8 0

1 9 9 0

2 0 0 0

2 0 1 0

2 0 2 0

2 0 3 0

2 0 4 0 ;2 0 5 0

2 0 6 0 ;

2 0 7 0f o r 1

2 0 8 0

2 0 9 0

2 1 0 0

2 1 1 0

2 1 2 0 ;

I d a $ 3 a

p h a

I d a $ 3 9

p h a

I d a # 1 4 1

p h a

j s r g o t o

j m p $ a 7 a e

= *

j s r $ 7 3

c m p # " @ "

b e q i s l a b e l

; l i n e n u m b e r

; g o s u bt o k e n

; g e tn e x tc h a r

; s e ei f l a b e lg o t o

; y e s / t h e nc h e c kt y p e

e x p rf o l l o w i n gg o t o ( s u b )

j s r $ 7 c

j s r $ a d 9 e

j s r $ b 7 f 7

= *

j m p $ a 8 a 3

; r e s e tf l a g s

; e v a l u a t ee x p r e s s i o n

; c o n v e r tf l o a tt o f i x e d

; p e r f o r mg o t o

u s e di n s t e a do f l i n e n u m

= *

j s r $ a 9 0 6

d e y

I d a ( $ 7 a ) , y

c m p# " $ "

b n es e t l a b e l

l a b e li s i n a s t r i n g

j s r $ 7 3

j s r $ b O 8 b

I d y # 0

I d a ( 7 1 ) , y

b e qu n d e f n d '

s t a l e n g t h

i n y

I d a ( 7 1 ) , y

t a x

i n y

I d a ( 7 1 ) , y

t a y

t x a

b n e f o r 1

d e y

= *

d e x

s t x a r g p t r

s t y a r g p t r+ 1

j m p h u n t

; i n d e x e n do f s t ' m t

; w i t h. y .

; c h e c kl a s tc h a r

; s e ei f s t r i n gv a r

; n o / t h e nl i t e r a l

v a r

; l o c a t ev a r

; v a r i a b l ep o i n t e r

s t ; v a rn o td e f i n e d

; s a v el e n g t h

; s e tp o i n t e rt o v a r

; i n . x .a n d. y .

; t h e nb a c k u p o n e

; s e t z p gp o i n t e r

; f i n dt h el i n e

2 1 3 0; * *o t h e r w i s el a b e li s c o n s t a n t

2 1 4 0 s e t l a b e l

2 1 5 0

2 1 6 0

2 1 7 0

2 1 8 0

T h eT r a n s a c t o r

= *

s t y l e n g t h

I d a $ 7 as t a a r g p t r

I d a $ 7 b

; o fl a b e la r g u m e n t

; c o p yt x t p t r; t os e a r c ha r gp o i n t e r

4 8

I O

O A

F C

L E

L P

E M

K C

K E

E K

L D

D C

N F

B N

D D

A J

M OJ O

D P

N P

O J

M M

M GK E

E F

O F

I G

N N

M H

M B

H M

F B

K D

O K

J C

A P

C GA E

G P

A l

O D

J G

A N

N P

M B

O OA L

E F

M A

K N

O O

B M

A E

M A

J A

L C

H O

E D

E K

2 1 9 0

2 2 0 0 ;

2 2 1 0h u n t

2 2 2 0

2 2 3 0

2 2 4 0

2 2 5 0

2 2 6 0 ;

2 2 7 0b a c k i

2 2 8 0

2 2 9 0

2 3 0 0

2 3 1 0

2 3 2 0

2 3 3 0 ;

2 3 4 0 b a c k 2

2 3 5 0

2 3 6 0

2 3 7 0

2 3 8 0

2 3 9 0 ;

2 4 0 0f o r 22 4 1 0

2 4 2 0

2 4 3 0

2 4 4 0

2 4 5 0

2 4 6 0

2 4 7 0 ;

2 4 8 0

2 4 9 0

2 5 0 0 ;

2 5 1 0

2 5 2 0

2 5 3 0

2 5 4 0 ;

2 5 5 0

2 5 6 0

2 5 7 0 ;

2 5 8 0n e x t l n

2 5 9 0

2 6 0 0

2 6 1 0

2 6 2 0

2 6 3 0

2 6 4 0

2 6 5 0

2 6 6 0

2 6 7 0

2 6 8 0 ;

2 6 9 0u n d e f n d

2 7 0 0

2 7 1 0 ;

2 7 2 0f o u n d

2 7 3 0

2 7 4 0

2 7 5 0 ;

2 7 6 0. e n d

s t a a r g p t r+ 1

= *

I d a 4 3

s t a s r c p t r

I d a 4 4

s t a s r c p t r+ 1

= *

I d y # 4

I d x l e n g t h

I d a ( s r c p t r ) , y

c m p # " @ "

b n e n e x t l n

= *

d e y

d e y

d e y

I d a ( a r g p t r ) . y

= *

i n y

i n y

i n y

i n y

c m p( s r c p t r ) , y

b n e n e x t l n

d e x

b n e b a c k 2

i n y

I d a ( s r c p t r ) , y

b e qf o u n d

c m p # " : "

b e qf o u n d

= *

I d y # 0

I d a ( s r c p t r ) , y

t a x

i n y

I d a ( s r c p t r ) , y

s t a s r c p t r+ 1

s t x s r c p t r

I d a ( s r c p t r ) , y

b n e b a c k i

s t = *

j m p $ a 8 e 3

= *

s e c

j m p$ a 8 c 5

; r e a ds t a r to f b a s i c

; t os o u r c ep o i n t e r

; f i r s tl i n ec h a r

; s e ei f l a b e ll i n e

; n o / t r yn e x tl i n e

; g e ts e a r c h c h a r

; c o m p a r ew i t hd e s t

; n o t e q . / n e x tl i n e

; e l s ec o n t i n u e

; f o rl e n g h to f a r g

; s h o u l d b e e n d

; o fs o u r c el a b e l

u n d e f i n e ds t a t e e r r

; s e tg o t o

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 51: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 51/84

N o wY o uS e eI t ,

N o wY o uD o n ' t

M i c h a e lR . M o s s m

Q u i s p a m s i s N B

T h es e c r e to f " t r a n s p a r e n t "c a r t r i d g e so n t h eC 6 4

H a v ey o ue v e rw o n d e r e dw h yt h o s em a r v e l l o u sc a r t r i d g e sc a n

d o t h i n g st o y o u rc o m p u t e r , b u tn e v e rs h o wu p a n y w h e r ei n

m e m o r y ?T h ef i r s tt i m eI s a wB u s s c a r dI I ( a nI E E Ei n t e r f a c ef o r

h eC 6 4t h a ta d d sb a s i c4 . 0 d i s kc o m m a n d s )a t a f r i e n d sh o u s e ,i t

m a d em ec u r i o u s .I a s k e dt o s e et h em a c h i n el a n g u a g ec o d e , b u t

w ec o u l dn o tf i n di t i n m e m o r y .T h i sc u r i o s i t ys t a y e do n t h eb a c k

b u r n e ru n t i lI b o u g h tm y F a s tL o a dc a r t r i d g e .A g a i n ,t h ep r o

g r a mc o u l dn o tb e f o u n di n m e m o r y .O v e r w h e l m e d ,I p r o c e e d e d

o d i s m a n t l et h ec a r t r i d g e .I n s i d e ,I e x p e c t e dt o f i n da m a z eo f

m o d e r ne l e c t r o n i c s .M u c ht o m yd i s a p p o i n t m e n t ,t h e r es a tt w o

o w l yI C s .O n ew a st h ee x p e c t e dE P R O Ma n dt h eo t h e ra 7 4 0 7 . 1

r a c e ds o m eo f t h el i n e sb u ti t d i d n ' tm a k e m u c hs e n s e .D i s a p

o i n t e d ,I c l o s e di t u p a n d i t r e m a i n e di n t h e b a c ko f m y

o m p u t e rf o ro v e ra y e a r .

A f e wm o n t h sb a c k ,I b o u g h ta " P r o m e n a d e "E P R O Mp r o g r a m

m e rt o b u r na f e wo f m yo w nc u s t o mc h i p s .E v e r yn o wa n dt h e n

w o u l dc a s ta n e y ea t t h a t F a s tL o a dc a r t r i d g e ,w i s h i n gt h a tI

o u l dm a k em y c a r t r i d g e si n v i s i b l ei n m e m o r y .I r e v i v e dm y

t t a c ko n t h a td e s p i c a b l ec a r t r i d g ew i t hr e n e w e dv i g o r .I r e

m o v e dt h eE P R O Mf r o mt h eb o a r da n dr e a dt h ep r o g r a mo u t

w i t hm yP r o m e n a d e .I l o o k e da t t h ec o d ea n df i g u r e dt h a tt h e

r o g r a mr a na t $ 8 0 0 0b u tI k n e wt h a tt h ep r o g r a mc o u l dn o tb e

e e na t $ 8 0 0 0 .T h i s t i m eI s a td o w na n dt r a c e do u te v e r yl i n eo n

h eb o a r da n dd r e wa d i a g r a ma s I w e n t .L o wa n db e h o l d ,t h e

e c r e t sw e r er e v e a l e dt o m e .

w o u l dl i k e t op o i n t o u tt h a tt h i s a r t i c l ei s n o tt o s h o wy o uh o wt o

o p yt h eF a s tL o a dc a r t r i d g e .T h ec a r t r i d g ei s s u c hg o o dv a l u e

o rt h em o n e yt h a tb u i l d i n go n ey o u r s e l fc o s t sm o r et h a n b u y i n g

t o u t r i g h t .T h ec o d ei t s e l fi s o f n o u s eb e c a u s ei t w i l ln o tr u nb y

u s tl o a d i n ga n dr u n n i n gi t a t $ 8 0 0 0- i t i s m u c hm o r ei n v o l v e d

h a nt h a t .T h ev a l u el i e si n b e i n ga b l et o p u tw e d g e si n B A S I Cn ds e t v e c t o r st h a ta r e c o m p l e t e l yt r a n s p a r e n tt o o t h e rp r o

r a m s .A l lt h i sa n dy o u rp r o g r a mo c c u p i e sn o m e m o r y . T h e

m e m o r ya r e aa t $ C 0 0 0- $ C F F Fi s f o u g h to v e rb y s o m a n y

r o g r a m s .T h e r ea r et i m e sw h e nI w a n tt h eD O Sw e d g ea n d

n o t h e rp r o g r a mi n m e m o r ya t t h es a m et i m e .T h i si s i m p o s s i b l e

e c a u s et h e yc o n f l i c ta t $ C 0 0 0 .

T o m a k ey o u ro w ni n v i s i b l ep r o g r a m ,i t i s n e c e s s a r yt o u n d e r

t a n dt h en o r m a lc o n t r o ll i n eo p e r a t i o no f t h ee x p a n s i o np o r t .

T h e s ea r e t h el i n e sa v a i l a b l e :

E X R O M- T h i sl i n ei s n o r m a l l yh i g h( 1 ) .T ot e l lt h eP L At h a ty o u

w a n tt h eC P Ut o r e a dt h e e x t e r n a lr o ma t $ 8 0 0 0 ,t h i s l i n ei s s e t

o w .

R Q M L

S N 7 4 0 7

R E S E T

* €

i r o l

T o£ Sa n dO E

o f R O Mc h i p

I

1 / 0 1

D E 0 O - D E F F x

8 O 0 O - 9 F F F ' *

1 ) P i n7 i s G r o u n d

2 ) P i n 1 4g o e st o + 5 Vs u p p l y

3 ) A l la d d r e s sa n dd a t al i n e so n t h eR O Mo r E P R O Mg o t o t h e i r

e q u i v a l e n t so n t h ee x p a n s i o np o r t .

F i g u r e1

R O M L- T h i sl i n ei s a t y p eo f d e c o d e da d d r e s sl i n e .W h e nt h e

C P Uw a n t st o r e a dt h e e x t e r n a lR O Ma t $ 8 0 0 0 ,t h i s l i n ei s p u l l e d

l o wo r 0 . R O M Lw i l ln e v e rg o l o wi f t h eE X R O Ml i n ei s n o tl o w .

R E S E T- T h i sl i n ei s u s u a l l yh i g hw h e nt h ec o m p u t e ri s r u n n i n g .

I t s p u r p o s ei s t o p r e v e n t t h eC P Uf r o mt r y i n gt o e x e c u t eM Li n s t r u c t i o n sw h e nt h ec o m p u t e ri s c o l ds t a r t e d .T h i sa l l o w s t h

o t h e r c h i p st o r e a c ht h e i r" n o r m a l "s t a t e sb e f o r e t h eC P U

a d d r e s s e st h e m .R E S E Ti s l o wd u r i n gr e s e t t i m e .T h ec o m p u t e

w o u l da c t f l a k yw i t h o u ta R E S E Tl i n e .T h eR E S E Tl i n eg o e sl o w

i n o n l yt w on o r m a lo p e r a t i o n s :

1 ) W h e nt h ec o m p u t e ri s t u r n e do n .

2 ) W h e nt h er e s e tb u t t o ni s p r e s s e do n t h ec o m p u t e r .

I / O1 , 1 / 0 2 -T h e s el i n e sa r ei n t e n d e df o rs e l e c t i n ga n e x t e r n a l

I / Od e v i c e ,e . g .A d d i n ga nA C I Ao ra C I Ac h i p .S e l e c t i o ni s d o n e

b yp u l l i n gt h el i n el o w .T h i si s d o n ew h e ny o u d oa r e a do r w r i t et o $ D E 0 0- $ D F F F . I / O1 i s t h ea r e af r o m$ D E 0 0- $ D E F Fa n d

I / O2 i s $ D F 0 0- $ D F F F .

T h eT r a n s a c t o r 4 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 52: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 52/84

N o w ,l e t ' sl o o ka t t h ei n v i s i b l ec a r t r i d g e- s e eF i g u r e1 . T h ec h i p

i s a 7 4 0 7 h e xb u f f e ra n ds o i f a l o wo r a1 i s p u ti n , a l o wo r 1

c o m e so u t .W h e nt h ec o m p u t e ri s t u r n e do n , t h eR E S E Tl i n ei s

l o w .T h i sc a u s e st h eE X R O Ml i n e t ob e l o w .T h el i n ei s h e l dl o w

f o r a p e r i o do f t i m e ,a f t e rr e s e t ,b y t h e c a p a c i t o r .W h e nt h e

c o m p u t e rr e a d st h e$ 8 0 0 0a r e ai t w i l ls e et h eE X R O Ml i n ei n a

l o ws t a t ea n du s eR O M Lt o a d d r e s st h e e x t e r n a lc a r t r i d g e .I f i t

f i n d st h ea u t o s t a r ts e q u e n c e ,i t t h e n p a s s e sc o n t r o lo v e rt o t h e

c a r t r i d g ec o d e .A l lt h i st i m e ,t h eE X R O Ml i n eh a sb e e nh e l dl o w

b e c a u s eR O M Ll i n ei s l o w .

T o r e v i e wt h e c o n c e p t :T h eR E S E Tl i n e s t a r t st h es e q u e n c eb u t

t h e R O M Ll i n eh o l d st h e E X R O Ml i n el o ww h i l et h e C P Ui s

r e a d i n gc o d e f r o mt h e$ 8 0 0 0b l o c k .I f t h eC P Us t o p se x e c u t i n g

c o d ef o r a p e r i o do f t i m e ,t h e nt h e c a r t r i d g ea t $ 8 0 0 0w i l l

d i s a p p e a r( E X R O Ms t a y sh i g hb e c a u s eR O M Li s h i g h ) .T h e

c a r t r i d g ec o d es e q u e n c ei s : n o r m a lc o l ds t a r t i n i t i a l i z a t i o n ,s e t

y o u ro w nv e c t o r s ,a n dt h e np a s sc o n t r o lt o B A S I C .

T h eq u e s t i o nn o wa r i s e s" H o wd o I g e tt h ec o d et o r e a p p e a ra t

$ 8 0 0 0 ,n o wt h a tt h ec a r t r i d g ei s i n v i s i b l e ? " .I f a r e a do r w r i t ei s

d o n et o $ D E 0 0 ,t h e nt h e I / O 1 l i n e w i l lg o l o wc a u s i n gt h e

4 0 :

5 0 :

6 0 :

9 0 :

1 0 0 :

1 1 0 :

1 2 0 :

1 3 0 :

1 4 0 :1 5 0 :

1 6 0 :

1 7 0 :

1 8 0 :

1 9 0 :

2 0 0 :

2 1 0 :

2 2 0 :

2 3 0 :

0 8 0 1

0 8 0 1

0 8 1 4

0 8 1 4

0 8 1 4

0 8 1 6

0 8 1 8

0 8 1 a

0 8 1 c0 8 1e

0 8 2 0

0 8 2 0

0 8 2 3

0 8 2 4

0 8 2 6

0 8 2 6

0 8 2 9

. o p tp 4

s t o r e= $ f b

. b a sm l

m l = *

a 9 0 0

8 5 f b

a 9 8 0

8 5 f c

0 00 0

a Oa 2

I d a

s t a

I d a

s t a

I d yI d x

# $ 0 0

s t o r e

# $ 8 0

s t o r e+ 1

# $ 0 0# $ 0 0

8 e 0 0

c a

d O f a

8 c

b 1

0 8 2 b9 1

2 4 0 :0 8 2 d2 5 0 :0 8 2 e

2 6 0 :0 8 3 0

2 7 0 :0 8 3 3

2 8 0 :0 8 3 3

2 9 0 :0 8 3 5

3 0 0 :0 8 3 7

c 8f O

4 c

e 6

a 5

c 9

3 1 0 :0 8 3 9f O

3 2 0 :0 8 3 b4 c

3 3 0 :0 8 3 e

3 4 0 :0 8 3 e6 0

0 0

f b

f b

0 3

2 6

f c

f c

a O

0 3

2 6

d e

d e

l o o p =

s t x $ d e O O

d e x

b n e l o o p

l o o p i=

s t y

I d a

s t a

$ d e 0 0

( s t o r e ) ,y

( s t o r e ) . y

; a d d r e s sf o rl o o p s t o r a g e

; s e tu p f o rr e a dw r i t el o o p

c o m p l e t e l yd i s c h a r g ec a

p a c i t o rf o rr e a d i n ge p r o m

; l o o pf o rr e a d i n ge p r o m

; r e a de p r o m

; s t o r et o r a ma t s a m e

m e m o r yl o c a t i o n

0 8

i n y

b e q a d d

j m p l o o p i

E X R O Ml i n et o g o l o w .T h ec a p a c i t o rw i l lh o l dt h e l i n el o wf o r

p e r i o do f t i m e . J u s te n o u g h ,s o t h a tw h e na r e a do r w r i t ei s d o n e

t o $ 8 0 0 0 ,t h e R O M Lw i l lb e p u l l e dl o w b yt h e C P Ub e c a u

E X R O Mi s s t i l ll o w .I n t h i sc a s e ,I / O1 l i n e s t a r t st h es e q u e n

b u t t h eR O M Ll i n e ,a g a i n ,h o l d si t .

O n eo f t h ev e c t o r st h a ty o us e t i nt h ec o l ds t a r tc o d ec o u l dp o i n

t o c o d ei n t h ec a s s e t t eb u f f e r ,t h e$ 0 2 A 7- $ 0 2 F Fa r e a ,o r $ C 0 0

b l o c k .T h i sc o d ei s n e c e s s a r yb e c a u s ei t w i l lm a k et h e $ 8 0 0

c o d ev i s i b l ea g a i n .T h ed r a w b a c ki s t h a tu s i n gt h ea b o v ea r e a si s

d a n g e r o u s b e c a u s eo t h e rp r o g r a m sl i k e t ou s et h e s es a m es p o t s

T h ea n s w e ri s i n u s i n gt h eI / O2 l i n e .Y o uw i l ln o t i c ef r o mF i g . l

t h a tI / O2 i s c o n n e c t e dt o t h eC S ( s e l e c t e db y a l o w )t h r o u g ha

b u f f e r .W h e ny o ud o a r e a do f t h ea r e af r o m$ D F 0 0- $ D F F Fy o u

w i l ls e ec o d e .T h em a g i ct h i n ga b o u tt h i sc o d ei s t h a ti t i s r e a l l

l o c a t e di n t h er o mc h i pa t $ 9 F 0 0- $ 9 F F F .Y o ua p p e a rt o s e ei t a t

I / O2 a r e ab e c a u s eo f t h ew a yt h ec h i pi s s e l e c t e d .

L e t ' sl o o ka t h o wt h i st y p eo f c a r t r i d g ec a nb e u s e di n y o u ro w n

c o d e .S u p p o s e y o u w o u l dl i k e t oi m p l e m e n ta w e d g ei n b a s i

W h e nt h em a c h i n ei s t u r n e do n , t h eR E S E Tl i n ei s p u l l e dl o w

c a u s i n gt h e E P R O Ma t $ 8 0 0 0t o a p p e a r .T h ec a r t r i d g es t a y

v i s i b l eb e c a u s eo f t h e c a p a c i t o ro n t h eE X

R O Ml i n e .T h ec o d ea t $ 8 0 0 0i s e x e c u t

b e c a u s et h e k e yc o d ee x i s t s .Y o um a k ea

j u m pt o t h e $ D F F 0a r e at o i n i t i a l i z eI / O

d e v i c e s ,p e r f o r mt h eR A Mt e s t ,s e tu p p a g

z e r ok e r n a ll o c a t i o n sa n dt h e nt h eI / Ov e c

t o r sa r es e t .C h r g e ta n dv a r i o u sz e r op a g

B A S I Cp o i n t e r sa n df i n a l l yt h e v e c t o ra t

$ 0 3 0 0- $ 0 3 0 Ba r es e t .I t i s h e r et h a ty o u

c a nn o ws e tt h eB A S I Ce r r o rv e c t o ra t $ 0 3 0

t o p o i n tt o y o u r c o d ea t $ D F 0 0 .W h e nt h eB A S I Ci n t e r p r e t e r e r r o r so u tb e c a u s ei t d o e

n o tr e c o g n i z ea c o m m a n d ,t h ee r r o rv e c t o

w i l lp o i n tt o y o u rc o d ea t $ D F 0 0 .T h ec o d

a t $ D F 0 0w i l ld o a r e a do r w r i t et o $ D E 0

T h i sw i l lc a u s et h eE X R O Ml i n e t og o l o

a n dt h ee p r o mt o a p p e a ra t $ 8 0 0 0 .Y o uc a n

n o wj u m pt o y o u rc o d ei n t h e E P R O Mt o

c h e c kt h e c h r g e t r o u t i n ef o ry o u rc o m m a n

I f i t i s y o u rw e d g et h e nt h e c o m m a n i s

c a r r i e do u t ,i f n o t t h e ny o uj u m pt o t h e

n o r m a le r r o rh a n d l i n gr o u t i n e .

a d d =

0 8

i n c s t o r e +1

I d a s t o r e+ 1

c m p# $ a 0

b e q e n d

j m p l o o p i

; i f l o wb y t ei s z e r o t h e n

i n c r e a s eh i g hb y t eb y o n e

; i f h i g h b y t e

$ a 0t h e ne n d

i s e q u a lt o

I c a ns e em a n yu s e sf o r t h i st y p eo f p r o

g r a m i n ga n dI t h i n kt h a tm a n yo f y o uw i l l

a l s o .I n c l u d e d h e r ei s a l i t t l em a c h i n el a n

g u a g ep r o g r a mt h a tw i l lm a k et h e c o d e

f r o mt h eF a s t - L o a dc a r t r i d g ea p p e a ra n d

t h e ns t o r ei t t o n o r m a lr a ma t $ 8 0 0 0 .

e n d =

r t s ; r e t u r nt o b a s i c ,p r o g r a m

c a n n o wb e r e a dw i t ha

m o n i t o rf r o m $ 8 0 0 0 - $ 9 f f f

T h eT r a n s a c t o r 5 O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u e0 3

Page 53: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 53/84

Page 54: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 54/84

B e c a u s eo f t h e s y s t e m a t i cp a t t e r n si n R G B ,a d i r e c t t r a n s f e r o f

c o m p o s i t ec o l o rm e m o r yt o V D Cc o l o rm e m o r yw o u l dr e s u l ti n

i n c o r r e c t c o l o r i n g .T h ef o l l o w i n g c h a r ts h o w st h e d i f f e r e n c e

b e t w e e nt h ea s s i g n e dc o l o r si n c o m p o s i t em o d ea n dt h o s eo f t h e

R G Bm o d e .

C o m p o s i t eC o l o r s

0 = B l a c k

1 = W h i t e

2 = R e d

3 = C y a n

4 = P u r p l e

5 = G r e e n

6 = B l u e

7 = Y e l l o w

8 = O r a n g e

9 = B r o w n

1 0 = L i g h tR e d

1 1 = D a r kG r a y

1 2 = M e d i u mG r a y1 3 = L i g h tG r e e n

1 4 = L i g h tB l u e

1 5 = L i g h tG r a y

R G BC o l o r s

0 = B l a c k

1 = D a r kG r a y

2 = D a r kB l u e

3 = L i g h tB l u e

4 = D a r k G r e e n

5 = L i g h tG r e e n

6 = D a r kC y a n

7 = L i g h tC y a n

8 = D a r k R e d

9 = L i g h tR e d

1 0 = D a r kP u r p l e

1 1 = L i g h tP u r p l e

1 2 = B r o w n

1 3 = Y e l l o w

1 4 = L i g h tG r a y

1 5 = W h i t e

N o to n l ya r e t h ec o l o r s d i f f e r e n ti n t h e t w om o d e s ,b u t t h e

f o r e g r o u n da n d b a c k g r o u n da r e r e v e r s e d .N o r m a lV D Ca t t r i b

u t e s d o n ' tw o r kt h es a m ea s t h e yd o i n b i t m a pm o d e .I n t e x t

m o d e ,t h eb o t t o mn i b b l ei s u s e dt o s u p p o r tt h ef o r e g r o u n dc o l o r

a s i t i s i n b i tm a pm o d e .B u tt h eu p p e rn i b b l ei s u s e dt o s u p p o r ta

b a c k g r o u n dc o l o rf o ra c h a r a c t e r s p a c e .T h e s eb i t sa r en o r m a l l y

u s e dt o s u p p o r tu n d e r l i n e ,f l a s h i n g ,r e v e r s ea n da l t e r n a t ec h a r

a c t e r s .A t t r i b u t e sa r eo n b y d e f a u l t ,b u tt o t u r nt h e mo n i n c a s ea

p r o g r a ms h u t st h e mo f fy o uc a ns e t r e g i s t e r2 5 ,b i t 6 . Y o um u s t

a l s ot e l lt h eV D Cw h e r ei n V D CR A My o u w a n tt h ea t t r i b u t e s .

T h i si s d o n ew i t hr e g i s t e r s2 0 a n d2 1 .2 0 i s t h eh i g h b y t ea n d2 1

i s t h el o wb y t eo f t h e1 6 b i ta d d r e s s .

W i t ht h a tb a c k g r o u n d o n 8 0c o l u m n s ,y o us h o u l db e a b l et o

f o l l o wm yc o n v e r s i o np r o g r a m .T h ep r o g r a mb e g i n sb y c l e a r i n g

t h e8 0 c o l u m nc h i pw i t h t h eb l o c kf i l lf u n c t i o n .T h ed e s t i n a t i o n

a d d r e s sm u s tb e s e t a t r e g i s t e r s1 8 / 1 9( h i g hb y t e / l o wb y t e ) .

T h e np l a c e t h ef i l lb y t ei n r e g i s t e r3 1 ( i . e .0 t o c l e a ro r 2 5 5t o f i l l ) .

N e x t ,c l e a rb i t 7 o f r e g i s t e r2 4 t o s e l e c tb l o c kf i l l ,a n dp l a c e t h e

n u m b e ro f m e m o r yl o c a t i o n st o f i l li n r e g i s t e r3 0 .F o l l o w i n gt h e

i n i t i a lw r i t et o r e g i s t e r3 1 ,t h e r ew i l la l r e a d yb e o n eb y t ew r i t t e n .

S e l e c t i n g a0 w o r dc o u n t( r e g3 0 )w i l lw r i t et o 2 5 6b y t e so f V D C

R A M .T h ep r o g r a mt h e n b l a n k st h es c r e e n w i t ha s i m p l e p r o c e s s

i n v o l v i n gr e g i s t e r3 5 ( d i s p l a ye n a b l e / b e g i n ) .

T h en e x ts t e p ,d o n ew i t ht h eC O P Yr o u t i n e ,i n v o l v e sc o p y i n g

c o l o rm e m o r yf r o m$ 1 C O O - $ 1 F F F( 7 1 6 8 - 8 1 9 1 )t o $ 1 3 0 0

( 4 8 6 4 ) .T h i sp r e s e r v e st h es c r e e ns o y o uc a nc o m p a r et h et w o

m o d e s ,o r m a k ea d j u s t m e n t st o t h ec o l o rt a b l ea n dc o n v e r ta g a i n

w i t h o u th a v i n gt o r e l o a d t h e h i - r e sp i c t u r e .T h ec o l o r sa r et h e n

c o n v e r t e dw i t hS H I F Tt o a n 8 0c o l u m ne q u i v a l e n t ,w h e r e

p o s s i b l e .B e c a u s e 8 0c o l u m n sc o n s i s t so f 8 d a r ks h a d e sa n d8

l i g h ts h a d e s ,t h e r ew a s n ' ta n e x a c tm a t c hf o r e a c ho f t h e

c o m p o s i t ec o l o r s .T h ep r o c e s si s t o w o r kd o w nt o a n i b b l e( 4 b i t s )

a n du s et h a tn i b b l e a sa n o f f s e t t oa 1 6 b y t e c o l o rl o o k u pt a b l e .

O t h e r w i s e ,a 2 5 6b y t el o o k u pt a b l ew o u l db e n e e d e d ,a n d

m o d i f y i n go n ec o l o rw o u l dr e q u i r e3 2 b y t e st o b e c h a n g e dt o

m o d i f ya l lo c c u r r e n c e so f t h a tc o l o r .T h eo f f s e tm e t h o dr e q u i r e

o n l yo n eb y t et o b e c h a n g e dt o f i xa l l 3 2 .T h ef o r e g r o u n da n d

b a c k g r o u n da l s on e e dt o b e r e v e r s e d , a st h e yw o r ko p p o s i t ei n

t h e t w om o d e s .T h ef o l l o w i n g c h a r ts h o w st h e d e f a u l tc o l o r

c o n v e r s i o nt a b l e .T h i si s s t o r e di n v a r i a b l eC O L O R Sa n dc a nb e

m o d i f i e dw h e r en e e d e d .

4 0 C o l u m nb e c o m e s8 0 C o l u m n

0 0 B l a c k

0 1 W h i t e

0 2 R e d

0 3 C y a n

0 4 P u r p l e

0 5 G r e e n

0 6 B l u e

0 7 Y e l l o w

0 8 O r a n g e

0 9 B r o w n

1 0 L i g h tR e d

1 1 D a r kG r a y

1 2 M e d i u mG r a y

1 3 L i g h tG r e e n

1 4 L i g h tB l u e

1 5 L i g h tG r a y

0 0 B l a c k

1 5 W h i t e

0 8 D a r kR e d

0 7 L i g h tC y a n

1 1 L i g h tP u r p l e

0 4 D a r k G r e e n

0 2 D a r kB l u e

1 3 Y e l l o w

1 0 D a r kP u r p l e

1 2 B r o w n

0 9 L i g h tR e d

0 1 D a r kG r a y

0 6 D a r kC y a n

0 5 L i g h tG r e e n

0 3 L i g h tB l u e

1 4 L i g h tG r a y

A s y o uc a ns e e ,n o e a s y a l g o r i t h mc o u l dm a k et h i st r a n s l a t i

a n dn o ta l lc o l o r sh a v ea p e r f e c tm a t c h ,u n l e s sy o u w o u l dm a k

m o r et h a no n ec o l o rb e c o m e b r o w no r r e d ,e t c .

N e x tt h e V I C - I Is c r e e na t $ 2 0 0 0 - $ 3 F F F( 8 1 9 2 - 1 6 3 8 3 )i s s e n tt o

t h eV D CR A Mw i t hV I C T O V D C .B e c a u s eo f m yi n e x p e r i e n i n

m a c h i n el a n g u a g eI m a d en o a t t e m p tt o w r i t et h a tr o u t i n ef r o m

s c r a t c h .I t i s a m o d i f i e dv e r s i o no f t h e r o u t i n ef o u n di n t h e 1 2 8

P r o g r a m m e r ' sR e f e r e n c eG u i d e( B a n t a mB o o k s ) . F o rm o r ed e

t a i l so n t h a tt y p eo f p r o c e s s ,s e eP a u l D u r r a n t ' sp r o g r a ma n d

a r t i c l e i nt h eS e p t e m b e ri s s u e .( G a m e sf r o mt h eI n s i d eO u t )

A f t e r t h eh i r e ss c r e e ni s t r a n s f e r r e d ,t h ec o l o rc a nb e p u ti n .T h e

H I T M Er o u t i n es i m p l ys e t st h e d a t ap o i n t e r( r e g ' s1 8 / 1 9 )t o

$ 2 0 0 0V D C( a t t r i b u t e s )a n dc o p i e s t h et r a n s l a t e d c o l o f r o m

$ 1 3 0 0 .T h es c r e e ni s t h e n t u r n e db a c ko nw i t hU N B L A N Ka n d .

. . v o i l a !

T h ep r o c e s si s v e r yq u i c k ,e s p e c i a l l yi f f a s tm o d ei s u s e d .A st h e

m a c h i n el a n g u a g ei s o n ep r o g r a m ,y o uc a ne a s i l yu s ei t w i t h

o t h e rB a s i cp r o g r a m s ,e t c .I h o p et h a ty o uw i l ln o tm e r e l yu s e

t h er o u t i n ea s i t i s , b u tw i l le x p e r i m e n tw i t ht h ep o s s i b i l i

p r o v e n .T h ep o t e n t i a li s e v e ng r e a t e ri f y o ur e p l a c e t h e1 6 K

c h i p sw i t h6 4 Kc h i p s .M yf r i e n d ,L o w e l l ,i s n o ww o r k i n go n

g e t t i n ga 1 2 8a n dw i l la l s oi n s t a l lt h e6 4 Kc h i p sa s I h a v ed o n e

H en e e d e d n of u r t h e rp r o o ft h a tt h e1 2 8i n 8 0 c o l u m n sc a nd o

I N C R E D I B L Ec o l o r g r a p h i c s .I ' l lc o v e r6 4 Ki n m yn e x ta r t i c l e

U n t i lt h e n ,I s t r o n g l yu r g ey o ut o p l a ya r o u n dw i t ha l l t h e

r e g i s t e r s t os e ew h a t y o uc a nd o . A f t e ra l l ,l o o kw h e r ei t g o tm e .

5 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 55: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 55/84

K M

N G

J M

G P

C B

J J

L E

M A

H K

J H

P O

L L

J F

L J

N J

I H

H H

F H

O D

A K

P E

B L

H F

A P

M A

J l

I M

B N

B N

B K

J N

C K

O B

H N

N l

M H

H H

F M

C N

E G

C A

J K

E C

H L

G G

M l

J O

1 0D E

H D

E J

I D

1 0 0

1 1 0

1 2 0

1 3 0

1 4 0

1 5 0

1 6 0

1 7 0

1 8 0

1 9 0

2 0 0

2 1 0

2 2 0

2 3 0

2 4 0

2 6 0

2 7 0

2 8 0

2 9 0

3 0 0

3 1 0

3 2 0

3 3 0

3 4 0

3 5 0

3 6 0

3 7 0

3 8 0

3 9 0

4 0 0

4 1 0

4 2 0

4 3 0

4 4 0

4 5 0

4 6 0

4 7 0

4 8 0

4 9 0

5 0 0

5 1 0

5 2 0

5 3 0

5 4 0

5 5 0

5 6 0

5 7 0

5 8 05 9 0

6 0 0

6 1 0

B a s i cd e m oF o rC o l o r8 0

r e ms a v e " 0 : v i e w e r . b a s " , 8

r e m* * c o l o r8 0 v i e w e r* *

r e m * *m a t t h e wp a l c i c* *

g r a p h i c1 , 1 :g r a p h i c5 , 1 :s y sd e c ( H c 0 2 7 "

: p r i n f g ot o 4 0 c o l s " :g r a p h i cC

i f p e e k ( d e c ( " d 0 0 " ) ) < > 1 9 8t h e n: r e mp o s i t i o nc o d e

, 1

!

g o s u b 2 7 0

p r i n t" f i l et o l o a d( o r$ f o rd d d i r e c t o r y ) "

i n p u t" > " ; f $

i f f $ = " $ "t h e ns c n c l r :d i r e c t o r y

: g o t o1 6 0

i f f $ = ' * "t h e ng o t o2 2 0

s c n c l r :g r a p h i c1

b l o a d ( f $ ) , p 7 1 6 8

f a s t :s y sd e c ( " c 0 0 " ) :s l o w

g e t k e ya $ :g r a p h i c1 , 1

g o t o1 6 0

" d d *

f o rj = 3 0 7 2t o 3 5 2 2 :r e a dx : p o k ej , ;

: c h = c h + x : n e x t

' : p r i n t

<

i f c h < > 4 8 6 6 3t h e np r i n t" * *c h e c k s u m

e r r o r* * " :s t o p

r e t u r n

d a t a 3 2 2 2 1 2 3 2 1 7 4

d a t a 1 2 , 3 2 , 6 1 , 1 2 , 3 2 ,

d a t a1 2 2 , 1 3 , 3 2 , 1 8 7 ,1 3 ,

d a t a1 6 9 , 0 , 3 2 , 9 6 , 1 3 ,

d a t a 1 3 , 1 6 9 , 0 , 3 2 , 9 4 ,

d a t a 3 2 , 1 1 0 , 1 3 , 4 1 , 1 2 7 ,

d a t a1 6 0 , 6 4 , 1 6 2 ,3 0 , 1 6 9 ,

d a t a 1 3 , 1 3 6 , 2 0 8 , 2 5 0 ,9 6 ,

d a t a 2 5 0 ,1 6 9 , 1 9 , 1 3 3 , 2 5 1 ,

d a t a2 3 0 , 2 5 1 ,3 2 , 8 8 , 1 2 ,

d a t a 8 8 , 1 2 , 2 3 0 , 2 5 1 ,3 2 ,

d a t a1 6 0 , 0 , 1 7 7 , 2 5 0 , 1 3 3 ,

d a t a 7 4 , 7 4 ,1 7 0 , 1 8 9 , 1 3 0 ,

d a t a1 6 5 , 2 5 2 ,1 0 , 1 0 , 1 0 ,

d a t a 7 4 , 7 4 ,1 7 0 , 1 8 9 , 1 3 0 ,

d a t a 1 0 , 1 0 , 1 0 1 , 2 5 3 ,1 4 5 ,

d a t a 2 1 7 ,9 6 , 0 , 1 5 , 8 ,

d a t a 2 , 1 3 , 1 1 , 1 2 , 9 ,

d a t a 3 , 1 4 , 1 6 9 , 0 , 1 3 3 ,

d a t a1 6 9 , 2 8 , 1 3 3 , 2 5 1 , 1 6 9 ,

d a t a1 6 2 , 4 , 3 2 , 1 7 3 ,1 2 ,

d a t a 2 5 3 , 2 0 2 , 2 0 8 , 2 4 6 ,9 6 ,

d a t a2 5 0 , 1 4 5 ,2 5 2 , 2 0 0 , 2 0 8 ,

d a t a 2 5 , 3 2 , 1 1 0 ,1 3 , 9 ,

d a t a 1 3 , 1 6 2 , 2 0 , 1 6 9 ,3 2 ,

d a t a1 6 2 , 2 1 , 1 6 9 ,0 , 3 2 ,

d a t a 1 2 , 1 6 9 ,0 , 3 2 , 9 6 ,

d a t a1 6 9 , 0 , 3 2 , 9 6 ,1 3 ,d a t a 4 0 , 3 2 , 9 6 ,1 3 ,1 6 9 ,

d a t a1 6 9 , 0 , 1 3 3 , 2 5 0 , 1 6 2

d a t a 1 3 , 2 3 2 ,3 2 , 9 6 ,1 3

6 2 0d a t a 2 5 , 1 3 3 , 1 5 5 , 1 6 9 ,7

1 3 ,

1 8 3 ,

9 6 ,

2 3 2 ,

1 3 ,

3 2 ,

0 ,

1 6 9 ,

3 2 ,

2 3 0 ,

8 8 ,

2 5 2 ,

1 2 ,

1 0 ,

1 2 ,

2 5 0 ,

7 ,

1 ,

2 5 0 ,

1 9 ,

2 3 0 ,

1 6 0 ,

2 4 9 ,

1 2 8 ,

3 2

9 6

1 3

1 6 2

3 2

1 8

1 3 3

1 3 3

3 2 ,

1 2 ,

1 6 2 ,

3 2 ,

1 6 2 ,

9 6 ,

3 2 ,

0 ,

8 8 ,

2 5 1 ,

1 2 ,

7 4 ,

1 3 3 ,

7 4 ,

1 0 ,

2 0 0 ,

1 0 ,

6 ,

1 3 3 ,

1 3 3 ,

2 5 1 ,

0 ,

9 6 ,

3 2 ,

9 6 ,

1 3 ,

1 6 2 ,

1

1 3 3

3 2

1 7 7

1 5 6

1 4 6

3 2

1 8

9 6

2 4

1 3

9 6

1 3 3

1 2

3 2

9 6

7 4

2 5 3

7 4

1 0

2 0 8

4

5

2 5 2

2 5 3

2 3 0

1 7 7

1 6 2

9 6

1 3

1 6 2

1 3

1 6 9

2 5 1

9 6

1 6 9

1 6 9

C L

L M

K B

L N

L B

E J

F A

K B

E LL P

E C

H M

D O

K O

B C

F E

E M

N H

B B

J J

P D

K F

N B

A H

L G

J D

P A

E C

K AE L

A J

D J

A F

M K

I L

P L

K G

K G

D B

B D

C K

C A

O HC B

K E

G E

M E

I K

K K

M L

F E

M CP B

E l

F J

I PL C

P KR F

6 3 0d a t a

6 4 0d a t a

6 5 0d a t a

6 6 0d a t a

6 7 0d a t a

6 8 0d a t a

6 9 0d a t a

7 0 0d a t a

7 1 0d a t a7 2 0d a t a

7 3 0d a t a

3 9 , 1 3 3 , 2 5 4 ,

9 4 , 1 3 , 3 2 ,

2 4 2 ,1 6 5 , 1 7 7 ,

2 5 0 , 3 2 , 9 4 ,

1 5 6 , 2 0 8 , 2 2 0 ,

2 5 5 , 1 2 , 1 6 9 ,

1 6 1 , 2 5 0 ,3 2 ,

1 9 8 ,1 5 5 , 2 0 8 ,

1 0 5 , 8 , 1 3 3 ,9 6 , 5 6 , 1 6 5 ,

1 6 5 , 2 5 0 , 2 3 3 ,

7 4 0d a t a2 5 0 , 2 0 8 ,2 ,

7 5 0d a t a

7 6 0d a t a

1 4 2 , 0 , 2 1 4 ,

1 4 1 , 1 , 2 1 4 ,

7 7 0d a t a 2 1 4 ,4 4 , 0 ,

7 8 0d a t a2 1 4 , 9 6 , 1 6 2 ,

7 9 0d a t a

8 0 0d a t a

8 1 0d a t a

1 3 , 1 6 2 ,1 9 ,

1 6 9 , 0 , 1 3 3 ,

3 2 , 1 6 3 ,1 3 ,

8 2 0d a t a 2 3 0 ,2 5 1 , 3 2 ,

8 3 0d a t a

8 4 0d a t a

8 5 0d a t a

8 6 0d a t a

8 7 0d a t a

1 6 3 , 1 3 , 9 6 ,

9 4 , 1 3 , 2 0 0 ,

3 2 , 1 1 0 ,1 3 ,

9 6 , 1 3 , 9 6 ,

9 6 , 1 3 , 9 6

1 6 2 , 0 , 1 6 1 , 2 5 0 ,

6 1 , 1 3 , 1 9 8 , 2 5 4 ,

2 0 8 , 2 1 , 1 6 2 ,0 ,

1 3 , 3 2 , 7 3 ,1 3 ,

1 6 9 , 1 , 1 3 3 , 1 7 7 ,

0 , 1 3 3 , 1 7 7 , 1 6 2 ,

9 4 , 1 3 , 3 2 , 8 7 ,

1 9 1 , 9 6 , 2 4 , 1 6 5 ,

2 5 0 , 1 4 4 ,2 , 2 3 0 ,2 5 1 , 2 3 3 ,1 , 1 3 3 ,

5 5 , 1 3 3 , 2 5 0 ,9 6 ,

2 3 0 , 2 5 1 ,9 6 , 1 6 2 ,

4 4 , 0 , 2 1 4 ,1 6 ,

9 6 , 1 6 2 , 3 1 , 1 4 2 ,

2 1 4 , 1 6 , 2 5 1 , 1 7 3 ,

1 8 , 1 6 9 ,3 2 , 3 2 ,

1 6 9 , 0 , 3 2 , 9 6 ,

2 5 0 , 1 6 9 ,1 9 , 1 3 3 ,

2 3 0 , 2 5 1 ,3 2 , 1 6 3 ,

1 6 3 , 1 3 , 2 3 0 , 2 5 1 ,

1 6 0 , 0 , 1 7 7 , 2 5 0 ,

2 0 8 , 2 4 8 ,9 6 , 1 6 2 ,

1 3 3 , 2 5 5 , 1 6 9 ,0 ,

1 6 2 , 3 5 , 1 6 5 , 2 5 5 ,

S o u r c eC o d eF o rC o l o r8 0

1 0 0 0r e ms a v e " 0 : c o l o r 8 O . s r c, 8

1 0 1 0r e m* * s o u r c es t a r t - u pi n p o w e ra s s e m b l e r

f o r m a t( a k ab u d d y - 1 2 8s y s t e m )

1 0 2 0 s y s 4 0 0 0

1 0 3 0 * = $ 0 c 0 01 0 4 0 . m e m

1 0 5 0 ;

1 0 6 0; c o l o r8 0 c o l o r h i - r e s

1 0 7 0; c o m p o s i t et o r g bc o n v e r t e r

1 0 8 0; m a t t h e wp a l c i c- 1 6 kv 2 . 1

1 0 9 0 ;

1 1 0 0

1 1 1 0

1 1 2 0

1 1 3 0

1 1 4 0

1 1 5 0

1 1 6 0

1 1 7 0

1 1 8 0 ;

1 1 9 0c l e a r

1 2 0 0

1 2 1 0

1 2 2 0

1 2 3 0

1 2 4 0

1 2 5 0

1 2 6 0

1 2 7 0

1 2 8 0

1 2 9 0

1 3 0 0

1 3 1 0

1 3 2 0

1 3 3 0

j s r c l e a r

j s r b l a n k

j s r c o p y

j s r s h i f t

j s r v i c t o v d c

j s r h i t m e

j s r u n b l a n k

r t s

= *

I d x # 1 8

I d a # 0

j s r w r i t e r

i n x

j s r w r i t e r

I d a # 0

j s r w r i t e

I d x # 2 4

j s r r e e d e r

a n d # 1 2 7

j s r w r i t e r

I d y # 6 4

I d x # 3 0

I d a # 0

m a i ns u b r o u t i n e

t a b l e

c l e a rv d cw / b l o c kf i l l

s e td a t ap o i n t e rt o 0

, f o rs t a r to f h i r e s

; s e tf i l lb y t et o 0

; c l e a rb i t7 o f

r e g i s t e r2 4 t o

; s e l e c tb l o c kf i l l

3 2

2 0 8

1 6 1

1 9 8

7 6

0

1 3

2 5 0

2 5 12 5 1

2 3 0

3 1

2 5 1

0

1

9 6

1 3

2 5 1

1 3

3 2

3 2

3 5

3 2

3 2

; c l e a r6 4 p a g e s( 6 4 * 2 5 6=

1 6 3 8 4b y t e st o c l e a r )

; r e g3 0 i s w o r dc o u n t

; 0 w o r d s= 2 5 6b y t e s

O 3

Page 56: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 56/84

C L

A L

E D

F B

I E

E O

E G

I P

K E

B l

J LN F

E l

G O

L H

O A

A J

C C

F K

G D

A P

E l

D L

N G

C K

B H

K F

J G

N N

P H

B E

L E

H E

P N

O F

K D

B G

J F

D G

N G

P K

P K

J L

D M

P L

H F

N M

N L

H M

B N

D L

C L

E C

N Er — r —E E

I N

C A

K E

O A

K C

J H

O C

A L

F l

K F

1 0

D H

P H

T h e T

1 3 4 0 ;

1 3 5 0 c l e a r 1

1 3 6 0

1 3 7 0

1 3 8 0

1 3 9 0 ;

1 4 0 0

1 4 1 0 ;

1 4 2 0s h i f t

1 4 3 0

1 4 4 01 4 5 0

1 4 6 0

1 4 7 0

1 4 8 0

1 4 9 0

1 5 0 0

1 5 1 0

1 5 2 0

1 5 3 0

1 5 4 0

1 5 5 0 ;

1 5 6 0 c o n v

1 5 7 0

1 5 8 0 ;

1 5 9 0n i b b l e s

1 6 0 0

1 6 1 0

1 6 2 0

1 6 3 0

1 6 4 0

1 6 5 0

1 6 6 0

1 6 7 0

1 6 8 0

1 6 9 0

1 7 0 0

1 7 1 0

1 7 2 0

1 7 3 0

1 7 4 0

1 7 5 0

1 7 6 0

1 7 7 0

1 7 8 0

1 7 9 0

1 8 0 0

1 8 1 0

1 8 2 0

1 8 3 0

1 8 4 0

1 8 5 0

1 8 6 0

1 8 7 0

1 8 8 0

1 8 9 0 ;

1 9 0 0c o l o r s

1 9 1 0

1 9 2 0

1 9 3 0

1 9 4 0

1 9 5 0

1 9 6 0

1 9 7 0

1 9 8 0

1 9 9 0

2 0 0 0

2 0 1 0

r a n s a c t o r

=

j s r

d e y

b n e

r t s

=

I d a

s t a

I d a

s t a

j s r

i n c

j s r

i n c

j s r

i n c

j s r

r t s

=

I d y

=

I d a

s t a

I s r

I s r

I s r

I s r

t a x

I d a

s t a

I d a

a s l

a s l

a s l

a s l

I s r

I s r

I s r

I s r

t a x

I d a

a s l

a s l

a s l

a s l

a d c

s t a

i n y

b n e

r t s

=

w r i t e r

c l e a r i

*

# 0

$ f a# $ 1 3

$ f b

c o n v

$ f b

c o n v

$ f b

c o n v

$ f b

c o n v

# 0

*

( $ f a ) , y

$ f c

c o l o r s . x

$ f d

$ f c

c o l o r s . x

$ f d

( $ f a ) , y

n i b b l e s

*

. b y t e O

. b y t e1 5

. b y t e8

. b y t e7

. b y t e1 0

. b y t e4

. b y t e2

. b y t e

. b y t e1 31 1

. b y t e1 2

. b y t e9

t r a n s l a t ec o l o ri n f o

; c o l o rs t a r t$ 1 3 0 0

; c o n v e r t $ 1 3 0 0

; c o n v e r t $ 1 4 0 0

; c o n v e r t$ 1 5 0 0

; c o n v e r t $ 1 6 O O

; c o n v e r tf o r e g r o u n d

; g e tc o l o r

; s h i f tf o r e g r o u n dd o w n

; t ob o t t o mn i b b l e

; g e tn e wv a l u e

; s t o r ef o r e g r o u n d

r e t r i e v eo r i g i n a lc o l o rb y t e

; s h i f tl e f tt o c l e a rt o pn i b b l e

; m o v e b a c kt o b o t t o mn i b b l e

; g e tn e wv a l u e

; m o v e b a c k g r o u n dt o t o pn i b b l e

; c o m b i n ef o r e g r o u n da n d

b a c k g r o u n d

; 4 0c o lc o l o r

; b l a c k

; w h i t e

; r e d

; c y a n

; p u r p l e

; g r e e n

; b l u e

; y e l l o wo r a n g e

b r o w n

l i g h tr e d

5 4

B M

G K

H I

D B

N J

M l

E J

F B

O K

E O

G JO G

A H

I I

O N

A P

I L

J l

G J

G K

D G

O J

G D

G L

K E

M OD D

I G

E J

A E

A J

K P

P N

E K

E C

I L

C G

I B

K J

O O

I F

C l

B L

G H

K H

B J

E J

F D

J O

C L

M F

O PH N

P A

I P

K G

A P

C A

P E

M H

O D

M L

H J

C CJ G

E OO H

M K

B L

2 0 2 0

2 0 3 0

2 0 4 0

2 0 5 0

2 0 6 0

2 0 7 0 ;

2 0 8 0 c o p y

2 0 9 0

2 1 0 0

2 1 1 0

2 1 2 02 1 3 0

2 1 4 0

2 1 5 0

2 1 6 0

2 1 7 0 ;

2 1 8 0 c o p y 1

2 1 9 0

2 2 0 0

2 2 1 0

2 2 2 0

2 2 3 0

2 2 4 0 ;

2 2 5 0

2 2 6 0 ;

2 2 7 0c o p y i t

2 2 8 0

2 2 9 0 ;

. b y t e l

. b y t e6

. b y t e5

. b y t e3

. b y t e1 4

= *

I d a # 0

s t a $ f a

s t a $ f c

I d a # $ 1 cs t a $ f b

I d a # $ 1 3

s t a $ f d

I d x # 4

= *

j s r c o p y i t

i n c $ f b

i n c $ f d

d e x

b n e c o p y i

r t s

= *

I d y # 0

2 3 0 0c o p y b y t e=

2 3 1 0

2 3 2 0

2 3 3 0

2 3 4 0

2 3 5 0 ;

2 3 6 0

2 3 7 0 ;

I d a ( $ f a ) , y

s t a ( $ f c ) , y

i n y

; d a r kg r a y

; m e d i u mg r a y

; l i g h tg r e e n

; l i g h tb l u e

; l i g h tg r a y

; c o p yc o l o rr a m

; f r o mn o r m a lv i c - i i

; s c r e e n ( $ 1 c 0 0 )

; c o p y t o $ 1 3 0 0

; c o p y4 p a g e s

b n e c o p y b y t e

r t s

2 3 8 0 v i c t o v d c=

2 3 9 0

2 4 0 0

2 4 1 0

2 4 2 0

2 4 3 0

2 4 4 0

2 4 5 0

2 4 6 0

2 4 7 0

2 4 8 0

2 4 9 0

2 5 0 0

2 5 1 0

2 5 2 0

2 5 3 02 5 4 0

2 5 5 0

2 5 6 0

2 5 7 0

2 5 8 0

2 5 9 0

2 6 0 0

2 6 1 0

2 6 2 0

2 6 3 0 ;

2 6 4 0a g a i n1

2 6 5 0

2 6 6 0

2 6 7 0 ;2 6 8 0a g a i n

2 6 9 0

2 7 0 0

I d x # 2 5

j s r r e e d e r

o r a # 1 2 8

j s r w r i t e r

I d x # 2 0

I d a # $ 2 0

j s r w r i t e r

I d x # 2 1

I d a # 0

j s r w r i t e r

I d x # 1

I d a # 4 0

j s r w r i t e r

I d a # $ 2 0

s t a $ f bI d a # 0

s t a $ f a

I d x # 1 8

j s r w r i t e r

i n x

j s r w r i t e r

s t a $ b 1

I d a # $ 1 9

s t a $ 9 b

= *

I d a # 7

s t a 1 ! Q r

= *

I d a # $ 2 7

s t a $ f e

t r a n s l a t ev i e — i ih i r e st o v d ch i r e

; s e tr e g i s t e r2 5

; b i tm a pm o d e

; b i t 7

; s e ta t t r i b u t e sa t $ 2 0 0 0( v d cr a m

; s e tv d cs c r e e nw i d t h( r e g1 )

; t o4 0 c o l u m n s

; s t a r to f v i c - i ih i r e s$ 2 0 0 0

; d a t a p o i n t e r ( v d c )t o $ 0 0 0 0

; f o rs t a r to f v d cb i tm a p

; c o l u m n c o u n t e r

; 8 b y t e sp e rc h a r a c t e r( 0 - 7 )

; 4 0c o l u m n s( 0 - 3 9 )

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 57: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 57/84

M A

P G

B P

J L

O PC D

E L

L C

M F

D J

C EK H

F F

N B

C G

L M

I P

G MA M

B E

P D

H C

1 0

N K

B HB H

B O

J K

0 0

G F

B l

E L

M E

M M

A G

M F

E H

D O

P P

F D

I N

G K

I D

K L

F E

E E

I N

M l

H P

O F

H I

A LJ H

A A

L M

I K

M D

A K

F N

0 0E G

G P

I H

E H

C A

G JM ME B

E L

2 7 1 0 ;

2 7 2 0t r a n h i

2 7 3 0

2 7 4 0

2 7 5 0

2 7 6 0

2 7 7 0

2 7 8 0

2 7 9 0 ;

2 8 0 0

2 8 1 02 8 2 0 ;

2 8 3 0

2 8 4 0

2 8 5 0

2 8 6 0

2 8 7 0

2 8 8 0

2 8 9 0 ;

2 9 0 0

2 9 1 0

2 9 2 0

2 9 3 0 ;

2 9 4 0h a l f

2 9 5 0

2 9 6 0

2 9 7 0

2 9 8 0

2 9 9 0

3 0 0 0

3 0 1 0

3 0 2 0

3 0 3 0 ;

3 0 4 0

3 0 5 0 ;

3 0 6 0a d d

3 0 7 0

3 0 8 0

3 0 9 0

3 1 0 0

3 1 1 0

3 1 2 0 ;

3 1 3 0

3 1 4 0 ;

3 1 5 0a d d 1

3 1 6 0

3 1 7 0 ;

3 1 8 0i n c r e a s e

3 1 9 0

3 2 0 0

3 2 1 0

3 2 2 03 2 3 0

3 2 4 0

3 2 5 0

3 2 6 0

3 2 7 0 ;

3 2 8 0u p t h e r e

3 2 9 0

3 3 0 0

3 3 1 0 ;

3 3 2 0

3 3 3 0 ;

3 3 4 0u p 1

3 3 5 0

3 3 6 0 ;3 3 7 0w r i t e

3 3 8 0

3 3 9 0 ;

T h eT r a n s a c t o r

=

I d x

I d a

j s r

j s r

d e c

b n e

I d a

b n e

I d x

I d a

j s r

j s r

d e c

b n e

I d a

s t a

i m p

=

I d a

s t a

I d x

I d a

j s r

j s r

d e c

b n e

r t s

c l c

I d a

a d c

s t a

b c c

i n c

=

r t s

s e c

I d a

s b c

s t aI d a

s b c

s t a

r t s

=

i n c

b n e

i n c

=

r t s

I d x

#

# 0

( $ f a , x )

w r i t e

a d d

$ f e

t r a n h i

$ b 1

h a l f

# 0

( $ f a , x )

w r i t e

i n c r e a s e

$ 9 c

a g a i n

# 1

$ b 1

a g a i n

*

# 0

$ b 1

# 0

( $ f a , x )

w r i t e

u p t h e r e

$ 9 b

a g a i n i

$ f a

# 8

$ f a

a d d 1

$ f b

*

*

$ f b

# 1

$ f b$ f a

# $ 3 7

$ f a

*

$ f a

u p 1

$ f b

*

• ; w r i t e t ov d cr a m

# 3 1

I C

C J

C N

D B

M E

L O

K P

J O

E l

I B

B JG J

G D

L M

E B

E F

L N

O MM l

M H

F L

G A

K J

A L

L O

L G

A D

K E

L E

O E

P F

H J

D D

C J

J F

L I

N GC K

B l

J L

F J

O M

C G

D P

L E

A l

C F

G GC C

C B

I A

M LM D

A N

O H

K F

B P

G CH H

I A

M l

A C

D O

K K

G G

A LI M

M F

M M

5 5

3 4 0 0w r i t e r

3 4 1 0

3 4 2 0 ;

3 4 3 0w r i t e l

3 4 4 0

3 4 5 0

3 4 6 0 ;

3 4 7 0

3 4 8 0

3 4 9 0 ;

3 5 0 0r e e d

3 5 1 0

3 5 2 0 ;

3 5 3 0r e e d e r

3 5 4 0

3 5 5 0 ;

3 5 6 0r e e d i

3 5 7 0

3 5 8 0

3 5 9 0 ;

3 6 0 0

3 6 1 0

3 6 2 0 ;

3 6 3 0h i t m e

3 6 4 0

3 6 5 0

3 6 6 0

3 6 7 0

3 6 8 0

3 6 9 0

3 7 0 0

3 7 1 0

3 7 2 0

3 7 3 0

3 7 4 0

3 7 5 0

3 7 6 0

3 7 7 0

3 7 8 0

3 7 9 0

3 8 0 0

3 8 1 0

3 8 2 0 ;

3 8 3 0a h e a d

3 8 4 0

3 8 5 0 ;

3 8 6 0 a h e a d1

3 8 7 0

3 8 8 0

3 8 9 0

3 9 0 0

3 9 1 0 ;3 9 2 0

3 9 3 0 ;

3 9 4 0b l a n k

3 9 5 0

3 9 6 0

3 9 7 0

3 9 8 0

3 9 9 0

4 0 0 0

4 0 1 0 ;

4 0 2 0u n b l a n k

4 0 3 0

4 0 4 0

4 0 5 04 0 6 0

4 0 7 0 ;

4 0 8 0. e n d

s t x

=

b i t

b p l

s t a

r t s

_

I d x

=

s t x

b i t

b p l

I d a

r t s

=

I d x

I d a

j s r

I d x

I d a

j s r

I d a

s t a

I d a

s t a

j s r

i n c

j s r

i n c

j s r

i n c

j s r

r t s

=

I d y

=

I d a

j s r

i n y

b n e

r t s

=

I d x

j s r

s t a

I d a

j s r

r t s

=

I d x

I d a

j s r

r t s

*

$ d 6 0 0

$ d 6 0 0

w r i t e l

$ d 6 0 1

*

# 3 1

*

$ d 6 0 0

*

$ d 6 0 0

r e e d i

$ d 6 0 1

# 1 8

# $ 2 0

w r i t e r

# 1 9

# 0

w r i t e r

# 0

$ f a

# $ 1 3

$ f b

a h e a d

$ f b

a h e a d

$ f b

a h e a d

$ f b

a h e a d

#

# 0

*

( $ f a ) , y

w r i t e

a h e a d i

*

# 3 5

r e e d e r

$ f f

# 0

w r i t e r

*

# 3 5

$ f f

w r i t e r

; w r i t et o v d cr e g i s t e r

; w a i tf o rs t a t u sb i tt o g o h i g h

; w r i t ev a l u e

; r e a dv d cr a m

; r e a dv d cr e g i s t e r

; w a i tf o rs t a t u sb i tt o g o h i g h

; r e a dv a l u e

t r a n s f e r c o l o rf r o mr a mt o v d c

; d a t ap o i n t e rt o $ 2 0 0 0( a t t r i b u t e s

; c o l o r s a r e a t $ 1 3 0 0

t r a n s f e r$ 1 3 0 0

t r a n s f e r$ 1 4 0 0

t r a n s f e r$ 1 5 0 0

t r a n s f e r$ 1 6 0 0

; r e a dr a m

; w r i t e t ov d c

; b l a n k 8 0 c o l s

; s t o r ec u r r e n ts c r e e np a r a m s

; b l a n ki t

; r e s t o r es c r e e n

; r e t r i e v es c r e e np a r a m s

; r e s t o r ep a r a m

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 58: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 58/84

T w i n - 8 0S c r e e n

F o rt h eC o m m o d o r e1 2 8

D . J .M o r r i

T o r o n t o ,O n t a r

U s et h ee x t r aV D Cm e m o r yf o ra n o t h e r8 0 - c o l u m ns c r e e n

T h e8 5 6 3V i d e oD i s p l a yC o n t r o l l e r( V D C )c h i pt h a tc o n t r o l s t h e8 0 -

c o l u m ns c r e e no n t h eC - 1 2 8h a si t so w nR A Mm e m o r yc o m p l e t e l y

o u t s i d e t h eC - 1 2 8m e m o r ys p a c e .T h eV D Cu s e s8 K b y t e st o s t o r e

t h e c o m p l e t e5 1 2 - m e m b e rc h a r a c t e rs e t , 2 K b y t e sf o r s c r e e n

m e m o r y ,a n da n o t h e r2 K b y t e sf o ra t t r i b u t em e m o r y( o n e b y t eo f

e a c hf o re a c hs c r e e nl o c a t i o ni n t h e8 0 c o l u m nb y 2 5 l i n es c r e e n ) .

T h u s ,a c o m p l e t es c r e e na n dc h a r a c t e rs e t r e q u i r e s1 2 K b y t e s .

S i n c e1 2 K b y t e c h i p sa r es o m e w h a ts c a r c e ,t h eV D Ci n f a c th a s1 6K

b y t e so f R A Ma v a i l a b l e .V a r i o u s u s e sh a v eb e e np r o p o s e df o r t h i s

e x t r am e m o r y :a t i n yR A Md i s k ,f o re x a m p l e .C o i n c i d e n t a l l y , t h e

u n u s e d4 K b y t e sa r e e x a c t l yw h a ti s n e e d e df o r a c o m p l e t e l y

s e p a r a t e s c r e e nm e m o r ya n da t t r i b u t em e m o r y .T h i sp r o g r a ms e t s

u p s u c ha s c r e e n ,a n da l l o w sy o ut o t o g g l eb e t w e e nt h et w os c r e e n s ,

i n e i t h e ri m m e d i a t eo r p r o g r a m m o d e .

W h a tM u s tB e D o n e

I n o r d e rt o s u p p o r ts u c ha d o u b l es c r e e n ,b o t ht h eV D Ca n dt h e

s c r e e ne d i t o rm u s tk n o ww h e r e ,i n V D CR A M ,s c r e e nm e m o r ya n d

a t t r i b u t em e m o r ys t a r t sf o re a c ho f t h et w os c r e e n s .T h eV D Cn e e d s

t o k n o ww h e r et o l o o kf o r i n f o r m a t i o nw h e ni t i s d r a w i n gt h e

s c r e e n ,a n dt h es c r e e ne d i t o rn e e d st o k n o ww h e r et o p u ti n f o r m a

t i o ni n r e s p o n s et o P R I N T c o m m a n d s . T h eV D Cl o o k st o i t s o w n

i n t e r n a lr e g i s t e r s$ 0 Ca n dS O Dt o c o n t a i nt h e a d d r e s s ,i n V D CR A M ,

o f t h es t a r to f s c r e e nm e m o r y ,w h i l er e g i s t e r s$ 1 4a n d$ 1 5c o n t a i n

t h ea d d r e s so f t h es t a r t o fa t t r i b u t em e m o r y .B o t ht h e s er e g i s t e r

p a i r sa r ei n h i g h - b y t e ,l o w - b y t eo r d e r ;j u s tt h e r e v e r s eo f n o r m a l

8 5 0 2o r d e r .T h ed e f a u l t8 0 - c o l u m ns c r e e n u s e st h ef i r s t2 K b y t e so f

V D C R A Mf o rs c r e e nm e m o r y ,a n dt h es e c o n d2 K b y t e b l o c kf o r

a t t r i b u t e s .I h a v e c h o s e nt o l e a v et h e s eu n t o u c h e d ,a n ds e tu p t h e

s e c o n ds c r e e nm e m o r yi n t h eu n u s e dr e g i o nf r o m4 K t o 6 K , a n d

t h es e c o n ds c r e e na t t r i b u t e sf r o m6 K t o 8 K ; a b o v e8 K , c h a r a c t e r

R A Ms t a r t s .S o t o i n f o r m t h eV D Ca b o u tt h en e wm e m o r ya l l o c a

t i o n ,a l lt h a ti s n e c e s s a r yi s t o t o g g l eV D Cr e g i s t e r$ 0 Cb e t w e e nt h e

v a l u e s0 a n d$ 1 0 ,a n dt o g g l eV D Cr e g i s t e r$ 1 4b e t w e e nt h ev a l u e s

$ 0 8 a n d$ 1 8 .

T h es c r e e ne d i t o rm u s ta l s ok n o ww h e r et o p u tt h i n g s .I t r e l i e so n

C - 1 2 8R A Ml o c a t i o n$ 0 A 2 E , w h i c hc o n t a i n st h ep a g eo f t h es t a r to f

s c r e e nm e m o r yi n t h e V D CR A M ,a n d l o c a t i o n$ 0 A 2 F ,w h i c h

c o n t a i n st h ep a g eo f t h es t a r to f a t t r i b u t em e m o r yi n V D CR A M .S i n c eo n l yt h ep a g ei s s t o r e d ,t h es c r e e ne d i t o ri n s i s t st h a tb o t h

s c r e e nm e m o r ya n da t t r i b u t em e m o r ys t a r to n p a g eb o u n d a r i e s ,

a l t h o u g ht h eV D Cd o e sn o tm a k et h es a m ed e m a n d . S ot o i n f o r

t h e s c r e e ne d i t o ra b o u tt h e n e wm e m o r ya l l o c a t i o n ,i t i s o n l y

n e c e s s a r yt o t o g g l e$ 0 A 2 Eb e t w e e nt h e v a l u e s 0a n d$ 1 0 ,a n d

t o g g l e$ 0 A 2 Fb e t w e e nt h ev a l u e s$ 0 8a n d$ 1 8 .

I t i s a l s on e c e s s a r yt o r e s e tv a l u e si n o t h e rV D Cr e g i s t e r sa n di n C -

1 2 8R A M .T h e s el o c a t i o n sc o n t a i ni n f o r m a t i o n a b o u t c l o c a

t i o n ,w i n d o w st h a ta r ee n a b l e d ,l o c a t i o n so f t a bs t o p s ,q u o t em o d e

n u m b e ro f i n s e r t s ,t y p ea n ds i z eo f c u r s o re t c .S p e c i f i c a l l y ,l o c a t i o

f r o m$ E 0t o $ F 9 ,$ 0 3 5 4t o $ 0 3 6 1 ,a n d$ 0 A 2 Bi n C - 1 2 8R A Ma l l

c o n t a i n i n f o r m a t i o nt h a td e f i n e s t h e p r e c i s en a t u r eo f a s c r e e n

T h e s ea r e t h e l o c a t i o n s t h a t t h es c r e e n - e d i t o rr o u t i n eS W A P P

s w i t c h e sw h e ny o ut r a n s f e rb e t w e e n4 0 a n d8 0 - c o l u m ns c r e e n

S i m i l a r l y ,i n t h eV D C ,r e g i s t e r s$ 0 A ,$ 0 B ,$ 0 E ,$ 0 F ,$ 1 8 ,$ 1A , a n d

$ 1 Dc o n t a i ni n f o r m a t i o nt h a ta l s od e f i n e s t h ep r e c i s en a t u r eo f a

s c r e e n .W h e ny o ut o g g l eb e t w e e n 8 0 -c o l u m ns c r e e n s , t h ev a l u e

i n a l lt h e s el o c a t i o n sm u s t b es t o r e d ,w h i l es t o r e dv a l u e sa r ep l a c e

i n a l l t h e s el o c a t i o n s .

W h a tD o e sI t

T h es w i t c hb e t w e e ns c r e e n si s t r i g g e r e db y a c u s t o mE S C a p

s e q u e n c e .T h e r ea r et w e n t y - s e v e n( t w e n t y - e i g h t ? )d e f a u l tE S C a p

s e q u e n c e sp r o g r a m m e di n t ot h e C - 1 2 8R O M ;t h e ya d da l o t o f

p o w e ra n dc o n v e n i e n c et o t h e s c r e e ne d i t o r .C o m m o d o r ea l s o

d e s i g n e d - i nf l e x i b i l i t y ;a t t h ep o i n ti n t h eE S C a p es e q u e n c eh a n

d l i n g r o u t i n ew h e r et h en e x tk e ya f t e rt h eE S Ch a sb e e nd e t e c t e

a n ds t o r e di n t h ea c c u m u l a t o r ,t h eR O Mr o u t i n ej u m p st h r o u g ha n

i n d i r e c ta d d r e s si n R A Ma t $ 0 3 3 8- $ 0 3 3 9 ,b e f o r ei m p l e m e n t i t h e

d e f a u l tE S Cs e q u e n c e s .R e s e t t i n gt h i sv e c t o rt o p o i n tt o a n e w

r o u t i n eo p e n s u pt h e p o s s i b i l i t y o ft w o h u n d r e d a n df i f t y - s

d i f f e r e n tE S C a p es e q u e n c e s !

I n t h i sa p p l i c a t i o n ,t h es e q u e n c eE S C- U PA R R O Wi s u s e dt o t o g g l

b e t w e e nt h et w os c r e e n s .A s i s t h ec a s e w i t ht h en o r m a lE S C a p

s e q u e n c e s ,t h i sm e a n sp r e s s i n ga n dr e l e a s i n g t h eE S Ck e y ,t h e n

p r e s s i n gt h e U P A R R O Wk e y . I np r o g r a m m o d e , P

C H R $ ( 2 7 ) a n d a nU PA R R O W( o rC H R $ ( 9 4 ) )w i l la c c o m p l i s t h e

s a m ee f f e c t .T h eU PA R R O Wi s n o t ac u r s o rk e y ;i t ' st h ee x p o n e n t

t i o ns y m b o l ,b e t w e e nt h eR E S T O R Ea n dt h eA S T E R I S Kk e y s .

I f y o up r e f e rs o m eo t h e r s e q u e n c e ,l o o ka t t h es i x t hn u m b e ri n t h e

f o u r t hD A T As t a t e m e n ti n t h e B A S I Cl o a d e rp r o g r a

T h eT r a n s a c t o r 5 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 59: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 59/84

R E L O C A T I N G / T W I N .I t ' s9 4 , t h ed e c i m a lC H R $v a l u ef o rt h eU P -

A R R O W .R e p l a c et h i so n eb y t e w i t ht h eC H R $c o d ef o rt h e c h a r a c t e r

o f y o u rc h o i c e ,a n dt h ec h a n g ei s m a d e .I f y o uc h o o s e o n eo f t h e

d e f a u l tE S C a p es e q u e n c e s ,t h i sc u s t o ma p p l i c a t i o nw i l lt a k ep r e c e

d e n c e ,a s l o n ga s y o ua r ei n 8 0 - c o l u m nm o d e ,s i n c et h i ss p e c i a l

h a n d l i n gr o u t i n ec o m e sb e f o r e t h ed e f a u l t r o u t i n e .

W h a tD oY o uG e t

T h et w o8 0 - c o l u m ns c r e e n sa v a i l a b l ew i t ht h i sp r o g r a ma r e

c o m p l e t e l y e q u a la n di n d e p e n d e n t .E a c hs c r e e nh a si t s o w nt a b

s e t t i n g s ,c o l o r s ,c u r s o rt y p e ,a n dw i n d o w s .E i t h e rs c r e e nc a n b es e t

o r e v e r s eo r n o r m a lm o d e ,o r c l e a r e d ,i n d e p e n d e n t l yo f t h eo t h e r .

W h e ny o ut o g g l eb e t w e e nt h et w os c r e e n s , t h ec u r s o rr e t u r n st o t h e

s p o t( a n dw i n d o w ) w h e r ei t w a sw h e ny o ul e f tt h e s c r e e n .I f t h e

c u r s o rf o rt h a ts c r e e nw a sa n o n - f l a s h i n g u n d e r l i n ew h e ny o ul e f t ,i t

w i l lb e t h es a m ew h e ny o uc o m eb a c k .I f y o u h a v eu s e ds o m eo f t h e

V D Cr e g i s t e r st o c h a n g et h es i z e o ft h eb l o c kc u r s o r ,t h a tn e wc u r s o r

w i l lr e m a i ni n e f f e c t f o rt h ep a r t i c u l a rs c r e e ni n w h i c hi t w a ss e tu p .

f y o ua r ei n q u o t em o d e ,t y p i n g ap r o g r a ml i n ew h e ny o ut o g g l e

o u t ,y o uw i l lb e i n q u o t em o d ew h e ny o ut o g g l eb a c k .I n f a c t ,i t ' s

e a s yt o l o s et r a c ko fw h i c hs c r e e ny o u ' r e l o o k i n ga t .L o c a t i o n$ 0 A 2 E

s z e r of o rt h en o r m a ls c r e e n ,a n d$ 8 0i f t h en e ws c r e e ni s a c t i v e .B u t

h e r ei s n o r e a lr e a s o nt o w o r r ya b o u tt h i s ,s i n c eT H ET W O

S C R E E N SA R EC O M P L E T E L YE Q U I V A L E N T ! !

n o n ei m p o r t a n t w a y ,t h i sd o u b l es c r e e na r r a n g e m e n ti s s u p e r i o rt o

h ew i n d o w sa v a i l a b l eo n t h eC - 1 2 8 .I f y o ul i s ta l o n gp r o g r a ml i n e ,

o n et h a tr u n st o t w oo r m o r ep h y s i c a ll i n e s ,t h es c r e e ne d i t o rm a k e s

a n o t eo f t h i si n w h a ti s c a l l e da l i n e - l i n km a p ,f o u n di n C - 1 2 8R A M

f r o m$ 0 3 5 Et o $ 0 3 6 1 .I f y o uc r e a t e ,a n dt h e nc o l l a p s ea w i n d o w ,

h i sl i n e - l i n km a pi s d e s t r o y e d .I f y o u w e r et o p r e s sR E T U R No n

o n e o f t h e s e l o n gl i n e s ,o n l yt h e o n e p h y s i c a ll i n ew o u l db e

r e c o g n i z e d .W h e ny o ut o g g l eb e t w e e nt h eT w i n - 8 0s c r e e n s ,h o w

e v e r ,t h el i n e - l i n km a pi s s t o r e da n dr e p l a c e dw i t ht h e a p p r o p r i a t e

o n ef r o ms t o r a g e .

W h oN e e d sI t

f y o u w a n tt o b e a b l et o d i s p l a y t w i c e a sm u c hi n t h ew a yo f r e s u l t s

r o ma p r o g r a m ,y o un e e di t . I f y o uw a n ta p r o g r a mt o P R I N T

c o n s t a n t p r o g r e s sr e p o r t s ,w h i l er e s u l t sa r e l e f ts e c u r ea n du n -

c r o l l e do n t h eo t h e rs c r e e n ,y o u n e e di t . I fy o uw o u l dl i k et o l o o ka t

w op a r t so f a l o n gp r o g r a ml i s t i n g a tt h es a m et i m e ,y o u n e e di t . I f

y o u ' r e u s i n gt h eT R A C Eu t i l i t y ,a n dw o u l dl i k e t ol i s tv a r i o u sl i n e s o f

h ep r o g r a m ,w i t h o u t d e s t r o y i n gt h eT R A C Ev a l u e s ,y o u n e e di t . I f

y o uh a v ea H E L Ps c r e e n ,f u l lo f i n f o r m a t i o nt h a ty o uk e e pt h u m b

n gt h r o u g hm a n u a l sf o r ,y o uc e r t a i n l yn e e di t .O r i f y o uj u s th a t et h e

d e ao f4 , 0 9 6b y t e so f m e m o r yg o i n gt o w a s t ea n dn e v e rb e i n gu s e d ,

y o u n e e di t .

T h e P r o g r a m s

R E L O C A T I N G / T W I N

F r e eR A Mi n B a n k1 5 , w h e r et h i sr o u t i n ei s l o c a t e d ,i s g e t t i n g

l u t t e r e du p w i t hv a r i o u sc u s t o mr o u t i n e s ,w h i c ha l w a y ss e e mt o

o m p e t ef o rt h es a m es p a c e .T o a l l e v i a t et h i sp r o b l e ms o m e w h a t ,

h i sB A S I Cl o a d e rf o rT W I N - 8 0i s a r e l o c a t i n go n e .T h ep r o g r a m

a s k sy o uw h e r ei n m e m o r yt o p u ti t s e l f ,t h e np u t si t s e l ft h e r ea n d

a c t i v a t e si t s e l f- i f y o uj u s tp r e s sR E T U R Ni n r e s p o n s et o t h i s

p r o m p t ,t h ep r o g r a mw i l ls t a r ta t l o c a t i o n6 1 4 4 ,w h i c hs h o u l db e

s a f e .T h eb y t e st h a tm u s tb e a d j u s t e df o re a c hn e ws t a r t i n gp o i n t a r e

f l a g g e db y m i n u sv a l u e si n t h eD A T As t a t e m e n t s .T h ep r o g r a md o e s

a l lt h ea d j u s t i n g ;j u s tb e c a r e f u ln o tt o m i s sa n y m i n u ss i g n s .T h e r e

a r em a n yp o s s i b l e l o c a t i o n si n B a n k1 5 R A M( s e eT a b l e1 ) ;s u r e l y

t h e yw o n ' ta l lb e o c c u p i e db ys o m eo t h e ri m p o r t a n tu t i l i t y .I f y o ua r e

r e a l l yt i g h tf o rs p a c e , t h ef i r s t3 2 b y t e so f t h er o u t i n ea r en e e d e do n l y

f o r i n s t a l l a t i o n ,n o tf o rt h ea c t u a l r o u t i n e .

A l t h o u g ht h ee n t i r er o u t i n er u n st o 2 2 4b y t e s ,t h e r ea r eo n l y2 0 6

v a l u e si n t h e D A T As t a t e m e n t s .E a c ho f t h e 1 8 n e g a t i v ev a l u e s

g e n e r a t e st w ob y t e st o b e P O K E di n t om e m o r y .

R e m e m b e r ,i f y o uc h o o s et o u s e ad i f f e r e n tE S C a p es e q u e n c et o

s w i t c hs c r e e n s ,b o t ht h eV E R I F I Z E Rr e p o r tc o d ef o rt h eD A T Al i n e ,

a n dt h et o t a lc h e c k s u m ,C K ,w i l lb e o f f .

T W I N - 8 0 . A S M

T h i sp r o g r a m ,m yf i r s tw i t ha s y m b o l i ca s s e m b l e r ,w a sw r i t t e nu s i n g

t h e " P o w e r A s s e m b l e r "( f o r m e r l y" B u d d y " )1 2 8M a c r o - A s s e m

f r o mS p i n n a k e r .A s a n a l t e r n a t i v et o d o i n gt h es a m ej o bu s i n gt h e

b u i l t - i nM o n i t o ra s s e m b l e r ,B u d d yl e a v e sm e e c s t a t i c ,v e r g i n go n

e u p h o r i c .I f y o uh a v ea d i f f e r e n ta s s e m b l e r ,y o us h o u l dh a v e n o

t r o u b l ec o n v e r t i n gt h ep o w e ra s s e m b l e rs o u r c ec o d et o w o r kw i t hi t ;

t h em o s tl i k e l yt h i n gt h a t y o u ' l lh a v et o c h a n g ea r e t h el o n gs y m b o l

n a m e sw i t ht h ee m b e d d e da p o s t r o p h e s .S o ,f o re x a m p l e ,t h el a b e l

" s a v e ' b a n k "c o u l db e c h a n g e dt o " S A V B N K "t o w o r kw i t ha n o t h e r

a s s e m b l e r .

T h es e t - u pr o u t i n es i m p l yr e s e t st h eE S C V E Cv e c t o r ,t e m p o r a r i l

s e t sB a n k1 5 ,m o m e n t a r i l ya c t i v a t e sb o t hs c r e e n st o c l e a rt h e mo f

g a r b a g e ,a n dr e s t o r e st h eb a n ks e t t i n gb e f o r ee x i t i n g .

T h en e wE S C a p eh a n d l e rc h e c k sf o rt h es p e c i a lE S C a p es e q u e n c e

a n dt h a ty o ua r eu s i n gt h e8 0 - c o l u m ns c r e e n ,b e f o r e s w i t c h i na l l

t h en e c e s s a r yl o c a t i o n s .

C o m m u n i c a t i o nw i t ht h eV D Ci s a i d e db y t h et w oR O Mr o u t i n e s ,

R E A D R E Ga t $ C D D Aa n dW R I T E R E Ga t $ C D C C .B o t hr o u t i n e s

m o v ei n f o r m a t i o nb e t w e e nt h ea c c u m u l a t o ra n dt h eV D Cr e g i s t e r

w h o s en u m b e ri s f o u n di n t h eX r e g i s t e r .T h er o u t i n e s t a k e c a ro f

t h e" h a n d s h a k i n g "b e t w e e nt h eC - 1 2 8a n di t si n d e p e n d e n t - m i

V D C .

W h a tN e x t

C l e a r l y ,w e h a v e n ' th e a r dt h el a s to f m u l t i p l es c r e e n sf o rt h eV D C .

F o re x a m p l e ,i f y o ua r ew i l l i n gt o l i v ew i t ho n ec o l o u rf o rt h ee n t i r e

s c r e e n ,n o u n d e r - l i n i n g ,n o f l a s h i n g ,a n do n l yo n ec h a r a c t e rs e t ,

y o uc a nd i s a b l e t h ea t t r i b u t e s .T h e nt h e t w o , 2K b y t eb l o c k so f

a t t r i b u t em e m o r yw o u l db e f r e e du p t o p r o v i d er o o mf o rt w om o r e

i n d e p e n d e n ts c r e e n s ;a t o t a lo f f o u r .S i n c ed i s a b l i n g t h ea t t r i b u t e s

e l i m i n a t e so n eo f t h ec h a r a c t e rs e t s , t h i sm e a n sh a l fo f t h e8 K o f

c h a r a c t e rR A Mi s a v a i l a b l e ;t w om o r es c r e e n s ,f o ra t o t a lo f s i x !O r

1 5 0l i n e s o f8 0 - c o l u m nt e x t ,j u s ta k e y - s t r o k eo r t w oa w a y !

T h eT r a n s a c t o r 5 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 60: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 60/84

Page 61: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 61/84

J N

K H

C OO AB B

C CC J

G D

C HP G

J H

B M

I GC N

G AF OO PC PM N

L GI L

B G

P L

D KB F

L I

I L

G DI M

C BD l

G F

L H

1 0

L O

K ME K

K N

F K

J D

A l

A P

1 6 6 0d o 1i t

1 6 7 0 :

1 6 8 0 :

1 6 9 0 :

1 7 0 0 :

1 7 1 0 :

1 7 2 0 :

1 7 3 0 :

1 7 4 0 :

1 7 5 0 :

1 7 6 0 :

1 7 7 0 :

1 7 8 0 :1 7 9 0 :

1 8 0 0l o o p i

1 8 1 0 :

1 8 2 0 :

1 8 3 0 :

1 8 4 0 :

1 8 5 0 :

1 8 6 0 :

1 8 7 0 :

1 8 8 0 l o o p 2

1 8 9 0 :

1 9 0 0 :

1 9 1 0 :

1 9 2 0 :

1 9 3 0 :

1 9 4 0 :

1 9 5 0 :1 9 6 0 :

1 9 7 0 l o o p 3

1 9 8 0 :

1 9 9 0 :

2 0 0 0 :

2 0 1 0 :

2 0 2 0 :

2 0 3 0 :

2 0 4 0 :

2 0 5 0 :

2 0 6 0 :

2 0 7 0 :

I d a m o d e ; i s 8 0 - c o l u m nb e i n gu s e d

a n d# % 1 0 0 0 0 0 0 0

b e qn o r m ' o u t; n o ,s o g o n o r m a lr o u t e

j s r s a v e ' b a n k; s a v eb a n ka n dg o b a n k1 5

j s r v d c ' t o g g l e; s w i t c hm e m o r i e s

I d a c u r m o d ; s w i t c hc u r m o da n dt a b l e O

I d x t a b l e O

s t x c u r m o d

s t a t a b l e O

I d x # t a b l e ' 1 ' l e n g t h - 1i n t e r c h a n g ev a l u e si n

I d a p n t . x ; t a b l e1 w i t hp a g e0

I d y t a b l e i . x ; f r o m$ e Ot o $ f 9

s t a t a b l e i, x

s t y p n t , x

d e x

b p l l o o p i

I d x # t a b l e ' 2 ' l e n g t h - 1; i n t e r c h a n g et h e t a bm a p s

I d a t a b m a p , x

I d y t a b l e 2 , x

s t a t a b l e 2 , x

t y a

s t a t a b m a p , x

d e x

b p l I o o p 2

I d y # t a b l e ' 3 ' l e n g t h - 1

; a n dl i n e l i n km a p s

; w i t hv a l u e si n t a b l e2

I d x t a b l e 3 , y

j s r r e a d r e g

p h a

I d a t a b l e 4 , y

j s r w r i t e r e g

p l a

s t a t a b l e 4 , y

d e y

b p l I o o p 3

j m po l d ' b a n k; g e to l db a n k ,a n du s ei t s

i n t e r c h a n g et h ev a l u e s

; i nt a b l e4 w i t ht h e

l v a l u e si n s e l e c t e dv d c

r e g i s t e r s

r e g i s t e r s a r el i s t e di n

; t a b l e3

B L

E D

I K

F E

J P

N DG MO AK CH I

I P

P F

A KD M

J L

K CI M

F M

B E

L D

E CJ D

A H

B MN K

L H

F F

K GF E

G NA MD KD N

K LK GB N

C F

I O

A l

P P

G D

G J

2 0 8 0 :

2 0 9 0 ; *

2 1 0 0 :

2 1 1 0 ; .

2 1 2 0 ; .

; r t st o r e t u r nt o b a s i c

» e n do f n e wh a n d l e rr o u t i n e* • • •

s u b r o u t i n e s• * • *

r o u t i n et o s t a s hb a n k& s e tb a n kt o 1 5 * •

2 1 3 0 s a v e ' b a n kI d a m m u c r ; s a v e b a n k i n

2 1 4 0 : s t a t a b l e O+ 1 ; t a b l e0 , t h e ns e t

2 1 5 0 : I d a # $ 0 0 ; t o b a n k 1 5

2 1 6 0 : s t a m m u c r

2 1 7 0 : r t s

2 1 8 0 :

2 1 9 0; • • • * r o u t i n et o f e t c ha n dr e s e t o l db a n k » * * «

2 2 0 0o l d ' b a n kI d a t a b l e O + 1; g e to l db a n k2 2 1 0 : s t a m m u c r ; a n ds t o r ei n m m u

2 2 2 0 : r t s

2 2 3 0 :

2 2 4 0; * r o u t i n et o t o g g l eb e t w e e ns c r e e n si n v d cm e m o r y<

2 2 5 0v d c ' t o g g l eI d a

e o r

s t a

I d x

j s r

v m 3

# $ 1 0

v m 3

# $ 0 c

w r i t e r e g

; t o g g l ev a l u eo f v m 3

; b e t w e e n $ 0 0 a n d $ 1 0

I d a

e o r

s t a

I d x

j s r

r t s

• e n do f s u b r o u t i n e s• * »

v m 4

# $ 1 0

v m 4

# $ 1 4

w r i t e r e g

; s t o r en e wv a l u ei n

; v d cr e g i s t e r# $ 0 c

; t o g g l ev a l u eo f v m 4

; b e t w e e n $ 0 8 a n d $ 1 8

; s t o r en e wv a l u ei n

; v d cr e g i s t e r# $ 1 4

2 2 6 0 :

2 2 7 0 :

2 2 8 0 :

2 2 9 0 :

2 3 0 0 :

2 3 1 0 :

2 3 2 0 :

2 3 3 0 :

2 3 4 0 :

2 3 5 0 :

2 3 6 0 :

2 3 7 0 ; .2 3 8 0 :

2 3 9 0t a b l e O = *

2 4 0 0. b y t e9 6 , 0

2 4 1 0t a b l e i = »

2 4 2 0. b y t e0 , 1 6 , 0 , 1 8 , 2 4 , 0 , 0 , 7 9 , 0 , 0 , 3 , 0 , 0 , 2 4 , 7 9 , 9 4 , 2 7 ,

2 4 3 0t a b l e 2 = .

2 4 4 0. b y t e1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2 8 , 1 2

2 4 5 0t a b l e 3 = .

2 4 6 0. b y t e1 0 , 1 1 , 1 4 , 1 5 , 2 6 , 2 4 , 2 9

2 4 7 0t a b l e 4 = »

2 4 8 0. b y t e1 6 0 , 2 3 1 , 1 6 , 0 , 2 4 0 , 3 2 , 2 3 1

2 4 9 0. e n d

J l t b m g i j tS C R E E ND I S P L A YS A M P L E S

S y m b o l i cA s s e m b l e rf o rt h eC - 6 4a n da D i s kD r i v e

* W r i t t e ni n 1 0 0 %M a c h i n eL a n g u a g e

• k N o ta S n a i l - p a c e dB A S I Cp a r a s i t e

* N oS u b r o u t i n eC a l l sm a d et o $ A O O O - B F F F

* A l lD i s kO p e r a t i o n sE x e c u t e dT h r o u g h

S t a n d a r dK E R N A LJ u m pT a b l e

* N o tC o p yP r o t e c t e d :A r c h i v a lB a c k u pE n c o u r a g e d

* C a nu s eR A Mu n d e rR O Mf o rO b j e c tG e n e r a t i o n

o r f o rS t o r a g eo fT e x ta n dS y m b o l i cL a b e l s

* E x t e n s i v eD i s kS u p p o r t

* 3 2 I m m e d i a t eC o m m a n d s

* 2 6 P o w e r f u lP s e u d o O p c o d e s

* 2 6 U s e r I m p l e m e n t e d P s e u d oO p c o d e s

* M o v e ,C o p y ,S w a p ,D e l e t e ,R e n u m b e r

* A u t oL i n eN u m b e r i n gf o rE a s yT e x tE n t r y

- k F o r w a r do r R e v e r s eO b j e c tG e n e r a t i o n -

( G o o df o rS p e l l i n gS t r i n g sB a c k w a r d )

* A d d i t i o n , S u b t r a c t i o n , M u l t i p l i c a t i o n ,D i v i s i o n ,

S h i f tl e f t ,S h i f t r i g h t

D o c u m e n t a t i o nI n c l u d e sF u l lL i s t i n g

o f Z e r oP a g ea s E m p l o y e db y M A S

1 0 0

1 0 1

1 0 2

1 0 3

1 0 4

1 0 5

1 0 6

1 0 7

c m p ' S O F b e qm o d g o t

c m p# $ 0 1b e qm o d g o t

c m p# $ 0 2b e q m o d g o t

c m p# $ 0 6b e qm o d g o t

c m p # $ 0 Ab e qm o d g o t

c m p# $ 0 8b e qm o d g o t

j m ps o m e w h e r e _ e l s e

1 0 8 m o d g o t ;d o a m o d u l e

1 Q 9 c t v m n t f i i l a

1 1 0

1 1 1

1 1 2

1 1 3

1 1 4

I d am o d v e c t o r s+ 1 , x p h a

I d am o d v e c t o r s , xp h a

I d am o d s t a t u s . xp h a

r t i

1 1 5 s o m es t r i n g so u t ;X R= L e n g t h

1 1 6

1 1 8

1 1 9

1 2 0

1 2 1

1 2 2

1 2 3

I d yt a b

m o v s t r $ , x( s c r e e nn i e m l . y

m o vc o l o r( c o l o r .m e m ) , y

i n yd e x

b n el o o p

r t s

S O O m e s s a g c

8 1 0

8 2 0

8 3 0

8 4 0 s p r i t e 1

B S O s p i l t e Z

8 6 0 s p r i t e 3

8 7 0

8 8 0

8 9 0

9 0 0

9 1 0

9 2 0

9 3 0

9 4 0

9 5 0

9 6 0

I a l p h a b e t

r e v e b ; s p e l ln e x t z o O )

a s c" a b c d e f g h i j k l m n o i

n r n^ n r i t p< £ t n r a f l pU l y ■ . » j j ■i i i ' - . ' \ yi < i i | i r

o b j" 0 : s p r i t e _ d a t a 1 "

o b j " 0 : s p r i t ed a t a 2 "

o b j " 0 : s p r i t ed a t a 3 "

o r gS C 0 0 0; s t a r ts o m e v

o u t1 ; b l a n kH Hs e r e

m a s; d e f i n e a s m a s t e r

I n k " 8 : s t a r t "

I n k" 0 : b o d y r

I n k" 0 : b o d y 2 "

I n k" 0 : b o d y 3 "

I n k " 0 : e n d "

9 7 0 E n do f j i l e

9 8 0 e n d

l e sb a c k w a r d s

i q r s t u v w x y z "

v h e r e s a f e

e n

r l i n k e r

$ 2 99 5 A l lO r d e r sS h i p p e d1 s tC l a s s

A v a i l a b l e E x c l u s i v e l yF r o m

M o u n t a i nW i z a r d r y S o f t w a

P . O .B o x6 6 1 3 4

P o r t l a n d ,O R9 7 2 6 6

T h eT r a n s a c t o r 5 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 62: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 62/84

M e m o r yL a n e

P s s s s t ,. . . w a n n ak n o wa r e a l l y

s n e a k yp l a c et o s t a s hs t u f fi n t h e1 2 8 ?

C h r i sM i l l e

K i t c h e n e r ,O N

B y n o wt h eM M U( M e m o r y M a n a g e m e n tU n i t )a t $ F F O Oi n t h e

C 1 2 8i s f a i r l yw e l lu n d e r s t o o d .B u tt h e r ei s m o r e ,a l o t m o r e

i n v o l v e di n r e a l l yb e i n ga b l et o s t r o l ld o w ni t s m e m o r yl a n e

( w i t h o u tg e t t i n gl o s to r t i r e do r m u g g e d ) .

U n d e r - t h e - R u g

P s s s t !H e yM a c( M a x i n e )w a n n a k n o wa r e a l l ys n e a k yp l a c et o

s t a s hs t u f fi n t h e1 2 8 ? O k a y ,j u s ts t e pa r o u n dt h ec o r n e ri n t o t h i s

h e r ea l l e y .

E n t e rt h e f o l l o w i n gc o d et h r o u g ht h em o n i t o r- p u ti t a t $ 1 4 0 .

0 1 4 0

0 1 4 1

0 1 4 3

0 1 4 6

0 1 4 8

0 1 5 1

0 1 5 3

0 1 5 6

0 1 5 8

0 1 6 1

0 1 6 2

0 1 6 4

0 1 6 6

0 1 6 9

0 1 7 2

0 1 7 5

s e i

I d a

s t a

I d a

s t a

I d a

s t a

I d x

s t a

i n x

b n e

I d a

s t a

s t a

s t a

b r k

# 7 e

f f O O

# f 1

d 5 0 8

# 2 0

d 5 0 7

# 2

2 0 0 0 :

0 1 5 8

# 0

d 5 0 8

d 5 0 7

f f O O

; n oi n t e r r u p t i o n sp l e a s e

; r a m1 w i t hi / ov i s i b l e

; b i t0 a t $ d 5 0 8i s t h ek e yt o t h i st r i c k

; s w a pp a g e s $ 0 0 a n d $ 2 0

; $ 0 0 a n d $ 0 1d o n ' ts w a p

x ; s t o r eb l a n k sa t " o r i g i n a l "z e r op a g e

l o o p

; r e s t o r et h er e g i s t e r s

; r e t u r n t om o n i t o r

G 1 4 0 ,t h e nt r yt o f i n dt h e2 5 4$ 2 0 ' s .B e t c h ac a n ' t .O k a y ,n o w

u s et h es a m es e t u pb u tL D A2 0 0 0 . Xt h e nS T A8 0 0 0 . Xi n t h e

l o o p i n gp a r t .N o wa f t e rG 1 4 0y o uw i l ls e et h a t8 0 0 2 - 8 0 f f( i n

b a n k1 ) i s a l l s p a c e s .S o t h o s es p a c e sm u s th a v eb e e ns o m e

w h e r e , o t h e r w i s eh o wc o u l dy o ug e ta t t h e ma g a i n ?

W a yb a c kw h e nI w a ss t i l la n u n - e n l i g h t e n e dg o o f1 t h o u g h tI

h a da b a c k d o o rt o 8 5 6 3R A M .N o wt h a tI a ma n e n l i g h t e n e d

g o o fI b e l i e v e t h a tt h e s e b y t e sa r es i t t i n g a t0 2 — f fi n R A M1 ( n o t

s h a r e dR A M0 ) .

A Z e r o P a g eo f Y o u r V e r yO w n

O n eo f t h en e a t e s tf e a t u r e so f t h e1 2 8i s i t sr e l o c a t a b l e ,o r m o r e

p r e c i s e l y ,s w a p p a b l ez e r op a g ea n ds t a c ka r e a s .I n t h ea b o v e

e x a m p l ep a g e$ 0 0 a n dp a g e$ 2 0a r es w a p p e d .A w r i t et o $ f fw o u l ds h o wu p a t $ 2 0 f fi n s h a r e dR A M0 ( a l w a y sR A M0 ) b u ta

w r i t et o $ 2 0 f fw o u l da p p e a ra t $ f fi n u n s h a r e dR A M1 .

N o r m a lp r a c t i c e( m i n ea n y w a y )i n v o l v e s w r i t i n go n l yt o t h el o w

b y t e s( $ D 5 0 7a n d$ D 5 0 9 )o f t h ep a g ep o i n t e rr e g i s t e r s .T h e n

n e wa n do l d s y s t e m p a g e sw i l la l w a y sb e i n s h a r e dR A M .0

w h i c he v e no v e r i d e s t h e$ f f O Om e m o r yc o n f i g u r a t i o ns e t t i n

a n dg i v e sr i s et o a s l i c kw a yo f a c c e s s i n ga n yp a g eo f R A M0 f r o m

R A M 1 .

H e r ea n I n t e r r u p t ,T h e r ea n I n t e r r u p t ,

E v e r y w h e r e a nI n t e r r u p t

H e r ei s a h a n d yl i t t l er o u t i n et o m a k ea s s e m b l yl a n g u a

p r o g r a m m i n gi n o u t - o f - t h e - w a yb a n k sa b i t m o r eh o m e yo n

t h e1 2 8 .B r i a nH i l c e ,a u t h o ro f P r o - L i n e ' sC o c o m p i l e r ,p u tm eo n

t o i t s o t h a t1 w o u l ds t o p g r i p i n gt o h i ma b o u tw h a ta b o t h e ri t

w a st r y i n gt o w r i t ec o d et o r u ni n B a n k1 . T h ef o l l o w i n gI R Q /

B R Kw e d g ea l l o w si n t e r r u p t st o b e s e r v i c e dn o m a t t e rw h i c

b a n ko f m e m o r yo n e ' sc o d eh a p p e n st o b e e x e c u t i n gi n .

F i r s tp o i n tt h eB R Kv e c t o ra t t h en o r m a lI R Qs e r v i c er o u t i n e

T h e nj u s tp o i n tt h eI R Qv e c t o ra t y o u ro w nr o u t i n ew h i c hm u s t

b e i n c o m m o nR A M .N o r m a l l yt h i s w i l lb e b e l o w$ 4 0 0 .A l ly o u

d ow h e na n i n t e r r u p th i t sy o u rr o u t i n ei s p u t a$ 0 0a t $ f f O O( B a n

1 5 )a n de x e c u t ea B R Ki n s t r u c t i o nf o l l o w e db ya N O P .E x e c u t i

r e s u m e sf o l l o w i n g t h eN O P .T h eo r i g i n a l$ F F 0 0a n dr e g i s t e

v a l u e sw i l lb e o n t h e s t a c k - r e s t o r et h e m .A nR T Ig e t sy o ub a c k

c o m p l e t e l yi n t a c tt o w h e r e v e ry o uc a m ef r o m .S i x t yt i m e sa

s e c o n d ;w o r k sl i k ea c h a r m .L o o k sl i k et h i s :

; f i r s tp o i n tb r kv e c

; a t i r qs e r v i c ec o d e

s e i

I d a 7 8 8

s t a 7 9 0

I d a 7 8 9

s t a 7 9 1

I d a # < i r q s r v; t h e n p o i n ti r qv e c

s t a 7 8 8 ; a ty o u rs w i t c hI d a # > i r q s r v

s t a 7 8 9

c l i

r t s

i r q s r v= *

I d a # 0

s t a $ f f O O

b r k

n o p

p l a

s t a $ f f O Op l a

t a y

i n t e r r u p tw e d g e

; s e tb a n k1 5 c o n f i g

; s e r v i c ei r qt h r ub r k

; o l dc o n f i go n s t a c k

; r e s t o r ei t

; r e g i s t e r st o o

T h eT r a n s a c t o r 6 O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 63: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 63/84

p l a

t a x

p l a

r t i ; r e t u r nf r o mi n t e r r u p t

T h e s a m eg e n e r a l i d e ac o u l db e u s e di n t h e6 4 t o t a k ea d v a n t a g e

o f i n t e r r u p ts e r v i c i n gf r o mt h eh i d d e nR A Mb e l o wK e r n a lR O M .

f y o u rp r o g r a mw a su s i n gi t so w nz e r op a g ey o um i g h tw a n tt o

p u s ht h e i n t e r r u p t e d$ D 5 0 7s e t t i n go n t h e s t a c ka n ds t i c ka $ 0 0

h e r ep r i o rt o t h eB R Ks o t h a tt h eI R Qr o u t i n ew o u l dn o tm e s s

w i t hy o u rp o i n t e r s ,t h e n ,r i g h t a f t e rt h eB R K : N O P ,p u l l$ D 5 0 7o f f

h e s t a c ka n dr e s e ti t . F a n c yt h a t- o v e r2 5 0b y t e so f w o n d e r f u l ,

b e a u t i f u l ,a b s o l u t e l yf r e ea n du n i n t e r r u p t e dz e r op a g ef o ry o u r

p r o g r a m .

K e e p i n gi n T o u c h W i t ht h eK e r n a l

E v e nt h o u g ht h e 1 2 8 h a sa b u n c ho f n e wK e r n a lr o u t i n e sf o r

c a l l i n go u t - o f - b a n kc o d e ,I t e n dt o s h ya w a yf r o mt h e m .T h e s e

e n dt o j u m pa l l o v e rt h e p l a c e ,s l o w i n gt h i n g sd o w na n d

g e n e r a l l yc o n f u s i n gt h ed a y l i g h t so u to f m e .B e s i d e s ,i t ' su s u a l l y

h eK e r n a lI ' mc a l l i n gi n t h ef i r s tp l a c e .I l i k et o w r i t em yo w n

J S R F A Rr o u t i n et o h a n d l eK e r n a lc a l l sf r o mo t h e rb a n k s . U s u a l l y

h e r ei s r o o ml o wo n t h es t a c k( $ 1 4 O - $ 1 C O )o r i n t h es y s t e m

n p u tb u f f e r( $ 2 0 0 - $ 2 9 f )f o rt h i ss o r t o ft h i n g .T h ef o l l o w i n gl e t s

y o uc a l lt h eK e r n a lf r o mB a n k1 . O n eb y t eo f m e m o r yi s n e e d e d

o s a v et h e . Yr e g i s t e r .

; . Y i s s a v e d i n H O L D Y

; a n dl o a d e dw i t ht h el o wb y t eo f t h e K e r n a lr o u t i n e

p r i o r t oc a l l i n gF A R K E R N A L

F A R K E R N A L= *

s t y

I d y

s t y

s t y

I d y

j s r

k e r n r t n

# 0

$ f f O O

$ d 5 0 7

h o l d y

S f f f f

k e r n r t n = * - 2

p h p

p h a

; s e l fm o dj s r

; b a n k 1 5

; y o u ro w nZ p a g eM r .K e r n a ls i r

; i nc a s ei t ' sn e e d e d

; c a l lr o u t i n e

; s a v es t a t u s

; a n d. A

I d a # m y z p g ; ; m yz e r op a g eb a c k

s t a $ d 5 0 7s t a $ f f O 2 ; ; l a t c h t ob a n k1

p l a ; r e m e m b e r . A

p i p ; a n ds t a t u s

r t s

H e r ei s h o wF A R K E R N A Lw o u l db e u s e dt o P R I N Tf r o mB a n k1 :

p r i n t

s t y h o l d y ; s a v e. y

I d y # $ d 2 ; < $ f f d 2

j m pf a r k e r n a l

I f y o u w e r ec o n v e r t i n ga p r o g r a mf r o mt h e6 4 ,t h i sp r i n tr o u t i n e

w o u l dr e p l a c et h eP R I N T= $ F F D 2a s s i g n m e n t .T h er e s to f y o u r

p r o g r a ms h o u l dn e v e rk n o wt h ed i f f e r e n c e .

N o t i c e a g a i nt h a ty o u r v e r yo w n ,p e r s o n a l ,p r i v a t e ,e x c l u s i v e

z e r op a g ew i l ls t i l lr e m a i nt h a tw a y .N e i t h e ri n t e r r u p t sn o r

K e r n a lc a l l sn e e db e a l l o w e dt o c h e wo n i t .

S h a r ea n dS h a r eA l i k e

T h es y s t e m k e e p sa $ 0 4a t $ d 5 0 6t h a tp r o v i d e sa n e s s e n t i a l1 K

o f c o m m o nR A Ma t t h e b o t t o mo f m e m o r y .S o n o r m a l l y ,n o

m a t t e rw h a t b a n ky o u d ob u s i n e s sw i t h ,c o m m o nR A Mf r o m

$ 0 0t o $ 3 f fw i l lb e v i s i b l e .A l m o s te v e r yb i gM Lp r o g r a mi s g o i n g

t o h a v et o m o v ea l i t t l ec o d ei n t ot h i sa r e ai n o r d e rt o a c c e s sa l lo f

m e m o r y .U n h a p p i l y ,t h eo p e r a t i n gs y s t e mh o g sa g o o dd e a lo f i t .

B u t d e s p a i rn o t ,f o rt h i sa r e ac a nb e e x p a n d e d a n de v e nm o v e d

a b o u ta t w i l l .O v e r s e e i n gt h i si s t h eR A Mc o n f i g u r a t i o nr e g i s t e r

a t $ D 5 0 6 . O n l yt h el o wn y b b l ei s u s e di n t h e1 2 8 .T h et w ol o w

o r d e rb i t sd e t e r m i n et h ea m o u n to f R A Mt o s h a r e .P a i r e dv a l u e s

o f 0 , 1 , 2 o r 3r e s u l t i nI K ,4 K ,8 Ko r 1 6 Kr e s p e c t i v e l yo f s h a r e d

R A M .B i t s2 a n d3 d e t e r m i n ew h e t h e rl o w ,h i g h ,o r b o t hl o wa n d

h i g hR A Mi s h e l dc o m m o n .

C o m m o nR A Mi s a l w a y sR A M0 . T h e $ D 5 0 6s e t t i n gt a k e s

p r i o r i t yo v e rt h e $ F F 0 0c o n f i g u r a t i o n b u tn o t o v e rt h e p a g e

p o i n t e r s .I f y o uj u s tc a n ' ts e e mt o f i t a l l y o u rr e l a yc o d eb e l o w

$ 4 0 0 ,o r i f y o u w a n tt o b e a b l et o a c c e s st h e4 0 c o l u m ns c r e e n

d i r e c t l yf r o mB a n k1 , t h e nk e e p$ D 5 0 6i n m i n d .

T h e r ei s a n o t h e rs i t u a t i o ni n w h i c he x p a n d i n gc o m m o nR A Mi s

v i r t u a l l ye s s e n t i a l .R O Mf o rt h eZ 8 0C P Ur e s i d e sf r o m$ O O - $ f f f

A t f i r s tg l a n c ei t w o u l ds e e mi m p o s s i b l et o s w i t c hB a n k si n Z 8 0

m o d ew i t h o u tw h i p p i n gm e m o r yr i g h to u tf r o m u n d e ry o u .N o

c o m m o nR A Mt o w o r kf r o m .. . u n l e s sy o u w e r et o f i r s ts t o r e ,

s a y ,a % 1 0 1 1a t $ D 5 0 6 ,l o c k i n g t h e t o p1 6 K( $ C 0 0 0 - $ F F F F i n t o

R A M 0 .

T h a tS e c r e t P l a c eA g a i n

W r i t i n g a$ 0 0t o $ D 5 0 6d i s a b l e sa l lc o m m o nR A M( e x c e p t$ f f O O )

i n c l u d i n g t h ef i r s tK o f m e m o r y .I t i s v i r t u a l l yi m p o s s i b l et o

c h a n g e b a n k si n t h i sm o d e .T h e1 2 8m o n i t o ri s u n a b l et o a c c e s s

$ 0 0 - $ 3 f fR A M1 f o rt h i sv e r yr e a s o n . B u tn o wt h i sp e r f e c t l yf r e e

w e l l - h i d d e nK o f R A Mi s y o u r sf o rt h e t a k i n gb y s i m p l ys t o r i n ga

$ 0 0a t $ D 5 0 6a n y w h e r ef r o mw i t h i nR A M1 .

B e y o n dt h eM M U

M Lm e m o r ym a n a g e m e n to f t h e1 2 8 g o e sw e l lb e y o n d m a s s

i n g$ F F 0 0d i r e c t l yo r v i ai t s$ F F 0 1 - $ F F 0 4w r i t e l a t c h e st o v a l u e s

a t $ D 5 0 1 - $ d 5 0 4 .H o w e v e r ,u s i n gt h e s ei n c o n j u n c t i o nw i t ht h e

p a g ep o i n t e r s( $ D 5 0 7 - $ D 5 0 8a n d$ D 5 0 9 - $ D 5 0 A )a n dt h eR A M

C O N F I G U R A T I O Nr e g i s t e r( $ D 5 0 6 )w i l lp a v et h ew a yt o t a p p i n g

t h er e a lp o t e n t i a lo f t h ev e r s a t i l e1 2 8 .

W h yM e ?

I h a v ej u s tf i n i s h e d( f o rt h e1 0 0 t ht i m e )n e w6 4 / 1 2 8a s s e m b l e

( m yB u d d y - S y s t e m s )f o rP r o - L i n es o f t w a r es o I w o u l dl i k e t o

t h i n kI k n o wa g r e a td e a la b o u tt h ei n sa n do u t so fp r o g r a m m it h e1 2 8 .I w o u l da l s ol i k ea J a g u a rX K E ,a s a t e l l i t ed i s ha n da

c o t t a g eb y t h el a k e .

T h eT r a n s a c t o r 6 1 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 64: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 64/84

E v e n tM a k e rf o rt h eA m i g ab y C h r i sZ a m a r a ,T e c h n i c a lE d i t o r

- S i m u l a t em o u s ea n dk e y b o a r di n p u t sw i t hC L Ic o m m a n d s

O n eo f t h ef i r s tt h i n g sy o u ' l ln o t i c ea b o u ta n y c o m p u t e ri s h o wy o u

h a v et o a s ki t t o d o t h et h i n g sy o u w a n td o n e .I n c o m p u t e r e s e ,t h a t

t r a n s l a t e st o t h e " U s e rI n t e r f a c e ' .U s e ri n t e r f a c e sc o m ei n t w o

f l a v o u r s :c o m m a n d - d r i v e n , a n di n t e r a c t i v e .T h eA m i g a ,b e i n gt h e

d o - e v e r y t h i n gm a c h i n et h a ti t i s , l e t sy o uh a v ei t b o t h w a y s .

F r o mt h e C L I( C o m m a n d - L i n eI n t e r f a c e ) ,t h e c o m m a n d - h a p p y

f o l k sc a nm e r r i l yp u n c hi n o b s c u r ei n c a n t a t i o n st o s e tt h em a c h i n e

i n t oa c t i o no n a n ym i s s i o n t h e yw i s ht o a s s i g ni t . P r o g r a m sd e s i g n e d

t o b e u s e df r o mt h eC L Ia r ec o n t r o l l e db y t h ea r g u m e n t st y p e di n

a f t e rt h ep r o g r a m n a m e ,m a k i n ga s i n g l ec o m m a n d .T h ea r g u m e n t s

c a n b en a m e so f f i l e so r o t h e r d a t af o rt h ep r o g r a mt o w o r ko n , o r

c e r t a i no p t i o n sa n ds e t t i n g s t h a tt h ep r o g r a ml o o k sa t t o f i n do u t

w h a ty o ue x p e c tf r o mi t . T h eb u i l t - i nC L Ic o m m a n d sl i k eC o p y ,

F o r m a t , E c h o , S e a r c h ,e t c .c a na l lb e u s e di n t h i sm a n n e r ,a n dm a n y

o t h e rp r o g r a m sg e t t h e i ra r g u m e n t sf r o mt h ec o m m a n dl i n ei n t h i s

w a ya s w e l l . A l lt h e U n i x - s t y l eu t i l i t i e st h a tp r o g r a m m e r sa r es o

f o n do f a r eo p e r a t e dv i ac o m m a n d - l i n ea r g u m e n t s .

T h eW o r k b e n c h ,o f c o u r s e ,i s a n e x a m p l eo f i n t e r a c t i v ep r o g r a m

o p e r a t i o n .A l t h o u g hW o r k b e n c hu s e sa W i n d o w / I c o n / M o u s e /

P o i n t e rk i n do f u s e r - i n t e r f a c e ,i t i s n ' tj u s tf o rW I M P s ,a n d e v e nR e a l

P r o g r a m m e r sc a n u s ei t t o g o o de f f e c t( a l t h o u g h t h e yu s u a l l yd o s o

o n l yw h e nn o o n e ' sl o o k i n g ) . I n t e r a c t i v e i n t e r f a c e sl i k eW o r k b e n c ha r e t y p i c a l l ye a s i e rt o u s et h a nc o m m a n d - d r i v e no n e s ,a n dc a n

o f t e nb e u s e dw i t h o u tr e l y i n go n r e f e r e n c em a n u a l so r y o u rm e m

o r y .A n e x a m p l eo f a n o p e r a t i o nt h a tc a n b e p e r f o r m e dv i a a

c o m m a n dO Ri n t e r a c t i v e l y( u s i n gW o r k b e n c h )i s c o p y i n ga f i l e .Y o u

c a ne i t h e rt y p e" c o p yf i l e lt o f i l e 2 "f r o mC L I , o rd r a ga n i c o n( i ft h e r e

i s o n ef o r t h a tf i l e )f r o mo n ed i s k o rd r a w e rt o a n o t h e ro n t h e

W o r k b e n c hs c r e e n .

N a t u r a l l y ,e a c h a p p r o a c hl e n d si t s e l fb e t t e rt o s o m ea p p l i c a t i o n s

t h a no t h e r s .A g r a p h i c se d i t o r , f o re x a m p l e ,s h o u l db e i n t e r a c t i v e ,

w h i l ea f i l ec o n v e r t e ro f s o m ek i n dw o u l dp r o b a b l yb e m o r eu s e f u l

a s a c o m m a n d( p r o g r a m st h a to p e r a t ee i t h e rw a ya r ea b o o n ,b u t

t h a t ' sn o ta l w a y sp r a c t i c a l ) .T h e c o m m a n d - d r i v e np r o g r a mh a sa

m a j o r a d v a n t a g eo v e rt h ei n t e r a c t i v eo n e ,t h o u g h :i t c a n b eo p e r a t e d

f r o m a n' E x e c u t e ' ,o r " s c r i p t " ,f i l e .A s c r i p tf i l ec a n a u t o m a t es o m e

p r o c e s st h a tt h e u s e rw o u l do t h e r w i s eh a v et o c a r r yo u tb y t y p i n gi n

c o m m a n d so n ea t a t i m e ,p o s s i b l yw a i t i n gf o ro p e r a t i o n st o c o m

p l e t ei n b e t w e e n .T h es c r i p tf i l ej u s tc o n t a i n s al i s to f c o m m a n d sa s

t h e yw o u l db e t y p e df r o mC L I ,a n di s e x e c u t e dw i t ht h eC L IE x e c u t e

c o m m a n d .A n i n t e r a c t i v ep r o g r a mw i l lb e o f l i t t l eu s ei n s u c ha

p r o c e s s , s i n c ei t w i l lc o m eu p a n dw a i tf o r t h e u s e rt o e n t e r

s o m e t h i n g ,w h i c hm a k e st h eo p e r a t i o nn o l o n g e ra u t o m a t i c .

A r e a le x a m p l e ? Y o uj u s tu s e d" P a g e S e t t e r "b y G o l dD i s k ,I n c . t o

c r e a t ea l o v e l yr e p o r t ,c o m p l e t ew i t ht h e o b l i g a t o r yp i e - c h a r t sa n d

b a rg r a p h st h a te v e r y o n eu s e st o s h o wo f ft h e i rc o m p u t e r .N o w ,y o u

w a n tt o p r i n ts e v e r a l c o p i e so f t h i sr e p o r t ,p e r h a p s a d v a n c i n gt h e

p a p e rb e t w e e nc o p i e s .Y o uw a n tt h i s t oh a p p e nw i t h o u ty o u r

a t t e n t i o n ,s i n c ei t m a yt a k e a l o n gt i m e .N o p r o b l e m- u s e t h e

" P a g e P r i n fp r o g r a mp r o v i d e do n t h eP a g e S e t t e rd i s kt o p r i n ty o u r

P a g e S e t t e rf i l e .P a g e P r i n ti s e x c e l l e n ti n t h a ti t c a nb e r u ne i t h e

f r o mW o r k b e n c h ,o r f r o mt h e C L Ib y g i v i n gi t t h e n a m eo f t h e

P a g e S e t t e rf i l ey o uw a n tt o p r i n t .

F i n e- m a k ea s c r i p tf i l et o p e r f o r mt h eP a g e P r i n tc o m m a n d s ,w i t h

E c h oc o m m a n d st h r o w ni n t o a d v a n c et h ep a g ea f t e re a c h c o p i s

p r i n t e d .E x e c u t et h es c r i p tf i l ea n da w a yy o ug o .E x c e p t ,o h l o o k-

P a g e P r i n tp u t su p a w i n d o wa n da s k sy o ut o p r e s sR E T U R Nt o p r i n t

t h e d o c u m e n t ,o r E S C A P Et o a b o r t .S o m u c hf o ry o u ra u t o m a t

s c r i p tf i l e- y o u ' l lh a v et o s t i c ka r o u n dw h i l ei t r u n sa n dp r e s s

R E T U R Ne v e r yt i m e P a g e P r i n ti s r u nt o p r o d u c et h en e x tc o p y .T h i s

i s n o tt o s a ya n y t h i n gb a da b o u tP a g e P r i n t- i t ' sj u s td e s i g n e da s a n

i n t e r a c t i v ep r o g r a m ,r a t h e rt h a n b e i n gc o m p l e t e l yc o m m a

d r i v e n .Y o uw i l lp r o b a b l yf i n dm a n yp r o g r a m st h a ty o u w o u l dl i k e

t o b e a b l et o o p e r a t ef r o ma s c r i p tf i l e( e v e nf r o ma S t a r t u

S e q u e n c e ) ,b u tt h e yr e q u i r ek e y b o a r do r m o u s ei n p u tf r o mt h eu s e r

b e f o r et h e yw i l ld o t h e i rj o ba n df i n i s hu p s o t h a tt h es c r i p tf i l ec a n

c o n t i n u e .W h a ty o un e e di n s u c hi n s t a n c e si s a w a yt o m a k et h e

c o m p u t e ri n e f f e c t" p r e s si t so w nb u t t o n s " .

W h i c h ,n o ts u r p r i s i n g l y ,i s w h y w ea r eh e r et o d a y .W ep r e s e n tt o y o u" E v e n t m a k e r " ,a c o m m a n d - d r i v e np r o g r a mt h a tl e t sy o us i m u l a

i n t e r a c t i v e i n p u t .I t w o r k sl i k et h i s :y o ut e l lE v e n t m a k e rw h a ti n p u

e v e n t sy o uw i s ht o t a k ep l a c e ,s u c ha s m o u s em o v e m e n t s k e y

p r e s s e sa n dr e l e a s e s ,e t c . ,a n dt h o s e e v e n t sh a p p e nw i t h i nt h e

A m i g aa s i f t h eu s e ra c t u a l l yp e r f o r m e d t h e m .T h i sc a ng e ts p o o k y

s i n c ey o uc a n h a v ea p r o g r a m d ot h i n g sb y i t s e l fa s i f s o m e o n ew a s

o p e r a t i n gi t , s o m e w h a tl i k ea p l a y e rp i a n o .

H o wT o U s eE v e n t m a k e r

W h e ny o ur u nE v e n t m a k e rf r o mt h eC L I ,y o ug i v ei t a l i s to f e v e n t

y o uw a n ti t t o s i m u l a t e .T h es i m p l e s to f t h e s ei s a k e y p r e s s .

e x a m p l e ,i f a p r o g r a mw a n t sy o ut o p r e s s" c "t oc o n t i n u e ,y o uc a ng e t

E v e n t m a k e rt o d o i t f o ry o u :f i r s tr u nt h ep r o g r a m( u s i n g" r u n "f r o m

C L I ) ,t h e ng e tE v e n t m a k e rt o e n t e r a" c "l i k et h i s :

E v e n t m a k e rc

Y o uc o u l de n t e rs e v e r a lk e y sl i k et h i s :

E v e n t m a k e ra b e d

F u n c t i o n k e y sa r es i g n i f i e db y " F "f o l l o w e db y t h e f u n c t i o nk e y

n u m b e r( F l ,F 2 ,e t c . ) .

O n l yu n s h i f t e d c h a r a c t e r sm a yb e s p e c i f i e di n t h i sw a y .I f S H I F T

C T R L ,A L T ,o r o t h e rk e y sa r et o b e h e l dw h i l et h e s ek e y sa r e

T h eT r a n s a c t o r 6 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 65: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 65/84

Page 66: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 66/84

/ * E v e n t m a k e r

• C h r i sZ a m a r a ,1 9 8 7

*

♦ P u t st h e s p e c i f i e dc h a r a c t e ri n t ot h ei n p u ts t r e a m a si f i t w e r e

• t y p e df r o m t h ek e y b o a r d .U s e f u li f y o ua r e r u n n i n ga p r o g r a mf r o m a

* s c r i p t t h a tw a n t sy o ut o p r e s sr e t u r no r s o m e t h i n gt o s t a r t .

*

• S e et h e' d o c s ' a r r a yb e l o wf o rc o m p l e t es p e c s .

• /

# i n c l u d e< e x e c / d e v i c e s . h >

# i n c l u d e < d e v i c e s / i n p u t e v e n t . h ># i n c l u d e < d e v i c e s / i n p u t . h >

c h a r * d o c s [ ]= {

" E v e n t m a k e r a c c e p t sa n yn u m b e ro f a r g u m e n t s , " ,

' e a c hs p e c i f y i n ga n i n p u t e v e n t .T h es y n t a xf o ra n e v e n ti s : \ n " ,

■ < k e y > - k e yd o w n " ,

" A < k e y > - k e yu p ' ,

" n : < k e y > - n u m e r i ck e y p a dk e y ' ,

" m : < x > , < y >- r e l a t i v em o u s em o v e m e n t " ,

' m : h - m o u s eh o m e( t o0 , 0 ) " ,

" d : i - d i s ki n s e r t e d " ,

" d : r - d i s k r e m o v e d " ,

' w : < n > - w a i t n s e c o n d s \ n " ,

" k e y sa r e e n t e r e da s s i n g l e u n s h i f t e dc h a r a c t e r s ,e x c e p t : \ n \

' s h i f t / a l t e t c .: L S H I F T R S H I F T L A L TR A L TL A M I G AR A M I G AC T R LC A P S " ,' m o u s eb u t t o n s: L M BR M B " ,

■ f u n c t i o nk e y s : F 1 - F 1 0 " ,

" o t h e rk e y s : H E L PR E T U R N U PD O W NL E F TR I G H T " ,

E S C T A B S P A C E E N T E R D E LB A C K S P C " ,

s t r u c tl O S t d R e q * i d R e q= N U L L ,« C r e a t e S t d l O ( ) ;/ * f o rI / Or e q u e s t s• /

s t r u c tP o r t* i d R e q P o r t= N U L L ,« C r e a t e P o r t ( ) ;

l o n gi d E r r o r= 1 , O p e n D e v i c e ( ) ;

m a i n( a r g c ,a r g v )

i n ta r g c ;

c h a r» * a r g v ;

{

i n t i ;

i f ( a r g c< 2 )

{ / « p r i n ti n s t r u c t i o n s* /

f o r( i = 0 ; i < s i z e o f ( d o c s )/ s i z e o f ( c h a r* ) ;i + + )

p u t s ( d o c s [ i ] ) ;

e x i t ( O ) ;

}

i f ( O p e n l n p u t D e v i c e ( )= = 0 )

f o r( i = 1 ; i < a r g o ;i + + )

M a k e E v e n t ( a r g v [ i ] ) ;

e l s e

p u t s f S o m e t h i n g w e n tw r o n g .S o r r y ,c a n ' th e l py o u . " ) ;

C l o s e l n p u t D e v i c e ( ) ;

}

O p e n l n p u t D e v i c e ( )

/ • c r e a t ep o r ta n dI / Or e q u e s tb l o c k ,o p e ni n p u td e v i c e• /

{

i f ( ( i d R e q P o r t= C r e a t e P o r t ( ' i d R e q P o r f ,0 L ) )= = N U L L

| | ( i d R e q= C r e a t e S t d l O ( i d R e q P o r t ) )= = N U L L

| | ( i d E r r o r= O p e n D e v i o e ( ' i n p u t . d e v i c e " ,0 L ,i d R e q ,0 L ) ) != N U L L

)

r e t u r n1 ;

r e t u r n0 ;

}

C l o s e l n p u t D e v i c e ( )

{

i f ( i d E r r o r= = 0 ) C l o s e D e v i c e ( i d R e q ) ;

i f ( i d R e q P o r t ) D e l e t e P o r t ( i d R e q P o r t ) ;

i f ( i d R e q ) D e l e t e S t d l O ( i d R e q ) ;

}

T h eT r a n s a c t o r 4 4 "

M a k e E v e n t( s t r i n g )

/ * F i l li n I n p u t E v e n ts t r u c t u r ea n dg i v eW R I T E V E N Tc o m m a n dt o i n p u td e v i c e• /

c h a r' S t r i n g ;

{s t r u c tI n p u t E v e n t M y l n p u t E v e n t ;

i d R e q - > i o _ C o m m a n d = I N D . W R I T E E V E N T ;

i d R e q - > i o _ F l a g s= 0 ;

i d R e q - > i o _ L e n g t h= s i z e o f ( s t r u c tI n p u t E v e n t ) ;

i d R e q - > i o _ D a t a= ( A P T R ) & M y l n p u t E v e n t ;

M y l n p u t E v e n t . i e . N e x t E v e n t= N U L L ;M y l n p u t E v e n t . i e _ T i m e S t a m p . t v _ s e o s= 0 ;

M y l n p u t E v e n t . i e _ T i m e S t a m p . t v _ m i c r o= 0 ;

M y l n p u t E v e n t . i e _ X= 0 ;

M y l n p u t E v e n t . i e . Y= 0 ;

i f ( S e t u p E v e n t ( s t r i n g ,& M y l n p u t E v e n t ) )

D o l O ( i d R e q ) ;

}

p a r s e X Y( s t r i n g ,x , y )

/ * g e tx a n dy v a l u ef r o mu s e r ' s i n p u ta n dp u ti n t os u p p l i e d a r g s• /

c h a r* s t r i n g ;

W O R D * x ,* y ;

{

i n ty a r g ;

• x = a t o i ( s t r i n g ) ;

i f ( ( y a r g= f i n d c h a r ( s t r i n g , ' , ' ) ) != - 1 )

• y = a t o i ( s t r i n g+ y a r g+ 1 ) ;

>

;

S e t u p E v e n t( e v e n t s t r i n g ,e v e n t )

/ * f i l li n s u p p l i e d I n p u t E v e n ts t r u c t u r eb a s e do ns u p p l i e d e v e n ts t r i n g* /

c h a r* e v e n t s t r i n g ;

s t r u c tI n p u t E v e n t» e v e n t ;

{

U W O R Dc l a s s ,c o d e ,q u a l ,m q u a l ,n q u a l ;

U W O R Dk e y . u p j n d i c a t o r= 0 ;

s t a t i cU W O R Dq u a l i f i e r= 0 ;

c o d e= q u a l= m q u a l= n q u a l= 0 ;

c l a s s= I E C L A S S . R A W K E Y ;

i f ( e v e n t s t r i n g [ O ]= = ' * ' ) / • k e yu pi n d i c a t o r- s k i po v e r* /

t

k e y . u p j n d i c a t o r= I E C O D E _ U P _ P R E F I X ;

e v e n t s t r i n g+ + ;

}

i f ( e v e n t s t r i n g [ 1 ]! = ' : ' ) / . n o r m a lk e y e v e n t * /

c o d e= f i n d k e y c o d e f e v e n t s t r i n g ,& q u a l ,& c l a s s ) ;

e l s e / * d i s k ,k e y p a do r w a i t• /

s w i t c h( e v e n t s t r i n g [ O ] )

;1

c a s e' n ' ; / * n u m e r i ck e y p a d* /

n q u a l= I E Q U A L I F I E R _ N U M E R I C P A D ;

c o d e= f i n d k e y c o d e f e v e n t s t r i n g ,& q u a l ,& o l a s s ) ;

b r e a k ;

c a s e' m ' :/ • m o u s em o v e m e n t♦ /

m q u a l= l E Q U A U F I E R . R E L A T I V E M O U S E ;

c o d e =I E C O D E . N O B U T T O N ;

c l a s s= I E C L A S S . R A W M O U S E ;

i f ( e v e n t s t r i n g [ 2 ]= = ' h ' )/ « m o u s eh o m e( t o pl e f t )* /

e v e n t - > i e _ X= e v e n t - > i e _ Y= - 1 0 2 4 ;

e l s e

p a r s e X Y f e v e n t s t r i n g+ 2 , & e v e n t - > i e _ X , & e v e n t - > i e _ Y

b r e a k ;

c a s e' d ' : / * d i s ke v e n t* /

i f ( e v e n t s t r i n g [ 2 ]= = ' i ' )

c l a s s= I E C L A S S J D I S K I N S E R T E D ;

e l s ei f ( e v e n t s t r i n g [ 2 ]= = ' r ' )

c l a s s= I E C L A S S _ D I S K R E M O V E D ;b r e a k ;

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u e0 3

Page 67: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 67/84

c a s e' w ' : / • w a i t ns e c o n d s • /

D e l a y ( ( U L O N G ) ( a t o i ( e v e n t s t r i n g+ 2 ) • 5 0 ) ) ;

r e t u r n0 ;

}

i f ( c l a s s= = I E C L A S SR A W K E Y& &c o d e> O x F F )

{

p r i n t f ( ' B a de v e n ts p e c i f i c a t i o n :° / o s \ n ' ,e v e n t s t r i n g ) ;

r e t u r n0 ;

}

i f ( c l a s s= = I E C L A S S _ R A W K E Y )

i f ( k e y _ u p _ i n d i c a t o r )

q u a l i f i e r& =® q u a l ;

e l s e

q u a l i f i e r| = q u a l ;

e v e n t - > i e _ C l a s s= c l a s s ;

e v e n t - > i e _ C o d e= c o d e| k e y _ u p _ i n d i c a t o r ;

e v e n t - > i e _ Q u a l i f i e r= q u a l i f i e r| m q u a l| n q u a l ;

r e t u r n1 ;

m d k e y c o d e( k e y ,q u a l i f i e r ,c l a s s )

* g i v e na s i n g l ek e ye v e n t ,f i n di t sc o d e a n dq u a l i f i e r• /

c h a r* k e y ;

U W O R D* q u a l i f i e r ,. c l a s s ;

{U W O R Dc o d e ;

n tt a b l e j n d e x ;

c h a r> k s t r i n g=

■ ' 1 2 3 4 5 6 7 8 9 0 -= \ @ @ @ q w e r t y u i o p [ ] @ @ @ @ a s d f g h j k l ;

t a t i cc h a r« k e y t a b l e 1 [ ]= {

• H E L P ' ,- R E T U R N ' ," U P " , - D O W N 1 ,1 E F T ' ,' R I G H T 1 ,

• E S C , ' T A B ' , - S P A C E ' , ' E N T E R ' ,' D E L ' ,' B A C K S P C

N U L L } ;

t a t i cU W O R Dc o d e . t a b l e i[ ] = {

0 x 5 f ,0 x 4 4 , 0 x 4 c ,0 x 4 d ,0 x 4 f ,0 x 4 e ,

0 x 4 5 , 0 x 4 2 , 0 x 4 0 , 0 x 4 3 , 0 x 4 6 , 0 x 4 1} ;

t a t i cc h a r• k e y t a b l e 2 [ ]= {

' L S H I F T - , ' R S H I F T ' ,' L A L T ' ,- R A L T " ,

' L A M I G A ' , - R A M I G A - ,- C T R L 1 , - C A P S ' ,

N U L L } ;

s t a t i cU W O R Dc o d e _ t a b l e 2 [ ]= {

0 x 6 0 , 0 x 6 1 , 0 x 6 4 , 0 x 6 5 , 0 x 6 6 ,0 x 6 7 , 0 x 6 3 ,0 x 6 2} ;

s t a t i cU W O R Dq u a l i f i e r _ t a b l e [ ]= {

I E Q U A L I F I E R . L S H I F T , I E Q U A L I F I E R . R S H I F T ,

n m , . l ' \

I E Q U A L I F I E R . R A L T ,

I E Q U A L I F I E R . R C O M M A N D ,

I E Q U A L I F I E R . C A P S L O C K } ;

l E Q U A U F I E R . L A L T ,

I E Q U A L I F I E R J . C O M M A N D ,

I E Q U A L I F I E R . C O N T R O L ,

s t a t i cU W O R Dk e y p a d _ c o d e s [ ]= {

0 x 4 a , 0 x 3 c , 0 x 0 0 ,O x O f ,0 x 1d , 0 x 1e , 0 x 1f ,

0 x 2 d , 0 x 2 e ,0 x 2 f ,0 x 3 d ,0 x 3 e , 0 x 3 f} ;

• q u a l i f i e r= 0 ;

♦ c l a s s= I E C L A S S . R A W K E Y ;

i f ( s t r l e n ( k e y )= = 1 )c o d e= f i n d c h a r ( k s t r i n g ,» k e y ) ;/ • s i n g l e - c h a rk e y • /

e l s ei f ( ( t a b l e j n d e x= f i n d s t r i n g ( k e y t a b i e 1 ,k e y ) )> = 0 )

c o d e= c o d e _ t a b l e 1[ t a b l e j n d e x ] ;/ • o t h e rk e y • /

e l s ei f ( ( t a b l e j n d e x= f i n d s t r i n g ( k e y t a b l e 2 ,k e y ) ) > =0 )

{ / • q u a l i f i e r - t y p ek e y• /

c o d e= c o d e _ t a b l e 2 [ t a b l e _ i n d e x ] ;

♦ q u a l i f i e r= q u a l i fi e r _ t a b l e [ t a b l e _ i n d e x ] ;

}e l s e i f( * k e y= = ' F ' & & s t r l e n ( k e y ) < =3 )

c o d e= 0 x 4 f+ a t o i ( k e y+ 1 ) ; / • f u n c t i o nk e y • /

e l s e i f ( s t r c m p ( ' L M B ' r k e y )= = 0 )

{ / • l e f tm o u s eb u t t o n» /

c o d e= I E C O D E . L B U T T O N ;

• q u a l i f i e r= l E Q U A L I F I E R . L E F T B U T T O N ;

• c l a s s= I E C L A S S . R A W M O U S E ;

}e l s e i f ( s t r c m p ( ' R M B ' ,k e y )= = 0 )

{ / • r i g h tm o u s eb u t t o n• /

c o d e= I E C O D E . R B U T T O N ;

• q u a l i f i e r= I E Q U A L I F I E R . R B U T T O N ;

• c l a s s= I E C L A S SR A W M O U S E ;

}e l s ei f ( k e y [ 0 ]= = ' n ' & &k e y [ 1 ]= = ' : ' / • n u m e r i ck e y p a dk e y • /

& &k e y [ 2 ]> = ' - ' & &k e y [ 2 ]< = ' 9 ' )

c o d e= k e y p a d _ c o d e s [ k e y [ 2 ]- ' - ' ] ;

e l s e

c o d e= - 1 ; / • i n v a l i de v e n ts p e c i f i e r• /

r e t u r nc o d e ;

f i n d c h a r( s t r i n g ,c h r )

/ * f i n da c h a r a c t e ri n a s t r i n ga n dr e t u r ni t sp o s i t i o n• /

c h a r» s t r i n g ;

c h a rc h r ;

{

i n tp o s ;

f o r ( p o s= 0 ; « s t r i n g ! = c h r& &' S t r i n g ;p o s ++ )

s t r i n g+ + ;

r e t u r n ( ' S t r i n g ?p o s: - 1 ) ;

f i n d s t r i n g( a r r a y , s t r i n g )

/ • f i n da s t r i n gi n a n a r r a ya n dr e t u r ni t sp o s i t i o n• /

c h a r• • a r r a y ,« s t r i n g ;

{

i n tp o s= 0 ;

w h i l e ( a r r a y [ p o s ]& &s t r c m p ( a r r a y [ p o s ] ,s t r i n g ) )

p o s ++ ;

r e t u r n ( a r r a y [ p o s ]! = N U L L ? p o s :- 1 ) ;

^ * y T H E1 S H O W

C o m m o d S a t u r d a y& S u n d a yO c t o b e r 3& 4 , 1 9 8 7

1 0 a . m . - 6p . m .

T H ED I S N E Y L A N DH O T E LA N A H E I M , C A L I F

■ E X H I B I T S ,E V E N T S

A N DD O O RP R I Z E S

■ N A T I O N A L L YK N O W NC O M M O D O R ES P E A K E R S

U S H O WS P E C I A L S

A N DD I S C O U N T S

M S E ET H EL A T E S TI N N O V A T I O N SI N

H A R D W A R EA N DS O F T W A R ET E C H N O L O G Y

T h eC o m m o d o r eS h o wi s t h eo n l yW e s tC o a s te x h i b i t i o na n dc o n f e re n c ef o c u s i n ge x c l us i v e l yo n t h eA M I G A ,C o m m o d o r e1 2 8a n d6 4 ,a n dP C 1 0 m a r k e tp l a c e .E n j o yt h eM a g ic a lK i n g d o mo f D i s n e ya l o n gw i t ht h o u s a n d so f C o m m o d o r eU s e r s .

C O M M O D O R E S H O W

A D M I S S I O N$ 1 0D I S C O U N TO ND I S N E Y L A N D T I C K E T

A V A I L A B L E

F o rM o r eI n f o r m a t i o no rt o R e s e r v eE x h i b i tS p a c e ,C o n t a c t

R KP R O D U C T I O N SP . O .B O X1 8 9 0 6 ,S A NJ O S E .C A9 5 1 5 8

( 4 0 8 )9 7 8 - 7 9 2 7 - 8 0 0 - 7 2 2 - 7 9 2 7 - I NC A8 0 0 - 2 5 2 - 7 9 2 7

T h eT r a n s a c t o r6 5 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 68: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 68/84

A N e wE C H O :

A nA m i g a D O SC o m m a n dR e p l a c e m e n N e a lB r i d g e s ,W e l l a n d ,O n t a r i o

. I ' v ed i s c o v e r e dt h ej o y so fp r o g r a m m i n gi n 6 8 0 0 0a s s e m b l yl a n g u a g e .

I m o v e df r o ma C 6 4e n v i r o n m e n tt o a n A m i g ao n l ya c o u p l eo f

m o n t h sa g o ,a n di t ' so n l yi n t h el a s tc o u p l eo f w e e k st h a tI ' v e

d i s c o v e r e dt h e j o y so f p r o g r a m m i n gi n 6 8 0 0 0a s s e m b l yl a n

g u a g e .A sm yf i r s tp r o j e c t ,r a t h e rt h a nc r e a t i n gs o m e t h i n gt o t a l l y

n e w ,I d e c i d e dt o i m p r o v eo n s o m e t h i n ga l r e a d yi n e x i s t e n c e .

W h a tf o l l o w si s a r e p l a c e m e n tf o r t h e A m i g a D o sc o m m a n d

" E C H O " .T h i sn e wE C H Oc o m m a n di s s h o r t e r ,f a s t e r ,a n db e t t e r ,

w h i l es t i l lr e t a i n i n ga l lt h ef e a t u r e so f t h eo l dE C H Oc o m m a n d .I t

w o r k su n d e rb o t hR e l e a s e1 . 1a n dR e l e a s e1 . 2o f t h eK i c k s t a r t /

W o r k b e n c hd i s k s .

T h r e ef i l el i s t i n g sf o l l o wt h i sa r t i c l e .

L i s t i n g1 ( " E c h o . a s m " )i s t h e C o m m o d o r eM a c r oA s s e m b l e r

s o u r c el i s t i n go f t h en e wc o m m a n d .

L i s t i n g 2( " E c h o . g e n " )i s a n A m i g a B a s i cp r o g r a mg e n e r a t o rt h a t

w i l lg e n e r a t ea n e x e c u t a b l ec o m m a n dc a l l e d" E C H O "o n y o u r

A m i g a B a s i cd e f a u l t d i r e c t o r y .T h i si s f o rt h o s eo f y o ul a c k i n g t h e

A s s e m b l e r .E a c hD A T Al i n ee n d sw i t h ac h e c k s u m ,s o t h eR E A D

l o o pa t t h e t o pc a nt e l ly o uw h a tl i n ea n e r r o ri s f o u n di n .

L i s t i n g3 ( " D a t e C h a n g e " )i s a n e x a m p l eo f a c o m m a n df i l eu s i n g

t h en e w E C H O .

H o wT oU s et h eN e wE C H O

T om a k ee f f e c t i v eu s eo f t h en e w E C H O ,I r e c o m m e n dt h a ty o u

d i r e c t l yr e p l a c e t h eo l dE C H Oc o m m a n d( i nt h ec : d i r e c t o r yo f

y o u rC L I / W o r k b e n c hd i s k )w i t ht h en e wo n e .. . a l ly o u re x i s t

i n gc o m m a n df i l e sw i l lf u n c t i o np e r f e c t l y ,a l b e i ts l i g h t l yf a s t e r .

U s a g e :E C H O[ - n ]< s t r i n g >

T h en e wE C H Oh a st h r e en e wf e a t u r e s . I nt h ee x a m p l e st h a t

f o l l o w ,' E C H O 'r e p r e s e n t s t h en e wE C H Oc o m m a n df i l e .

1 ) I f t h e c h a r a c t e r s' - n ' p r e c e d et h e< s t r i n g > a r g u m e n t ,a

n e w l i n ec h a r a c t e rw i l ln o tb e p r i n t e da f t e rt h e < s t r i n g > . F o r

e x a m p l e ,w i t h i n ac o m m a n ds e q u e n c e ,

E C H O- n B r o

E C H Ok e n

w o u l dd i s p l a y :

B r o k e n

2 ) Q u o t e s a r o u n dt h e< s t r i n g >a r en o r m a l l yu n n e c e s s a r ya n d

m a yb e l e f to u t .T h u s ,

E C H O" H e l l oW o r l d ? "

w i l ld i s p l a y t h es a m et h i n g a s

E C H OH e l l oW o r l d ?

T h eo n l yu s e f u lp u r p o s et h e yc a ns e r v ei s t o i n d i c a t el e a d i n

b l a n k s ,a s i n

E C H O" T h i si s 3 s p a c e so v e r . "

o r t o v i s u a l l yd e l i m i tt r a i l i n gb l a n k s( f o re a s i e re d i t i n g ) ,a s i n

A l s o ,

E C H O- n " T h ec u r r e n td a t ei s :

E C H O

T h eT r a n s a c t o r

p r i n t sa b l a n kl i n e .

A p a r t f r o mt h i s ,q u o t e sa r e i g n o r e db y t h e n e wE C H Oc o m

m a n d .

3 ) W i t h i nt h e < s t r i n g > ,a n yc h a r a c t e rp r e c e d e db y a ' A ' i s

c o n v e r t e di n t oi t se q u i v a l e n tC O N T R O Lc h a r a c t e r .T h i sf e a t u r m a k e si t p o s s i b l et o s e n dA N S Ic o d e st o t h ec o n s o l ea n dp r i n t e r

F o re x a m p l e ,

E C H O - n A l

w i l lg e n e r a t ea n dd i s p l a ya n A S C I I1 2 ( F o r m f e e d ) ,e f f e c t i v

c l e a r i n gt h es c r e e n ,a n d

E C H O> p r t :A [ [ 1m H e l l o T h e r e A [ [

w i l lp r i n t" H e l l oT h e r e "i n b o l d t y p eo n t h ep r i n t e r( A [r e s u l t si n

a n E S C a p ec h a r a c t e r ) .

T h en e wE C H Oh a n d l e st h e' * ' c h a r a c t e ri n e x a c t l y t h es a m em a n n e ra s t h eo l dE C H O .

6 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u e0 3

Page 69: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 69/84

A b o u tT h e P r o g r a m

T h ef i l e" E C H O . a s m " ,w h e na s s e m b l e da n dl i n k e d ,c o m e st o 2 9 2

b y t e s .T h i si s 2 6 8b y t e ss m a l l e rt h a nt h ee x i s t i n gc o m m a n d .I

h a p p e nt o l i k es h o r t c o d e .M yf i r s tm a c h i n e( w a y b a c ki n ' 8 2 )

w a sa 1 KZ X 8 1 ,s o I l e a r n e dt o s q u e e z em yp r o g r a m sr i g h tf r o m

t h es t a r t .I t ' sh e a l t h ym e n t a le x e r c i s e .

I h a v ed o n em yb e s tt o d o c u m e n tt h ea s s e m b l e rl i s t i n gf u l l y .I nt e r m so f f u n c t i o n ,i t f i r s to p e n st h e D O Sl i b r a r y .T h e n ,i f t h e

a r g u m e n tw a s ' ? ' , i t p r i n t st h e t e m p l a t e( ' : ' ) a n d g e t sa n

a r g u m e n ts t r i n gf r o mt h e c u r r e n t i n p u td e v i c e .I t t h e nc h e c k s

t h eb e g i n n i n go f t h ea r g u m e n ts t r i n gf o ra ' - n ' .I f f o u n d , af l a gi s

s e ti n d i c a t i n gt o t h eo u t p u ts e c t i o n t h a tn o E n d - o f - L i n ec h a r a c

t e r i s t o b e t r a n s m i t t e da f t e rt h eo u t p u ts t r i n g .T h e nt h e m a i n

l o o pc o p i e s t h er e s t o ft h ea r g u m e n ts t r i n gt o t h eo u t p u tb u f f e r ,

h a n d l i n g q u o t e sa n dt h es p e c i a lc h a r a c t e r s( ' * 'a n d' A ' ) . I tt h e n

c a l l st h eW r i t er o u t i n ei n t h eD O Sl i b r a r yt o s e n dt h er e s u l to u tt o

t h e c u r r e n t o u t p u t d e v i c e ,w i t ho r w i t h o u ta l i n e f e e d ,a s i n d i

c a t e db y t h e E n d - o f - L i n ef l a g .A f t e r w a r d s , t h eD O Sl i b r a r yi s

c l o s e d ,a n dc o n t r o li s r e t u r n e dt o t h eC L I .

T h er o u t i n ei s p o s i t i o ni n d e p e n d e n t .I h a v e n ' tt e s t e di t , b u tt h i s

s h o u l dm e a nt h a ti t l o a d sa n de x e c u t e ss l i g h t l y f a s t e rt h a na

s i m i l a r r e l o c a t a b l er o u t i n ew o u l db e c a u s e( a )r e g i s t e r sa r ef a s t e r

t h a nm e m o r y , a n d( b )t h er e l o c a t i n gl o a d e ri n R O Md o e s n ' th a v e

t o r e l o c a t ea n y t h i n gw h e ni t r e a d st h ec o m m a n df r o mt h ed i s k .I

r a n ar o u g ht e s tw h i c hs h o w e dt h a tt h en e wE C H Oc o m m a n di s

a p p r o x i m a t e l y6 0% f a s t e rw h e nr u n n i n gi t f r o md i s kt h a nt h e

o l dE C H O .B e i n gp o s i t i o ni n d e p e n d e n tm a k e si t s m a l l e r ,a s w e l l .

M a c h i n ei n s t r u c t i o n s t h a to p e r a t es o l e l yo n i n t e r n a l r e g i s t e r s

t a k eu p l e s sb y t e st h a nt h o s et h a tr e f e r e n c ei m m e d i a t ev a l u e s

a n dm e m o r ya d d r e s s e s .

O n ei n t e r e s t i n g n o t e :R a t h e rt h a nc r e a t ea b u f f e rt o h o l dt h e

o u t p u ts t r i n g ,I r e - u s e dt h e a r g u m e n tl i n e b u f f e r .S i n c e t h e

a r g u m e n tl i n ei s n ' tr e f e r e n c e de l s e w h e r ea f t e r t h i sr o u t i n ei s

t h r o u g hw i t hi t , t h e r e ' sn o p r o b l e m . T h i s o n l yw o r k sb e c a u s et h e

l e n g t ho f t h e o u t p u ts t r i n g t h a tt h i sr o u t i n ep r o d u c e si s a l w a y s

l e s st h a no r e q u a lt o t h e l e n g t ho f t h eo r i g i n a la r g u m e n ts t r i n g .I f

i t w e r ep o s s i b l ef o r t h e o u t p u ts t r i n gt o b e l o n g e rt h a nt h e

a r g u m e n ts t r i n g ,d i s a s t e rw o u l dr e s u l tb e c a u s et h e o u t p u ts t r i n g

w o u l dw r i t eo v e ri n p u tc h a r a c t e r st h a th a d n ' tb e e ns c a n n e dy e t .

A n o t h e rn o t e :A l t h o u g ht h i sn e wE C H Oc o m m a n dd o e sa l l t h e

t h i n g s t h e o l do n ed o e s , t h e i n v e r s ei s n o tt r u e .T h a ti s , i f y o u

m a k eu s eo f t h ei m p r o v e df e a t u r e si n y o u rc o m m a n df i l e s ,y o u

m u s t h a v et h en e wE C H Oc o m m a n di n y o u rc : d i r e c t o r yw h e n

y o uE X E C U T Et h o s ef i l e s .I f y o uc o m eu p w i t ha u s e f u lc o m

m a n df i l eu s i n gt h e n e wE C H O ,a n dy o uw a n tt o d i s t r i b u t ei t ,

d o n ' tf o r g e tt o d i s t r i b u t et h en e wE C H Oc o m m a n dw i t hi t , o r

y o u ' l lg e tc o m p l a i n t s .

L i s t i n g1 : S o u r c eC o d e

; - ' E c h o . a s m '

A n e wE C H Oc o m m a n db y N e a lB r i d g e s , 0 2 / 8 7 .

M ya d d r e s s :

; N e a lB r i d g e s ,

; 4 C r e s c e n tD r i v e ,

: W e l l a n d ,O n t a r i o ,

: C a n a d a ,L 3 B2 W 5 .

; P h o n e :( 4 1 6 ) - 7 3 4 - 7 7 8 9 .

; - T h i si s a C L Ic o m m a n d .I t ' sm e a n tt o r e p l a c e t h ee x i s t i n g

; E c h oc o m m a n d .A l t h o u g hi t h a sm o r ef e a t u r e s ,i t i s u p w a r d l yc o m p a t i b l e

; w i t ht h ee x i s t i n gc o m m a n d .I t ' sa l s oq u i t ea b i ts h o r t e r& f a s t e r .

: T ou s ei t e f f e c t i v e l y ,I r e c o m m e n dd i r e c t l ys u b s t i t u t i n g

: i t f o rt h ee x i s t i n g' E c h o 'c o m m a n di n t h ec : d i r e c t o r yo fy o u r

; C U A A / o r k b e n c hd i s k .

; - U s a g e :E c h o[ - n ]< s t r i n g >

; N o t e s :I f y o ui n c l u d et h e' - n ' ,n o l i n e f e e dw i l lb e p r i n t e da t t h e

; e n do f t h el i n e .T h e' n ' m u s t b el o w e r c a s e .

; - S p e c i a l f e a t u r e sw i t h i n< s t r i n g > :A ' * 'f o l l o w e db ya c h a r a c t e r

; w i l lb e c o n v e r t e di n t oa C T R Lc h a r a c t e r .F o r e x a m p l e , 1b e c o m e s

; A S C I 1 1 2 ,( F o r m f e e d ) , " gb e c o m e sA S C I I 7( B e l l ) ,A jb e c o m e s

: A S C I 1 1 0( L i n e f e e d ) ,• [ b e c o m e sA S C I I2 7 ( E s c ) ,e t c .

; E x a m p l e :E c h o- n * l

; c l e a r s t h e s c r e e n .

; E x a m p l e :E c h o" [ [ 2 m H e l l oT h e r e !

; s w i t c h e st o t e x tc o l o u rn u m b e rt w o( n o r m a l l yb l a c k )& d i s p l a y s

; ' H e l l oT h e r e ! 'i n t h a t c o l o u r .

; - Q u o t e s( ' )a r o u n dt h ea r g u m e n t< s t r i n g >a r eu n n e c e s s a r y

; u n l e s sy o uw i s ht o h a v el e a d i n gs p a c e si n y o u rs t r i n g ,

; f o re x a m p l e :E c h o ' H e l l oW o r l d ! "

; A sd e s c r i b e di n t h eA m i g a D o sM a n u a l :

; I f f o rs o m er e a s o ny o uw i s ht o p r i n ta q u o t ec h a r a c t e r ,y o um a yd o s o

; b y p r o c e e d i n gi t w i t ha ' * ' .

; E x a m p l e :E c h o* " H e l l oW o r l d . * '

; d i s p l a y s : " H e l l oW o r l d "

; - I f y o uw i s ht o p r i n ta ' • ' ,u s et w oo f t h e m .

; E x a m p l e :E c h ol n p u t » * O u t p u t 2 3 4

; d i s p l a y s :l n p u t * O u t p u t2 3 4

; - ' E c h o 'b y i t s e l fd o e sn o t h i n g .

; - ' E c h o" " 'p r i n t sa b l a n kl i n e .

; - P e r m i s s i o nt o c o p yb u tn o tt o s e l l .

; —T h ef o l l o w i n gr e g i s t e re q u a t e s

; s a v em e m o r y& i n c r e a s e t h es p e e do f t h ep r o g r a m .

; —R e g i s t e rE q u a t e :-

b u f p t r

a r g p s t r

a r g p t r

c h a r

B i t f l a g s

S p e c f l a g

c o u n t

a r g l e n

D o s b a s e

o u t p u t

e q u r a 2

e q u ra 3

e q u ra 5

e q u r d O

e q u r d i

e q u r d 2

e q u r d 3

e q u rd 4

e q u rd 5

e q u r d 7

; —S y m b o l i ce q u a t e s :

A b s E x e c B a s e e q u$ 4

L F

C T R L m a s k

e q u 1 0

- U s e df o r :

; O u t p u tb u f f e rp t r .

; S t o r a g ep l a c ef o r p t r

; t o s t a r to f a r g u m e n tl i n e .

; R rt o s t a r to f

; a r g u m e n tl i n e .

; C h a r b e i n g r e a di n

; f r o ma r g u m e n tl i n e .

; B i t0 i s u s e dt o s i g n a lt y p eo f l i n et e r m i n a t i o n .

; B i t 1i s u s e df o rt h eq u o t e

; t o g g l ef l a g ,a t h i n gi n c o r p o r a t e dt o k l u d g e

; t h es t r a n g ep a r s i n go f t h ee x i s t i n gE c h oc o m m a n d

; F l a gf o ru s ew i t h s p e c i a l

; s y m b o l s ' * ' & ' " ' .

; L e no f o u t p u tl i n e .

; L e no f a r g u m e n tl i n e .

; D o sl i b r a r yp o i n t e r .

; C L Io u t h a n d l e .

; L o co f p t r t ot h e

; E x e cl i b r a r y .

; L i n eF e e dv a l u e .

e q u0 / o 0 0 0 1 1 1 1 1; M a s kt o m a k eC T R Lc h a r s .

T h eT r a n s a c t o r 6 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 70: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 70/84

; —C h e c kf o r' - n 'a t s t a r to fa r g u m e n tl i n e :

x l i b M A C R O ; M a c r ot o s a v em yf e e b l ef i n g e r s . c m p i . w# ' - n ' , ( a r g p t r )+

x r e f_ L V O \ 1

E N D M

b n e . s f i x p t r

m o v e q# 1 , B i t F l a g s

c a l l M A C R O ; A n o t h e rm a c r ot o s a v et y p i n g .

j s r _ L V O \ 1 ( a 6 )

E N D M

; —F i n df i r s tn o n - b l a n kc h a r :

x l i b C l o s e J h e s ea r e L i b r a r y r o u t i n e sr e f e r e n c e d f i n d s p c c m p i . b# ' ' . ( a r g p t r )+

x l i b O p e n l i b r a r y; e x t e r n a l l yb y t h i sp r o g r a m . b l e . s f i n d s p c

x l i b C l o s e L i b r a r y

x l i b O u t p u t

x l i b W r i t e

x l i b I n p u t

x l i b R e a d

|

; —I n i t i a ls e t u p :

_ m a i n m o v e . la O , a r g p t r

m o v e . la O . a r g p s t r

m o v e . ld O . a r g l e n

l e a d o s n a m e ( p c ) , a 1

c l r d O

m o v e . lA b s E x e c B a s e , a 6

c a l l O p e n L i b r a r y

m o v e . ld O . d o s b a s e

b e q c l o s e

; —G e t C U o u t h a n d l e :

g e t o u t m o v e . ld o s b a s e , a 6

c a l l O u t p u t

m o v e . l d O . o u t p u t

; —C h e c kt h ee x i s t e n c eo f a n a r g u m e n tl i n e

c h e c k l e n c m p i . b# 1 , a r g l e n

b l e c l o s e

j

; —C h e c kf o ra r g u m e n t= ' ? '+ L F :

c h e c k q m c m p i . w# ' ? ' * 2 5 6+ L F , ( a r g p t r

b n e . s s t r t s c a n

J

; —D i s p l a yt e m p l a t e :

g e t l i n e l e a t e m p ! a t e ( p c ) , a 2

m o v e . l a 2 , d 2

m o v e . lo u t p u t . d i

m o v e . l# e n d t e m p - t e m p l a t e ,

m o v e . ld o s b a s e , a 6

c a l l W r i t e

; —G e ta r g u m e n tl i n ef r o mi n p u td e v i c e :

c a l l I n p u t

m o v e . l d O , d 1

m o v e . la r g p t r , d 2

m o v e . l# 2 5 5 , d 3

c a l l R e a d

m o v e . ld O . a r g l e n

b r a . s c h e c k l e n

s u b q . l # 1 , a r g p t r

b r a . s s e t u p

;

; —R e s e tp t rt o s t a r to f l i n ei f t h e r ew a s n ' ta '

f i x p t r m o v e . la r g p s t r , a r g p t r

s e t u p c l r . l c o u n t

R e m e m b e rp t rt o a r g u m e n tl i n e . c l r . b S p e c F l a g

M a k ec o p yo f i t f o rr e f e r e n c e .

R e m e m b e rt e no f a r g u m e n tl i n e . ;

- S p e c i f yn a m e' d o s . l i b r a r y ' . ; —M a k e n e wo u t p u tl i n ef r o ma r g u m e n tl i n e

S p e c i f ya n yv e r s i o n( 0 m e a n s s c a n m o v e . b( a r g p t r )+ , c h a r

a n yv e r s i o ni s O K ) .

T h e nu s i n gE x e cl i b r a r y , c m p i . b# L F , c h a r

O p e nD o sl i b r a r y . b e q e x i t

R e m e m b e rd o s b a s ep t r .

C h e c kf o re r r o r( d O= 0 m e a n s

' O hd e a r ,i t d i d n ' to p e n ' ) . ;

; —C h e c ks p e c i a lc h a r sf l a g :

t s t . b S p e c F l a g

U s i n gD o sl i b r a r y , b n e . s d o f l a g

g e tC L Io u t h a n d l e ,

& t h e nr e m e m b e ri t .

; —C h e c kf o rq u o t e :

I f n o a r g u m e n tc h a r s , c m p i . b# ' ' ' , c h a r

e x i tp r o g r a m . b n e . s c h k s p c l

b c h g # 1 , B i t F l a g s

b r a . s s c a n

) ; I f t h ea r g u m e n ti s ' ? ' o n l y , ;

s h o wt e m p l a t e& r e a da r g u m e n t ; —C h e c kf o rs p e c i a lc h a r s( *a n d• ) :

l i n ef r o m c o n s o l ei n p u td e v i c e . c h k s p c l c m p i . b# ' * ' , c h a r

( T h e e q u a t i o nr e s u l t si n a w o r d b n e . s c h k o t h e r

e q u a l l i n ga ' ? ' c h a rf o l l o w e db ya L F ) . b t s t # 1 , B i t F l a g s

b e q . s c h k o t h e r

m o v e q# 1. S p e c F l a g

- S p e c i f yp t r t ot e m p l a t es t r i n gi n c h k o t h e r c m p i . b# ' " ' , c h a r

d 2 ( v i aa 2 ) ; b n e . s i f f l a g

S p e c i f yo u t h a n d l ei n d 1 ; m o v e q# 2 , S p e c F l a g

3 3 ; S p e c i f yn u m b e ro f c h a r si n d 3 ; i f f l a g t s t . b S p e c F l a g

t h e nu s i n gD o sl i b r a r y ,

s h o wt h et e m p l a t e .

b n e . s s c a n

S t i l lu s i n gD o sl i b r a r y ,g e t t h e ; —P u tc h a ri n b u f f e r :

c u r r e n t i n h a n d l e . p u t i n b u f m o v e . bc h a r . ( b u f p t r )+- S p e c i f y i n h a n d l ei n d 1 ;

S p e c i f ya r g u m e n tb u f f e rp t ri n d 2 ; a d d q . b# 1 , c o u n t

S p e c i f ym a xl e ni n d 3 ; b r a . ss c a n

s t i l lu s i n gD o sl i b r a r y ,R e a dl i n e .

S e t a r g l e nt o t h e a c t u a ll e n o ft h e ;

l i n er e a d& g o b a c k u pt o c h e c k ; —H a n d l es p e c i a l c h a r s :

l i n el e na g a i n . d o f l a g c m p i . b# 1 , S p e c F l a g

; —S t a r tt h ea r g u m e n tl i n es c a n n i n gp r o c e s s :

s t r t s c a n c l r . b B i t F l a g s

m o v e . la r g p t r . b u f p t r

i

T h eT r a n s a c t o r

C l e a re n d - o f - l i n ef l a ga n dq u o t e

t o g g l ef l a g . b e q . s d f e x i t

S e t b u f p t r t o s t a r t o f a n d i . b# C T R L m a s k , d O

o u t p u tb u f f e r .( S i n c e t h ea r g u m e n tl i n e

i s n ' tn e e d e dt w i c e ,I ' mu s i n gi t

f o rt h eo u t p u tb u f f e ra s d f e x i t c l r . b S p e c F l a gw e l l ,& t h e r e f o r es e t t i n g

b u f p t rt o a r g p t ra c h i e v e sm yp u r p o s e . ) b r a . s p u t i n b u f

A r ef i r s t2 c h a r s' - n ' ?

I f Y E S ,

s e tB i tO o fB i t F l a g st o 1 ,

w h i c hm e a n s

' D o n ' ts e n d a nE O Lc h a r a c t e r

a f t e rp r i n t i n gt h el i n e ' .

L o o pu n t i ln x tn o n - b l a n kc h a rf o u n d .

W h e nf o u n d ,f i xp t r&

g o t o m a i n s c a nl o o p .

- n ' :

R e s e ta r g u m e n tl i n e p t r

t o s t a r to f l i n e .

C l e a ro u t p u t - c h a r sc o u n t .

C l e a rs p e c i a lc h a r sf l a g .

G e tf i r s ta r g u m e n tc h a r( a f t e r

' - n ' ,i f t h e r ew a sa ' - n ' ) .

I s i t E n d - O f - L i n ec h a r ?

I f Y E S ,t h e nt h e r e ' sn om o r e

a r g u m e n tl i n e ,& i t ' s

t i m et o s h o wo u t p u t .

C h e c ks p e c i a lc h a r sf l a g .

I f l a s tc h a rw a ss p e c i a l

o n e( e i t h e r• o r A ) ,g o t o d o f l a g

t o h a n d l ei t .

I f r e c e i v e dc h a ri s q u o t e ,

a v o i de n t i r e l y .

N e w E c h od o e s n ' td oq u o t e sw i t h o u t

' • ' i nf r o n to f t h e m .

I s i t ' * ' ?

I f Y E S ,w a st h e r ea p r e c e d i n g ' " ' ?

I f N O ,d i s p l a yi t a s a ' * ' .

I f Y E S ,s e tf l a gt o 1 .

I s i t ' * ' ?

I f Y E S ,s e tf l a gt o 2 .

I f S p e c F l a gi s s o m e t h i n go t h e rt h a n0

( m e a n i n gs p e c i a lc h a r

w a sr e c e i v e d ) ,

g o b a c k& g e t n e x tc h a r .

P u to u t p u tc h a ri n o u t p u tb u f f e r .

I n c r e m e n t o u t p u t - c h a r s c ob y 1 .

G ou p& g e ta n e wa r g u m e n t

l i n ec h a r .

I f f l a gw a ss e t t o1 b yl a s t

c h a r ( m e a n i n g ' * ' ) ,

t h i sc h a ri s m e a n tt o b e s h o w e d ,

& n e e d s n oa l t e r i n g .

I f i t ' s2 ( m e a n i n g' * ' ) ,

k n o c kt h i sc h a rd o w n

t o i t se q u i v a l e n tC T R Lc h a r .

I n e i t h e rc a s e ,c l e a rs p e c i a lc h a r sf l a g ,

& g o u p& s t o r ec h a ri n

o u t p u tb u f f e r .

6 8 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 71: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 71/84

; —A f t e rl o o k i n ga t a l la r g u m e n tc h a r s :

e x i t b c l r . b# 1 , B i t F l a g s ; C l e a rq u o t e st o g g l ef l a g ,

t s t . b B i t F l a g s ; C h e c kl i n et e r m i n a t i o nt y p ef l a g .

b n e . s n o l f ; I f i t ' s1 , d o n ' t p u ta L Fa t e n d

; o f o u t p u ts t r i n g .

m o v e . b# L F , ( b u f p t r ) ; I f i t ' s0 , p u ta l i n e f e e da t e n d .

a d d q . b# 1 , c o u n t ; & i n c r e m e n tc o u n tt o h a n d l ei t .

n o l f m o v e . la r g p s t r , d 2 ; - S p e c i f ys t a r t o fo u t p u tl i n ei n d 2 ;

m o v e . lo u t p u t . d i ; S p e c i f y o u t h a n d l ei n d 1 ;

m o v e . l c o u n t , d 3 ; S p e c i f y# o fc h a r st o w r i t ei n d 3 ;

c a l l W r i t e ; s h o wt h eo u t p u t .

; —C l o s eo p e n e dl i b r a r i e s :

c l o s e m o v e . ld o s b a s e . a i ; - S p e c i f yD o sl i b r a r yi n a 1 ;

m o v e . lA b s E x e c B a s e , a 6; t h e nu s i n gE x e cl i b r a r y ,

c a l l C l o s e L i b r a r y; c l o s eD o sl i b r a r y ,

c l o s e i r t s ; R e t u r nc o n t r o lt o C L I .

; —D o sL i b r a r yn a m e :

d o s n a m e d c . b ' d o s . l i b r a r y ' , 0n a m eo f D o sl i b r a r y

; —T e m p l a t es t r i n g :

t e m p l a t e d c . b ' : '

e n d t e m p

e n d

L i s t i n g2 : G e n e r a t e sl o a df i l e" E c h o '

R E M" E c h o . g e n "

R E MA m i g a B a s i cF i l eG e n e r a t o rf o r" E c h o " .

C L S

C O L O R2 : p r i n t "* * *" ;

C O L O R3 : P R I N T" E c h oP r o g r a mG e n e r a t o r "

C O L O R2 : p r i n t "* * *" ;

C O L O R3 : P R I N T" G e n e r a t e dB yM a k e G e n( N e a lB r i d g e s ,

0 2 / 8 7 ) . "

C O L O R1 P R I N T :P R I N T" P l e a s eW a i t ,c r e a t i n gE c h o .. . "

O P E N" E c h o "F O RO U T P U TA S1

P R I N T

l = 9 5 : f= 0

W H I L E f= 0

S u m= 0 : = l + 5

F O Ri = 1 T O8

R E A Dx : I F x < > 2 5 6T H E N

I F x >= 0 A N Dx < 2 5 6T H E NP R I N T# 1 , C H R $ ( x ) ;

S u m= ( S u m +x ) A N D2 5 5

E N DI F

N E X T: R E A Dx : I Fx < 0T H E NR E A Dx : f= 1

I F S u m O x T H E N

P R I N T" E r r o ri n L i n e " ; l

C L O S E1 : K I L L" E c h o " :E N D

E N DI F

W E N D

D o n e :C L O S E1 P R I N T" E c h oC r e a t e d . "

E N D

1 0 0D A T A0 , 0 , 3 , 2 4 3 , 0 , 0 , 0 , 0 , 2 4 6

1 0 5D A T A0 , 0 , 0 , 2 , 0 , 0 , 0 , 0 ,2

1 1 0D A T A0 , 0 , 0 , 1 , 0 , 0 , 0 , 6 0 , 6 1

1 1 5D A T A0 , 0 , 0 , 0 , 0 , 0 ,3 , 2 3 3 , 2 3 6

1 2 0D A T A0 , 0 , 0 , 6 0 , 4 2 ,7 2 , 3 8 , 7 2 ,2 8

1 2 5D A T A4 0 , 0 , 6 7 , 2 5 0 ,0 , 2 1 8 ,6 6 , 6 4 , 1 9 3

T h eT r a n s a c t o r

1 3 0D A T A

1 3 5D A T A

1 4 0D A T A

1 4 5D A T A

1 5 0D A T A

1 5 5D A T A

1 6 0D A T A

1 6 5D A T A

1 7 0D A T A1 7 5D A T A

1 8 0D A T A

1 8 5D A T A

1 9 0D A T A

1 9 5D A T A

2 0 0D A T A

2 0 5D A T A

2 1 0D A T A

2 1 5D A T A

2 2 0D A T A

2 2 5D A T A

2 3 0D A T A2 3 5D A T A

2 4 0D A T A

2 4 5D A T A

2 5 0D A T A

2 5 5D A T A

2 6 0D A T A

2 6 5D A T A

2 7 0D A T A

2 7 5D A T A

2 8 0D A T A

2 8 5D A T A

L i s t i n g3 :

4 4 , 1 2 0 ,0

4 2 , 0 , 1 0 3

7 8 , 1 7 4 , 2 5 5

0 , 1 , 1 1 1

6 3 , 1 0 , 1 0 2

3 6 , 1 0 , 3 4

0 , 2 , 4 4

7 8 , 1 7 4 , 2 5 5

3 8 , 6 0 , 02 5 5 , 2 1 4 ,4 0

3 6 , 7 7 , 1 2

1 1 4 , 1 , 1 2

8 3 , 1 4 1 ,9 6

6 6 , 2 , 1 6

1 0 3 , 0 , 0

1 2 , 0 , 0

0 , 1 , 9 6

1 0 2 , 8 , 8

1 1 6 , 1 , 1 2

1 1 6 , 2 , 7 4

8 2 , 3 , 9 61 0 3 , 4 , 2

9 6 , 2 3 6 ,8

1 0 2 , 6 , 2 0

3 6 , 1 1 , 3 4

2 5 5 , 2 0 8 ,3 4

7 8 , 1 7 4 , 2 5 4

1 1 5 , 4 6 , 1 0 8

1 2 1 , 0 , 5 8

0 , 0 , 3

0 , 0 , 3

2 4 5

4

0

1 9 6

0

4 2

7

6 9

2 0 2

00

9 3

2 9

2

2 9

6 4

3 4

2 3 0

1

0

2

1 9 80

1 2 9

1 8 8

7

6 9

9 8

1 0 5

3 2

2 3 3

2 4 2

, 7 8 ,

, o ,

, 4 6 ,

, o ,

, 6 9 ,

, 3 8 ,

, 7 8 ,

, 3 4 ,

, o ,, 9 6 ,

, 4 5 ,

, 0 ,

, 4 2 ,

, 1 2 ,

, 7 4 ,

1 0 2 ,

, 1 2 ,

0 ,

0 ,

1 0 2 ,

1 2 ,

0 ,

0 ,

0 ,

3 8 ,

4 4 ,

7 8 ,

9 8 ,

0 ,

0 ,

2 5 6 ,

1 7 4

1 9 0

0

1 7 4

2 5 0

6 0

1 7 4

0

2 5 52 0 0

1 1 0

3 2

7 5

0

2

6

0

1

9 4

2 0 4

2

3 1

1

1 0

3 ,

1 2 0 ,

1 1 7 ,

1 1 4 ,

0

0 ,

2 5 6 ,

A S a m p l eC o m m a n dF i l e

; " D a t e C h a n g e "

; A C o m m a n dF i l eb y N e a lB r i d g e s

2 5 4 , 1 0 4 ,1 0

4 4 , 6 9 , 1 9 2

1 2 , 4 , 2 5 3

1 2 , 8 5 , 1 2 7

0 , 1 8 8 , 2 1 2

0 , 0 , 1 8 5

2 5 5 , 2 0 8 , 6 2

3 6 , 1 3 , 2 4

7 8 , 1 7 4 ,9 36 6 , 1 , 1 0 4

1 0 2 , 1 2 , 2 3 1

1 1 1 , 2 5 0 ,3 7

6 6 , 1 3 1 ,1 2 4

0 , 1 0 , 1 3 5

1 0 2 , 4 4 , 1 3 3

8 , 6 5 , 2 2 7

0 , 4 2 , 1 2 5

1 0 3 , 2 , 2 2 5

1 0 2 , 2 , 7 1

2 0 , 1 9 2 , 2 0 0

0 , 1 , 1 3 86 6 , 2 , 2 0 8

7 4 , 1 , 3 3

8 2 , 3 , 1 5 5

7 8 , 1 7 4 ,1 2 5

0 , 4 , 2 2 2

1 0 0 ,1 1 1 , 2 4 2

9 7 , 1 1 4 ,2 9

3 , 2 4 2 ,2 0 0

0 , 0 , 2 3 6

2 5 6 , 2 5 6 ,- 1

0 2 / 8 7 .

; A S h o r tR o u t i n et o C h a n g et h eS y s t e mD a t e .

; D e m o n s t r a t i o no f n e wE C H Oc o m m a n d .

j

F A I L A T 2 5; p r e v e n t

; p r i n tb l a n kl i n e( A j ) ,p r i n t

E C H O - n

D A T E

;

p r e m a t u r ee x i tf r o ms e q u e n c e

' T h ec u r r e n t ..

A j " T h ec u r r e n td a t e

; p r i n td a t e

s "

; p r i n tb l a n kl i n e ,p r i n t' E n t e rt h e .. .

E C H O - nA j " E n t e rt h ec o r r e c td a t e :

; r e a dd a t ef r o mk e y b o a r d

D A T E> n i l?

; c h a n g et o c o l o u r0 , g o u p 3

; a n de r a s et o E n do f S c r e e n

E C H O - n

D A T E

E C H O"

6 9

A [ [ 0 m A [ [ 3 A A [ [ 2 0 C A |

l i n e s ,

[ J

/ , n o n e w l i n e

' , c h a n g et o c o l o u r# 2

" A [ [ 2 m

o v e r2 0 c h a r a c t e r s ,

; p r i n tn e wd a t ew h e r eo l dd a t ew a s

; p r i n tb l a n kl i n e

N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 72: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 72/84

P r o g r a m m e dC u r s o r

o n t h eA m i g a ?

J i mB u t t e r f i

T o r o n t o ,O n t a r

. . . i n s i d eq u o t a t i o nm a r k s ,t h i n g sw o r k al i t t l ed i f f e r e n t l y .

S l i py o u rA m i g ai n t oC L I ,a n dt y p et h ef o l l o w i n gc o m m a n d :

E C H O H O T * * D O G

T h ec o m p u t e rw i l lo b e d i e n t l ye c h oH O T * * D O Gf o ry o u .Y o ud i d

k n o wt h a tE C H O ' Sa r g u m e n td o e s n ' tn e e dt h o s eq u o t e s ,d i d n ' ty o u ?

Y o uu s e q u o t e sm o s to f t h et i m eb e c a u s ew h a t y o u w a n tp r i n t e d

c o n t a i n so t h e r w i s e f o r b i d d e nc h a r a c t e r s ,m o s t l ys p a c e s .

T h a ts e e m sr e a s o n a b l e .L e t ' sb e m o r e" c o n v e n t i o n a l "a n dt y p e :

E C H O1 H O T * * D O G "

S a m et h i n g ,e x c e p tf o rp u t t i n gq u o t em a r k sa r o u n dt h ea r g u m e n t .

B u tw a i t .. . o n eo f t h ea s t e r i s k sh a sd i s a p p e a r e d !W h a t ' sh a p p e n i n g

h e r e ?

I t t u r n so u tt h a tw h e ny o u ' r ei n s i d eq u o t a t i o n m a r k s ,t h i n g sw o r ka

l i t t l ed i f f e r e n t l y .E s p e c i a l l ya s t e r i s k s :t h e yw o r ka l o t d i f f e r e n t l y .

W i t h o u tt h e q u o t a t i o nm a r k s ,a s t e r i s k sa r e j u s t l i k ea n y o t h e r

c h a r a c t e r .T h eq u o t a t i o nm a r k sg e n e r a t ea s p e c i a lt y p eo f f o r m a t .

I t ' sl i k et h e" q u o t em o d e "o r " p r o g r a m m e dc u r s o r "y o um a yh a v e

s e e no n e a r l i e rC o m m o d o r em a c h i n e s .

S p e c i a lT r e a t m e n t

W h e ny o ut y p e a l m o s ta n yC L Ia r g u m e n tw i t h i n q u o t a t i o nm a r k s ,

t h ea s t e r i s kb e c o m e ss o m e t h i n gl i k ea n e s c a p e - t y p ec h a r a c t e r .Y o u

m i g h th a v e s e e n s o m e t h i n gl i k e t h i s i nC , o r i n p r o g r a m ss u c ha s

P a g e S e t t e r ,e x c e p tt h a ta m o r eu s u a lc h a r a c t e ri s t h e B a c k s l a s h .I t

s a y s :t h en e x t c h a r a c t e rt o f o l l o wi s n o t ar e g u l a r c h a r a c t e r ;i n s t e a d ,

i t ' sa s p e c i a ls i g n a l .E x c e p t i o n :w h e ny o ug i v e t h ec h a r a c t e rt w i c e ,

t h e s e c o n dc h a r a c t e ri s a c c e p t e da s t y p e d .S o t h e t w oa s t e r i s k s

c o l l a p s ei n t oo n e .I f y o ul i k e ,y o um a yt r a n s l a t et h et w oc h a r a c t e r s

a s " H e r e ' sa s p e c i a lc h a r a c t e r . . .I j u s tm e a na n o r d i n a r ya s t e r i s k " .

T h ea s t e r i s ki s a r e m n a n to f a n A m i g as y s t e ml a n g u a g ec a l l e d

B C P L .T h i sl a n g u a g ew a sa f o r e r u n n e ro f t h eC l a n g u a g e ,a n dy o u ' l l

s t i l lf i n db i t so f i t w i t h i nt h eA m i g ai f y o ud i gd e e pe n o u g h .O r i g i n a l

B C P Lh a da c o n s i d e r a b l en u m b e ro f s p e c i a lc o d e sg e n e r a t e db y a n

a s t e r i s k ;o n t h eA m i g ao n l yf o u ro f t h e mr e m a i n :

* * - g e n e r a t e sa s i n g l ea s t e r i s k ;

* " - g e n e r a t e sq u o t a t i o nm a r k s ;

* n - g e n e r a t e sa n e w l i n e( t h e " l i n e f e e d " )

* e - g e n e r a t e sa n A S C I I e s c a p ec h a r a c t e r .

W e ' v ea l r e a d yt r i e dt h ea s t e r i s k .Y o um i g h tt r y f o rs o m ei n t e r e s t i n g

e f f e c tw i t ht h en e x tt w ob y t y p i n g :

E C H O' P R E S S - " R E T U R N * 'W H E NR E A D Y 1

E C H O" L I N Ei H . n L . I N E 2 1

( D i d n ' tk n o wy o uc o u l dp r i n tt w ol i n e sw i t ho n eE C H Os t a t e m e n

d i dy o u ? )

B u tt h e s e r i o u so n ei s t h e * e s e q u e n c e ,w h i c hg e n e r a t e st h eE S C

e s c a p ec h a r a c t e r .Y o um i g h tr e c o g n i z et h i sa s C H R $ ( 2 7 )o r h e x a d

c i m a lI B ,b u ti f y o ud o n ' t ,n o m a t t e r .I t o f t e nh a se f f e c t ss i m i l a rt o

t h o s ep r o d u c e db y p r e s s i n g t h eE S Ck e y .Y o up r o b a b l yk n o wt h a t

p r e s s i n gE S Cf o l l o w e db y t h e " c "k e yc l e a r st h eC L Is c r e e n .I t a l s o

g e t sy o uo u t o f c e r t a i na n n o y i n gp r o b l e m s ,s u c ha s a p e c u l i a

c h a r a c t e rs e t .W e l lt h e n :I f * e i n q u o t e sm a t c h e st h eE S Ck e y ,t r y

t h i s :

E C H O' * e c '

Y o uw e r en o t s u r p r i s e dt o s e et h es c r e e nc l e a r ,w e r ey o u ?

Y o um i g h tp e r h a p sw o n d e rw h a tv a l u et h i sh a s .I t ' se a s i e rt o p r e s s

t w ok e y s ,E S Ca n d" c " ,t h a nt o t y p ei n t h ew h o l el i n es h o w na b o v e

B u tE C H Oi s o f t e nu s e di n b a t c hf i l e s( w h i c hI l i k et o c a l lE X E C U

f i l e s ,b e c a u s ey o uu s u a l l yi n v o k et h e mb y m e a n so f t h eE X E C U

c o m m a n d ) . S o y o uc a n h a v ea c o m m a n ds e q u e n c e -n o t ap r o g r a m

j u s ta c o m m a n ds e q u e n c e- c l e a rt h e s c r e e n .I t c a na l s od o o t h e r

t h i n g sf o ry o u ,w h i c hw e ' l lg e tt o i na m o m e n t .

F i l eN o n s e n s e

B y t h ew a y ,t h e u s eo f t h e a s t e r i s ki s n o t r e s t r i c t e d t ot h eE C H O

c o m m a n d .A n y t h i n gt h a ty o up u ti n q u o t a t i o nm a r k su s e sa s t e r i s

e s c a p ec a p a b i l i t i e s .S o i f y o u w a n tt o n a m ea f i l eS N O W * J O By o u

m a ye i t h e rc a l li t e x a c t l yt h a t . . .o r " S N O W * * J O B " .R e m e m b e r :y o u

o n l yn e e dt o d o u b l et h ea s t e r i s ki f y o ug i v e t h en a m ew i t h i nq u o t e s

Y o uc a na l s os l i pq u o t a t i o nm a r k si n t ot h e f i l en a m ei t s e l f .I f y o u

w a n tt o c a l la f i l e" C A T "- n o tC A T ,b u t " C A T " ,w i t ht h eq u o t e sa s p a r t

o f t h en a m e- y o um a yd o s o b y c a l l i n gi t " ♦ " C A T * " .I t w i l lm a k ei t

h a r df o ro t h e r st o r e f e r e n c e t h ef i l eb y n a m e .I t w i l lm a k ei t h a r df o r

Y O Ut o r e f e r e n c et h ef i l eb y n a m e .Y o ur e a l l yd o n ' tw a n tt o d o t h i s ,

e x c e p tt o p r o v et h a ti t c a n b ed o n e .

I ' mh a p p yt o r e p o r tt h a tt h eD O Sr e j e c t sf a n c i e rf i l en a m e s ,t h eo n e s

y o u ' l l t r yt o c r e a t eu s i n gt h en e w l i n ea n de s c a p es e q u e n c e s .A f t e r

y o ut h i n ka b o u ti t , y o u ' l lb e g l a di t d i d .

T h eC S I

I f y o ug e n e r a t et h eE S Cc h a r a c t e r( a n dw e k n o w h o wt o d o t h a t ,

d o n ' tw e ? )y o uc a nf o l l o wi t w i t h al e f t - s q u a r e - b r a c k e t

( " [ ■ )a n dt h ec o m b i n a t i o ni s c a l l e d aC S I .C S Is t a n d sf o rC o n t r o

T h eT r a n s a c t o r 7 O N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 73: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 73/84

S e q u e n c eI n t r o d u c e r ,w h i c hm e a n st h a ts o m e t h i n gs p e c i a lw i l l

f o l l o w .I f y o ug e ti n t ot h em a c h i n e ,y o uc a na l s oc r e a t ea C S Ia s a

s i n g l ec h a r a c t e r ,C H R $ ( 1 5 5 )o r h e x9 B .

T h eC S Is e e m sl i k ea n e wf o r mo f E S C A P E ,b u t i t h a sq u i t ea

d i f f e r e n tc h a r a c t e r ( n op u ni n t e n d e d ) .T h e E S Ci s f o l l o w e db y o n e

a n do n l yo n ea c t i o nc h a r a c t e r ; C S Im a yb e f o l l o w e db y n u m e r i cd a t a

( w h i c hi s n o t e d ) b u tt e r m i n a t e s o n l yw h e ny o ur e a c ht h ec o m m a n d

c h a r a c t e r .T h ec o m m a n dc h a r a c t e ri s u s u a l l ya l p h a b e t i c ,a n db e

c a r e f u l :u p p e rc a s e v e r s u s l o w e r c a s ei s s i g n i f i c a n th e r e .

T h i sb u s i n e s so f n u m b e rf o l l o w e db y c o m m a n di s r a t h e rl i k et h e

s y s t e m u s e di n E D ,t h es c r e e ne d i t o r ,f o r" e x t e n d e d "c o m m a n d s .

T h o s ea r e t h ec o m m a n d sy o ug e tb y p r e s s i n g t h eE S Ck e y .T h e i r

s y s t e m ,a s w i t hC S Ii s :t y p et h en u m b e rf i r s t ,a n dt h e nt h ec o m m a n d

l e t t e r ;t h ec o m m a n dw i l lb e e x e c u t e dt h ea p p r o p r i a t en u m b e ro f

t i m e s .C S Ih a si t so w nc o m m a n d s ,o f c o u r s e , n o t t h eo n e st h a tE D

u s e s .

F o re x a m p l e ,t h eC S Ic o m m a n df o r" l i n e f e e d "i s " E "( n o t e t h eu p p e r

c a s e ) .S o y o uc a nc o m m a n d :

E C H O" * e [ 6 E B A N A N A "

Y o u ' l lb e p l e a s e dt o s e et h ec o m p u t e rs k i ps i x l i n e sa n dt h e np r i n t

B A N A N A .

J u s tc h e c k i n gt h a ty o uf o l l o w t h e s y n t a x .I n t h ea b o v ee x a m p l e ,w e

M U S Tb e i n q u o t a t i o nm a r k s ;t h e a s t e r i s k i n d i c a t e sa s p e c i a l

c h a r a c t e rf o l l o w s ;t h ee s i g n a l s t h a tt h i si s a n E S Cs e q u e n c e ;t h e [

s a y s ," h e r ec o m e sa s p e c i a lc o m m a n d " ;t h e6 i s r e a da s t h en u m b e r

o f t i m e st o p e r f o r mt h e f o l l o w i n go p e r a t i o n ;t h eE i s t h ec o m m a n d

f o rl i n e f e e d ,s o w e d o s i xl i n e f e e d s ;a n d ,a s I t h i n kF r e u ds a i d ,t h e

B A N A N Ai s j u s ta B A N A N A .

I f y o u ' v ec o p e dw i t ht h a to n e ,I ' l lt e l ly o ut h a tF ( c a p i t a l sa g a i n )i s t h e

c o m m a n df o rN E G A T I V El i n e f e e d .S o y o um i g h tt r y :

E C H O" * e [ 5 F H E L L O "

Y o u ' l ls e e s o m e t h i n gy o um i g h th a v ec o n s i d e r e di m p o s s i b l e ; t h e

c u r s o rg o i n gU Po n t h eC L Is c r e e n !I f y o ud o m u c ho f t h i s ,y o u ' l lf i n d

y o u r s e l ft y p i n go v e ro l ds c r e e nt e x t ,w h i c hi s n o tf u n .. . y o us t i l l

d o n ' th a v et r u es c r e e ne d i t i n g a sy o u m a y k n o wf r o me a r l i e r

C o m m o d o r em a c h i n e s .

I w o n ' tg o t h r o u g ha l l t h e c u r i o u sc o m m a n d st h a tc a nb e i n v o k e dw i t hC S I .C h e c k T h eA m i g a D O SM a n u a l ( B a n t a mB o o k s ) ;w i t h i ni t ,

l o o ka t t h ea p p e n d i xi n T h eD e v e l o p e r ' sM a n u a l .Y o u ' l lf i n dl o t so f

c o m m a n d st o p l a yw i t ha n dm a k et h eC L I s c r e e nd o s t r a n g et h i n g s .

T h e r e ' so n ei n p a r t i c u l a rI ' d l i k e t os h o wy o u :c o m m a n dm ( l o w e r

c a s e ) ,S e tG r a p h i cR e n d i t i o n .

G r a p h i cR e n d i t i o n

t h e p r i n t i n g c o l o u r ( 3 0i s i n v i s i b l e ,s o i s o f l e s s u s e ) .T r yt h e s e :

E C H O" * e [ 3 2 mD A R K H O R S E* e [ 3 1 m "

E C H O■ * e [ 3 3 mR E D R O V E R S* e [ 3 1 m "

Y o uc a nc h a n g ec o l o u r s s e v e r a lt i m e so n a l i n e ,i f y o uw i s h .

N o wf o r t h e " 4 0 "c o d e s .T h e yc h a n g eb a c k g r o u n dc o l o u ra s y o u

p r i n t :

E C H O" * e [ 4 1 mI N V I S I B L E * e [ 4 0 m "

E C H O" * e [ 4 2 mB L A C K B A K* e [ 4 0 m '

E C H O" * e [ 4 3 mR E D B A C K S* e [ 4 0 n V

Y o uw o n ' ts e et h e o u t p u tf r o mt h ef i r s tl i n ev e r yw e l l ,s i n c ei t w i l lb e

p r i n t e dw h i t eo n w h i t e .N o t et h a tt h e b a c k g r o u n dc o l o u ro n l yi s

c h a n g e dh e r e .

T h e r ea r ea f e wi n t e r e s t i n gn u m b e r si n t h e0 t o 7 r a n g e .T r y :

E C H O" * e [ 1 mB o l d f a c e !* e [ 0 m "

E C H O" * e [ 3 mI t a l i c s !* e [ 0 m "

E C H O" * e [ 4 mU n d e r l i n e* e [ 0 m "E C H O" * e [ 7 m R e v e r s e d ! * e [ 0 m "

N o t et h a tc o d e0 b r i n g s t h ef o n tb a c kt o n o r m a l .

A f i n a ln o t e :y o uc a n u s e s e v e r a lo f t h e s e c o d e s ,s e p a r a t e db y

s e m i c o l o n s .S o a s a l a s tg r a n dc o m b i n a t i o n ,t r y :

E C H O" * e [ 3 2 ; 4 3 m R e a d * e [ 3 ; 4 m T h eT r a n s a c t o r

* e [ 0 ; 3 2 ; 4 3 mr e g u l a r l y ! * e [ O m "

Y o um a yh a v es p o t t e dt h a tt h es e q u e n c e* e [ 0 mr e s t o r e se v e r y t h i n g

t o n o r m a l .W h e nw e u s e di t i n t h e m i d d l eo f t h e l a s tl o n gl i n e i n

o r d e rt o c a n c e l t h ei t a l i c sa n du n d e r l i n ef e a t u r e s ,w eh a dt o r e i n s t a t e

t h ec o l o u r sw ew e r eu s i n g .

P r i n t e rF o o t n o t e

T h es a m eC S Ic o d e st h a tw o r kw i t ht h es c r e e nw i l lo f t e nw o r kw i t h

t h ep r i n t e r .I o f t e nu s eE C H Ow i t hr e d i r e c t i o ni n o r d e rt o j o ta n o t e

o n t h ep r i n t e r .T h u s :

E C H O> P R T :" A u g u s t1 5 / 8 7L i s t i n g "

T h i sw i l l s p i to u t t h e c o r r e c tm e s s a g et o t h ep r i n t e r .

B u ti t ' si n t e r e s t i n gt o s e et h a tm a n yo f t h ep r i n t e rc o d e sa r es i m i l a rt o

t h o s ew eh a v e u s e dt o t h e s c r e e n .T h ew h o l el i s to f p r i n t e rc o n t r o l

c o d e sm a yb e f o u n di n t h em a s s i v eA m i g aR O MK e r n a lM a n u a l ;i t

h a sa l s ob e e np a r t i a l l yr e p r i n t e di n n u m e r o u sp l a c e s .A s i m p l e

e x a m p l ew i l ld o h e r e :i f y o u rp r i n t e rh a sa n i t a l i c sf o n t ,t y p e :

E C H O P R T :" * e [ 3 mI t a l i c s !* e [ 0 m "

T h e c o m m a n d ," C S I . .n u m e r i c .. m " c h a n g e st h ew a yt h i n g sa r e T h e s a m ec o d et h a td i dt h ej o bt o t h es c r e e nw i l ld o i t t o t h ep r i n t e r ,

s h o w no n t h e C L Is c r e e n .T h ec h a n g ei s m o d e r a t e l yp e r m a n e n t

w i t h i nt h eo p e nC L I , s oI t r y t oc h a n g et h i n g sb a c ka t t h ee n do f

e a c hl i n e .S o .. . y o u ' l ls e et w o s e q u e n c e so f * e [w i t h i n t h e q u o t e s ,

o n et o p r o d u c et h ee f f e c ta n d o n et o g e tu s b a c k .

I l i k et h e" 3 0 "c o d e st h eb e s t .T h e yr u n f r o m 3 0t o 3 3 ,a n dc h a n g e

C o n c l u s i o n

Y o uc a nc e r t a i n l yp e p u py o u rS t a r t u p - S e q u e n c ef i l ew i t ha b i to f

c o l o u ra n do t h e rs p e c i a le f f e c t s .A n dy o um i g h te v e n h a v ea b e t t e r

i d e ao f s o m eo f t h eA m i g a ' sm a r v e l l o u si n n e rs p a c ee f f e c t s .

T h eT r a n s a c t o r 7 1 N o v e m b e rT 9 8 7 :V o l u m e8 , I s s u eO 3

Page 74: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 74/84

A d d i n gA n a l o gR G BC a p a b i l i t y

t o t h e1 9 0 2M o n i t o r

L a r r yP h i l l i

V a n c o u v e rB C

. . .a n a l o gR G Bm o d ew a sp r e s e n to n l yo n v e r ye a r l y1 9 0 2m o n i t o r s .. .

W h e nI f i r s tp u r c h a s e dm yA m i g a ,I t h o u g h tt h a tI w o u l db e a b l et o

u s e a 1 9 0 2f o r t h e m o n i t o r ,a s i t h a sa s w i t c hp o s i t i o nf o r R G B

a n a l o g .T h i sf e e l i n gw a sr e i n f o r c e db y t h ef a c tt h a tt h eA m i g a ' s 1 0 8 0

m o n i t o r l o o k e di d e n t i c a lt o t h e1 9 0 2i n t e r m so f t h ec a s e ,c o n t r o l s ,

a n ds w i t c h e s .A l a s ,i t w a sn o t t o b e , f o r i n C o m m o d o r e ' si n f i n i t e

w i s d o m , a n dp r o b a b l ya t t h ei n s i s t e n c eo f t h em a r k e t i n gt y p e s , t h e

a n a l o gR G Bm o d ew a sp r e s e n to n l yo n v e r ye a r l y1 9 0 2m o n i t o r s .

L a t e r v e r s i o n sh a ds o m ec o m p o n e n t sm i s s i n gt h a tc r i p p l e dt h e

a n a l o gR G Bc i r c u i t r y .T h i sa r t i c l ed e s c r i b e sh o wt o a d dt h ec o m p o

n e n t sn e c e s s a r y .T h i sm o d i f i c a t i o nw i l lw o r ko n t h e1 9 0 2o n l y ,a n d

N O T o n t h e l 9 0 2 A .

N o t e :I f y o u d on o tf e e lc o m f o r t a b l ew o r k i n gi n s i d ey o u rm o n i t o r ,

t h i s m o d i f i c a t i o ni s n o t f o r y o u !I f t h i s i s t h e c a s e ,e i t h e rf i n d

s o m e o n ew h oh a st h ee x p e r i e n c ea n d k n o w l e d g en e c e s s a r yo r t a k e

t h i s a r t i c l ea n dy o u r 1 9 0 2t o a q u a l i f i e ds e r v i c e t e c h n i c i a n .R e a dt h i s

d i s c l a i m e ru n t i ly o ur e a l i z e t h a tI w i l ln o tb e h e l dr e s p o n s i b l ef o ra n y

d a m a g ey o um a yd o t o y o u r s e l f o ry o u rm o n i t o r .

I f y o uf i n dt h ec o m p o n e n t sa l r e a d yi n p l a c e ,y e tt h em o n i t o rw i l ln o t

a l l o w a n a l o gR G B ,i t i s p o s s i b l et h a ts o m et r a c e sh a v eb e e nc u to n

t h e b o a r dn e a rt h e R G Bs w i t c h .I f s o , y o ua r e o n y o u ro w n ,b u t

s i m p l yr e c o n n e c t i n gt h e ms h o u l db e s u f f i c i e n t t og e ti t w o r k i n g .

N o wt o t h e m o d i f i c a t i o ni t s e l f .F i g u r e1 i s t h ec o m p l e t ep a r t sl i s t ,a n da l lc o m p o n e n t sa r eb o t hc o m m o n l ya v a i l a b l ea n dl o wc o s t .F i g u r e2

s h o w st h el a y o u to f t h eb o a r da n dt h ea p p r o x i m a t el o c a t i o no f t h e

p a r t st o a d d .A l lp a r t st o b e a d d e da r e c l e a r l ym a r k e dw i t hs i l k

s c r e e no n t h e1 9 0 2m a i nb o a r d .S t e pb y s t e p ,h e r ew eg o :

1 . R e m o v et h eb a c kc o v e r

- 6 s c r e w s

2 . R e m o v es h i e l do n b o t t o mo f m a i nb o a r d

- u n s o l d e ra n dt w i s tt a b s

3 . R e m o v em e t a lm o u n t i n gp l a t e sh o l d i n gi n p u t j a c k sa n ds m a l l

b o a r d s .

- 3 s c r e w st h r o u g hm a i nb o a r d

- 1 s c r e wh o l d i n gt h et w op l a t e st o g e t h e r

- 1 s c r e wh o l d i n gR C Aj a c kb l o c k

- 2 p o s t sh o l d i n gR G Bc o n n e c t o r

4 . R e m o v em e t a ls h i e l df r o mc o m p o n e n ts i d eo f b o a r d .

- t w i s t t a b s

5 . L o c a t ea n ds u c kt h es o l d e rf r o mt h eh o l e sf o rt h ec o m p o n e n t st o

b e a d d e d .

- R 7 2 6 7 / 8 / 9i n a r e a1 , n e a rI C 7 2 0 1

- R 7 2 7 0 / 1 / 2i n a r e a3

- D 7 2 1 8 / 1 9 / 2 0i n a r e a 3

- C 7 2 0 2 / 3 / 4i n a r e a3- C 7 2 1 9 / 2 0i n a r e a2

- J M 1 2 3 / 4 / 5i n a r e a3

6 . S o l d e ri n c o m p o n e n t s ,p a y i n gp a r t i c u l a r a t t e n t i o nt o t h ep o l a r i t

o f t h ee l e c t r o l y t i cc a p a c i t o r sa n dd i o d e s .C a p a c i t o r sa r em a r k e

o n t h e b o a r d ' ss i l ks c r e e n i n g w i t ha ' d o t 'n e a rt h e n e g a t i v el e a d .

D i o d e sa r es h o w nw i t h ap i c t u r ej u s t l i k et h es c h e m a t i cr e p r e -

s e n t a t i o n .

N O T E :t h eb o a r di s s i n g l e s i d e d ,a n dt h eb o n d i n gi s n o tt h e b e s to n

t h et r a c e s ,s o u s ec a u t i o na n dl o wh e a ts o y o uw o n ' td a m a g et h e

t r a c e s .

7 . R e p l a c et h et o ps h i e l da n dm e t a lm o u n t i n gp l a t e s .

8 . T e s ty o u rw o r ka t t h i st i m eb y p l a c i n g t h es w i t c hi n t h e t h i r d

p o s i t i o n( t ot h er i g h ta s s e e n f r o mt h e r e a ro f t h e m o n i t o r , f

t h e s w i t c h )a n dh o o k i n gt h eA m i g at o t h e m o n i t o rt h r o u g ha

s t a n d a r dA m i g aR G Bc a b l e .

9 . I f a l l i s w e l l ,r e p l a c e t h eb o t t o ms h i e l da n dr e s o l d e rt h et a b s

1 0 .S o m e1 9 0 2m o n i t o r sh a da s m a l l e rh o l et h r o u g hw h i c ht h eR G B

s w i t c hp r o t r u d e d , a l l o w i n gi t t o b e u s e di n o n l y2 p o s i t i o

( p o s i t i v ea n dn e g a t i v e R G B I ) .I f t h i si s t h ec a s e , c u tt h es l o ti n t h e

c a s et o a l l o wt h e s w i t c ht o b e p l a c e di n t h en e w l ya c q u i r e dR G B

a n a l o gp o s i t i o n .

1 1 .R e p l a c et h ec o v e r .E n j o y !

F i g u r e1 : P a r t sL i s t

R e s i s t o r s. C a p a c i t o r s

R 7 2 6 7

R 7 2 6 8

R 7 2 6 9

R 7 2 7 0

R 7 2 7 1

R 7 2 7 2

1 5 0o h m s

1 5 0o h m s

1 5 0o h m s

8 2 0o h m s

8 2 0o h m s

8 2 0o h m s

C 7 2 0 23 3 0 u f - 1 0 V

C 7 2 0 33 3 0 u f - 1 0 V

C 7 2 0 43 3 0 u f - 1 0 V

C 7 2 1 9 . O l u f

C 7 2 2 04 7 u f - 1 0 V

D i o d e s

D 7 2 1 81 N 4 1 4

D 7 2 1 91 N 4 1 4

D 7 2 2 01 N 4 1 4

J u m p e r s

J M 1 2 3w i r e

J M 1 2 4 w i r e

J M 1 2 5 w i r e

F i g u r e2 : A sv i e w e df r o mb o t t o mo f b o a r d

I C 7 2 0 3

R G BS w i t c h

1 1 1 1 1 1 1 1 1 1 1

3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3

3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3

3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3

3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3 3

2 2 2

2 2 2

I C 7 2 0 1

I C 7 2 0 2

T h eT r a n s a c t o r 7 2 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 75: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 75/84

A m i g aD i s p a t c h e sb y T i m G r a n t h a m ,T o r o n t o ,O n t a r i o

A sI w r i t et h i s ,t h e s t o c kp r i c eo fC B Mh a s d r o p p e dy e ta g a i nt o a b o u t 8 . 5 0

o n t h eN Y S E ,w h e r ei t h a ss t e a d i e d .A q u a r t e r l y r e p o r ti s d u eo u ti n t h e

m i d d l eo fA u g u s ta n dI w o u l dn o tb e a t a l ls u r p r i s e di f i t c o n t a i n sn e w so f

a l o s s ,n e w st h a th a sa l r e a d y l e a k e dt o W a l lS t r e e t .

W ew i l la l l k n o wb y t h et i m ey o ur e a dt h i s ,o f c o u r s e ,b u td o n ' tb e t o o

d i s h e a r t e n e di f i t d o e s .C B Md o e sn o ts e e mt o b e l a y i n go f fa n ym o r es t a f f .

I n f a c t ,t h e ys e e mt o b e h i r i n go n a s m a l lb a s i s . I na d d i t i o n , p a r to f t h e

l o s sm a yb e a t t r i b u t a b l et o i n i t i a lm a n u f a c t u r i n gc o s t so f t h e5 0 0a n dt h e

2 0 0 0 . R e p o r t si n d i c a t et h a tt h e5 0 0h a sg o t t e no f ft o a g o o ds t a r ti n s a l e s

a n dt h a ts h o u l db e r e f l e c t e di n t h e n e x t q u a r t e r l yr e p o r t .

I h a v er e c e n t l yj o i n e dt w om o r ei n f o r m a t i o n s e r v i c e si n m yo b s e s s i v e

q u e s tf o rA m i g ai n f o r m a t i o n :G E n i ea n dB I X .T h el a t t e ri s p r e t t ye x p e n

s i v e— a c c e s s e df r o mC a n a d at h r o u g hT y m n e t ,i t i s $ 1 5( U S )p e rh o u ra t

1 2 0 0b p s .T h a tf i g u r ei s f o rn o n - p r i m eh o u r sa n dt h e r ei s a n a d d i t i o n a l

$ 2 5( U S )s i g n - u pc h a r g e .

I f o u n di t p a r t i c u l a r l yi r r i t a t i n gt h a tn o w h e r ea r e p o t e n t i a lC a n a d i a n

c u s t o m e r so f B I Xt o l dt h a tt h eT y m n e ta c c e s sc h a r g ei s $ 6 ( U S ) r a t h e r

t h a nt h e $ 2 ( U S ) s p e l l e d o u ti n t h ea d si n B Y T Ea n di n t h es i g n - o n

m e s s a g e .M o s tC a n a d i a n sd o n ' tf i n do u ta b o u tt h e e x t r ac h a r g eu n t i lt h e y

g e tt h e i rb i l l s ,I i m a g i n e .T h eo n l yr e a s o n/ f o u n do u tw a sb e c a u s em y

n a s t ys u s p i c i o u sn a t u r em a d em ea s kt h e s e r v i c e r e pw h oh a dc a l l e dt o

c o n f i r mm ys i g n - o n .H e h a dt o g o t o s o m el e n g t h st o f i n do u th i m s e l f .

G r r r r r .

B I Xi s a g r e a tp l a c ef o ri n - d e p t hA m i g at e c h n i c a l i n f o r m a t i o n ,t h o u g h .I

w a sa b l et o g e th e l po n C h a r l i e H e a t h ' s g e t f i l e r e q u e s t e rf o rm yk e e p

p r o g r a m( c o m i n gR S N )d i r e c t l yf r o mc h e a t hh i m s e l f .T o m a n yp r o f e s

s i o n a lp r o g r a m m e r s ,t h ec o s t o ft h e s e r v i c ei s w e l lw o r t ht h e i n f o r m a t i o n

g a i n e d .

G E n i e ,o n t h e o t h e rh a n d ,i s c l e a r l yi n t e n d e dt o b e a c o n s u m e rn e t w o r k .

S of a r ,t h e yh a v eb e e na m o d e lo f e f f i c i e n c ya n ds e r v i c e :c o s t s a r ec l e a r l y

s t a t e d , i nC a n a d i a nd o l l a r sf o rC a n a d i a nc u s t o m e r s ,a n dd o c u m e n t a t i o n

a r r i v e dp r o m p t l y .T h e r ei s a v i g o r o u sA m i g ac l u b ,* S t a r s h i pA m i g a * ,

o p e r a t e db y D e bC h r i s t e n s e n . d e b ! d e f e c t e df r o mt h eD e l p h i n e t w o r k ,

w h e r es h eh a da r r i v e da f t e rC o m p u S e r v eh a db o o t e dC B Mf r o mo p e r a

t i o no f i t sC o m m o d o r ef o r u m s .I h a v en o th a da n o p p o r t u n i t yt o s p e n d

m u c ht i m ew a n d e r i n gt h ed e c k so f * S t a r s h i pA m i g a * ,b u tf o rl e s st h a n

$ 1 0( C a n . )p e rh o u r( p l u st h e$ 2 5( C a n . )s i g n u pf e e ) ,i t a p p e a r st o w e l l

w o r t hi n v e s t i g a t i n g .

T h i sb r i n g sm yn e t w o r km e m b e r s h i p st o f i v e .H o w e v e r ,i t h a sb e e ns o

l o n g s i n c eI l a s ta c c e s s e d D e l p h it h a t1 h a v em i s p l a c e dm yp a s s w o r d .I f

y o ut h i n kt h a ti s i n d i c a t i v e o fm yo p i n i o no f t h e v a l u eo f D e l p h i ,1 s h a n ' t

c o r r e c ty o u .

P DT i p s

A s u s u a l ,t h e a r e n a( o rs h o u l dI s a y ' f r e e - f o r - a l l ' ? )o f p u b l i cd o m a i n

s o f t w a r eh a ss e e nt h ea r r i v a l o fs o m ep o w e r f u ln e wc o n t e n d e r s .A C O

2 . 0 0b y S t e v eP i e t r o w i c z ,c u r r e n t l ya v a i l a b l ee x c l u s i v e l yo n P e o p l e L i n k

i s a n A m i g av e r s i o no f a c o n c e p to r i g i n a l l yi n t r o d u c e do n a M a c i n t o s h

p r o g r a me n t i t l e dV M C O .F a i t h f u lr e a d e r so f t h i sc o l u m nm a yr e m e m b e r

m yd e s c r i p t i o no f V M C Oi n t h el a t el a m e n t e dT P U GM a g a z i n e .

T h ep r o g r a mi s i n t e n d e df o rl i v et e l e c o m m u n i c a t i n g .T h ed i s p l a yc o n s i s t s

o f a s e r i e so f e m p t yc h a i r sa r o u n da c o n f e r e n c et a b l e .A se a c ha t t e n d e e

a r r i v e s ,t h ee m p t yc h a i ri s r e p l a c e dw i t ha p i c t u r e o ft h en e wa r r i v a l .

W h e nt h a tp e r s o nm a k e sa c o m m e n t ,t h e yc a n s w i t c ht h e p i c t u r e

d i s p l a y e dt o r e f l e c tt h ec o n t e n to f t h ec o m m e n t .O n em i g h th a v ea h a p p y

f a c e ,a ' f l a m e 'o r a n g r yf a c e ,a ' b a c k - i n - a - m i n u t e 'f a c e ,a n ds o o n .O f

c o u r s e ,t h i sd i s p l a yo n l ya p p e a r so n t h em a c h i n e so f t h o s ea t t e n d e e sw h o

a r er u n n i n gt h es o f t w a r e ,a n dh a v et h ef a c e so f e a c ha t t e n d e e s t o r e di n

t h ep r o g r a m ' sf a c el i b r a r i e s .

T h eA m i g av e r s i o n ,A C O ,a d d sc o l o u rt o t h e p r o c e e d i n g s , s ot o s p e a k .

D P a i n tc a nb e u s e dt o c r e a t ey o u ro w nf a c e s ,o r t h e yc a nb e d e s i g n e d

w i t ht h eA C O f a c e sp r o g r a ma v a i l a b l e a s p a r to f t h eA C O . a r cf i l e .T h e

w h o l et h i n gi s b u i l to n D a nJ a m e s 'e x c e l l e n tc o m mt e r m i n a lp r o g r a m .

J o u r n a li s a n i n t r i g u i n gp r o g r a m .I t r e c o r d sa l l I n p u t E v e n t s g e n e

b y t h ei n p u t . d e v i c e ,i n c l u d i n gt i m i n g s ,a n ds t o r e st h e mi n t oa f i l e .T h e s e

e v e n t sc o n s i s to f k e yp r e s s e sa n d m o u s ea c t i o n s .T h e n ,u s i n gt h e

a c c o m p a n y i n gP l a y b a c kp r o g r a m ,t h es e q u e n c eo f I n p u t E v e n t sc a nb e

r e p l a y e dt h r o u g ht h ei n p u t . d e v i c e , f o o l i n gt h eA m i g ai n t ot h i n k i n gt h e y

a r er e a l l yo r i g i n a t i n gf r o mt h eo p e r a t o r .T h er e s u l ti s a n e x a c tp l a y b a c ko f

t h eu s e r ' si n t e r a c t i o nw i t ht h ec o m p u t e r . T a l ka b o u tt h e g h o s ti n t h e

m a c h i n e !

J o u r n a l s u g g e s t sa n u m b e ro f i n t e r e s t i n g a p p l i c a t i o n s :a s a w a yt o c r e a t e

s c r i p tf i l e sf o rt e r m i n a lp r o g r a m s ;f o rs o f t w a r et u t o r i a l s ;a n df o rp r o d u c t

d e m o n s t r a t i o n s .U s e r so f D P a i n tI I , f o re x a m p l e ,c o u l ds e ej u s th o wJ i m

S a c h sc r e a t e da l lt h o s ew o n d e r f u lg r a p h i c s .

T w on e wl a n g u a g e sh a v ea r r i v e do n t h e s c e n e :D r a c oa n dI c o n .

D r a c oi s d e s c r i b e db y i t si n v e n t o r ,C h r i sG r a yo f E d m o n t o n ,A l b e r t a , a sa

l a n g u a g ec o m b i n i n ga l l t h e b e s tf e a t u r e so f C a n dP a s c a l .O r i g i n a l l y

d e v e l o p e df o rC P / M - 8 0s y s t e m s ,J e f f r i e sh a sa d d e da D r a c oc o m p i l e rf o r

t h eA m i g a .

I c o ni s a d e s c e n d a n to f S N O B O L ,a n i n t e r e s t i n gl a n g u a g ew i t ha h o s to f

p o w e r f u l s t r i n g - h a n d l i n gf e a t u r e s .I c o na l s oo f f e r sl i s tp r o c e s s i n ga n ds e t

m a n i p u l a t i o nc o m m a n d s ,b u ti s b e t t e r i n t e g r a t e da n dm o r ec o n s i s t e n t

t h a nS n o b o l .S c o t tB a l l a n t y n e h a s p o r t e dv e r s i o n 6o f I c o nt o t h eA m i g a

a l r e a d y ,a n di s n o wp o r t i n g6 . 3 ,w h i c hs h o u l db e r e a d yt h i sf a l l .

T h eT r a n s a c t o r 7 3 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 76: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 76/84

S e v e r a li s s u e sa g o ,1 h i n t e db r o a d l yt h a tC B Ms h o u l dm a k et h e i n c l u d e

f i l e sa v a i l a b l et o t h eg e n e r a lp u b l i ca t a n o m i n a lc h a r g e ,s o t h a tp e o p l e

l i k eJ i mB u t t e r f i e l dc o u l d l e a v eA m i g a B A S I Cb e h i n da n ds t a r td i g g i n g

t h r o u g ht h eO Si n a s s e m b l yl a n g u a g ea n dC w i t h o u tp a y i n ga n a r ma n da

l e gf o ra c o m p i l e r . I ' mp l e a s e dt o a n n o u n c et h a tC B Mi s d o i n ge x a c t l y

t h a t : f o r$ 2 0( U S )y o ug e t t w od i s k sc o n t a i n i n gt h eC a n da s s e m b l y

l a n g u a g ei n c l u d ef i l e sa n dt h e1 . 2A u t o d o c st o t e l ly o uw h a ti t ' sa l la b o u t .

I f y o uw a n tt o o r d e rt h e m ,s e n da r e q u e s ta n da c h e q u et o L a u r i eB r o w n

a t C B M ' sW e s tC h e s t e rH Q .

A n o t eo f w a r n i n g :c u r r e n t l y ,t h eo n l yP Da s s e m b l e rI k n o wo f t h a ti s

c o m p l e t e l y c o m p a t i b l ew i t h t h e. i i n c l u d ef i l e s , i sA 6 8 kb yC h a r l i e G i b b s .

O t h e r sr e q u i r et h a tt h ei n c l u d ef i l e sb e r e f o r m a t t e df i r s t .

T A BB o o k sh a sp u b l i s h e dA m i g aA s s e m b l yL a n g u a g eP r o g r a m m i n g ,

( # 2 7 1 1 - H ,$ 1 9 . 9 5 ) .I d o n ' tk n o wi f i t ' sa n yg o o d ,b u ti t i s t h ef i r s to f i t s

k i n d .

H a r da n ds o f tn e w s

Y o um a yr e m e m b e rm y c o m p l a i n t sl a s t i s s u ea b o u tA m i g aT a x ,a

C a n a d i a n i n c o m et a x c a l c u l a t i o np r o g r a m .D a v i dS o p u c h ,o n eo f t h e

p r o g r a m m e r s ,t e l l sm e t h a tr e g i s t e r e do w n e r sw i l lb e n o t i f i e do f t h e

a v a i l a b i l i t yo f a n u p g r a d et h a tf i x e sb u g sa n da d d s e n h a n c e m e n t s .B e t a

t e s t e r sa n dR e v e n u e C a n a d aw i l l i n g ,i t s h o u l db e r e a d yb y D e c e m b e r ,a t a

c o s to f $ 2 9 . 9 5 .

T o r o n t o ' sE r i cH a b e r f e i i n e rh a sc o m p l e t e dt h el a t e s tv e r s i o no f h i sf i n e

s h a r e w a r eV T 1 0 0 / 1 0 2t e r m i n a le m u l a t o rH a n d s h a k e . H eh a sa d d e d

Y m o d e ma n db a t c hY m o d e mf i l et r a n s f e r s ,a n df i x e ds o m em i n o rb u g s .

I n a s u r v e yo f a v a i l a b l eV T 1 0 0e m u l a t o r sr e c e n t l yc a r r i e do u to n U s e n e t ,

H a b e r f e l l n e r ' sp r o g r a mc a m eo u to n t o p .A l lh e r e q u e s t si s $ 2 5 ,f o l k s .

C o m s p e ci s d e l i v e r i n gt h e i rv e r s i o no f a r e c o v e r a b l eR A Md i s k( R R D )t o

o w n e r so f t h eA X 2 0 0 0m e m o r yb o a r d s .T h ef i r s t9 0 0o r s oA X 2 0 0 0u n i t s

r e q u i r ea m i n o r h a r d w a r ef i xt o u s et h eR R D .T h i si s p r o v i d e da s p a r to f

t h e u p g r a d ep a c k a g e ,i n a d d i t i o nt o t h e s o f t w a r e .C o m s p e c ' sR R Di s

s l i g h t l yd i f f e r e n tf r o mo t h e r si n t h a tt h eA m i g al i t e r a l l ys e e si t a s a n o t h e r

d i s k d r i v e- i t c a n b ef o r m a t t e d , d i s k d o c t o r e d , d i s k s a l v e da n dd i s k c o p i e d .

M o s ti m p o r t a n t l y ,o f c o u r s e ,i t c a ns u r v i v ea w a r mr e b o o t( c t r l - a m i g a -

a m i g a ) .

B y t h e t i m ey o ur e a dt h i s ,C o m s p e cw i l lh a v ea l s oa n n o u n c e dt h e

a v a i l a b i l i t y o ft h e i rS C S I h a r dd r i v e s .D o m e n i cD e F r a n c e s c o ,d e s i g n e ro f

t h eb o t ht h eR A Mb o a r da n dt h eS C S Ii n t e r f a c e , t o l dm e t h a tt h eS C S I

i n t e r f a c ew i l la u t o c o n f i g u r e ,h a s a b u s p a s s - t h r o u g ha n dd o e sn o t

i n t e r f e r ew i t hm u l t i t a s k i n gi n a n yw a y .I t w i l lp r o v i d et r a n s f e rr a t e so f

n e a r l y2 9 0K b p e rs e c o n df o r r e a d sa n d2 5 0K b f o rw r i t e s ,o n c et h e

A m i g a D O Sh a r dd r i v es u p p o r ta r r i v e sf r o mC B M .T h ed r i v e c h a s s i sh a s

r o o mf o ro n ef u l lh e i g h td r i v e ,o r 2 h a l f - h e i g h td r i v e s .I n a d d i t i o n ,t w o

p o r t sa r ep r o v i d e dt o c h a i ns e v e r a lo t h e rS C S Id e v i c e s ,i n c l u d i n gM a c i n

t o s hh a r dd r i v e s .F i r s to f f e r i n g s c o n s i s to f a 2 0 M ba n da 4 0 M bd r i v e .T h e

S C S Ii n t e r f a c ei t s e l fw i l ll i k e l yb e a v a i l a b l es e p a r a t e l yi n t h en e a rf u t u r e .

A S D GI n c .m a k e sa n u m b e ro f p r o d u c t st h a th a v eb e e nv e r yw e l l

r e c e i v e d ,i n c l u d i n gF a c e ,a f l o p p y d i s k a c c e s s a c c e l e r a t o rp r o g r a m ,a n da

2 M bZ o r r oR A Mb o a r dt h a ti s u p g r a d a b l et o 8 M b .N o wt h e ya r ew o r k i n g

o n t w oo t h e r p r o d u c t s : t h e2 0 0 0 - a n d - la n dS D P( S a t e l l i t eD i s k

P r o c e s s o r ) .T h ef o r m e r ,t o c o s ta b o u t$ 8 0 0( U S ) ,i s a b o xf o rt h e1 0 0 0t h a t

w i l la c c e p t p l u g - i nc a r d si n t e n d e df o r b o t ht h e 1 0 0 0a n d t h e 2 0 0 0 ,

i n c l u d i n gt h eB r i d g ec a r d .T h eS D P ,a s I u n d e r s t a n di t ,w i l lr e o r g a n i z et h e

t r a c k so n a d i s kt o p r o v i d ef a s t e ra c c e s s .A l lA S D Gh a r d w a r ec o m e sw i t h

a n u n u s u a l l yl o n g1 8 - m o n t hw a r r a n t y ;a l l s o f t w a r ei s p r o v i d e d w i t h

l i f e t i m e f r e eu p g r a d e s ,a n di s n o tc o p yp r o t e c t e d .B r a v o !

M i c h i g a nS o f t w a r e , t h em a k e r so f t h eI n s i d e rR A Mb o a r d , a r en o ws e l l i n

K w i k s t a r t .T h i sk i tp r o v i d e sK i c k s t a r t1 . 2i n R O Mf o rt h e1 0 0 0 ,a s i t i s

n o wf o rt h e5 0 0 a n d2 0 0 0 .I t d o e s n ' t l o c ky o uo u to f f u t u r ev e r s i o n so f

K i c k s t a r t ,h o w e v e r .B y s i m p l y h o l d i n gt h e w a r mr e b o o t k e y sa l i t t l e

l o n g e r ,t h eK w i k s t a r tR O M sw i l lb e s w i t c h e do u t ,a n d y o uc a nb o o tw i t h a

d i f f e r e n t K i c k s t a r t .T h ep r o d u c tw o r k sw i t ht h eI n s i d e rb o a r da n dc o s t s

$ 1 6 9 . 9 5( U S ) .U s i n gt h eK w i k s t a r tR O M sa l s of r e e s2 5 6 Ko f t h eR A M

p r e v i o u s l yu s e d b yt h e d i s k - l o a d e dK i c k s t a r t- a w e l lt h o u g h to u t

p r o d u c t .

V i d e o S c a p e3 Di s n o wa v a i l a b l ea n dt h es o u r c eo fs o m es p e c t a c u l a 3 D

a n i m a t i o nd e m o s .L o o kf o rt h e mo n t h en e ws e r i e s o fC B Mt e l e v i s i o na d s

t o s t a r tr u n n i n gi n S e p t e m b e r . . .D i g i v i e w2 . 0a n dD i g i p a i n t2 . 0h a v e

a l s o a r r i v e d .T h ef o r m e rp r o v i d e ss o m ef i r s t - r a t ei m a g ep r o c e s s i

s o f t w a r ea n d t h e l a t t e ri s a H A M - m o d ep a i n tp r o g r a mt h a tp e r m i t

d r a w i n gw i t ha l l 4 0 9 6c o l o u r s . . .T h em a k e r so f A c q u i s i t i o n

D a t a m a t ,t w o p o w e r f u lr e l a t i o n a ld a t a b a s em a n a g e m e n tp r o g r a m

h a v e r e s p o n d e dt o v o c i f e r o u sc o m p l a i n t so f d i f f i c u l t yo f u s e w i t hi m

p r o v e du s e ri n t e r f a c e sa n dd o c u m e n t a t i o n . . .M i m e t i c s ,p u b l i s h e r so f t h e

S o u n d S c a p es y s t e m ,h a v ee x p a n d e dt h e i rd e v e l o p e r s u p p o r tt o i n c l u d

f u l ld o c u m e n t a t i o no f a l lt h es o u n d s c a p e . l i b r a r yf u n c t i o n sa n dA z t e c

C s u p p o r t . . .

O n l i n e2 . 0 0i s a s i g n i f i c a n tu p g r a d et o t h eo r i g i n a lw i t hV T 1 0 0a n d

T e k t r o n i c s t e r m i n a le m u l a t i o n s a d d e d ;K e r m i t ,Y m o d e ma n dZ m o d e

p r o t o c o l s s u p p o r t e d ;a u t o c h o p ;A N S Ic o l o u r ;a n dt h ea b i l i t yt o k e e p u

w i t ht e x to u t p u t .I t n o l o n g e rh o g st h ep r i n t e rd e v i c e ,e i t h e r .H o w e v e ra

s m a l lb u gh a ss u r f a c e d :i f y o ud i s a b l et h ea u t o c h o pf e a t u r e ,X m o d e

t r a n s f e r sw i l ln o l o n g e rw o r k .P u b l i s h e rM i c r oS y s t e m sS o f t w a r ei s

p r o v i d i n ga f r e ef i x .

D i g a !( w i s hI k n e ww h a tt h en a m em e a n t ) ,f r o mA e g i sD e v e l o p m

a p p e a r st o b e f o l l o w i n gi n t h ef o o t s t e p so f S o u n d s c a p e .T h e c o m p a i s

p o s t i n gd o c u m e n t a t i o no n t h e t e r m i n a le m u l a t i o n sa n dt h ep r o p r i e t

D o u b l e T a l kp r o t o c o lo n t h en e t w o r k st o e n c o u r a g eo u t s i d e d e v e l

T h en e wv e r s i o no f t h ep r o g r a mb e i n gd e v e l o p e d b yA e g i sw i l li n c l u d

t h eW X m o d e mp r o t o c o lu s e db y P e o p l e L i n k ,a n da c h a tw i n d o wf o rl i v e

c o n f e r e n c i n g .

B y n o wy o um a yk n o wt h a tt h e5 0 0p r o v i d e sN T S Co u t p u ti n m o n o

c h r o m eo n l y .T h o s ew h on e e da c o l o u r o u t p u tf o r t h e i rV C Rh a v et h r e e

p o s s i b l es o l u t i o n s .M i m e t i c sw i l lb e s e l l i n gg e n l o c k sf o ra l l t h r e eA m i g a

t h a t , i na d d i t i o nt o s y n c h r o n i z i n gt h eA m i g ao u t p u tt o a n o t h e r v i

s o u r c e ,p r o v i d e a c o l o u rN T S Cs i g n a lf r o mt h eR G B Ao u t p u t .C B Mw i l lb e

s e l l i n ga n a n e n c o d e rt h a td o e st h es a m et h i n gf o ra b o u t$ 5 0( U S ) .O ry o u

c a nm a k ey o u ro w ne n c o d e r ,u s i n gt h es a m eM o t o r o l a1 3 7 7 Pc h i pt h a t

t h e1 0 0 0u s e s ,f o ra b o u t$ 2 5i n p a r t s .Y o uc a nw r i t et o M o t o r o l af o r f r e

d o c u m e n t a t i o nt h a ti n c l u d e sa s c h e m a t i c .

T h eC o m m o d o r e6 4 e m u l a t o rI h a v e m e n t i o n e di n t h ep a s ts h o u l db e o u t

b y t h et i m ey o ur e a dt h i s .I t w i l lc o s ta b o u t$ 1 5 0( U S ) ,a n dc o n s i s t so f b o t h

s o f t w a r ea n da h a r d w a r ei n t e r f a c e t h a tp l u g si n t ot h ep a r a l l e lp o r ta n d

p e r m i t sc o n n e c t i o no f t h e1 5 4 1d i s kd r i v e .T h em a k e r sc l a i me m u l a t i o i s

c o m p l e t e , w i t ht h ee x c e p t i o no f t h eS I Dc h i p ,a n dt h e yn o wh a v eG E O S

r u n n i n go n t h eA m i g a .T h ee m u l a t o rt a k e so v e rt h ec o m p u t e r , h o w

N om u l t i t a s k i n gp o s s i b l e .

M i c r o f i c h eF i l e rp r o v i d e s au n i q u e l yA m i g a w a yo fv i e w i n ga d a t a b a s

a s t h en a m ei m p l i e s ,a l l t h e r e c o r d sa r e p r e s e n to n t h e s c r e e ni n a

m i n i a t u r i z e d f o r m a t .O n ec a n s c a nt h e mw i t ha ' m a g n i f y i n gg l a s s 'a n d

z o o mi n o n p a r t i c u l a r r e c o r d s .B e c a u s ei t h a n d l e sg r a p h i c d a t aa s w e l la s

t e x ta n dn u m b e r s ,t h i si s a n i d e a lm e a n st o s t o r ea n dd i s p l a yr e a l - e s t a

p r o p e r t i e s ,p e r s o n n e lr e c o r d sa n ds o o n .A p o s s i b l el i m i t a t i o ni s t h a tt h e

e n t i r ed a t a b a s em u s t b ei n m e m o r ya t o n c e .

T h eT r a n s a c t o r 7 4 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u e0 3

Page 77: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 77/84

a r r i nM a s s e n a ' sM e n u E dp r o g r a mn o ww o r k su n d e r1 . 2 .N o w ,i f o n l y

o m e o n ew o u l df i n i s ht h eE g a dg a d g e te d i t o r . . .T e x t c r a f tP l u sh a s

e e nr e l e a s e di n E u r o p e .N ow o r da b o u tw h e ni t w i l lc r o s st h es e a .. .

o f t C i r c u i t sI n c .h a sa n n o u n c e dt h a ta s c h e m a t i cc a p t u r ep r o g r a mc a l l e d

c h e m ei s i n b e t at e s ta n dw i l ls o o n b ea v a i l a b l ef o r$ 4 9 9 . 9 5( U S ) .I t i s

o m p a t i b l e w i t ht h e i rs u c c e s s f u lP C L Op r i n t e dc i r c u i tb o a r dl a y o u t

o f t w a r es e r i e s ,w h i c hn o wi n c l u d e sP C L O j r ,a s c a l e d - d o w nv e r s i o nf o r

o m eu s es e l l i n ga t $ 6 9 . 9 5( U S ) . . .T h eG e r m a nv e r s i o no f t h e2 0 0 0 ,

v a i l a b l ei n C a n a d a a n dE u r o p e , h a sw a i ts t a t e si n t h eR A Mp l u g g e di n t o

h es o - c a l l e dC P Ub u ss l o tt h a ts l o wt h em a c h i n et o a b o u t8 5 - 9 0% o f t h e

p e e do fa 1 0 0 0 .T h e5 0 0 a n dt h eW e s tC h e s t e r2 0 0 0( w h e ni t a r r i v e s )w i l l

o th a v et h i sp r o b l e m .

o a n n eP a r kh e r ei n T o r o n t or e m o v e da r e s i s t o rf r o mt h ee n c o d e rc i r c u i t

n h e r1 0 0 0a s d e s c r i b e di n A m a z i n gC o m p u t i n g ,V o l .2 , N o .7 , t e s t e di t

i t ha v e c t o r s c o p ea n df o u n dt h a tt h e c o l o u rb a l a n c ew a sb a n go n .

o w e v e r ,h e rA m i g aw a sa p r e - J u n e' 8 6m a c h i n e :t h eA m a z i n ga r t i c l e

a i dt h er e m o v e dr e s i s t o r i nt h e s em a c h i n e ss h o u l db e r e p l a c e dw i t ha

7 0 KO h mr e s i s t o r .I s u p p o s et h e l e s s o nh e r ei s t h a tt h o s ew h on e e dt o

a k et h ec h a n g es h o u l dg e ts o m e o n ew i t ha v e c t o r s c o p et o c h e c ki t . . .

D Iw i l lg e ts o m en e e d e dc o m p e t i t i o nw h e nO x x i ,o f M a x i p l a n r e k n o w n ,

o m e so u tw i t ht h e i rM o d u l a2 c o m p i l e r ,c a l l e dB e n c h m a r k .R e p o r t sr o mb e t at e s t e r si n d i c a t e t h a ti t i s v e r yf a s t . . .C i t yD e s k ,a d e s k t o p

u b l i s h i n gp r o g r a mw r i t t e nf o rM i c r o S e a r c hI n c .b y S u n R i z eI n d u s t r i e s

w h oa l s om a k et h eP e r f e c t S o u n ds t e r e od i g i t i z e r ) ,i s n o wa v a i l a b l e .F o r

o r ei n f o ,c o n t a c tT o mH a y d e na t ( 7 1 3 )9 8 8 - 2 8 1 8 , 9 - 6C S T . . .T w o

t t r a c t i v ed i s k - b a s e dm a g a z i n e s h a v e a p p e a r e df o rt h eA m i g a ,T h eN e w

l l a d i na n dA M n e w s . T h el a t t e ri s o f p a r t i c u l a ri n t e r e s t t oC a n a d i a n s

i n c ei t i s p u b l i s h e di n M o n t r e a l .T h ef u l la d d r e s si s V e r t e xA s s o c i a t e s ,

1 5T r e n t o nA v e . ,M o n t r e a l ,P Q ,H 3 P2 A 1 .P h o n e :( 5 1 4 )7 3 9 - 3 3 0 1 .

a s a n y o n eb e s i d e sm e n o t i c e d t h eb u gi n t h eo p ti v e r s i o no f t h ed i r

o m m a n dt h a ta p p e a r sw h e ni t i s u s e dw i t ht h er a m :d i s k ?I f y o ud e l e t ea

i l e ,t h ef i l ed i s a p p e a r sb u t t h em e m o r yd o e sn o tg e td e a l l o c a t e d .Y o uc a n

a v ea n e m p t yr a m :d i s kt h a tt a k e su p 2 0 0 Ko f p r e c i o u sm e m o r y !

' m g l a dt o s e et h a ta n i n c r e a s i n gn u m b e ro f t h i r d - p a r t yA m i g ad e v e l

p e r sh a v ee s t a b l i s h e da n e t w o r kp r e s e n c e .A e g i sD e v e l o p m e n t a n d

i c r o l l l u s i o n sh a v et h e i ro w nc o n f e r e n c e s( f o r u m s )o n B I X ;M i c r o S y s

e m sS o f t w a r ef i e l d sq u e s t i o n so nC I S ;A S D G ,C L t d . ,a n dG o l dD i s km a k e

e g u l a ra p p e a r a n c e so n m a j o rn e t w o r k s .M o s tA m i g ad e v e l o p e r sh a v e

r o v e nt o b e a c c e s s i b l ea n dr e s p o n s i v et o t h e i rc u s t o m e r sa n d1 h o p et h e y

o n t i n u et o d o s o .

h eA m i g a , n e t w o r k c o m p u t i n ga n dt h ew h o l ed a m nt h i n g

n m yn i n e - t o - f i v ec a p a c i t ya s a s s i s t a n t e d i t o ro f D e s i g nE n g i n e e r i n g

a g a z i n e ,I h a v eb e e na b l et o g a i n af a i r l yb r o a dp e r s p e c t i v eo n t h eu s eo f

o m p u t e r s ,f r o mm i c r o st o s u p e r c o m p u t e r s .

n eo f t h em o s te x c i t i n gd e v e l o p m e n t si s i n t h ea r e ao f ' d i s t r i b u t e d

o m p u t i n g ' . T h i sr e q u i r e s m u l t i p l ec o m p u t e r sc o m m u n i c a t i n go v e ra

e t w o r k .T h ei d e ai s t o d i s t r i b u t et h e e x e c u t i o no f a s i n g l e l a r g e

r o g r a mo v e ra l lt h em a c h i n e si n t h en e t w o r k ,a s s i g n i n gp r o c e d u r e st o

h em o s ta p p r o p r i a t ec o m p u t e r .I m a g ep r o c e s s i n gf u n c t i o n s ,f o re x a m

l e ,c o u l db e e x e c u t e db y a d e d i c a t e da r r a yp r o c e s s o ro n t h en e t w o r k ,

h i l et h eu s e ri n t e r f a c ef o rt h ep r o g r a mc o u l db e h a n d l e db ya p e r s o n a l

o m p u t e r .T h ee n t i r ep r o c e s sw o u l db e t r a n s p a r e n tt o t h eu s e r ,s i t t i n g a t

i so r h e rc o n s o l e .M o r ei m p o r t a n t l y ,i t w o u l d b ei n d e p e n d e n to f t h e

e t w o r k ,c o m p u t e r so r o p e r a t i n gs y s t e m s b e i n gu s e d -a t a l lo r d e r ,b u t

n et h a te m b o d i e st h ed r e a mo f i n t e g r a t i n ga l lc o m p u t e rr e s o u r c e si n t o

n e h u g e c o m p u t i n gs y s t e m .

X e r o xd e v e l o p e dt h ef i r s td i s t r i b u t e dc o m p u t i n gs y s t e m ,i m p l e m e n t i n

R P C s( r e m o t ep r o c e d u r ec a l l s )u n d e ri t sX N S( X e r o xN e t w o r kS y s t e m ) .

S u nM i c r o s y s t e m sm a d eR P C sm o r eb r o a d l ya v a i l a b l eb y i m p l e m e n t i n

t h e mu n d e rT C P / I P ,a n i n d u s t r ys t a n d a r dn e t w o r k i n gp r o t o c o l ,a n d

N F S( N e t w o r kF i l eS y s t e m ) ,i t so w nn e t w o r kd a t a - s h a r i n gp r o t o c o lt h a t

h a sb e c o m ea d e f a c t oi n d u s t r ys t a n d a r d .N o wA p o l l oh a st h r o w ni t s

h a ti n t ot h et o k e nr i n gb yp l a c i n g t h es p e c i f i c a t i o n sf o ri t sN C S( N e t w o r k

C o m p u t i n gS y s t e m )i n t ot h ep u b l i cd o m a i n .

A p o l l o ' ss c h e m ei s t h e

m o s tf l e x i b l e ,p o w e r f u l

s y s t e my e t ,f o ra

n u m b e ro f r e a s o n s .O n e ,i n a d d i t i o nt o b e i n gm a c h i n e a n do p e r a t i n gs y s t e m

i n d e p e n d e n t ,i t ' sn e t w o r ki n d e p e n d e n t .I t c o u l dq u i t el i t e r a l l yb e i m p l e

m e n t e do v e ra t e l e p h o n el i n ew i t h am o d e ma t e a c he n d ,t h o u g ht h e

t r a n s m i s s i o no v e r h e a dw o u l ds l o wd o w np r o g r a me x e c u t i o n p r o b a b

b e y o n dt h ep o i n to f p r a c t i c a l i t y .T w o ,i t s u p p o r t s c o n c u r r e n tp r o g r a m

m i n g .T h e s a m ep r o c e d u r ec o u l db e i n s t a l l e da n dc a l l e do n m u l t i p l e

m a c h i n e ss i m u l t a n e o u s l y ,w i t ha l l r e s u l t sf u n n e l l e dt o t h e c a l l i n g

p r o g r a m .

( I r e c e n t l ys a wa d e m o n s t r a t i o no f o v e r3 0 A p o l l o w o r k s t a t i o n sc o n c u r

r e n t l yc a l c u l a t i n ga M a n d e l b r o tp i c t u r e .W h a tw o u l dn o r m a l l yh a v e

t a k e nw e l lo v e rt w oh o u r so n o n ew o r k s t a t i o n t o o ks e v e n m i n u t e so n

t h en e t w o r k .B e a ri n m i n dt h a ta l l t h ew o r k s t a t i o n sw e r es i m u l t a n eo u s l yb e i n g u s e db y t h e i ro p e r a t o r sf o ro t h e rt a s k s- s o m ew e r en o t

e v e na w a r et h a tt h e i rm a c h i n e s w e r ea l s ow o r k i n go n t h eM a n d e l b r o t

p i c t u r e . )

T h i r d l y ,i t p r o v i d e sf o r d y n a m i cl o a d b a l a n c i n ga c r o s st h e n e t w o r k .

W h a tt h i sm e a n si s t h a ti f o n ec o m p u t e rh a sm o r eC P Ut i m ef r e et h a n

a n o t h e r , t h es y s t e mw i l lh a v et h e R P Ce x e c u t e db y t h a tm a c h i n e .

B e s i d e s p r o v i d i n gm o r ee f f i c i e n tu s eo f t h ec o m p u t i n g h a r d w a r ea v a i l a

b l e ,t h i sm a k e sl i f ee a s i e rf o rt h ep r o g r a m m e rw r i t i n gt h ed i s t r i b u t e d

a p p l i c a t i o n .H eo r s h e d o e sn o th a v et o k n o ww h i c hm a c h i n e ( s ) c a r

t h ec o d ef o rt h eR P C .

U n f o r t u n a t e l yf o rA p o l l o , t h e i n d u s t r ym o m e n t u mi s b e h i n dS u n ' sN F Ss y s t e m .A d o p t i n gA p o l l o ' s s u p e r i o rs y s t e mw o u l dm e a na g o o dd e a lo f

r e t r e n c h i n g . N e v e r t h e l e s s ,p e o p l ea r e i m p r e s s e dw i t ht h e s y s t e m ' s

f e a t u r e s .A p o l l oh a se s t a b l i s h e d t h eN e t w o r k C o m p u t i n gF o r u mt o

d i s c u s sd i s t r i b u t e dc o m p u t i n ga n do v e rt h i r t yc o m p a n i e sh a v ej o i n e d ,

i n c l u d i n gS u n , A p p l e ,T e x a sI n s t r u m e n t sa n dM o t o r o l a .M y s o u r c e s

i n d i c a t e t h a tm e m b e r sw a n tt o s e et h ef e a t u r e so f N C Sd e v e l o p e du n d e r

N F S .

W h e r ed o e st h eA m i g af i t i n t ot h i s ?N o wt h a tA m e r i s t a r T e c h n o l

h a s d e v e l o p e dE t h e r n e tb o a r d sf o rt h eA m i g aa n dN F Sc l i e n ts o f t w a r e ,

t h eA m i g ac a nf i t i n t oa d i s t r i b u t e dc o m p u t i n ge n v i r o n m e n t .I t w o u l d

p r o v i d em u c ho f t h e s a m ef u n c t i o n a l i t ya s t h ew o r k s t a t i o n s- t h e

g r a p h i ci n t e r f a c e ,t h e m u l t i t a s k i n g- b u t a t a l o wc o s t .W i t ht h e

c o n c u r r e n tc o m p u t i n gc a p a b i l i t yp r o v i d e db y N C S ,a n e t w o r kc o n s i s t

i n ge n t i r e l yo f A m i g a sc o u l d s i m u l t a n e o u s l ye x e c u t ea s i n g l ep r o g r a m .

T h em o r eI l e a r na b o u tt h e i n d u s t r ya s a w h o l e ,t h em o r eI s e et h e

A m i g af i l l i n ga l a r g en i c h eb e t w e e nt h ew o r k s t a t i o na n dt h e m i c r o .I B M

a n d A p p l e h a v e e a c h d e v e l o p e d s u c hp r o d u c t sb u ta t s e v e r a lt i m e st h e

p r i c eo f t h eA m i g aw i t h o u ts e v e r a lt i m e st h ec a p a b i l i t y .

I ' ma l w a y si n t e r e s t e di n a n yc o m m e n t so r q u e s t i o n sy o um a yh a v e .

T h e yc a n b es e n tt o m e c / oT h eT r a n s a c t o r , o rv i ae l e c t r o n i cm a i l

a d d r e s s e dt o 7 1 4 2 5 , 1 6 4 6o n C o m p u S e r v e ;A M T A Go n P e o p l e L i n k

d i s p a t c h e ro n B I X ;t . g r a n t h a mo n G E n i e ;o r t o T i m G r a n t h a mo n

W a y n eB e y e a ' sf i n eB l o o mB e a c o nB B Sa t ( 4 1 6 )2 9 7 - 5 6 0 7 .

T h eT r a n s a c t o r 7 5 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 78: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 78/84

N e w sB R KS u b m i t t i n gN E W SB R KP r e s s R e l e a s e s

I f y o uh a v ea p r e s sr e l e a s ey o uw o u l dl i k e t os u b m i tf o rt h eN E W SB R Kc o l u m n ,

m a k es u r et h a tt h ec o m p u t e ro r d e v i c ef o rw h i c ht h ep r o d u c ti s i n t e n d e di s

p r o m i n e n t l yn o t e d .W er e c e i v eh u n d r e d so f p r e s sr e l e a s e sf o re a c hi s s u e ,a n d

o n e sw h o s ei n t e n d e dr e a d e r s h i pi s n o tc l e a rm u s tu n f o r t u n a t e l yg os t r a i g h tt o t h e

t r a s hb i n .I t s h o u l da l s ob e m e n t i o n e dh e r et h a tw eo n l yp r i n tp r o d u c tr e l e a s e s

w h i c ha r ei n s o m ew a ya p p l i c a b l et o C o m m o d o r ee q u i p m e n t .N e w so f e v e n t s

s u c ha s c o m p u t e r s h o w ss h o u l db e r e c e i v e da t l e a s t6 m o n t h si n a d v a n c e .

T r a n s a c t o rN e w s

N o - F a u l tP r o g r a mE n t r y I n s u r a n c e

W e g e t s e v e r a ll e t t e r si n t h e w a k eo f e a c hi s s u er e p o r t i n gp r o b l e m sw i t h

p r o g r a m st y p e di n f r o ml i s t i n g si n t h em a g a z i n e .W eu n d e r s t a n dt h ef r u s t r a t i o n

r e a d e r sf e e lw h e nt h e yh a v et y p e di n s e v e r a lp a g e so f D A T As t a t e m e n t so r

a s s e m b l e rs o u r c e o n l yt o f i n dt h a tt h er e s u l t i n gp r o g r a mr u n se i t h e r i n c o r r e c t l y

o r n o ta t a l l ,w h e t h e ri t w a st h e i re r r o r o ro u r st h a ti s t o b l a m e .

W e ' r e h o p i n gt h a to u rn e wN o - F a u l tP r o g r a mI n s u r a n c e s y s t e mw i l lp r o v i d ea

w a yo u t .H e r e ' sh o wi t w o r k s :l e t ' ss u p p o s ey o u ' v ej u s te n t e r e da l o n gp r o g r a m

f r o mt h el a t e s ti s s u ea n ds a v e di t t o d i s k .N o wy o ur u ni t b u ty o u rm a c h i n e

c r a s h e s ,s o y o uu n l o a da f e wa p p r o p r i a t ee x p l e t i v e sa n dl o a di t b a c ki n t o

r e c h e c kt h eV e r i f i z e rc o d e s .A f e w h o u r sl a t e r ,y o u re y e b a l l s a r es p i n n i n gi n

c o u n t e r - r o t a t i n gc i r c l e sa n dy o us t i l lh a v e n ' tf o u n dt h e b u g , s oy o us a v et h e

p r o g r a mt o a n e wd i s k , l a b e li t c l e a r l yw i t hy o u rn a m e ,a d d r e s sa n d p h o n e

n u m b e r ,p l u st h ev o l u m ea n di s s u en u m b e ry o u w e r ew o r k i n gf r o m ,a n dd r o pi t

i n t h e m a i lt o u s w i t ha b r i e fd e s c r i p t i o no f t h ep r o b l e m .

W h e nw eg e ty o u rd i s k , w e ' l lr e t u r ni t w i t ht h eo f f i c i a lv e r s i o no f t h ep r o g r a m

a l o n g s i d ey o u ro w na s s o o na s p o s s i b l e . Y o u ' l lb e o u tt h e p r i c eo ft h e p o s t a g e ,b u t

y o u ' l lh a v ea w o r k i n gp r o g r a m .W e ' l lb e o u tt h ep o s t a g et o o ,b u tw e ' l lh a v ea

h a n d - e n t e r e dc o p yo f t h ep r o g r a mw i t hw h i c hw e c a nf i n do u tw h e t h e rt h e

l i s t i n gi n t h em a g a z i n ec o n t a i n sa n e r r o r .T h a tw i l lm a k ei t a l o te a s i e rf o ru s t o

t r a c kd o w nt h eo c c a s i o n a lb u g a m o n g s tt h em a n yp r o g r a m sw ep u b l i s h ,s o t h a t

w ec a np r i n tc o r r e c t i o n sa s s o o na s p o s s i b l ea f t e rt h eo r i g i n a lv e r s i o n a p p e a r s .

B yt h ew a y ,i f y o u ' dl i k et o c h e c kw i t h u sb y p h o n ef o rb u gr e p o r t sb e f o r ey o u

m a i li n t h ed i s k , t h a t ' sf i n e ,a n dj u s tm i g h ts a v ey o ut h e e x t r at r o u b l eo f g e t t i n g

t h ep a c k a g er e a d y .

S e n dT P U GS u b s c r i p t i o n st o T P U G !

I f y o uw i s ht o r e c e i v e t h e T r a n s a c t o r c o n t a i n i n g t h ei n s e r tf o rT P U Gm e m b e r s

( T o r o n t oP e tU s e r sG r o u p ) ,y o u m u s tb e a T P U Gm e m b e r .T ob e c o m ea T P U G

m e m b e r ,w r i t et h e ma t 5 3 0 0Y o n g eS t r e e t ,T o r o n t o , O n t a r i o ,M 2 M5 R 2 .

Y o uc a nd oy o u r s e l f ,T P U G ,a n du s a f a v o u rb y w r i t i n gt o t h e md i r e c t l y .U s i n g

o u rs u b s c r i p t i o nc a r d st o s t a r to r r e n e wT P U Gm e m b e r s h i p sm a ys a v ey o ua f e w

c e n t si n p o s t a g e , b u tc a nl e a dt o b u r e a u c r a t i cs l i p - u p sr e s u l t i n gi n s h i p m e n to f

t h ew r o n gm a g a z i n e ,o r a t b e s ta d e l a yi n y o u rs u b s c r i p t i o n . A l s o ,p l e a s e

r e m e m b e rt o m a k ec h e q u e sp a y a b l et o " T P U GI n c . "f o rT P U Gm e m b e r s h i p s .

T r a n s a c t o rR e n e w a l s

M a n ys u b s c r i p t i o nr e n e w a l sa r r i v ew i t ha r e q u e s tt h a tt h e yb e" b a c k - d a t e d "t oa

p r e v i o u si s s u e .T h em a i nr e a s o nw e c a n ' to b l i g ei s t h e p o s t a g ed i f f e r e n c e

b e t w e e nc o p i e st h a tg oo u ta s p a r to f t h eb u l k s u b s c r i b e rm a i l i n ga n da s i n g l e

c o p ya t r e g u l a rr a t e s( y o um a yh a v en o t i c e d t h a to u rp r i c ef o rb a c ki s s u e s

i n c l u d e st h e c o s to f p o s t a g e ) .S u b s c r i p t i o n sc a no n l yb e s t a r t e dw i t h t h e n e x t

i s s u ed u eo u t .E a r l i e rm a g a z i n e sm u s tb eo r d e r e da s b a c ki s s u e s .

S u b s c r i p t i o n o r d e r sm u s tb e r e c e i v e da t l e a s tt h r e ew e e k sb e f o r e t h er e l e a s eo fa n i s s u et oe n s u r et h a tt h es u b s c r i p t i o nw i l ls t a r tw i t ht h a ti s s u e .S o ,i fy o uo r d e r

a s u b s c r i p t i o na n dd o n ' tg e tt h e n e x ti s s u e t h a tc o m e so u t ,i t m a yb e t h a tw e

r e c e i v e di t t o ol a t e t og e ty o u rn a m et o t h ep r i n t e r ;y o u rf i r s ti s s u es h o u l d b et h e

f o l l o w i n g o n e .

U s et h eN e wS u b s c r i p t i o nC a r d s !

W h e no r d e r i n g s u b s c r i p t i o n so r T r a n s a c t o r p r o d u c t s , p l e a s eu s ea s u b s c r i p

c a r df r o mt h em o s tr e c e n ti s s u e .T h ec a r d sa r ec o n s t a n t l yb e i n gu p d a t e d ,a n d

p r o d u c ta n dp r i c ei n f o r m a t i o nf r o mo l d e rc a r d si s n o l o n g e rv a l i d .S u bc a r d st h a t

s h o wo u ro l da d d r e s sw i l lt a k e l o n g e rt o r e a c hu s , a n dm a n yo f t h e p r o d u

l i s t e da r en o l o n g e ra v a i l a b l e .T h em o s tn o t a b l ed i f f e r e n c eb e t w e e nt h eo l da n d

n e ws u bc a r d si s t h eC a n a d i a np r i c ef o ra y e a r ' s s u b s c r i p t i o n :i t i s n o w$ 1 9 . 0

a n dt h e$ 1 5 . 0 0p r i c el i s t e do n t h eo l d e rc a r d sw i l ln o l o n g e rb e h o n o u r e d

N e wT r a n s a c t o rS p e c i a lO f f e r s

B e g i n n i n gw i t ht h i s i s s u e ,w ea r es t a r t i n ga p o l i c yo f s p e c i a lo f f e r se v e r yi s s u e

T h es u b s c r i p t i o n c a r da n n o u n c e st h eo f f e r ,w h i c hi s v a l i df o ri t e m so r d e r e d f

t h a ts u b s c r i p t i o nc a r do n l y ,a n do n l yf o rt h es p e c i f i e d t i m e .

T h es p e c i a lo f f e r t h i si s s u ei s f o rT r a n s a c t o rd i s k s :b u ya n yt h r e e ,a n dg e tt w o

f r e e !T h i sd o e sn o t a p p l yt o d i s ks u b s c r i p t i o n s ,o n l yt o t h r e e d i s k so r d e r e da t o n et i m e .S i m p l y u s et h eo r d e rc a r d( i n s e r tf r o mt h i si s s u eo n l y ) ,m a r ko f fa n y5 d i s k s

b u ts e n dp a y m e n tf o ro n l y 3( o rc h e c ko f f1 0 a n dp a yf o r6 ) .T h i so f f e ra p p l i

o n l yt o o r d e r sp o s t m a r k e db e f o r eN o v e m b e r1 , 1 9 8 7 , s ow e r e c o m m e n y o u

t a k ea d v a n t a g eo f i t n o w !

N e wC o m b o - S u b s c r i p t i o nP r e m i u m s

U pt o n o w ,w h e ny o uo r d e r e da c o m b i n e dm a g a z i n e / d i s ks u b s c r i p t i o n ,w es e n t

y o ua f r e eT r a n s a c t o rT - S h i r tt o s w e e t e nt h e d e a l .S o r r y ,b u t w e h a v et o

w i t h d r a wt h a to f f e r ,e f f e c t i v ei m m e d i a t e l y .I n s t e a d ,y o un o wg e ty o u rc h o i c eo f

t h e T - S h i r t ,t h e P o t p o u r r iD i s k , o r t h eT r a n s B a s i c2 D i s ka n d M a n u

w h i c h e v e rs u i t sy o ub e s t !J u s tc h e c kt h ea p p r o p r i a t eb o xa t t h et o po f t h eO r d e

F o r mw h e ny o uf i l li n y o u r c o m b o - s u b s c r i p t i o na p p l i c a t i o n .

U . S .O r d e r sI n v o i c e dI n C a n a d i a nD o l l a r s

I f y o uo r d e r e da s u b s c r i p t i o nf r o mt h eU . S .a n dr e c e i v e da n i n v o i c ef o r$ 1 9 . 5

d o n ' tb e a l a r m e d :t h a t ' s1 9 . 5 0C a n a d i a nd o l l a r s ,w h i c h w o r k so u tt o j u s tu n d e

$ 1 5 . 0 0U Sa t c u r r e n te x c h a n g er a t e s .

A d v e r t i s e r sW a n t e d

I f a n y o n ei s i n t e r e s t e di n p l a c i n gf u l l - p a g e ,h a l f - p a g eo r q u a r t e r - p a g ec o l o u ro r

b l a c ka n dw h i t ea d si n t h eT r a n s a c t o r ,p l e a s ec o n t a c tu s f o rr a t e sa n di n f o r m

t i o n .Y u p ,y o uh e a r dr i g h t .W e ' l lt a k ea d sn o w ,b u ts p a c ei s l i m i t e d .O u rc e i l i n

c u r r e n t l yi s t h ec o v e rs p o t sp l u s 5p a g e so f t h ei n t e r i o r .

G r o u pS u b s c r i p t i o nR a t e s :T h e2 0 / 2 0D e a l

T h eT r a n s a c t o rh a s a l w a y sb e e np o p u l a ra m o n g C o m m o d o r eu s e r g r o u p s s o t o

e n c o u r a g en e ws u b s c r i b e r sw ea r eo f f e r i n gq u a n t i t yd i s c o u n t sf o rm a g a z i n ea n d

d i s ks u b s c r i p t i o n s :2 0p e r c e n to f ff o rg r o u po r d e r so f2 0o rm o r es u b s c r i p t i oI f

y o uc a ng e tt o g e t h e re n o u g hf r i e n d s o rc l u bm e m b e r s ,j u s tp u ta l lt h es u b s c r

t i o n si n a s i n g l ee n v e l o p e ,a n dy o ug e tt h e d i s c o u n t .Y o ud o n ' tn e e dt o b e a u s e r

g r o u pt o q u a l i f y- a n y 2 0o r m o r es u b s c r i p t i o n c a r d si n a s i n g l ep a c k a g eg e tt h e

2 0 / 2 0d e a l ,n o q u e s t i o n sa s k e d .

M a i l - O r d e rP r o d u c t sN oL o n g e rO f f e r e d

W eh a v er e m o v e ds e v e r a lp r o d u c t sf r o m o u rm a i l - o r d e rc a r d :T h eG n o m eS p e e

C o m p i l e ra n dG n o m eK i tU t i l i t y ,t h e " p o c k e t "s e r i e so f s o f t w a r e ,P R I S M

S u p e r K i t1 5 4 1 , t h eB H 1 0 0h a r d w a r ec o u r s em a t e r i a l ,t h eA n c h o rV o l k s m o d

a n dt h eC o m s p e c2 m e g a b y t eR A Me x p a n s i o nu n i t s .W es t i l lh a v es o m es t o c ko f

t h es o f t w a r ea n dc a no r d e rm o r eo ft h e o t h e r p r o d u c t si f n e c e s s a r y ,s ow es h o u l

b ea b l et o f i l la n yo r d e r sf r o mp r e v i o u ss u b s c r i p t i o nc a r d s .

T h eT r a n s a c t o r 7 6 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 79: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 79/84

T r a n s a c t o rM a i lO r d e r

T h ef o l l o w i n gd e t a i l sa r ef o rp r o d u c t sl i s t e do n t h em a i lo r d e rc a r d .I fy o uh a v ea

p a r t i c u l a rq u e s t i o n a b o u ta n i t e mt h a ti s n ' ta n s w e r e dh e r e ,p l e a s ew r i t e o rc a l l .

W e ' l l g e tb a c kt o y o u a n dm o s tl i k e l yi n c o r p o r a t e t h ea n s w e ri n t of u t u r e e d i t i o n s

f t h e s ed e s c r i p t i o n ss o t h a to t h e r sm i g h tb e n e f i tf r o m y o u re n q u i r y .

■ M o v i n gP i c t u r e s- t h eC - 6 4A n i m a t i o nS y s t e m ,$ 2 9 . 9 5( U S / C )

T h i sp a c k a g ei s a f a s t ,s m o o t h ,f u l l - s c r e e na n i m a t o rf o rt h eC o m m o d o r e6 4 ,

w r i t t e nb yA H A !( A c m eH e u r i s t i cA p p l i c a t i o n s ! ) .W i t hM o v i n gP i c t u r e sy o uu s e

o u rf a v o u r i t eg r a p h i c st o o l t od r a wt h ef r a m e so fy o u rm o v i e , t h e ns h o wi t a t f u l l

n i m a t i o ns p e e dw i t h as i n g l ec o m m a n d .M o v i e' s c r i p t s 'w r i t t e ni n B A S I Cc a n

s et h eM o v i n gP i c t u r e sc o m m a n ds e tt o p r o v i d ec o m p l e t ec o n t r o lo f a n i m a t e d

r e a t i o n s .B A S I Ci s s t i l la v a i l a b l ef o re d i t i n g s c r i p t s o re x e c u t i n gp r o g r a m s e v e n

w h i l ea m o v i ei s b e i n gd i s p l a y e d .A n i m a t i o n s e q u e n c e s c a ne a s i l yb e a d d e dt o

B A S I Cp r o g r a m s .M o v i n gP i c t u r e s f e a t u r e s i n c l u d e :s p l i ts c r e e n o p e r a t i o n- p a r t

r a p h i c s ,p a r tt e x t- e v e nw h i l e am o v i ei s r u n n i n g ;r e p e a t ,s t o pa t a n yf r a m e ,

h a n g ep o s i t i o na n dc o l o u r s ,v a r yd i s p l a ys p e e d ,e t c ;h o l ds e v e r a lm o v i e si n

m e m o r ya n ds w i t c hi n s t a n t l yf r o mo n e m o v i et o a n o t h e r ;i n s t a n t ,o n - l i n eh e l p

v a i l a b l ea t t h et o u c ho fa k e y ;n oc o p yp r o t e c t i o nu s e do n d i s k .

■ T h eP o t p o u r r iD i s k ,$ 1 7 . 9 5 U S , $ 1 9 . 9 5C d n .

h i si s a C - 6 4p r o d u c tf r o mt h es o f t w a r ec o m p a n yc a l l e dA H A ! ,o t h e r w i s e

k n o w na s N i c kS u l l i v a na n dC h r i sZ a m a r a .T h eP o t p o u r r i d i s ki s a w i d e

s s o r t m e n to f 1 8 p r o g r a m sr a n g i n gf r o mg a m e st o e d u c a t i o n a lp r o g r a m st o

t i l i t i e s .A l lp r o g r a m s c a nb e a c c e s s e df r o ma m a i nm e n uo r l o a d e ds e p a r a t e l y .

N oc o p yp r o t e c t i o ni s u s e do n t h ed i s k ,s o y o u c a nc o p yt h ep r o g r a m s y o u w a n t

o y o u ro t h e r d i s k sf o re a s ya c c e s s .B u i l t - i nh e l pi s a v a i l a b l ef r o ma n y p r o g r a ma t

n yt i m e w i t ht h et o u c ho f a k e y ,s oy o un e v e rn e e dt o p i c ku p a m a n u a lo r e x i ta

r o g r a mt o l e a r nh o wt o u s ei t . M a n yo f t h ep r o g r a m so n t h e d i s ka r eo f a h i g h

n o u g hq u a l i t y t h a tt h e y c o u l db e r e l e a s e do n t h e i ro w n ,b u ty o ug e ta l l1 8o n t h e

o t p o u r r id i s kf o rj u s t$ 1 7 . 9 5U S/ $ 1 9 . 9 5C a n a d i a n . S e et h eA di n t h i si s s u ef o r

m o r ei n f o r m a t i o n .

■ T r a n s B A S I CI I $ 1 7 . 9 5U S ,$ 1 9 . 9 5 C d n .

A nu p d a t e dT r a n s B A S I Cd i s ki s n o wa v a i l a b l e ,c o n t a i n i n ga l lT Bm o d u l e se v e r

r i n t e d .T h ef i r s tT r a n s B A S I Cd i s kw a sr e l e a s e dj u s ta sw ep u b l i s h e dT r a n s B A S I C

o l u m n* 9s o t h em o d u l e sf r o mc o l u m n s1 0 , 1 1a n d1 2 d i dn o te x i s t .T h en e w

m a n u a lc o n t a i n se v e r y t h i n gi n t h eo r i g i n a l ,p l u sa l lt h ed o c sf o rt h ee x t r a s .T h e r e

r eo v e r1 4 0c o m m a n d sa t y o u rd i s p o s a l .Y o up i c kt h eo n e sy o u w a n tt o u s e ,a n dn a n yc o m b i n a t i o n !I t ' ss o s i m p l et h a ta s u m m a r yo f i n s t r u c t i o n sf i t sr i g h to n t h e

i s kl a b e l .T h em a n u a ld e s c r i b e se a c ho f t h ec o m m a n d s ,p l u sh o wt o w r i t ey o u r

w nc o m m a n d s .

e o p l ew h oo r d e r e dT B1 c a n u p g r a d et oT BI I f o rt h ep r i c eo fa r e g u l a rT r a n s a c t o r

D i s k( 8 . 9 5 / 9 . 9 5 ) .I f y o ua r e u p g r a d i n g ,y o ud o n ' tn e c e s s a r i l yn e e dt o s e n du s

o u ro l dT Bd i s k ;i f y o uo r d e r e di t f r o mu s ,w ew i l lh a v ey o u rn a m eo n f i l ea n d

i l ls e n dy o uT BI I f o rt h eu p g r a d ep r i c e .P l e a s ei n d i c a t eo n t h eo r d e rf o r mt h a t

o uh a v et h eo r i g i n a lT Ba n d w a n ti t u p g r a d e d .

o m eT B sw e r es o l da t s h o w s ,e t c ,a n dt h e yw o n ' tb e r e c o r d e di n o u rd a t a b a s e .I f

h a t ' st h ec a s e ,j u s ts e n du s a n y t h i n gy o uf e e li s p r o o fe n o u g h( e . g .p h o t o c o p y

o u rr e c e i p t ,y o u rm a n u a lc o v e r , o re v e nt h ed i s k e t t e ) ,a n dT BI I i s y o u r sf o rt h e

p g r a d ep r i c e .

■ T h eA m i g aD i s k ,$ 1 2 . 9 5U S ,$ 1 4 . 9 5C d n .

i n a l l y ,t h ef i r s tT r a n s a c t o rA m i g ad i s ki s a v a i l a b l e .I t c o n t a i n sa l lo f t h eA m i g a

r o g r a m sp r e s e n t e di n t h e m a g a z i n e ,o f c o u r s e , i n c l u d i n gs o u r c ec o d ea n d

o c u m e n t a t i o n .Y o uw i l l f i n dt h ep o p u l a r" P o p C o l o u r s "p r o g r a m ,t h ep r o g r a m

m e r ' sc o m p a n i o n" S t r u c t u r eB r o w s e r " , t h e G u r u - k i l l i n g" T r a p S n a p p e r " ,u s e r -

r i e n d l y" P o p T o F r o n t " ,a n do t h e r s .I n a d d i t i o n ,w eh a v ei n c l u d e dp u b l i cd o m a i n

r o g r a m s- a g a i n ,w i t hd o c u m e n t a t i o n -t h a tw e t h i n k T r a n s a c t o r r e a d e r sw i l l

i n du s e f u l .A m o n gt h e s ea r e t h e i n d i s p e n s a b l eA R C ;C s h ,a p o w e r f u lC L I -

e p l a c e m e n tD O Ss h e l l ;B L i n k ,a l i n k e rt h a ti s m u c hf a s t e ra n dh a sm o r ef e a t u r e s

h a nt h es t a n d a r dA L i n k ;F o x ya n dL y n x ,a 6 5 0 2c r o s sa s s e m b l e ra n dl i n k e rt h a t

m a k e si t sd e b u to nt h eA m i g aD i s k ;a n da n e x c e l l e n ts h a r e w a r et e x te d i t o r c a l l e d

U E d i t .I n a d d i t i o n ,w e h a v ei n c l u d e do u ro w ne x p r e s s i o n - e v a l u a t o rc a l c u l a t o r

h a tu s e sv a r i a b l e sa n d w o r k si n a n yn u m b e rb a s e .A l lp r o g r a m sc o n t a i n s o u r c e

o d ea n dd o c u m e n t a t i o n ;a l l c a nb e r u n f r o mt h eC L I ,a n ds o m ef r o mW o r k

e n c h .T h e r e ' ss o m e t h i n gf o re v e r y o n eo n t h eT r a n s a c t o rA m i g ad i s k .

■ T r a n s a c t o rT - S h i r t s ,$ 1 3 . 9 5U S ,$ 1 5 . 9 5 C d n .

■ J u m b oT - S h i r t ,$ 1 7 . 9 5U S ,$ 1 9 . 9 5C d n .

A s m e n t i o n e de a r l i e r ,t h e yc o m ei n S m a l l ,M e d i u m ,L a r g e ,E x t r aL a r g e ,a n d

J u m b o .T h eJ u m b om a k e sa g o o dn i g h t - s h i r t / b e a c h - t o p- i t ' sB I G .I ' m6 f o o tt a l l ,

a n d w e i g hi n a t a s l i m1 5 0p o u n d s- t h eS m a l lf i t sm et i g h t ,b u tt h a t ' sh o wI l i k e

t h e m .I fy o ud o n ' t ,w es u g g e s ty o uo r d e rt h e m1 s i z eo v e rw h a t y o uu s u a l l y b u y .

O n eo f t h ef r e eg i f tc h o i c e sw e o f f e rw h e ny o uo r d e ra c o m b i n a t i o n m a g a

A N Dd i s k s u b s c r i p t i o ni s a T r a n s a c t o rT - S h i r ti n t h es i z ea n dc o l o u ro f y o u r

c h o i c e( s o r r y ,J u m b oe x c l u d e d ) .T h es h i r t sc o m ei n r e do r l i g h tb l u ew i t h a3 -

c o l o u rs c r e e no n t h ef r o n tf e a t u r i n go u rm a s c o t ,D u k e ,i n a s n a p p yw h i t e t u xa n d

t o ph a t ,s t a n d i n gb e h i n d o u rl o g oi n 3 Dl e t t e r s .

■ I n n e rS p a c eA n t h o l o g y$ 1 4 . 9 5U S ,$ 1 7 . 9 5 C d n .

T h i si s o u re v e r p o p u l a rC o m p l e t eC o m m o d o r eI n n e rS p a c eA n t h o l o g y .E v e n

a f t e rt w oy e a r s ,w es t i l lg e t i n q u i r i e sa b o u ti t sc o n t e n t s .B r i e f l y ,T h eA n t h o l o g yi s

a r e f e r e n c eb o o k- i t h a sn o " r e a d i n g "m a t e r i a l( i e ." p a r a g r a p h s " ) .I n 1 2 2

c o m p a c tp a g e s ,t h e r e a r em e m o r ym a p sf o r5 C B Mc o m p u t e r s ,3 D i s kD r i v e s ,

a n dm a p so f C O M A L ;s u m m a r i e so f B A S I Cc o m m a n d s ,A s s e m b l e r a n dM L M

c o m m a n d s ,a n dW o r d p r o c e s s o ra n dS p r e a d s h e e tc o m m a n d s .M a c h i n e L a n

g u a g e c o d e sa n dm o d e sa r e s u m m a r i z e d ,a s w e l l a se n t r yp o i n t st o R O M

r o u t i n e s .T h e r ea r e s e c t i o n so n M u s i c , G r a p h i c s ,N e t w o r ka n dB B Sp h o n e

n u m b e r s ,C o m p u t e rC l u b s ,H a r d w a r e ,u n i t - t o - u n i tc o n v e r s i o n s ,p l u sm u c h

m o r e . . .a b o u t2 . 5m i l l i o nc h a r a c t e r st o t a l !

■ T h eT r a n s a c t o rB o o ko f B i t sa n dP i e c e s* 1 ,$ 1 4 . 9 5 U S , $ 1 7 . 9 5 C d n

N o tc o u n t i n gt h eT a b l eo f C o n t e n t s , t h e I n d e x ,a n dt i t l ep a g e s ,i t ' s2 4 6p a g e so f

B i t sa n dP i e c e sf r o mi s s u e so fT h eT r a n s a c t o r ,V o l u m e s4 t h r o u g h6 . E v e ni f y o u

h a v ea l l t h o s ei s s u e s ,i t m a k e sa h a n d yr e f e r e n c e -n o m o r ef l i p p i n gt h r o u g h

m a g a z i n e sf o rt h a to n eb i tt h a ty o uj u s tk n o wi s s o m e w h e r e . . .A l s o ,e a c hi t e mi s

f o r w a r d / r e v e r s er e f e r e n c e d .O c c a s i o n a l l yt h ei t e m si n t h eB i t sc o l u m na p p e a r e d

a s u p d a t e st o p r e v i o u sb i t s .B i t s t h a tw e r es i m i l a ri n n a t u r ea r e a l s o c r o s s -

r e f e r e n c e d .A n dt h ei n d e xm a k e si t e v e ne a s i e rt o f i n dt h o s eq u i c kf a c t st h a t

e l i m i n a t ea l o to fw h e e lr e - i n v e n t i n g .

■ T h eB i t sa n dP i e c e sD i s k ,$ 8 . 9 5 U S , 9 . 9 5C d n .

■ B i t sB o o kA N DD i s k ,$ 1 9 . 9 5U S ,2 4 . 9 5 C d n .

T h i s d i s k c o n t a i n sa l l o f t h ep r o g r a m sf r o mt h e T r a n s a c t o rb o o ko f B i t sa n d

P i e c e s( t h e" b i t sb o o k " ) ,w h i c hi n t u r nc o m ef r o mt h e" B i t sa n dP i e c e s "s e c t i o no f

p a s t i s s u e so f t h em a g a z i n e .T h e" b i t sd i s k "c a ns a v ey o ua l o to f t y p i n g ,a n di nc o n j u n c t i o nw i t ht h eb i t sb o o k a n di t sc o m p r e h e n s i v ei n d e x c a ny i e l da q u i c k

s o l u t i o nt o m a n ya p r o g r a m m i n gp r o b l e m .

■ T h eG - L I N KI n t e r f a c e ,$ 5 9 . 9 5U S , 6 9 . 9 5C d n .

T h eG l i n ki s a C o m m o d o r e6 4 t o I E E Ei n t e r f a c e .I t a l l o w s t h e6 4 t o u s eI E E E

p e r i p h e r a l ss u c ha s t h e4 0 4 0 ,8 0 5 0 ,9 0 9 0 ,9 0 6 0 ,2 0 3 1 ,a n d S F D - 1 0 0 1d i s k

d r i v e s ,o r a n y I E E Ep r i n t e r ,m o d e m ,o r e v e ns o m eH e w l e t t - P a c k a r da n d

T e k t r o n i c se q u i p m e n tl i k eo s c i l l o s c o p e sa n ds p e c t r u ma n a l y z e r s .T h eb e a u t yo f

t h e G l i n ki s i t s " t r a n s p a r e n c y "t o t h e C 6 4o p e r a t i n g s y s t e m .S o m eI E E E

i n t e r f a c e sf o rt h e6 4 a d d B A S I C4 . 0c o m m a n d sa n do t h e rt h i n g st o t h es y s t e m

t h a ts o m e t i m e si n t e r f e r ew i t hu t i l i t i e sy o um i g h tl i k e t o i n s t a l l .T h eG l i n ka d d s

n o t h i n g !I n f a c ti t ' ss o t r a n s p a r e n tt h a ta s w i t c hi s u s e dt o t o g g l eb e t w e e ns e r i a l

a n d I E E Em o d e s ,n o ta l i n k e d - i nc o m m a n dl i k es o m eo f t h eo t h e r s .S w i t c h i n g

f r o mo n eb u st o t h e o t h e ri s a l s o p o s s i b l ew i t h a s m a l l s o f t w a r er o u t i n e a s

d e s c r i b e di n t h ed o c u m e n t a t i o n .

A so f T r a n s a c t o rD i s k* 1 9 ,a m o d i f i e d v e r s i o no fJ i mB u t t e r f i e l d ' s" C O P Y - A L L

w i l lb e o ne v e r yd i s k .I t a l l o w sf i l ec o p y i n g f r o ms e r i a l t oI E E Ed r i v e s ,o r v i c e

v e r s a .

■ T h e T r @ n s @ c t o r1 5 4 1R O MU p g r a d e s ,$ 5 9 . 9 5U S ,$ 6 9 . 9 5C d n .

Y o uc a nb u r ny o u ro w nu s i n gt h eR O Md u m pf i l eo nT r a n s a c t o rD i s k* 1 3 ,o ry o u

c a ng e t as e tf r o mu s .T h e r ea r e 2R O M sp e rs e t ,a n dt h e yf i xn o to n l y t h eS A V E ®

b u g ,b u t an u m b e ro fo t h e rb u g st o o( a sd e s c r i b e di n P . A .S l a y m a k e r ' sa r t i c l e ,V o l

7 , I s s u e0 2 ) .R e m e m b e r ,i f S A V E ®i s a b o u tt o f a i lo ny o u , t h e nS c r a t c ha n dS a v e

m a yj u s tc l o b b e ry o ut o o .T h i sh a s n ' tb e e np r o v e n1 0 0 % ,b u t t h e s eR O M sw i l l

e l i m i n a t ea n yp o s s i b i l i t i e ss h o r to f d e l i b e r a t e l yc a u s i n gt h e m( i e .a l l o c a t i n go r

o p e n i n gd i r e c ta c c e s sb u f f e r sb e f o r e t h eS a v e ) .

N O T E :O u rR O Mu p g r a d ek i td o e sN O Tf i ti n t h e1 5 4 1 Cd r i v e s .W h e r ew es u p p l y

t w oR O M s ,C o m m o d o r e n o wh a si t d o w nt o o n eM A S S I V E1 6 K b y t eR O M .W e

T h eT r a n s a c t o r 7 7 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 80: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 80/84

d o n ' tk n o wi f t h en e wd r i v e ss t i l lc o n t a i nt h eb u g se l i m i n a t e db y o u rk i t ,b u tw e ' l l

f i n do u ta n dr e - c u ta s e c o n dk i ti f n e c e s s a r y .I n t h em e a n t i m e ,1 5 4 1 Co w n e r s

s h o u l dn o to r d e rt h i si t e mu n t i lf u r t h e rn o t i c e .

■ T h eM i c r oS l e u t h :C 6 4 / 1 5 4 1T e s t C a r t r i d g e ,$ 9 9 . 9 5U S ,$ 1 2 9 . 9 5C d n .

W en e v e r e x p e c t e dt h i sc a r t r i d g e ,d e s i g n e db y B r i a nS t e e l e( a s e r v i c e t e c h n i c i a n

f o rs e v e r a ls c h o o l si n s o u t h e r nO n t a r i o ) ,w o u l dt u r no u tt o b e s o p o p u l a r .T h e

M i c r oS l e u t hw i l l t e s tt h eR A Mo f a C 6 4e v e ni f t h em a c h i n ei s t o os i c kt o r u na

p r o g r a m !T h ec a r t r i d g e t a k e sc o m p l e t ec o n t r o lo f t h em a c h i n e .I t t e s t sa l lR A Mi n

o n e m o d e ,a l l R O Mi n a n o t h e rm o d e , a n dp u t su p a m e n uw i t ht h e f o l l o w i n g

c h o i c e s :

1 ) C h e c kd r i v es p e e d

2 )C h e c kd r i v ea l i g n m e n t

3 ) 1 5 4 1S e r i a lt e s t

4 ) C 6 4s e r i a lt e s t

5 )J o y s t i c k p o r t1 t e s t

6 )J o y s t i c kp o r t2 t e s t

7 ) C a s s e t t ep o r tt e s t

8 ) U s e rp o r tt e s t

A s e c o n d b o a r d( i n c l u d e d ) p l u g so n t ot h eU s e rP o r t ;i t c o n t a i n s8 L E D st h a tl e t

y o uz e r oi n o n t h ef a u l t yc h i p .C o m p l e t ew i t hm a n u a l .

T r a n s a c t o rD i s k s ,T r a n s a c t o rB a c kI s s u e s ,a n dM i c r o f i c h e

A l l T r a n s a c t o r s s i n c eV o l u m e4 I s s u e 0 1 a r en o wa v a i l a b l eo n m i c r o f i c h e .

A c c o r d i n gt o C o m p u t r e x ,o u rf i c h em a n u f a c t u r e r ,t h es t r i p sa r et h e" p o p u l a r9 8

p a g es i z e " ,s o t h e ys h o u l d b e c o m p a t i b l ew i t he v e r yf i c h er e a d e r .S o m ei s s u e s a r e

O N L Ya v a i l a b l eo n m i c r o f i c h e- t h e s ea r em a r k e d" M Fo n l y " .T h eo t h e ri s s u e s

a r ea v a i l a b l ei n b o t h p a p e ra n df i c h e .D o n ' tc h e c kb o t h b o x e sf o rt h e s e u n l e s s

y o u w a n tb o t ht h ep a p e rv e r s i o nA N Dt h e m i c r o f i c h es l i c e f o rt h es a m ei s s u e .

T o k e e pt h i n g ss i m p l e ,t h e p r i c eo f T r a n s a c t o r M i c r o f i c h ei s t h e s a m ea s

m a g a z i n e s ,b o t hf o r s i n g l ec o p i e sa n ds u b s c r i p t i o n s ,w i t ho n ee x c e p t i o n :a

c o m p l e t es e to f 2 4 ( V o l u m e s4 , 5 ,6 , a n d7 ) w i l lc o s tj u s t$ 4 9 . 9 5U S ,$ 5 9 . 9 5C d n .

T h i sl i s ta l s os h o w st h e" t h e m e s "o f e a c hi s s u e .T h e m ei s s u e s d i d n ' ts t a r t u n t i l

V o l u m e5 , I s s u e 0 1 .T r a n s a c t o rD i s k* 1 c o n t a i n sa l l p r o g r a m s f r o mV o l u m e4 ,

a n dD i s k # 2c o n t a i n sa l lp r o g r a m s f r o mV o l u m e5 , I s s u e s1 - 3 .A f t e r w a r d st h e r ei s

a s e p a r a t e d i s kf o re a c hi s s u e .D i s k8 f r o mT h eL a n g u a g e sI s s u ec o n t a i n s

C O M A L0 . 1 4 ,a s o f t - l o a d e d ,s l i g h t l ys c a l e d - d o w nv e r s i o no f t h eC O M A L2 . 0

c a r t r i d g e .A n dV o l u m e6 , I s s u e0 5 l i s t st h e d i r e c t o r i e sf o rT r a n s a c t o rD i s k s1 t o 9 .

I V o l .4 , I s s u e0 1 ( ■ D i s k1 ) ■ V o l .4 , I s s u e0 4 - M Fo n l y

I V o l .4 , I s s u e0 2 ( ■ D i s k1 ) ■ V o l .4 , I s s u e0 5 -M Fo n l y

I V o l .4 , I s s u e0 3 ( ■ D i s k1 ) ■ V o l .4 , I s s u e0 6 - M Fo n l y

I V o l .5 , I s s u e0 1 - S o u n da n dG r a p h i c s

I V o l .5 , I s s u e0 2 -T r a n s i t i o nt o M a c h i n e L a n g u a g e- M Fo n l y

I V o l .5 , I s s u e0 3 -P i r a c ya n dP r o t e c t i o n- M Fo n l y

I V o l .5 , I s s u e0 4 -B u s i n e s s& E d u c a t i o n- M Fo n l y

I V o l .5 , I s s u e0 5- H a r d w a r e& P e r i p h e r a l s

I V o l .5 , I s s u e0 6- A i d s& U t i l i t i e s

I V o l .6 , I s s u e0 1 - M o r eA i d s& U t i l i t i e s

I V o l .6 , I s s u e0 2 - N e t w o r k i n g& C o m m u n i c a t i o n s

I V o l .6 , I s s u e0 3 -T h eL a n g u a g e s

I V o l .6 , I s s u e0 4 - I m p l e m e n t i n gT h eS c i e n c e s

I V o l .6 , I s s u e0 5 -H a r d w a r e& S o f t w a r eI n t e r f a c i n g |

I V o l .6 , I s s u e0 6 -R e a lL i f eA p p l i c a t i o n s

I V o l .7 , I s s u e0 1 - R O M/ K e r n e l R o u t i n e s

I V o l .7 , I s s u e0 2 -G a m e sF r o m T h eI n s i d eO u t

I V o l .7 , I s s u e0 3 -P r o g r a m m i n gT h eC h i p s

I V o l .7 , I s s u e0 4- G i z m o s a n dG a d g e t s

I V q I .7 , I s s u e0 5 - L a n g u a g e sI I

I V o l .7 , I s s u e0 6- S i m u l a t i o n sa n dM o d e l l i n g

I V o l .8 , I s s u e0 1 - M a t h e m a t i c s

I V o l .8 , I s s u e0 2 -O p e r a t i n gS y s t e m s

I V o l .8 , I s s u e0 3 -F e a t u r e :S u r g eP r o t e c t o r

I n d u s t r yN e w s

I D i s k1 )

I D i s k1 )

I D i s k1 )

I D i s k2 )

I D i s k2 )

I D i s k2 )

I D i s k3 )

I D i s k4 )

I D i s k5 )

I D i s k6 )

I D i s k7 )

I D i s k8 )

I D i s k9 )

D i s k1 0 )

D i s k1 1 )

D i s k1 2 )

D i s k1 3 )

D i s k1 4 )

D i s k1 5 )

D i s k1 6 )

D i s k1 7 )

D i s k1 8 )

D i s k1 9 )

D i s k2 0 )

T h ef o l l o w i n gi t e m sa r eb a s e do n p r e s sr e l e a s e sr e c e n t l yr e c e i v e df r o mt h e

m a n u f a c t u r e r s . P l e a s e n o t et h a tp r o d u c td e s c r i p t i o n sa r e n o t t h e r e s u l t o f

e v a l u a t i o nb yT h eT r a n s a c t o r .

A m i E X P Oi n N e wY o r kC i t y

O nO c t o b e r 1 0 , 1 9 8 7 ,A m i E X P O ,a s h o wd e d i c a t e de x c l u s i v e l yt o t h eA m i g aa n d

i t sa f t e r m a r k e t ,w i l lo p e nt o t h ep u b l i ci n N e wY o r kC i t y .

A m o n gt h e e x h i b i t o r s a r eA c t i v i s i o n ,s u b L o g i c ,C e n t r a lC o a s t ,B r o w n - W

A m a z i n eC o m p u t i n g ,A m i P r o j e c t , B y t eb y B y t e ,G o l dD i s k ,A m e r i s t a r ,M a n x

L a t t i c e ,O x x i ,a n da h o s to f o t h e r s .S o u n d sl i k ei t ' l lb e a g o o do n e !

I n f o r m a t i o no ns h o wh o u r sa n da d m i s s i o np r i c e sw e r en o t a v a i l a b l ea t t h i s t i m

F o rm o r ei n f o r m a t i o n , c o n t a c tA m i E X P OH e a d q u a r t e r s ,2 1 1E a s t4 3 r dS t r e e tS u i t e3 0 ] ,N e wY o r k ,N Y ,1 0 0 1 7 ,1 - 8 0 0 3 2A M I G A .I n N Yc a l l( 2 1 2 )8 6 7 - 4 6 6

S p e c i a lA m i g aS o f t w a r eO f f e r

C o m m o d o r eh a s a n n o u n c e da s p e c i a ls o f t w a r ep r o m o t i o nf o r C o m m o d

C o m p u t e rC l u b sa n dc e r t i f i e de d u c a t o r s .

C o m m o d o r eU s e rG r o u p sa n dt h e i rm e m b e r s ,p l u sc e r t i f i e dt e a c h e r sa n df a c u l t

m e m b e r so f C a n a d i a ns c h o o l s , c o l l e g e sa n du n i v e r s i t i e sp u r c h a s i n ga n yA m i g

c o m p u t e rb e t w e e nA u g u s t2 1 a n dO c t o b e r 3 1 , 1 9 8 7 ,w i l lb eo f f e r e d a s e l e co f

b r a n d - n a m es o f t w a r ep a c k a g e sf o ra f r a c t i o n o f t h e i ru s u a lr e t a i lp r i c e .

T h e" c r e a t i v i t ys o f t w a r e " p a c k a g e , w i t ha s u g g e s t e dr e t a i lv a l u eo fo v e r$ 7 5 0w i l l

b e a v a i l a b l ef o ro n l y$ 1 9 9 ,a n di n c l u d e s :

• D E L U X EP A I N TI I b yE l e c t r o n i cA r t s

• P A G E S E T T E R ,t h ed e s k t o pp u b l i s h i n gs y s t e m f r o m G o l dD i s k

• A E G I SA N I M A T O Rb yA e g i sD e v e l o p m e n t

• T E X T C R A F TP L U Sw o r dp r o c e s s o rf r o mC o m m o d o r e - A m i g a

• M A R B L EM A D N E S S ,t h ea r c a d eg a m e ,a l s ob y E l e c t r o n i cA r t s

• A 5 0 0 X Jj o y s t i c kf r o mE p y x

T h e" p r o d u c t i v i t ys o f t w a r e "p a c k a g e , s u g g e s t e dr e t a i lo v e r$ 1 4 0 0 ,w i l lb e

o f f e r e df o ro n l y $ 3 9 9 . T h i sp a c k a g ec o n t a i n s :

W O R DP E R F E C T ,a l e a d i n gw o r dp r o c e s s o rf r o mW o r dP e r f e c t

P A G E S E T T E RD E L U X Ed e s k t o pp u b l i s h i n gs y s t e mw i t hL a s e r s c r i p t ,F o n t s e tI ,

a n dH y p h e n a t i o nm o d u l e s ,b y G o l dD i s k( u p g r a d a b l et o P r o f e s s i o n a lP a g e ) .

S U P E R B A S EP E R S O N A L ,a n i n n o v a t i v ed a t a b a s ef r o mP r o g r e s s i v eP e r i p

e r a l sa n dS o f t w a r e

M A X I P L A N5 0 0 ,a m u l t i - t a s k i n gs p r e a d s h e e tp r o g r a mf r o mO x x iI n c .

D I G At e l e c o m m u n i c a t i o n sp r o g r a mf r o mA e g i s

D E L U X EV I D E Op r e s e n t a t i o nv i d e oa n dg r a p h i c ss y s t e m f r o mE l e c t r o n i cA r t s

C L I M A T E ,a n i c o ns h e l lf o rA m i g aD O Sf r o mP r o g r e s s i v e P e r i p a n d

S o f t w a r e

T h e s ec o m b i n a t i o nA m i g aa n ds o f t w a r eo f f e r s w i l lb e a v a i l a b l ei n m o r et h a n6 0 0

i n d e p e n d e n tr e t a i l ,a n dp a r t i c i p a t i n gC a n a d i a nT i r ea n dK - M a r ts t o r e sa c r o s

C a n a d a .T h ep r o m o t i o ni s a i m e da t i n f l u e n t i a lu s e r si n o u rt w om o s ti m p o r t a

m a r k e t s- h o m e / h o b b ya n de d u c a t i o n .

F o rm o r ei n f o r m a t i o n , p l e a s ec o n t a c t ,S t a n P a g o n i so r K a t h e r i n eD i m o p o u

C o m m o d o r eB u s i n e s sM a c h i n e s ,3 4 7 0P h a r m a c yA v e n u e ,A g i n c o u r t , O n

( 4 1 6 ) 4 9 9 - 4 2 9 2 .

B e n c h m a r kM o d u l a - 2f r o mO x x i ,I n c .

O x x i ,I n c .h a sb e g u ns h i p p i n gB e n c h m a r k ,a M o d u l a - 2d e v e l o p m e n t s yf o r

t h eA m i g a .T h ep a c k a g ei n c l u d e sa n i n t e g r a t e dc o m p i l e r ,l i n k e ra n dE M A C

b a s e de d i t o r ,a l o n gw i t hs e p a r a t e v e r s i o no f t h ec o m p i l e ra n dl i n k e r ,M o d u l a

s t a n d a r dl i b r a r i e sp l u sf u l lA m i g as u p p o r tl i b r a r i e s ,p r o f i l i n g ,c r o s s - r e f e

a n do t h e ru t i l i t i e s ,e x t e n s i v ed e m o s , a n dm o r et h a n7 0 0p a g e so fd o c u m e n t a

O x x ir e p o r ta v e r a g ec o m p i l a t i o ns p e e d so f 1 0 , 0 0 0l i n e sp e rm i n u t ew i t hb u r s t

s p e e d so fu pt o 3 0 , 0 0 0l i n e sp e rm i n u t e . T h e i rp r o p r i e t a r yl i n k e ri s c l a i m e dt o b e

s i m i l a r l yv e r yf a s tc o m p a r e dw i t h o t h e r h i g hl e v e ll a n g u a g e p a c k a g e a v a i l a b

f o rt h eA m i g a .B e n c h m a r kM o d u l a - 2i s s a i db yO x x it o g e n e r a t eo b j e c tc o d ef i l e s

o fc o m p a r a b l es i z ea n de x e c u t i o ns p e e dt o t h o s e c r e a t e db yt h eA z t e cC c o m p i l

f r o mM a n xS o f t w a r eS y s t e m sI n c .

T h eT r a n s a c t o r 7 8 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 81: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 81/84

I n a d d i t i o nt o t h e b a s i c$ 1 9 9( U S )p a c k a g e , t h r e ea d d - o np r o d u c t sa t $ 9 9w i l lb e

a v a i l a b l ea t t h et i m eo f B e n c h m a r k ' so f f i c i a lS e p t e m b e rr e l e a s e .T h e s ep r o d u c t s

w i l lh a v ee x t e n s i v ei n d e p e n d e n t d o c u m e n t a t i o na n de x a m p l e s ,b u tc a n o n l y b e

u s e di n c o n j u n c t i o n w i t ht h e b a s i cp a c k a g e .T h e ya r e :

• C L a n g u a g eS t a n d a r dL i b r a r y ,i n c l u d i n g v e r s i o n so f p r i n t f ,s c a n f ,f o p e n ,a n d

m a n yo t h e r s t a n d a r dC f u n c t i o n sf o re a s y p o r t i n go f C p r o g r a m st o M o d u l a - 2 .

• A s p e c i a l' s i m p l i f i e d 's e to f t h eA m i g as t a n d a r dl i b r a r i e s t oa l l o wq u i c k , p a i n l e s s

c r e a t i o no f I n t u i t i o nw i n d o w s ,s c r e e n s ,g a d g e t sa n dm e n u s ,p l u sc o n v e n i e n t

a c c e s st o t h e1 D C M P( I n t u i t i o n ' sm e s s a g ep o r t ) ,t h ec o n s o l ed e v i c e ,s p e e c h

s y n t h e s i s ,e t c .• I F FL i b r a r i e sa n da G r a p h i cI m a g eR e s o u r c eM a n a g e m e n tl i b r a r y / u t i l i t y .T h e s e

w i l la l l o wt h ep r o g r a m m e rt o p r o c e s s I F Ff i l e s ,a n dt o i n c l u d eg r a p h i c sd a t a ,i n

a n yo f t h r e ef o r m a t s ,w i t hp r o g r a mc o d ef o r f a s tr u n - t i m ea c c e s s .T h et h r e e

f o r m a t sc u r r e n t l ys u p p o r t e da r e I n t u i t i o n( B O B )f o r m a t ,S i m p l eS p r i t e sa n d

V i r t u a lS p r i t e s .

F o rf u r t h e ri n f o r m a t i o n ,c o n t a c tO x x iI n c . ,1 8 3 5 - AD a w n sW a y ,F u l l e r t o n ,

C a l i f o r n i a9 2 6 3 1 .T e l e p h o n e( 7 1 4 )9 9 9 - 6 7 1 0 .

D e s i g n T e x t ,f r o mD e s i g n T e c hB u s i n e s sS y s t e m sI n c .

D e s i g n T e x t , af u l l - f e a t u r e dW Y S I W Y G( W h a tY o uS e eI s W h a tY o uG e t )w o r d

p r o c e s s o rf o rt h eA m i g a ,i s s c h e d u l e dt o b e g i ns h i p p i n gO c t o b e r1 , 1 9 8 7 .T h e

p r o d u c tm a k e su s e

o ft h e

A m i g a ' ss t a n d a r dI n t u i t i o nu s e ri n t e r f a c e ,w i t h

e x t e n s i v eu s eo f g a d g e t s ,p u l l d o w nm e n u s( m o s tm e n uo p t i o n sa l s oh a v e

k e y b o a r ds h o r t c u t s )a n dw i n d o w s .F a s ts c r o l l i n go f t h et e x tc a n b e a c c o m p l i s h e d

e i t h e rf r o mt h e k e y b o a r do r w i t ht h e m o u s e ;h o r i z o n t a ls c r o l l i n gi s a l s o

s u p p o r t e db e y o n dt h es t a n d a r d8 0 c o l u m ns c r e e n w i d t h .B o t hi n t e r l a c ea n dn o n -

i n t e r l a c ed i s p l a y s a r ea v a i l a b l e .

D e s i g n T e x ta l l o w s f o r m a t t i n gi n m u l t i p l ec o l u m n s ,e d i t i n go f m u l t i p l ed o c u

m e n t si n m u l t i p l ew i n d o w ss i m u l t a n e o u s l y ,t a b u l a ri n p u to f f i g u r e s ,s e m i

a u t o m a t i ch y p h e n a t i o na n da s e l e c t i o no f t h i r t e e n8 x 8f o n t s ,e a c hw i t ha 1 2 x 2 4

e q u i v a l e n tf o rp r i n t e r o u t p u t .P r i n t i n gc a n b ed o n ei n u p t o f o u rp a s s e sf o r

a d d i t i o n a lr e s o l u t i o n .I F FG r a p h i c sm a yb e f r e e l yi n t e r s p e r s e dw i t ht e x t ,a n d

n o r m a lp r i n t i n gc a n b ei n t e r s p e r s e d w i t ht h eb i t - m a p p e dp r i n t i n gu s e df o rt h e

s p e c i a lD e s i g n T e x tf o n t s .

A m o n gt h em a n yo t h e rs p e c i a l f e a t u r e so f D e s i g n T e x ta r ea u t o m a t i c i n d e xa n d

f o o t n o t e g e n e r a t i o n ,w i d o wa n d o r p h a nc o n t r o l , s p e c i a l d r i v e r sf o r p o p u l a r

p r i n t e r s ,a l l o w i n gu p t o 2 9 2d o t s p e ri n c h ,t h e a b i l i t y t oi m p o r tT e x t C r a f t ,

S c r i b b l ea n d A s c i if i l e s ,t w os p e l l - c h e c k i n gm o d e s( r e a l - t i m ea n d w h o l e -

d o c u m e n t ) , c o m p l e t eo n - l i n eh e l p ,a n do p t i o n a lt e r m i n a lm o d u l e s .

A p a r t f r o m D e s i g n T e x ti t s e l f ,t h ep a c k a g ea l s oi n c l u d e sa n e a s y - t o - u s ed a t ab a s e

c a l l e dP e o p l e B a s e .P e o p l e B a s ei s f u l l yi n t e g r a t e dw i t hD e s i g n T e x ta n dc a n b e

c a l l e da s am e n us e l e c t i o nf r o mw i t h i nt h ew o r dp r o c e s s o r .I t o f f e r sf o r ml e t t e r

a n dL i t t l eB l a c kB o o kg e n e r a t i o n ,a d d r e s sl i s ta n dm a i l i n gl a b e l p r i n t i n g , c l i e n t

c o n t a c tu p d a t i n g ,m u l t i p l es e a r c hc r i t e r i a ,a n df i l es e c u r i t y .

D e s i g n T e x tw i l ls e l lf o r$ 7 9( U S )f o ra d v a n c eo r d e r s ,a n da t t h er e g u l a rp r i c eo f

$ 1 2 9( U S )u p o nr e l e a s e .F o rm o r ei n f o r m a t i o n ,c o n t a c tD e s i g n T e c hB u s i n e s s

S y s t e m sI n c . ,# 3 0 4 - 8 5 0B u r r a r dS t r e e t ,V a n c o u v e r ,B r i t i s hC o l u m b i a V 6 Z 2 J 1 ,

C a n a d a ;o r t e l e p h o n e( 6 0 4 )6 6 9 - 1 8 5 5 .

J F o r t h ,f r o mD e l t aR e s e a r c hI n c .

D e l t aR e s e a r c h h a sa n n o u n c e dJ F o r t hf o rt h eA m i g a ,a s o f t w a r ed e v e l o p m e n t

e n v i r o n m e n t b a s e do n t h e F o r t h' 8 3s t a n d a r d .T h eF I Ga n dF o r t h - 7 9s t a n d a r d s

a r e a l s os u p p o r t e d .S p e c i a lt o o l b o x e ss i m p l i f yd e v e l o p m e n tf o r t h eA m i g a .

C o m p l e t e da p p l i c a t i o n sc a nb e ' t u r n k e y e d 'a n dd i s t r i b u t e dw i t h o u tr o y a l t i e s .

J F o r t h ' sc o d ei s c l a i m e dt o b e c o m p a r a b l ei n s p e e dt o C . P r o g r a m sa r ec o m p i l e d

d i r e c t l y i n t om a c h i n ec o d e ,u n l i k em o s tF o r t h s ,w h i c hi n t e r p r e tt o k e n sa t r u n

t i m e .

J F o r t hi s a n i n t e r a c t i v ee n v i r o n m e n t a n da c o m p i l e r .A n ys u b r o u t i n e ,v a r i a b l e ,

c o n s t a n to rd a t as t r u c t u r ec a n b et e s t e dd i r e c t l yf r o mt h ek e y b o a r d .B yc o m p i l i n g

i n c r e m e n t a l l y ,o n e c a n m o d i f ya p r o g r a m ,c o m p i l e ,l i n ka n dt e s t i ns e c o n d s .

U t i l i t i e si n c l u d e a6 8 0 0 0a s s e m b l e ra n dd i s a s s e m b l e r ,s e a r c ha n ds o r tr o u t i n e s ,

l o c a lv a r i a b l e s ,a n df l o a t i n g p o i n t .A m i g as t r u c t u r e sa n dc o n s t a n t s a r e p r e d e

i n " . j "f i l e sc o r r e s p o n d i n gt o t h e" . h "f i l e su s e di n C . A m i g al i b r a r yr o u t i n e s a r e

c a l l e db y n a m e .A n O b j e c tO r i e n t e dD e v e l o p m e n t E n v i r o n m e n t i s a l s o

i n c l u d e d .E x a m p l ep r o g r a m sd e m o n s t r a t eg r a p h i c s ,H A Mm o d e ,s p e e c hs y n t h e

s i s ,p u l l - d o w nm e n u s ,e t c .S o u r c ec o d ef o rm o s to f t h es y s t e mi s i n c l u d e d .

J F o r t hi s g e n e r a lp u r p o s ea n dc a nb e u s e dt o d e v e l o p g a m e s ,b u s i n e s sa p p l i c a

t i o n s ,m u s i cs y s t e m ,e t c .J F o r t hw i l lr u na b o u tf o u rt i m e sf a s t e ro n A m i g a s

e q u i p p e dw i t ha 1 7M H z6 8 0 2 0p r o c e s s o r .T h i sm a k e si t s u i t a b l ef o ru s ei n C P U -

i n t e n s i v ee n g i n e e r i n ga p p l i c a t i o n s .

J F o r t hi s a v a i l a b l e a ta n i n t r o d u c t o r yp r i c eo f $ 9 9 . 9 5U S .C o n t a c t : D e l

R e s e a r c h ,2 0 1 DS t r e e t ,S u i t e1 5 ,S a nR a f a e l ,C a l i f o r n i a9 4 9 0 1 ,( 4 1 5 )4 8 5 - 6 8 6 7 .

L e x C h e c k , f r o m C . D . AI n c .

C D . A .I n c .h a s a n n o u n c e dL e x C h e c k ,a s p e l l i n gc h e c k e rf o r t h e A m i g a .

L e x C h e c k w o r k sw i t hT e x t c r a f t ,S c r i b b l e !a n dN o t e p a df o r m a t t e df i l e sa s w e l la s

a l lA S C I It e x tf i l e s .T h em a s t e rd i c t i o n a r yc o n t a i n s1 0 0 , 0 0 0 w o r d sa n d y o um a y

a d dy o u ro w nw o r d st o t h ea u x i l i a r yd i c t i o n a r i e s .B e c a u s et h ed i c t i o n a r ya l w a y s

r e s i d e so n d i s k ,L e x C h e c ku s e sl e s st h a n1 0 0 Ko f R A M ,a n dt h u sc a nb e r u n

s i m u l t a n e o u s l yw i t hm o s tw o r dp r o c e s s o r s .

I n a d d i t i o nt o s t a n d a r dE n g l i s h v o c a b u l a r y ,L e x C h e c ka l s or e c o g n i z e sa w i d e

v a r i e t yo f p r o p e rn a m e s ,p l a c en a m e sa n dt e c h n i c a lt e r m s . C . D . A .r e p o r t s t h a ta

t w o - p a g e d o c u m e n tc a n b e c h e c k e di n u n d e r o n em i n u t e .

L e x C h e c kr u n su n d e rW o r k b e n c h1 . 2 ,a n dr e t a i l sf o r$ 4 2 . 9 5( U S ) .C o n t a c t

C . D . A .I n c . ,P . O .B o x1 0 5 2 ,Y r e k a , C a l i f o r n i a9 6 0 9 7 ,t e l e p h o n e ( 9 1 6 ) 8 4 2

V i d e o S c a p e3 D ,f r o mA e g i sD e v e l o p m e n tI n c .

A e g i s h a sr e l e a s e dV i d e o S c a p e3 D ,a s e to f t h r e ep r o g r a m sf o rt h eA m i g at h a t

p e r m i tt h e c r e a t i o no f 3 - Dt e l e v i s i o n q u a l i t yg r a p h i c sa n da n i m a t i o n s .T h e

p a c k a g er e q u i r e s am i n i m u mo f 5 1 2 KR A M ,w i t hm o r ep r e f e r r e d .

T h et h r e ep r o g r a m st h a tm a k eu p t h ep a c k a g ei n c l u d eD e s i g n e r 3 D ,f o rm a k i n g

3 Do b j e c t s ;P l a y A N I M ,f o rp l a y i n gb a c ka n i m a t i o n si n r e a lt i m e ;a n d V i d e o S c a

3 D ,f o rm a k i n gt h ef i n i s h e d v i d e o , p l u su t i l i t i e sf o rc r e a t i n gc o m m o ng e o m e t r i c

s h a p e s s u c ha s s p h e r e s , c o n e s ,r e c t a n g l e sa n df r a c t a ll a n d s c a p e s .

3 Do b j e c t sa r e c r e a t e de i t h e rb y n u m e r i ce n t r yo fX ,Y ,Z c o o r d i n a t e s , o rb y o n eo f

t h e s u p p l i e du t i l i t i e s ,o r b y u s i n gD e s i g n e r3 D ' st h r e e - w i n d o w e dp o i n t - a n d -

c l i c km e t h o d . W i t hD 3 D ,t h e r ea r et h r e ew i n d o w sr e p r e s e n t i n g t h ef r o n t ,s i d e ,

a n dt o pv i e wo fy o u ro b j e c ta s y o uc r e a t ei t . S c a l i n g ,n u m e r i cv a l u ed i s p l a y ,a n d

n u m e r i ce n t r y h e l p m a i n t a i na c c u r a c ya s t h eo b j e c ti s d r a w n .W h e nf i n i s h e d ,a

m o t i o nf i l ec a n b el o a d e da n dt h eo b j e c ti s p a s s e dt o t h ep r e v i e ww i n d o w .H e r e ,

i n r e a lt i m e , t h e o b j e c tc a n b es h o w ni n m o t i o n f r o ma l ls i d e s .E a c hf r a m eo f t h e

m o t i o nf i l ei s r e c o r d e di n R A Ma n dp l a y e db a c ka t a n a d j u s t a b l es p e e d .

O n c et h eo b j e c t sa r e c r e a t e d ,t h e ya r el o a d e di n t oV i d e o S c a p e ' sm a i nc o n t r o l

p a n e l .H e r et h es c e n e sa r e p u tt o g e t h e r . D e t a i l sr e g a r d i n gc a m e r a a n do b j e c t

m o t i o n ,b a c k g r o u n d s ,f o r e g r o u n d s ,h o r i z o na n do t h e r i n f o r m a t i o na r ed e t e r

m i n e d ,a n da c o m p l e t e s c e n ei s c r e a t e d .A V C Rc a nb e h o o k e du p t o r e c o r dt h e

s c e n eo n ef r a m ea t a t i m e , o r af e w s e c o n d sa t a t i m e u s i n gt h eP l a y A N I M

m o d u l e .

T oc r e a t ea n A N I Mf i l er e q u i r e sa t l e a s to n em e g a b y t eo f R A M ;h o w e v e r ,m a n y

A N I M sw i l lp l a yb a c k o na 5 1 2 KA m i g a .A n A N I Mf i l ec a n c o m p r e s sa 4 0 Kf r a m e

i n t ol e s st h a nI K .T h eA N I Mc o m p r e s s e df i l ef o r m a ti s a v a i l a b l ea t n oc h a r g et o

i n t e r e s t e dp a r t i e s .

V i d e o S c a p e3 D ,$ 1 9 9 . 9 5( U S )f r o mA e g i sD e v e l o p m e n tI n c . ,2 2 1 0W i l s h i r e# 2 7 7 ,

S a n t a M o n i c a ,C a l i f o r n i a ,t e l e p h o n e( 2 1 3 )3 9 2 - 9 9 7 2 .

T h eT r a n s a c t o r 7 9 N o v e m b e r1 9 8 7 :V o l u m e8 , I s s u eO 3

Page 82: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 82/84

N e w !I m p r o v e d !

T R A N S B A S I C2 !

w i t hS Y M A S S 1

" I u s e dt o b e s o a s h a m e do f m yd u l l ,m e s s yc o d e ,b u t

n o m a t t e rw h a tI t r i e dI j u s tc o u l d n ' t g e tr i d o f t h o s e

s t u b b o r ns p a g h e t t is t a i n s ! "w r i t e sM r s .J e n n yR . o f

R i c h m o n dH i l l ,O n t a r i o ." T h e nt h eT r a n s a c t o rp e o p l e

a s k e dm e t o t r yn e wT r a n s B A S I C2 , w i t hS y m a s s 8 .

T h e ye x p l a i n e dh o wT r a n s B A S I C2 , w i t hi t s s c o r e so f

t i n y' t o k e n s ' ,w o u l dg e tm yc o d el o o k i n g c l e a n ,f a s t !

" I w a ss c e p t i c a l ,b u t I f i g u r e dt h e r ew a sn o h a r mi n

g i v i n gi t a t r y .W e l l ,a l l i t t o o kw a so n el o a da n dI w a s

c o n v i n c e d !T r a n s B A S I C2 w e n tt o w o r ka n dg o t m y

c o d el o o k i n gc l e a na s n e wi n s e c o n d s !N o wI ' mt e l l i n g

a l lm yf r i e n d st o t r yT r a n s B A S I C2 i n t h e i rm a c h i n e s ! "

T r a n s B A S I C2 , w i t hS y m a s s ,t h e s y m b o l i ca s s e m b l e r .

P a c k a g ec o n t a i n sa l l 1 2 s e t so f T r a n s B A S I Cm o d u l e s

f r o mt h em a g a z i n e ,p l u sf u l ld o c u m e n t a t i o n .M a k ey o u r

B A S I Cp r o g r a m sr u nf a s t e ra n db e t t e rw i t ho v e r1 4 0

a d d e ds t a t e m e n ta n df u n c t i o nk e y w o r d s .

D i s ka n d M a n u a l$ 1 7 . 9 5U S ,$ 1 9 . 9 5C d n .

( s e eo r d e r c a r da t c e n t e ra n dN e w sB R Kf o rm o r ei n f o )

T r a n s B A S I C2" C l e a n e rc o d e ,l o a da f t e rl o a d ! "

B i t s& P i e c e sI :

T h eD i s

F r o mt h ef a m o u sb o o ko f t h es a m en a m e ,T r a n s a c

P r o d u c t i o n sn o wb r i n g sy o uB i t s& P i e c e sI : T h eD i s k

Y o u ' l lt h r i l lt o t h e s p e c i a le f f e c t so f t h e s c r e e

d a z z l e r s !Y o u ' l ll a u g ha t t h e h o u r so f t y p i n gt i m

y o u ' l ls a v e !Y o u ' l lb e i n s p i r e da s y o u b o l d l yg ow h e r en o b i t sh a v eg o n eb e f o r e !

" E x t r a o r d i n a r i l yf a i t h f u lt o t h ep l o t

o f t h e b o o k .. . T h eB A Ma l o n ei s

w o r t ht h ep r i c eo f a d m i s s i o n ! "

V i n c e n tC a n b y t e

" A b s o l u t

m a g n e t i c

G e n eS y s c a l

" I fy o u m o u n to n l yo n eb i t sd i s ki n 1 9 8 7 ,m a k ei t t h i s

o n e !T h ef u l l yc r o s s - r e f e r e n c e di n d e xi s u n f o r g e t t a b

R e c sR e a d ,N e wY o r kT I S

W A R N I N G :S o m es e c t o r sc o n t a i nn u l lb y t e s .R a t e dG C R

B I T SS P I E C E SI : T H ED I S K ,A M y l a rF i l m ,i n a s s o c i a t i o nw i t hT r a n s a c t o rP r o d u c t i

P l a y i n ga t a d r i v en e a ry o u !

D i s kS 8 . 9 5U S , S 9 . 9 5C d n .B o o k$ 1 4 . 9 5U S ,$ 1 7 . 9 5C d n

B o o k& D i s kC o m b oJ u s t$ 1 9 . 9 5 U S ,$ 2 4 . 9 5C d n !

Page 83: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 83/84

T H ET I M ES A V E

T y p ei n a l o to f T r a n s a c t o rp r o g r a m s ?•

D o e st h ea b o v et i m ea n da p p e a r a n c eo f t h es k yl o o kf a m i l i a r ?

W i t hT h eT r a n s a c t o rD i s k ,a n yp r o g r a m - i sj u s ta L O A Da w a y !

O n l y$ 8 . 9 5U S ,$ 9 . 9 5C d n .P e rI s s u e6 D i s kS u b s c r i p t i o n( o n e y e a r )

J u s t$ 4 5 . 0 0U S ,$ 5 5 . 0 0C d n .

( s e eo r d e rf o r ma t c e n t e rf o l d )

N o wA m i g aO w n e r sC a nS a v eT i m eT o o !T r a n s a c t o rA m i g aD i s k# 1 ,$ 1 2 . 9 5U S ,$ 1 4 . 9 5C d n .

A Ht h eA m i g ap r o g r a m s f r o mt h em a g a z i n e , w i t h c o m p l e t ed o c u m e n t a t i o no n d i s k ,p l u so u rp i c k o ft h e p u b l i cd o m a i n !

Page 84: The Transactor V8 03 1987 Nov

8/7/2019 The Transactor V8 03 1987 Nov

http://slidepdf.com/reader/full/the-transactor-v8-03-1987-nov 84/84

T H EW O R L DO F

C O M M O


Recommended